-
Notifications
You must be signed in to change notification settings - Fork 7.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SSD1309 on SPI bus (IDFGH-9249) #10635
Comments
@DmytroKoval Thanks for reporting! Looks like SSD13xx OLED LCD SPI mode is a little different from other LCD screens like ST7789, where the DC level will turn high when transmitting parameters. We will consider to make that configurable in the |
That's smart, because SSD1322 and 1351 (for example, I didn't check all product line) require D/C high on parameter transmission. Good luck with update! |
Any chance this might be resolved before the 5.2 release? I can make the pull request if it would help |
…r transfers fixes esp-idf issue espressif#10635
…r transfers fixes esp-idf issue espressif#10635
…r transfers fixes esp-idf issue espressif#10635
Add in a flag to keep the DC pin in the command state during parameter transfer fixes esp-idf issue espressif#10635
Thanks for the contribution. After the PR gets merged to the master branch, we will backport it to release/v5.2 for sure. @kscz |
@suda-morris On baranch v4.4.8, I tried to make the chages dc gpio level in case of command, parameter and data on the file esp_lcd_panel_io_spi.c file, but it doesn't work. I complied on v5.2.3, it works fine. Is there is any fundamental changes in the driver also, apart from introduction of due to some restrictions, I cannot upgrade my sdk to v5.2 and want to use the ssd1309 with lcd library . |
Answers checklist.
IDF version.
esp-idf-v5.0
Operating System used.
Windows
How did you build your project?
Command line with idf.py
If you are using Windows, please specify command line type.
PowerShell
Development Kit.
ESP-WROOM32
Power Supply used.
USB
What is the expected behavior?
I tried to use ESP-IDF 5.0 LED driver + LVGL with SSD1309 OLED connected via SPI. As a code base an I2C OLED example for SSD1306 display was taken. SSD1306 and SSD1309 are compatible at command level. I changed I2C bus/io config to SPI. Sample initialization code is shown below.
After 3 last lines of code display should have being initialized.
What is the actual behavior?
After 3 last lines of code shown above display is filled with noisy pixels with no other output.
Steps to reproduce.
Debug Logs.
No response
More Information.
After investigation I found function
static esp_err_t panel_io_spi_tx_param(esp_lcd_panel_io_t *io, int lcd_cmd, const void *param, size_t param_size)
at
components/esp_lcd/src/esp_lcd_panel_io_spi.c
which transmits data/commands via SPI. I noticed, that it inverts D/C line before command parameter transmission (this line). But according to SSD1309 datasheet D/C line should be held at low level (command mode) during transmission of command parameters, and it is stated in both SSD1306 and SSD1309 datasheets.
The text was updated successfully, but these errors were encountered: