Floyd-Fish / ST7789-STM32

using STM32's Hardware SPI to drive a ST7789 based IPS displayer
GNU General Public License v3.0
276 stars 55 forks source link

Added function that prepares RGB565 image array to be fed into the ST7789_DrawImage function #22

Closed bayesiandog closed 7 months ago

bayesiandog commented 2 years ago

ST7789_DrawImage function casts the uint16_t value of the image array into a uint8_t which causes the array to be sent to the ST7789 controller low byte first. This results in wrong output and so the proposed solution is to just exchange these high and low bytes beforehand similar to the ST7789_DrawPixel function, with a different function.

issue 15

Guilherme-Mello commented 11 months ago

how do i use this?

bayesiandog commented 10 months ago

Use ST7789_PrepareRGB565_ImageArray function before calling ST7789_DrawImage.