ESP32 screen corruption at top when running benchmark

As the title says, I’m trying to run some basic benchmarking on a little integrated esp32-s3 with a round screen (480x480).

What I’m facing after a couple of days of troubleshooting is corruption at the top of the screen like some form of corruption or mismatch going on.

Image of what it looks like:

This however goes away once the benchmark is finished and the results are shown so it appears to either be some kind of strange buffer situation or a some kind of flushing before ready condition?

Benchmark finished:

As far as I can tell, I’m doing everything correctly in terms of setup and usage of the underlying esp lcd functionality, but still the problem persists.

Weirdly, if I use the Arduino IDE, and an example I found online here:

I get it to run well (ensuring I choose the options spoken about in the video below) so I picked through the library he’s using (Arduino GFX) so I could copy the esp init details and ensure I’m doing it the same way with the same timings etc, but I still get the same thing.

The details of the screen:
Name of the module: ZX2D10GE01R (Panlee)
480x480 resolution
ST7701S driver
ESP32-S3 N16R8 built in

Software dev environment:
I’m using PlatformIO with ESP-IDF 5.1.1 (as far as I can make out from platformio feedback during upload.

I’m limited by the number of links I can put here as a new user so I’ll upload the code below

I’m attaching here the code for main.c, screen.c, board.h, lv_conf.h, platformio.ini, and sdkconfig.
The platform.ini and sdkconfig files have had .txt added to the end to allow for uploading

Happy to supply more information as needed.

platformioini.txt (854 Bytes)
screen.c (13.3 KB)
main.c (1.1 KB)

board.h (2.1 KB)
lv_conf.h (25.5 KB)
sdkconfigesp32s3box.txt (57.4 KB)