Closed smarq8 closed 2 years ago
I think I found issue. It was cold solder joint on a connector between MCU and display on SCLK line. Also I provide here working setup:
main.cpp
#include <Arduino.h>
#include "TFT_eSPI.h"
TFT_eSPI tft;
void setup(){
Serial.begin(2000000);
tft.init();
tft.setRotation(1);
tft.fillScreen(tft.color24to16(0x000000));
}
void loop(){
tft.setCursor(10,10);
tft.setTextSize(2);
tft.printf("hello world\n%u",millis());
tft.fillCircle(10,50,10,tft.color24to16(0xff0000));
tft.drawRect(1,1,160-2,80-2,tft.color24to16(0x0000ff));
Serial.printf("%u\n",millis());
delay(1000);
}
#define ST7735_DRIVER
#define TFT_WIDTH 80
#define TFT_HEIGHT 160
#define ST7735_GREENTAB160x80 // For 160 x 80 display (BGR, inverted, 26 offset)
#define TFT_INVERSION_ON
#define TFT_RGB_ORDER TFT_BGR
#define TFT_BL 22 // LED back-light control pin
#define TFT_BACKLIGHT_ON HIGH // Level to turn ON back-light (HIGH or LOW)
#define TFT_MISO VMISO_PIN
#define TFT_MOSI VMOSI_PIN
#define TFT_SCLK VSCLK_PIN
#define TFT_CS 16 // Chip select control pin
#define TFT_DC 4 // Data Command control pin
#define TFT_RST 5 // Reset pin (could connect to RST pin)
#define SPI_FREQUENCY 27000000 // 40MHz begin to glitch
Hello I prototype some board with TFT009-81AINN display, it use ST7735 controller, pin1 tied to VCC for 4 wire spi, I already fixed missing connection at pin12 (backlight). I tried any tc parameter for tft.ini(tc) without succes. I also check signals by osciloscope and it seems fine. My MCU - ESP32-WROOM-32D. Any solution what I'm missing or does this library support it? Also does it metter if TFT_RES is connected to IO5 (pwm at boot)? Its reasaon why I put delay(1000).
main.cpp
config: