mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-19 09:00:54 +00:00
remove buffer swap calls
we now go between a ram-based compositing buffer and the hw buffer which effectively gives us our double buffer
This commit is contained in:
parent
216ff46e29
commit
729a0ca6b9
1 changed files with 1 additions and 8 deletions
|
|
@ -119,7 +119,6 @@ pub fn process_update(perclk: u32) {
|
||||||
gfx::msg(&mut sh1107, " START to boot", Point::new(0, 16), Mono::White.into(), Mono::Black.into());
|
gfx::msg(&mut sh1107, " START to boot", Point::new(0, 16), Mono::White.into(), Mono::Black.into());
|
||||||
gfx::msg(&mut sh1107, " SELECT to update", Point::new(0, 0), Mono::White.into(), Mono::Black.into());
|
gfx::msg(&mut sh1107, " SELECT to update", Point::new(0, 0), Mono::White.into(), Mono::Black.into());
|
||||||
|
|
||||||
sh1107.buffer_swap();
|
|
||||||
sh1107.draw();
|
sh1107.draw();
|
||||||
|
|
||||||
// setup IO pins to check for update viability
|
// setup IO pins to check for update viability
|
||||||
|
|
@ -144,7 +143,6 @@ pub fn process_update(perclk: u32) {
|
||||||
|
|
||||||
if do_update {
|
if do_update {
|
||||||
gfx::msg(&mut sh1107, "Connect to USB", Point::new(16, 64), Mono::White.into(), Mono::Black.into());
|
gfx::msg(&mut sh1107, "Connect to USB", Point::new(16, 64), Mono::White.into(), Mono::Black.into());
|
||||||
sh1107.buffer_swap();
|
|
||||||
sh1107.draw();
|
sh1107.draw();
|
||||||
|
|
||||||
crate::platform::cramium::usb::init_usb();
|
crate::platform::cramium::usb::init_usb();
|
||||||
|
|
@ -218,7 +216,6 @@ pub fn process_update(perclk: u32) {
|
||||||
Mono::Black.into(),
|
Mono::Black.into(),
|
||||||
Mono::White.into(),
|
Mono::White.into(),
|
||||||
);
|
);
|
||||||
sh1107.buffer_swap();
|
|
||||||
sh1107.draw();
|
sh1107.draw();
|
||||||
last_usb_state = new_usb_state;
|
last_usb_state = new_usb_state;
|
||||||
}
|
}
|
||||||
|
|
@ -279,7 +276,6 @@ pub fn process_update(perclk: u32) {
|
||||||
Mono::White.into(),
|
Mono::White.into(),
|
||||||
Mono::Black.into(),
|
Mono::Black.into(),
|
||||||
);
|
);
|
||||||
sh1107.buffer_swap();
|
|
||||||
sh1107.draw();
|
sh1107.draw();
|
||||||
sh1107.clear();
|
sh1107.clear();
|
||||||
return;
|
return;
|
||||||
|
|
@ -467,7 +463,6 @@ pub fn process_update(perclk: u32) {
|
||||||
Mono::White.into(),
|
Mono::White.into(),
|
||||||
Mono::Black.into(),
|
Mono::Black.into(),
|
||||||
);
|
);
|
||||||
sh1107.buffer_swap();
|
|
||||||
sh1107.draw();
|
sh1107.draw();
|
||||||
sh1107.clear();
|
sh1107.clear();
|
||||||
return;
|
return;
|
||||||
|
|
@ -490,12 +485,11 @@ pub fn process_update(perclk: u32) {
|
||||||
}
|
}
|
||||||
|
|
||||||
gfx::msg(&mut sh1107, " Booting Xous...", Point::new(0, 64), Mono::White.into(), Mono::Black.into());
|
gfx::msg(&mut sh1107, " Booting Xous...", Point::new(0, 64), Mono::White.into(), Mono::Black.into());
|
||||||
sh1107.buffer_swap();
|
|
||||||
sh1107.draw();
|
sh1107.draw();
|
||||||
sh1107.clear();
|
sh1107.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
struct UsizeToString {
|
pub struct UsizeToString {
|
||||||
buf: [u8; 16], // Enough space for a u32 decimal string
|
buf: [u8; 16], // Enough space for a u32 decimal string
|
||||||
pos: usize,
|
pos: usize,
|
||||||
}
|
}
|
||||||
|
|
@ -525,7 +519,6 @@ fn progress_bar(sh1107: &mut Oled128x128<'_>, percentage: usize) {
|
||||||
let mut usizestr = UsizeToString::new();
|
let mut usizestr = UsizeToString::new();
|
||||||
write!(usizestr, "{}%", percentage).ok();
|
write!(usizestr, "{}%", percentage).ok();
|
||||||
gfx::msg(sh1107, usizestr.as_str(), Point::new(55, 26), Mono::Black.into(), Mono::White.into());
|
gfx::msg(sh1107, usizestr.as_str(), Point::new(55, 26), Mono::Black.into(), Mono::White.into());
|
||||||
sh1107.buffer_swap();
|
|
||||||
sh1107.draw();
|
sh1107.draw();
|
||||||
sh1107.clear();
|
sh1107.clear();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue