The problem you have is not likely linked to LVGL. Make sure you can run regular Micropython code with Thonny + ESP32 before attempting to use LVGL.
Also I noticed your are using an Adafruit library. Those run on Circuitpython, not Micropython. There is not port of LVGL for Circuitpython. Make sure you understand the differences between Circuitpython and Micropython:
A bit of work is needed to run Adafruit libraries on Micropython, this link might help you, although is it targeted for RP2040 and not ESP32:
In general, If you want to provide snippets of your code on any technical forum, don´t post pictures of your code: it cannot be copy pasted, and nobody will go through the hassle of writing your code by hand to reproduce the problem. Same for incomplete, vague photos of your hardware: provides schematics, not a photo of half of your prototype !
Make sure you go through all the basics, step by step, and that you actually understand all the steps. Even if it looks slow, it´s the fastest way to reach your goal.
I have a question, you mentioned that I used an “Adafruit library” and said that this library can only be used on CircuitPython, so why does this driver use this repository in the “lv_binding_micropython”. That makes me think it’s for MicroPython
I also advice you, for debugging purposes, not to use the boot.py file but to rename it like boot-test.py : when Micropython finds a boot.py file it will execute it automatically at boot. This makes debugging quite difficult, preventing you sometimes to go step-by-step with the interpreter, then only saving your code as a file when it works.
When your project work, you can use the boot.py file, in order not to have to start your code manually every time.
raceback (most recent call last):
File “lv_utils.py”, line 123, in task_handler
File “/lib/st77xx.py”, line 442, in disp_drv_flush_cb
File “/lib/st77xx.py”, line 248, in blit
File “/lib/st77xx.py”, line 235, in set_window
KeyError: (128, 160, ‘greentab’)
take the whole lgvl code away of your boot-test.py, does the SPI initalizing happen without error ?
if yes, then do some simple SPI checks to make sure your SPI bus works.
Also in the st77xx lib it´s clear that the greentab board is not supported, try the blacktab.
After testing, SoftSPI works fine
When I set ‘model’ to ‘blacktab’, there were no errors on the first run, but nothing changed on the LCD
The second time it runs, my board automatically restarts, which is the output of the IDE
(intermittently online) That looks to be the case (also). A recommendation to @PCX-LK: use the driver/generic/st77xx-test.py to test raw interfacing with the display first, without LVGL, in Thonny. That should iron out issues related to hardware itself. Good luck!
(Sorry, did not see the post) Copy driver files to the device along with adjusted st77xx-test.py. Adjust the spi config and use one of the if 1: blocks at the end (disable the other ones by changing to if 0:) , again adjusted to your model, to set up the LCD and call test_lcd. It will show some colored rectangles at different screen orientations and also change the backlight. There is not LVGL involved at all, just the hardware driver itself.