russhughes/s3lcd

Compatibility with esp-idf 5.0.2

Closed this issue · 11 comments

Is there are planed a compatibility with esp-idf 5.0.2 ?

https://newreleases.io/project/github/espressif/esp-idf/release/v5.0-beta1
SPI_LCD: Removed dc_as_cmd_phase as it's added by mistake and the functionality is not ready in the hardware. Now you have to use a GPIO to control the LCD's D/C line.

Greetings Dennis

Yes, I plan on supporting esp-idf 5.0.2 soon.

Yes, I plan on supporting esp-idf 5.0.2 soon.

There is more that the deprecated dc_as_cmd_phase in esp_lcd_panel_io_spi_config_t that never used :)
Is there a another way to use DMA from v4.4.4 to 5.0.2 ?
Am I correct in saying that the main drawing actions take place in memory buffers and only a couple of functions really start the hardware/esp-idf-calls ?
Is there a more elegant way to integrate the specialized SDCardMMC configuration into micropython than via a patch?

kf106 commented

Compiling for a T-Display-S3, the instructions as given failed for me.

Using idf.py --version = v4.4.4 and changing the reference to an absolute path (because the relative one doesn't work - I'm guessing you now end up in the wrong folder):

make USER_C_MODULES=~/GIT/Lilygo/s3lcd/src/micropython.cmake FROZEN_MANIFEST="" FROZEN_MPY_DIR=$UPYDIR/modules

This gives:

Manifest files have changed, solving dependencies.
....CMake Error at /home/kf106/GIT/Lilygo/esp-idf/tools/cmake/build.cmake:452 (message):
  HINT: Please check manifest file of the following component(s): main_esp32

  ERROR: Because project depends on idf (>=5.0.2) which doesn't match any
  versions, version solving failed.

I then tried upgrading idf to v5.0.2 and using your PR, @c-logic, which succeeded.

kf106 commented

I spoke too soon:

=~=~=~=~=~=~=~=~=~=~=~= PuTTY log 2023.10.11 17:50:05 =~=~=~=~=~=~=~=~=~=~=~=
ESP-ROM:esp32s3-20210327

ESP-ROM:esp32s3-20210327
Build:Mar 27 2021
rst:0x7 (TG0WDT_SYS_RST),boot:0x8 (SPI_FAST_FLASH_BOOT)
Saved PC:0x40043ac8
Invalid chip id. Expected 9 read 0. Bootloader for wrong chip?
ets_main.c 329 

the newest micropython version is only compatible with idf 5.0.2.

v1.2.0 compiles with idf 4.4.4

greetings

kf106 commented

the newest micropython version is only compatible with idf 5.0.2.

v1.2.0 compiles with idf 4.4.4

greetings

I was trying idf 5.0.2 with your https://github.com/c-logic/s3lcd

I'll try Russ Hughes repo again, and delete everything and start a new shell terminal again.

So the instructions for this repo should be changed to tell you how to select version 1.2.0 of micropython, I suppose...

kf106 commented

I assume you meant v1.20.0 of micropython. I tried that and got the same "Invalid chip id. Expected 9 read 0. Bootloader for wrong chip?" error, but at least it built with that.

With v1.19 of micropython it doesn't build.

Trying to load bootloader.bin, partition_table.bin and micropython.bin at the suggested locations in the terminal doesn't work. and nor does loading firmware.bin at 0x0 (invalid chip). I'm using a LilyGo T-Display-S3

kf106 commented

Is the problem that I'm compiling build-GENERIC and what I need is one relevant for my particular device?

kf106 commented

Finally got it to work using https://github.com/russhughes/st7789s3_mpy/ and some extra information that I had to deduce through some detective work. I've left an issue in that repo explaining what I did to succeed.

I also verified that the same process works for this repository. See russhughes/st7789s3_mpy#8 for details.

Thank you for providing these repositories, @russhughes - they're far better than the ones provided by Lilygo.

i think the best choice is BOARD=GENERIC_S3

make USER_C_MODULES=~/s3lcd/src/micropython.cmake BOARD=GENERIC_S3 -j

build-GENERIC is for a other ESP32 and not the ESP32-S3

IDF 5.0.2 + micropython v1.21.0
make USER_C_MODULES=~/s3lcd/src/micropython.cmake BOARD=ESP32_GENERIC_S3 -j
tested and executed with WC01 Plus (with 16MB-Patch)