drivers.Epaper.EPD¶
High-level driver for a 2.9-inch tri-color (black/white/red) e-paper display.
Controls a 128x296 Waveshare-compatible EPD panel over SPI. Handles hardware
reset sequencing, command and data transmission, LUT waveform tables, image
buffering, full-panel refresh, and deep-sleep/wake power management. Uses
drivers.Epaper.Epdconfig.Epdconfig for the underlying GPIO and SPI
peripheral access.
The driver targets a passive e-paper controller that retains the last frame without power and requires a full refresh (no partial updates) for each new image.
Example
Initialize the panel, clear it, and put it to sleep:
>>> from drivers.Epaper.EPD import EPD
>>> epd = EPD()
>>> epd.init()
>>> epd.Clear()
>>> epd.sleep()
>>> epd.Dev_exit()
Note
Hardware pin assignments (BCM numbering) are inherited from
drivers.Epaper.Epdconfig.Epdconfig:
RST_PIN= GPIO 17 (hardware reset, active-low pulse)DC_PIN= GPIO 25 (data/command select; 0 = command, 1 = data)CS_PIN= GPIO 8 (SPI chip-select, active-low)``BUSY_PIN``= GPIO 24 (controller busy flag; 0 = busy, 1 = idle)
SPI is fixed to bus 0, device 0, mode 0, max_speed_hz = 1_240_000.
Only full-panel refresh is supported; partial updates are not implemented
by this controller. Each call to EPD.display() or EPD.Clear()
drives the full waveform LUT through the panel.
Attributes¶
Classes¶
E-paper display driver for a 128x296 tri-color (black/white/red) panel. |
Module Contents¶
- drivers.Epaper.EPD.EPD_HEIGHT = 296¶
- drivers.Epaper.EPD.EPD_WIDTH = 128¶
- drivers.Epaper.EPD.epd¶