need to know the buffer configuration to slint ui #5294
Replies: 6 comments
-
#![no_std] extern crate alloc; use alloc::{rc::Rc, boxed::Box}; fn create_slint_app() -> AppWindow {
} use rp_pico as bsp; use bsp::entry; use display_interface_spi::SPIInterface; use bsp::hal::{ use bsp::hal::prelude::*; #[entry]
} pub fn exit() -> ! { |
Beta Was this translation helpful? Give feedback.
-
Thank you for taking the time to report your issue with Slint! What is the problem here? Maybe you could put the code into a repo on Github or elsewhere and put a link to that repo here? It is way easier to just check out something than to copy/paste things into possibly multiple files. The missing Cargo.toml makes it even harder to just try this out. A short description of what you actually observe and what you expect to happen instead would also help. |
Beta Was this translation helpful? Give feedback.
-
i have tried to use https://docs.rs/gc9a01a/latest/gc9a01a/ it is working fine with draw line by line - but when trying to use buffer - embedded hal - not able to know how to // ... configure the screen driver to use buffer1 or buffer2 ... in the docs of mcu |
Beta Was this translation helpful? Give feedback.
-
[dependencies] |
Beta Was this translation helpful? Give feedback.
-
Do you have enough memory to drive a buffer on the rp-pico? |
Beta Was this translation helpful? Give feedback.
-
yes i have, i feel my configuration to make it work is having a trouble. let me update and let you know on this. |
Beta Was this translation helpful? Give feedback.
-
#![no_std]
#![no_main]
extern crate alloc;
use alloc::{rc::Rc, boxed::Box};
slint::include_modules!();
fn create_slint_app() -> AppWindow {
let ui = AppWindow::new().expect("Failed to load UI");
}
use rp_pico as bsp;
use bsp::entry;
use fugit::RateExtU32;
use display_interface_spi::SPIInterface;
use embedded_graphics::prelude::*;
use embedded_graphics::{
pixelcolor::Rgb565,
primitives::{Circle, PrimitiveStyleBuilder, Rectangle, Triangle},
};
use bsp::hal::{
clocks::{init_clocks_and_plls, Clock},
gpio, pac, pwm,
sio::Sio,
spi,
watchdog::Watchdog,
};
use bsp::hal::prelude::*;
use gc9a01a;
use panic_halt as _;
use slint::platform::{Platform, software_renderer::MinimalSoftwareWindow};
use slint::platform::software_renderer::Rgb565Pixel;
#[entry]
fn main() -> ! {
use bsp::hal;
use embedded_hal::timer;
// Pull in any important traits
use fugit::RateExtU32;
use slint::platform::WindowEvent;
}
pub fn exit() -> ! {
loop {
cortex_m::asm::bkpt();
}
}
[dependencies]
embedded-hal = { version = "0.2.7", features = ["unproven"]}
embedded-alloc = "0.5"
embedded-graphics-core ="0.4.0"
display-interface ="0.4.1"
display-interface-spi = "0.4.1"
gc9a01a = "0.1.1"
cortex-m = "0.7"
cortex-m-rt = "0.7"
panic-halt = "0.2"
tinybmp = "0.5"
embedded-graphics = "0.8.0"
rp-pico = "0.7"
fugit = "0.3"
[dev-dependencies]
cortex-m = "0.7"
cortex-m-rt = "0.7"
panic-halt = "0.2"
tinybmp = "0.5"
embedded-graphics = "0.8.0"
rp-pico = "0.7"
fugit = "0.3"
[dependencies.slint]
version = "1.6.0"
default-features = false
features = ["compat-1-2", "unsafe-single-threaded", "libm", "renderer-software"]
[build-dependencies]
slint-build = "1.6.0"
Beta Was this translation helpful? Give feedback.
All reactions