mirror of
https://github.com/Anshorei/epd-waveshare.git
synced 2026-10-03 22:06:43 +00:00
add error messages for debugging
This commit is contained in:
+2
-2
@@ -257,7 +257,7 @@ where
|
|||||||
}
|
}
|
||||||
|
|
||||||
fn clear_frame(&mut self, spi: &mut SPI) -> Result<(), SPI::Error> {
|
fn clear_frame(&mut self, spi: &mut SPI) -> Result<(), SPI::Error> {
|
||||||
self.send_resolution(spi)?;
|
self.send_resolution(spi).expect("resolution error");
|
||||||
|
|
||||||
//let size = WIDTH as usize / 8 * HEIGHT as usize;
|
//let size = WIDTH as usize / 8 * HEIGHT as usize;
|
||||||
let color_value = self.color.get_byte_value();
|
let color_value = self.color.get_byte_value();
|
||||||
@@ -267,7 +267,7 @@ where
|
|||||||
spi,
|
spi,
|
||||||
Command::DATA_START_TRANSMISSION_1,
|
Command::DATA_START_TRANSMISSION_1,
|
||||||
&[color_value; WIDTH as usize / 8 * HEIGHT as usize]
|
&[color_value; WIDTH as usize / 8 * HEIGHT as usize]
|
||||||
)?;
|
).expect("data trans 1 error");
|
||||||
|
|
||||||
//TODO: Removal of delay. TEST!
|
//TODO: Removal of delay. TEST!
|
||||||
//self.delay_ms(2);
|
//self.delay_ms(2);
|
||||||
|
|||||||
Reference in New Issue
Block a user