Struct esp_ward::display::pcd8544::Pcd8544Display

source ·
pub struct Pcd8544Display<CLK: OutputPin, DIN: OutputPin, DC: OutputPin, CE: OutputPin, RST: OutputPin, BL: OutputPin> {
    pub inner: PCD8544<CLK, DIN, DC, CE, RST, BL>,
}
Expand description

Represents a PCD8544 display and provides methods to interact with it.

Fields§

§inner: PCD8544<CLK, DIN, DC, CE, RST, BL>

The underlying PCD8544 driver instance.

Implementations§

source§

impl<CLK: OutputPin<Error = Infallible>, DIN: OutputPin<Error = Infallible>, DC: OutputPin<Error = Infallible>, CE: OutputPin<Error = Infallible>, RST: OutputPin<Error = Infallible>, BL: OutputPin<Error = Infallible>> Pcd8544Display<CLK, DIN, DC, CE, RST, BL>

source

pub fn create_on_pins( pin_clk: CLK, pin_data: DIN, pin_dc: DC, pin_ce: CE, pin_rst: RST, pin_backlight: BL ) -> Pcd8544Display<CLK, DIN, DC, CE, RST, BL>

Creates and initializes a new Pcd8544Display.

§Arguments
  • pin_clk - Clock pin.
  • pin_data - Data input pin.
  • pin_dc - Data/command mode select pin.
  • pin_ce - Chip enable pin.
  • pin_rst - Reset pin.
  • pin_backlight - Backlight control pin.
§Returns

A Pcd8544Display instance ready to be used.

Trait Implementations§

source§

impl<CLK: OutputPin<Error = Infallible>, DIN: OutputPin<Error = Infallible>, DC: OutputPin<Error = Infallible>, CE: OutputPin<Error = Infallible>, RST: OutputPin<Error = Infallible>, BL: OutputPin<Error = Infallible>> Display for Pcd8544Display<CLK, DIN, DC, CE, RST, BL>

source§

fn set_pixel(&mut self, x: usize, y: usize)

Sets a pixel on the display at the specified coordinates.

§Arguments
  • x - The x coordinate of the pixel.
  • y - The y coordinate of the pixel.
source§

fn reset(&mut self)

Resets the display

source§

fn write_str(&mut self, str: &str)

Writes a string to the display.

§Arguments
  • str - The string to be written on the display.

Auto Trait Implementations§

§

impl<CLK, DIN, DC, CE, RST, BL> Freeze for Pcd8544Display<CLK, DIN, DC, CE, RST, BL>
where CLK: Freeze, DIN: Freeze, DC: Freeze, CE: Freeze, RST: Freeze, BL: Freeze,

§

impl<CLK, DIN, DC, CE, RST, BL> RefUnwindSafe for Pcd8544Display<CLK, DIN, DC, CE, RST, BL>
where CLK: RefUnwindSafe, DIN: RefUnwindSafe, DC: RefUnwindSafe, CE: RefUnwindSafe, RST: RefUnwindSafe, BL: RefUnwindSafe,

§

impl<CLK, DIN, DC, CE, RST, BL> Send for Pcd8544Display<CLK, DIN, DC, CE, RST, BL>
where CLK: Send, DIN: Send, DC: Send, CE: Send, RST: Send, BL: Send,

§

impl<CLK, DIN, DC, CE, RST, BL> Sync for Pcd8544Display<CLK, DIN, DC, CE, RST, BL>
where CLK: Sync, DIN: Sync, DC: Sync, CE: Sync, RST: Sync, BL: Sync,

§

impl<CLK, DIN, DC, CE, RST, BL> Unpin for Pcd8544Display<CLK, DIN, DC, CE, RST, BL>
where CLK: Unpin, DIN: Unpin, DC: Unpin, CE: Unpin, RST: Unpin, BL: Unpin,

§

impl<CLK, DIN, DC, CE, RST, BL> UnwindSafe for Pcd8544Display<CLK, DIN, DC, CE, RST, BL>
where CLK: UnwindSafe, DIN: UnwindSafe, DC: UnwindSafe, CE: UnwindSafe, RST: UnwindSafe, BL: UnwindSafe,

Blanket Implementations§

§

impl<T> Any for T
where T: 'static + ?Sized,

§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Az for T

source§

fn az<Dst>(self) -> Dst
where T: Cast<Dst>,

Casts the value.
§

impl<T> Borrow<T> for T
where T: ?Sized,

§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
§

impl<T> BorrowMut<T> for T
where T: ?Sized,

§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<Src, Dst> CastFrom<Src> for Dst
where Src: Cast<Dst>,

source§

fn cast_from(src: Src) -> Dst

Casts the value.
source§

impl<T> CheckedAs for T

source§

fn checked_as<Dst>(self) -> Option<Dst>
where T: CheckedCast<Dst>,

Casts the value.
source§

impl<Src, Dst> CheckedCastFrom<Src> for Dst
where Src: CheckedCast<Dst>,

source§

fn checked_cast_from(src: Src) -> Option<Dst>

Casts the value.
§

impl<T> From<T> for T

§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T, U> Into<U> for T
where U: From<T>,

§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

source§

impl<T> OverflowingAs for T

source§

fn overflowing_as<Dst>(self) -> (Dst, bool)
where T: OverflowingCast<Dst>,

Casts the value.
source§

impl<Src, Dst> OverflowingCastFrom<Src> for Dst
where Src: OverflowingCast<Dst>,

source§

fn overflowing_cast_from(src: Src) -> (Dst, bool)

Casts the value.
source§

impl<T> SaturatingAs for T

source§

fn saturating_as<Dst>(self) -> Dst
where T: SaturatingCast<Dst>,

Casts the value.
source§

impl<Src, Dst> SaturatingCastFrom<Src> for Dst
where Src: SaturatingCast<Dst>,

source§

fn saturating_cast_from(src: Src) -> Dst

Casts the value.
§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> UnwrappedAs for T

source§

fn unwrapped_as<Dst>(self) -> Dst
where T: UnwrappedCast<Dst>,

Casts the value.
source§

impl<Src, Dst> UnwrappedCastFrom<Src> for Dst
where Src: UnwrappedCast<Dst>,

source§

fn unwrapped_cast_from(src: Src) -> Dst

Casts the value.
source§

impl<T> WrappingAs for T

source§

fn wrapping_as<Dst>(self) -> Dst
where T: WrappingCast<Dst>,

Casts the value.
source§

impl<Src, Dst> WrappingCastFrom<Src> for Dst
where Src: WrappingCast<Dst>,

source§

fn wrapping_cast_from(src: Src) -> Dst

Casts the value.