So I finally finished my custom UI firmware with 63 screens in SquareLine Studio and successfully exported them to VSCode. But getting this massive UI to actually boot on my custom ESP32-S3 board was a nightmare and I wasted a lot of time just figuring out how to turn the display on without crashing the whole processor.
Here is what I figured out:
The RAM problem
At first, the firmware just kept crashing silently. I realized that the ESP32-S3 has only about 320KB of internal SRAM. When you try to initialize an LVGL UI with 68 different screens and graphics, it eats the internal memory instantly and dies. I had to force the microcontroller to use the external 8MB PSRAM.
- The TFT_eSPI vs Adafruit library conflict
From the start, I wanted to use the TFT_eSPI library because it is extremely fast. But there were too many problems with it on my custom PCB. TFT_eSPI is heavily hardware-optimized and tries to access the registers directly, which probably created a conflict with my Octal PSRAM clock or my specific pinout.
So I switched to the Adafruit_ST7789 library. It is definitely slower because it doesn’t have all those deep hardware dependencies, but it works! It overrides the pinouts directly from the code and is much more stable for my custom build.
Right now, I made just a basic startup program to link the GUI to the display, and it successfully booted! Next up, I need to program the movement logic for my 5-way joystick so I can actually scroll through all those 63 screens.
And this is just a beginning. I still have to solder the remaining modules on the device (IR LEDs, IR receiver, Buzzer, NEO-M8N GPS, PN532) and assemble the 3D printed case.