Closed c-logic closed 1 year ago
Sorry I've been busy and have not had time to look at this.
no hurry. I'll test it with a parallel TFT this week. "WT32 SC01 Plus"
Not yet usable with with i80. the use with i80 runs in a error+reset.
Found the i80 error. The clock source must be set.
E (66580) lcd_panel.io.i80: lcd_i80_select_periph_clock(504): unsupported clock source: 0
E (66580) lcd_panel.io.i80: esp_lcd_new_i80_bus(154): select periph clock 0 failed
Here is the fix:
diff --git a/src/s3lcd.c b/src/s3lcd.c
index f29b6c6..32cb8c0 100644
--- a/src/s3lcd.c
+++ b/src/s3lcd.c
@@ -1384,6 +1384,7 @@ STATIC mp_obj_t s3lcd_init(mp_obj_t self_in) {
esp_lcd_i80_bus_config_t bus_config = {
.dc_gpio_num = config->dc_gpio_num,
.wr_gpio_num = config->wr_gpio_num,
+ .clk_src = LCD_CLK_SRC_DEFAULT,
.data_gpio_nums = {
config->data_gpio_nums[0],
config->data_gpio_nums[1],
Please give a hint how to get the error message.
the current micropython version does not use the SPIRAM and so the memory is not enough for the frame buffer. (SC01 PLUS)
The error messages are printed to the serial console. This is a problem if you use the native ESP32-S3 USB serial port since the USB is reset whenever there is an error, making it impossible to see the error messages. I use a 3.3-volt USB serial adapter connected to the ESP32-S3's serial TXD0 & RXD0 pins. These pins are available on the WT32-SC01 Plus' Debug Interface connector.
SPIRAM should be supported but may require using a BOARD_VARIANT like this:
make BOARD=ESP32_GENERIC_S3 BOARD_VARIANT=SPIRAM_SX
I have yet to test this. I will later tonight.
This worked for my WT32-SC01 Plus.
make BOARD=ESP32_GENERIC_S3 PORT=/dev/ttyACM0 USER_C_MODULES=../../../../s3lcd/src/micropython.cmake
MicroPython v1.20.0-457-gdc99840b3 on 2023-09-13; Generic ESP32S3 module with ESP32S3
Type "help()" for more information.
>>> import gc
>>> a = bytearray(1024 * 1024)
>>> b = bytearray(1024 * 512)
>>> gc.mem_free()
468592
IDF_PATH=/home/dennis/esp-idf5.0.2 ESP_IDF_VERSION=5.0
make BOARD=ESP32_GENERIC_S3 USER_C_MODULES=~/s3lcd/src/micropython.cmake
MicroPython v1.20.0-396-g1dedb65e6-dirty on 2023-09-14; Generic ESP32S3 module with ESP32S3
Type "help()" for more information.
import gc a = bytearray(1024 * 1024) Traceback (most recent call last): File "
", line 1, in MemoryError: memory allocation failed, allocating 1048576 bytes
Hope to support micropython 1.21.
only testet on LilyGo S3 Dongle