mirror of
https://github.com/Anshorei/epd-waveshare.git
synced 2026-10-03 22:06:43 +00:00
Mainly improved Documenation
This commit is contained in:
+3
-18
@@ -27,8 +27,11 @@ mod graphics;
|
||||
#[cfg(feature = "graphics")]
|
||||
pub use self::graphics::Display7in5;
|
||||
|
||||
/// Width of the display
|
||||
pub const WIDTH: u32 = 800;
|
||||
/// Height of the display
|
||||
pub const HEIGHT: u32 = 480;
|
||||
/// Default Background Color
|
||||
pub const DEFAULT_BACKGROUND_COLOR: Color = Color::White;
|
||||
const IS_BUSY_LOW: bool = true;
|
||||
|
||||
@@ -87,24 +90,6 @@ where
|
||||
DC: OutputPin,
|
||||
RST: OutputPin,
|
||||
{
|
||||
/// Creates a new driver from a SPI peripheral, CS Pin, Busy InputPin, DC
|
||||
///
|
||||
/// This already initialises the device. That means [init()] isn't needed
|
||||
/// directly afterwards.
|
||||
///
|
||||
/// [init()]: InternalWiAdditions::init
|
||||
///
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust,ignore
|
||||
/// //buffer = some image data;
|
||||
///
|
||||
/// let mut epd7in5 = EPD7in5::new(spi, cs, busy, dc, rst, delay);
|
||||
///
|
||||
/// epd7in5.update_and_display_frame(&mut spi, &buffer);
|
||||
///
|
||||
/// epd7in5.sleep();
|
||||
/// ```
|
||||
fn new<DELAY: DelayMs<u8>>(
|
||||
spi: &mut SPI,
|
||||
cs: CS,
|
||||
|
||||
Reference in New Issue
Block a user