9 #include <satcat5/cfg_spi.h>
144 bool scroll(s16 rows)
override;
145 void spi_done(
unsigned nread,
const u8* rbytes)
override;
149 bool in_viewport(u16 row)
const;
152 bool spi_cmd(u8 len,
const u8* cmd,
Ili9341* callback);
155 void try_twidth(u16
width);
161 const u8 m_devidx, m_madctl;
162 u16 m_init_step, m_scroll, m_viewtop, m_viewsize;
163 u16 m_draw_step, m_draw_done, m_tile_col, m_tile_row, m_tile_width, m_tile_height;
SPI Event Handler callback for use with SpiGeneric.
Polymorphic API for a generic SPI interface.
Display device driver for the ILI9341.
static constexpr u16 COLOR_MAGENTA
Constant definitions for 16-bit color mode.
static constexpr u16 COLOR_CYAN
Constant definitions for 16-bit color mode.
static constexpr u16 COLOR_WHITE
Constant definitions for 16-bit color mode.
u16 scroll_pos() const
Current scroll position.
static constexpr u16 COLOR_GREEN
Constant definitions for 16-bit color mode.
static constexpr u16 COLOR_YELLOW
Constant definitions for 16-bit color mode.
static constexpr u16 COLOR_LIGHTGREY
Constant definitions for 16-bit color mode.
static constexpr u16 COLOR_MAROON
Constant definitions for 16-bit color mode.
static constexpr u8 ADAFRUIT_ROT0
Adafruit panels all use BGR mode with MH = 0.
static constexpr u8 MADCTL_BGR
Constants for the MADCTL register (Section 8.2.29).
bool draw(const satcat5::gui::Cursor &cursor, const satcat5::gui::DrawCmd &cmd) override
Draw pixels to the screen at the designated location.
static constexpr u8 MADCTL_MH
Constants for the MADCTL register (Section 8.2.29).
static constexpr u16 COLOR_DARKGREY
Constant definitions for 16-bit color mode.
static constexpr u8 MADCTL_MX
Constants for the MADCTL register (Section 8.2.29).
static constexpr u8 MADCTL_MV
Constants for the MADCTL register (Section 8.2.29).
static constexpr u16 COLOR_NAVY
Constant definitions for 16-bit color mode.
static constexpr u16 COLOR_PURPLE
Constant definitions for 16-bit color mode.
static constexpr u16 COLOR_GRELLOW
Constant definitions for 16-bit color mode.
static constexpr u16 COLOR_BLUE
Constant definitions for 16-bit color mode.
bool viewport(u16 top, u16 size)
Configure the scrolling viewport:
static constexpr satcat5::gui::LogColors LIGHT_THEME
Recommended colors for light theme (black text on white).
void timer_event() override
Child class MUST override this method.
static constexpr satcat5::gui::LogColors DARK_THEME
Recommended colors for dark theme (white text on black).
static constexpr u8 MADCTL_MY
Constants for the MADCTL register (Section 8.2.29).
static constexpr u16 COLOR_PINK
Constant definitions for 16-bit color mode.
Ili9341(satcat5::cfg::SpiGeneric *spi, u8 devidx, u8 madctl=ADAFRUIT_ROT0)
Constructor links to the specified SPI interface.
static constexpr u8 ADAFRUIT_ROT90
Adafruit panels all use BGR mode with MH = 0.
static constexpr u16 COLOR_RED
Constant definitions for 16-bit color mode.
static constexpr u8 ADAFRUIT_ROT180
Adafruit panels all use BGR mode with MH = 0.
static constexpr u16 COLOR_ORANGE
Constant definitions for 16-bit color mode.
static constexpr u16 COLOR_DARKCYAN
Constant definitions for 16-bit color mode.
bool busy() const
Busy with initialization or a previous command?
static constexpr u16 COLOR_DARKGREEN
Constant definitions for 16-bit color mode.
static constexpr u16 COLOR_OLIVE
Constant definitions for 16-bit color mode.
void reset()
Initiate software reset.
static constexpr u8 ADAFRUIT_ROT270
Adafruit panels all use BGR mode with MH = 0.
static constexpr u8 MADCTL_ML
Constants for the MADCTL register (Section 8.2.29).
bool scroll(s16 rows) override
Optional: Advance the predefined viewport by N pixels.
static constexpr u16 COLOR_BLACK
Constant definitions for 16-bit color mode.
bool invert(bool inv)
Invert entire display.
Required API for display devices.
u16 width() const
Total size of the display, in pixels.
Each "draw command" updates a rectangular region of pixels.
Timer objects are polled after a fixed delay or at a regular interval.
"Display" and "Canvas" API for rendering text and graphics
Core event-processing loop for SatCat5 software.
Cursor object tracks position and foreground/background colors.
Color parameters for the LogToDisplay class.