Closed fsiek closed 1 year ago
The beta version of esphome fixes most of it due to this pr: https://github.com/esphome/esphome/pull/5311
To get the full 40Mhz on esp32 i had to avoid defining the miso pin as there seem to be a limit to 26Mhz for full duplex connections.
Sorry, not speaking about factor 2 but 25. SPI seems to run at 1.6 Mhz instead of 40Mhz.
Hi could you run esphome in DEV mode and use PR#5406 to see of your issue will be fixed with that one.
OK, checked in dev mode and it looks much better now. This time I can see in the log that the data rate is set, which was not the case before.
[09:17:11][D][spi_device:354]: mode 0, data_rate 40000kHz
This leads to a much better throughput:
[09:17:12][W][component:204]: Component ili9xxx.display took a long time for an operation (0.33 s).
There is still room for improvements but I guess this topic can be marked as resolved with the new SPI component code.
The problem
Experimenting with a ESP32 Wroom32, 240Mhz, 520kB Ram, 4MB flash, connected to a ST7796 with 320x480.
Due to heap memory restrictions I am experimenting using esp-idf instead of arduino as it gives me ~20kB larger maximum heap block for the display buffer.
Even esp-idf gives me a larger possible display area, the display is running very slow with the esp-idf framework. Setting the data_rate (SPI) for the display in the yaml file has no effect.
It look like the SPI data rate is not set correctly to the possible 40MHz.
Which version of ESPHome has the issue?
2023.8.3
What type of installation are you using?
pip
Which version of Home Assistant has the issue?
2023.9.1
What platform are you using?
ESP32
Board
ESP32-D0WD-V3 (revision v3.1)
Component causing the issue
Display ST7796
Example YAML snippet
Anything in the logs that might be useful for us?
Additional information
I changed display.py to work with color_palette: GRAYSCALE in YAML according to recommended fix from clydebarrow: https://github.com/esphome/esphome/pull/5406 but the problem shows up with color_palette: IMAGE_ADAPTIVE, too.