This is how Pimoroni issues the commands in their C++ driver: https://github.com/pimoroni/pimoroni-pi ... st7789.cpp
It should be clear that it uses DC signal
(4-lines serial interface use: CSX (chip enable), D/CX (data/ command flag), SCL (serial clock) and SDA (serial data input/output))
mode which is well supported by ST7789V.
P.S. BTW for serial interface they use SPI+DMA for data and clock, the rest is driven in software through SIO, and a little bit of overclocking
It should be clear that it uses DC signal
(4-lines serial interface use: CSX (chip enable), D/CX (data/ command flag), SCL (serial clock) and SDA (serial data input/output))
mode which is well supported by ST7789V.
P.S. BTW for serial interface they use SPI+DMA for data and clock, the rest is driven in software through SIO, and a little bit of overclocking
// The ST7789 requires 16 ns between SPI rising edges.
// 16 ns = 62,500,000 Hz
// 2350 doesn't support 62,500,000 so use 75,000,000 seems to work.
Code:
void ST7789::command(uint8_t command, size_t len, const char *data) { gpio_put(dc, 0); // command mode gpio_put(cs, 0); if(spi) { spi_write_blocking(spi, &command, 1); } else { write_blocking_parallel(&command, 1); } if(data) { gpio_put(dc, 1); // data mode if(spi) { spi_write_blocking(spi, (const uint8_t*)data, len); } else { write_blocking_parallel((const uint8_t*)data, len); } } gpio_put(cs, 1); }
Statistics: Posted by gmx — Sun Nov 16, 2025 2:06 am