auryn31 / festival_finder

60 stars 6 forks source link

Missing GC9A01 bodmer/TFT_eSPI display configuration #4

Open juergs opened 3 months ago

juergs commented 3 months ago

Hi Auryn, very nice project for starting. :-) Thank you for sharing your code.

By using your repo, i noticed that your TFT-configuration is missing in the pio-libdeps-folder _...\ESP32_festival_finder-auryn31.pio\libdeps\esp32dev\TFT_eSPI\UserSetup.h

`

define GC9A01_DRIVER

define TFT_WIDTH 240 // GC9A01 240 x 240 ,ST7789 240 x 240 and 240 x 320

define TFT_HEIGHT 240 // GC9A01 240 x 240

`

ESP32-pin-config is also missing: Therefore PIO loads the TFTeSPI-Lib in a default, not proper initial mode. ==> For ESP32 Dev board with GC9A01 display (8266-pins are set as default) ... .pio\libdeps\esp32dev\TFT_eSPI\User_Setups\Setup46_GC9A01ESP32.h has to be edited manually for correct gpio setting:

In my case this is the config according to your schematic:

//--- For ESP32 Dev board (only tested with GC9A01 display)
//--- The hardware SPI can be mapped to any pins
#define TFT_MOSI 15 // = SDA, In some display driver board, it might be written as "SDA" and so on.
#define TFT_SCLK 14
#define TFT_CS   5  // Chip select control pin
#define TFT_DC   27  // Data Command control pin
#define TFT_RST  33  // Reset pin (could connect to Arduino RESET pin)
#define TFT_BL   -1  // was 22,  LED back-light not implemented use -1 to disable.

Additionally i had to overwrite these setting here: _.pio\libdeps\esp32dev\TFT_eSPI\User_Setups\Setup46_GC9A01ESP32.h

#define GC9A01_DRIVER
//--- my round 240x240 TFT, juergs added.  Overwritten by user_setup.h?
#define TFT_MOSI 15 // = SDA, In some display driver board, it might be written as "SDA" and so on.
#define TFT_SCLK 14
#define TFT_CS   5  // Chip select control pin
#define TFT_DC   27  // Data Command control pin
#define TFT_RST  33  // Reset pin (could connect to Arduino RESET pin)
#define TFT_BL   -1  // LED back-light, could be 22

GPIO 22 seems to be doubled for the QMC5883L.SCL use value -1 instead to disable.

May be a minor issue only, but makes it easier to run-out-of-the-box. ;-)

regards, Jürgen

juergs commented 2 months ago

Sorry, didn't see that github limits file quantity, preventing library-sources from upload.
Here the config of the display and specially the TFT_eSPI-Library is explained in detail: gc9a01

auryn31 commented 2 months ago

Thank you a lot for the comments I had some changes in the lib directly, but true, thought i documented it :) Will integrate your requests on my next change, when i have time :)