adafruit / Adafruit-ST7735-Library

This is a library for the Adafruit 1.8" SPI display http://www.adafruit.com/products/358 and http://www.adafruit.com/products/618
https://learn.adafruit.com/1-8-tft-display
564 stars 305 forks source link

Flickering Mini PiTFT 1.14" on Uno R4 Wifi #188

Open leonpierre opened 1 year ago

leonpierre commented 1 year ago

`#define TFT_CS 10

define TFT_RST -1 // -1 for unused

define TFT_DC 8

const uint16_t Display_Color_Black = 0x0000; const uint16_t Display_Color_Blue = 0x001F; const uint16_t Display_Color_Red = 0xF800; const uint16_t Display_Color_Green = 0x07E0; const uint16_t Display_Color_Cyan = 0x07FF; const uint16_t Display_Color_Magenta = 0xF81F; const uint16_t Display_Color_Yellow = 0xFFE0; const uint16_t Display_Color_White = 0xFFFF;

uint16_t Display_Text_Color = Display_Color_White; uint16_t Display_Backround_Color = Display_Color_Black;

Adafruit_ST7789 tft = Adafruit_ST7789(TFT_CS, TFT_DC, TFT_RST); // Hardware SPI init

void setup() { tft.init(135, 240);
tft.setFont(); tft.setRotation(135); // 135 or 45 tft.fillScreen(Display_Backround_Color);
tft.setTextColor(Display_Text_Color); tft.setTextSize(2);

tft.print("TEST"); }`

Should output TEST and that's it, but flickers and only shows the text if I press the Reset button on the R4 Wifi. The same code is working fine on an e.g. Arduino Nano.

Do I have to use another SPI mode (although tried everything) or adjust the SPI speed or is the new R4 not yet supported? Link to issue on Arduino forum: https://forum.arduino.cc/t/flickering-mini-pitft-1-14-with-st7789-library/1145766