Using Arduino IDE version 2.3.6
DevKit: ESP32-S3-USB-OTG
Board: ESP32 S3 MINI 1
Screen: ST7789
Library: TFT_eSPI 2.5.43
user_setup.h:
#define ST7789_DRIVER
#define TFT_RGB_ORDER TFT_BGR
#define TFT_WIDTH 240
#define TFT_HEIGHT 240
#define TFT_MOSI 7
#define TFT_SCLK 6
#define TFT_CS 5
#define TFT_DC 4
#define TFT_RST 8
#define TFT_BL 9
Tried multiple times but couldn't get the screen to light up. Seeking HELP.
Thanks in advance.
Need help - unable to light up ST7789 screen via Arduino IDE
-
lbernstone
- Posts: 1132
- Joined: Mon Jul 22, 2019 3:20 pm
Re: Need help - unable to light up ST7789 screen via Arduino IDE
You can try setting TFT_BACKLIGHT_ON, but I find it easier to just manually set the backlight level:
Code: Select all
analogWrite(TFT_BL, 128); // 0-255
Re: Need help - unable to light up ST7789 screen via Arduino IDE
which file in Arduino\libraries\TFT_eSPIUser_Setups did you edit?
with the ESP32-S3-DevKitC-1 and Waveshare General 2inch LCD Display Module IPS Screen 240×320 ST7789
I used Documents\Arduino\libraries\TFT_eSPIUser_Setups/Setup71_ESP32_S2_ST7789.h
and setup Documents\Arduino\libraries\TFT_eSPI\User_Setup_Select.h to select that file
what output do you get on the Arduino IDE serial monitor?
with ESP32S3 I found that using ESP32 core 2.3.0 and 2.0.17 it goes into a reboot loop
using ESP32 core 2.0.14 works OK
with the ESP32-S3-DevKitC-1 and Waveshare General 2inch LCD Display Module IPS Screen 240×320 ST7789
I used Documents\Arduino\libraries\TFT_eSPIUser_Setups/Setup71_ESP32_S2_ST7789.h
and setup Documents\Arduino\libraries\TFT_eSPI\User_Setup_Select.h to select that file
what output do you get on the Arduino IDE serial monitor?
with ESP32S3 I found that using ESP32 core 2.3.0 and 2.0.17 it goes into a reboot loop
using ESP32 core 2.0.14 works OK
-
lbernstone
- Posts: 1132
- Joined: Mon Jul 22, 2019 3:20 pm
Re: Need help - unable to light up ST7789 screen via Arduino IDE
With TFT_eSPI, I put a build_opt.h in the sketch folder with the following contents. This makes it more portable (and versionable). You need the USE_HSPI_PORT macro. I then put analogWrite(TFT_BL, TFT_BL_LEVEL); in setup() after init'ing the device. https://wokwi.com/projects/436838160182099969
Code: Select all
-DST7789_DRIVER
-DTFT_SDA_READ
-DTFT_WIDTH=240
-DTFT_HEIGHT=320
-DTFT_CS=12
-DTFT_MOSI=7
-DTFT_SCLK=5
-DTFT_DC=9
-DTFT_RST=11
-DTFT_BL=3
-DTFT_BL_LEVEL=250
-DTFT_INVERSION_OFF
-DTFT_ROT=3
-DLOAD_FONT2
-DLOAD_FONT4
-DLOAD_FONT6
-DUSER_SETUP_LOADED
-DSPI_FREQUENCY=40000000
-DUSE_HSPI_PORT
Re: Need help - unable to light up ST7789 screen via Arduino IDE
Thanks. I met the same issue that stuck in a reboot loop as well. I will try this solution to see if it can lead to a positive result.which file in Arduino\libraries\TFT_eSPIUser_Setups did you edit?
with the ESP32-S3-DevKitC-1 and Waveshare General 2inch LCD Display Module IPS Screen 240×320 ST7789
I used Documents\Arduino\libraries\TFT_eSPIUser_Setups/Setup71_ESP32_S2_ST7789.h
and setup Documents\Arduino\libraries\TFT_eSPI\User_Setup_Select.h to select that file
what output do you get on the Arduino IDE serial monitor?
with ESP32S3 I found that using ESP32 core 2.3.0 and 2.0.17 it goes into a reboot loop
using ESP32 core 2.0.14 works OK
Re: Need help - unable to light up ST7789 screen via Arduino IDE
Thank you for providing a new direction. Let me take a look and have a try.With TFT_eSPI, I put a build_opt.h in the sketch folder with the following contents. This makes it more portable (and versionable). You need the USE_HSPI_PORT macro. I then put analogWrite(TFT_BL, TFT_BL_LEVEL); in setup() after init'ing the device. https://wokwi.com/projects/436838160182099969Code: Select all
-DST7789_DRIVER -DTFT_SDA_READ -DTFT_WIDTH=240 -DTFT_HEIGHT=320 -DTFT_CS=12 -DTFT_MOSI=7 -DTFT_SCLK=5 -DTFT_DC=9 -DTFT_RST=11 -DTFT_BL=3 -DTFT_BL_LEVEL=250 -DTFT_INVERSION_OFF -DTFT_ROT=3 -DLOAD_FONT2 -DLOAD_FONT4 -DLOAD_FONT6 -DUSER_SETUP_LOADED -DSPI_FREQUENCY=40000000 -DUSE_HSPI_PORT
Who is online
Users browsing this forum: No registered users and 1 guest