FireBeetle ESP32-E & 0.96" 80x160 display

userHead IanBrown 2022-05-30 06:20:41 565 Views1 Replies

I'm using the FireBeetle ESP32-E and 0.96" 80x160 display. When I plug them into my own code, in VSCode with Platform.IO, the code works, uploads and displays nothing.

 

So I went back to basics and loaded each of the examples from the DFRobot_GDL library (st7735 80x160) into the Arduino IDE 1.8.13 IDE and all worked first time - so the wiring is right, the code works and the ‘ballCollision’ sample works great. I then moved the example into VSCode PlatformIO, … nothing is shown. The backlight is on, but there's nothing on the display. I'm doing some debug output to Serial.println, so I can see that the board hasn't crashed.

 

The only change I had to make to the library was in DFRobot_Picdecoder_SD.cpp to put a #if 0 at the top and #endif at the bottom as it failed to find SD.h:

    .pio/libdeps/firebeetle32/DFRobot_GDL/src/DFRobot_Picdecoder_SD.cpp:4:10: fatal error: SD.h: No such file or directory

 

Now, there is an SD class in 

    /Users/ianbrown/Library/Arduino15/packages/DFRobot/hardware/esp32/0.2.1/libraries/SD

And

    /Users/ianbrown/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/libraries/SD

 

My platformio.ini contains:

[env:firebeetle32]

platform = espressif32

board = firebeetle32

framework = arduino

monitor_speed = 115200

lib_deps =

fastled/FastLED@^3.5.0

robtillaart/float16@^0.1.6

h2zero/NimBLE-Arduino@^1.3.8

hideakitai/MPU9250@^0.4.8

asukiaaa/MPU9250_asukiaaa@^1.5.11

dfrobot/DFRobot_GDL@^1.0.1

 

But that must be for the espidf framework - whereas the DFRobot_GDL library is claimed to be compatible with the Arduino framework. If I set the framework to espidf then VSCode PlatformIO can no longer see the DFRobot_GDL library at all.

 

 

 

 

Given the code works in Arduino IDE 1.8.13, I presume the framework should be set to ‘arduino’ in platformio.ini in VSCode PlatformIO. I also get the same problems in Arduino IDE 2.0 as I do in VSCode PlatformIO - but then IDE 2.0 is based on VSCode. 

 

So, what can I test next to see what's causing the difference in behaviour?

 

I'd much rather stay with VSCode PlatformIO as it's a much more professional IDE.

 

 

 

 

 

 

 

 

 

 

 

 

 

2022-05-30 21:27:05

Sorted it.

The examples show the following:

 

#define TFT_DC D2

#define TFT_CS D6

#define TFT_RST D3

 

Changing that to the following just works:

 

 

#define TFT_DC 25

#define TFT_CS 14

#define TFT_RST 26

 

 

 

userHeadPic IanBrown