Skip to content

Commit

Permalink
s3-lcd-ev-board: add display & touch, update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Lzw655 committed Aug 8, 2023
1 parent bf3cc23 commit d05add1
Show file tree
Hide file tree
Showing 23 changed files with 1,805 additions and 1,338 deletions.
4 changes: 2 additions & 2 deletions LCD.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,5 @@ The list of available LCD displays and links to LCD driver component and touch d
| <img src="docu/pics/ssd1306.jpg" width="150"> | 128x32 0,91" OLED | SSD1306 | [IDF](https://github.com/espressif/esp-idf/tree/master/components/esp_lcd) | - | - | |
| <img src="docu/pics/ssd1963.jpg" width="150"> | Parallel | SSD1963 | **N/A** | - | - | |
| <img src="docu/pics/st7796.jpg" width="150"> | Parallel/SPI | ST7796 | [Component Manager](https://components.espressif.com/component/espressif/esp_lcd_st7796) | - | - | |
| <img src="docu/pics/esp32-s3-lcd-ev-board_480x480.png" width="150"> | [ESP32-S3-LCD-EV-Board](https://docs.espressif.com/projects/espressif-esp-dev-kits/en/latest/esp32s3/esp32-s3-lcd-ev-board/user_guide.html) | GC9503 | [Component Manager](https://components.espressif.com/component/espressif/esp_lcd_gc9503) | FT5X06 | [Component Manager](https://components.espressif.com/component/espressif/esp_lcd_touch_ft5x06) | |
| <img src="docu/pics/esp32-s3-lcd-ev-board_800x480.png" width="150"> | [ESP32-S3-LCD-EV-Board-2](https://docs.espressif.com/projects/espressif-esp-dev-kits/en/latest/esp32s3/esp32-s3-lcd-ev-board/user_guide.html) | ST7262E43 | **N/A** | GT1151 | [Component Manager](https://components.espressif.com/component/espressif/esp_lcd_touch_gt1151) | |
| <img src="docu/pics/esp32-s3-lcd-ev-board_480x480.png" width="150"> | [ESP32-S3-LCD-EV-Board](https://docs.espressif.com/projects/esp-dev-kits/en/latest/esp32s3/esp32-s3-lcd-ev-board/user_guide.html) | GC9503 | [Component Manager](https://components.espressif.com/component/espressif/esp_lcd_gc9503) | FT5X06 | [Component Manager](https://components.espressif.com/component/espressif/esp_lcd_touch_ft5x06) | |
| <img src="docu/pics/esp32-s3-lcd-ev-board_800x480.png" width="150"> | [ESP32-S3-LCD-EV-Board-2](https://docs.espressif.com/projects/esp-dev-kits/en/latest/esp32s3/esp32-s3-lcd-ev-board/user_guide.html) | ST7262E43 | **N/A** | GT1151 | [Component Manager](https://components.espressif.com/component/espressif/esp_lcd_touch_gt1151) | |
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Board support packages for development boards using Espressif's SoCs, written in
| [ESP32-S2-Kaluga Kit](esp32_s2_kaluga_kit) | ESP32-S2 | LCD display, audio codec + power amplifier,<br>smart LED and camera | <img src="docu/pics/kaluga.png" width="150"> |
| [ESP32-S3-USB-OTG](esp32_s3_usb_otg) | ESP32-S3 | LCD display, uSD card slot, USB-OTG | <img src="docu/pics/esp32_s3_otg.png" width="150"> |
| [ESP32-S3-EYE](esp32_s3_eye) | ESP32-S3 | LCD display, camera, uSD card slot, microphone and accelerometer | <img src="docu/pics/s3-eye.webp" width="150"> |
| [ESP32-S3-LCD-EV-BOARD](esp32_s3_lcd_ev_board) | ESP32-S3 | LCD display with touch, audio codec + power amplifier | <img src="docu/pics/esp32-s3-lcd-ev-board_800x480.png" width="150"> |
| [ESP32-S3-LCD-EV-Board](esp32_s3_lcd_ev_board) | ESP32-S3 | LCD display with touch, audio codec + power amplifier | <img src="docu/pics/esp32-s3-lcd-ev-board_800x480.png" width="150"> |
| [ESP32-S3-Korvo-2](esp32_s3_korvo_2) | ESP32-S3 | LCD display, camera, uSD card slot, microphone, audio codec + power amplifier | <img src="docu/pics/korvo-2.png" width="150"> |
| [ESP32-LyraT](esp32_lyrat) | ESP32 | uSD card slot, microphone, audio codec + power amplifier | <img src="docu/pics/lyrat.png" width="150"> |
| [ESP32-C3-LCDKit](esp32_c3_lcdkit) | ESP32-C3 | LCD display with encoder, IR, PDM audio| <img src="docu/pics/esp32_c3_lcdkit.png" width="150"> |
Expand Down Expand Up @@ -41,12 +41,12 @@ Best way to start with ESP-BSP is trying one of the [examples](examples) on your
| [display_camera](examples/display_camera) | Kaluga-kit |
| [display_audio_photo](examples/display_audio_photo) | ESP-BOX |
| [display_rotation](examples/display_rotation) | ESP-BOX |
| [display_lvgl_demos](examples/display_lvgl_demos) | ESP32-S3-LCD-EV-BOARD |
| [display_lvgl_demos](examples/display_lvgl_demos) | ESP32-S3-LCD-EV-Board |
| [mqtt_example](examples/mqtt_example) | Azure-IoT-kit |
| [sensors_example](examples/sensors_example) | Azure-IoT-kit |

### BSP headers
Each BSP provides its header file in 'bsp' subfolder, so it can be included as follows: `#include "bsp/name-of-the-bsp.h"`.
Each BSP provides its header file in 'bsp' subfolder, so it can be included as follows: `#include "bsp/name-of-the-bsp.h"`.
For you convenience, each BSP also provides a wrapper header, which has the same name for all BSPs: `#include "bsp/esp-bsp.h"`.

BSPs that contain LCD screen or touchscreen also provide `bsp/display.h` and `bsp/touch.h`. These files provide functions for LCD or touchscreen initialization without LVGL graphics library, which is used by default.
Expand Down
6 changes: 3 additions & 3 deletions SquareLine/boards/esp32_s3_lcd_ev_board/manifest.json
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
{
"name":"ESP32-S3-LCD-EV-BOARD",
"name":"ESP32-S3-LCD-EV-Board",
"version":"1.0.0",
"mcu":"ESP32S3",

"screen_width":"800",
"screen_height":"480",
"screen_color_swap":false,

"short_description":"ESP32-S3-LCD-EV-BOARD is a development board for evaluating and verifying ESP32-S3 screen interactive applications. It has the functions of touch screen interaction and voice interaction.",
"long_description":"ESP32-S3-LCD-EV-BOARD has an ESP32-S3-WROOM-1 module with built-in 16 MB Flash and 8 MB PSRAM. It features onboard audio codec + audio amplifier and onboard dual microphone pickup. It uses USB type-C interface for download and debugging. ESP32-S3-LCD-EV-BOARD can be used with different screen sub boards with various screen sizes and resolutions, and supports RGB, 8080, SPI, I2C interface screens.",
"short_description":"ESP32-S3-LCD-EV-Board is a development board for evaluating and verifying ESP32-S3 screen interactive applications. It has the functions of touch screen interaction and voice interaction.",
"long_description":"ESP32-S3-LCD-EV-Board has an ESP32-S3-WROOM-1 module with built-in 16 MB Flash and 8 MB PSRAM. It features onboard audio codec + audio amplifier and onboard dual microphone pickup. It uses USB type-C interface for download and debugging. ESP32-S3-LCD-EV-Board can be used with different screen sub boards with various screen sizes and resolutions, and supports RGB, 8080, SPI, I2C interface screens.",

"placeholders":
{
Expand Down
6 changes: 3 additions & 3 deletions components/esp_lvgl_port/docs/performance.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ On the other hand, the frame buffer(s) will consume significant portion of your

Main takeaways from the graph are:

* The size of **LVGL buffer** and **double buffering** feature has big impact on performance.
* The size of **LVGL buffer** and **double buffering** feature has big impact on performance.
* Frame buffer size >25% of the screen does not bring relevant performance boost
* Frame buffer size <10% will have severe negative effect on performance

Expand Down Expand Up @@ -124,7 +124,7 @@ Default changes:

[^1]: This is not working in default and sometimes in fast changes on screen is not working properly.

### RGB LCD (without `esp_lvgl_port`), PSRAM (octal) with GDMA - ESP32-S3-LCD-EV-BOARD
### RGB LCD (without `esp_lvgl_port`), PSRAM (octal) with GDMA - ESP32-S3-LCD-EV-Board

<img src="https://github.com/espressif/esp-bsp/blob/master/docu/pics/esp32-s3-lcd-ev-board_800x480.png?raw=true" align="right" width="300px" />

Expand Down Expand Up @@ -155,5 +155,5 @@ Default settings:
The graphical performance depends on a lot of things and settings, many of which affect the whole system (Compiler, Flash, CPU, PSRAM configuration...). The user should primarily focus on trade-off between frame-buffer(s) size and RAM consumption of the buffer, before optimizing the design further.

Other configuration options not covered in this document are:
* Hardware interfaces, color depth, screen definition (size), clocks, LCD controller and more.
* Hardware interfaces, color depth, screen definition (size), clocks, LCD controller and more.
* Complexity of the graphical application (number of LVGL objects and their styles).
17 changes: 17 additions & 0 deletions esp32_s3_lcd_ev_board/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,20 @@
* RGB Anti-tearing:
* Optimize direct mode
* Use triple-buffer in full-refresh mode

## v2.0.0 - 2023-08-07

### Features

* Configurations:
* Add support for screen rotation using triple buffers when enabling RGB anti-tearing.
* Add support for configuring SPIFFS.
* Remove the `BSP_LCD_SUB_BOARD` configuration.
* Implementations:
* Use `esp_lcd_panel_io_additions` and `esp_lcd_gc9503` components to drive the LCD of sub_board2.
* Use `esp_codec_dev` component to handle audio chips.
* Implement automatic detection of the LCD sub-board type
* APIs:
* Add new APIs for display in `bsp/display.h`
* Add new APIs for touch in `bsp/touch.h`
* Add new APIs for spiffs, audio in `bsp/esp32_s3_lcd_ev_board.h`
14 changes: 4 additions & 10 deletions esp32_s3_lcd_ev_board/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
set(SUB_BOARD_SRC "")

if (CONFIG_BSP_LCD_SUB_BOARD_480_480)
set(SUB_BOARD_SRC "sub_board/sub_board_480x480.c")
elseif (CONFIG_BSP_LCD_SUB_BOARD_800_480)
set(SUB_BOARD_SRC "sub_board/sub_board_800x480.c")
endif()
file(GLOB_RECURSE SRCS src/*.c)

idf_component_register(
SRCS "esp32_s3_lcd_ev_board.c" ${SUB_BOARD_SRC}
SRCS ${SRCS}
INCLUDE_DIRS "include"
PRIV_INCLUDE_DIRS "priv_include"
REQUIRES driver
PRIV_REQUIRES esp_timer esp_lcd
REQUIRES driver spiffs esp_lcd
PRIV_REQUIRES esp_timer
)
61 changes: 50 additions & 11 deletions esp32_s3_lcd_ev_board/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -26,27 +26,42 @@ menu "Board Support Package"
default 100000
endmenu

menu "LCD"
choice BSP_LCD_SUB_BOARD
prompt "Select Sub board"
default BSP_LCD_SUB_BOARD_800_480
config BSP_LCD_SUB_BOARD_480_480
bool "Sub board 2 with 480x480 RGB LCD"
config BSP_LCD_SUB_BOARD_800_480
bool "Sub board 3 with 800x480 RGB LCD"
endchoice
menu "SPIFFS - Virtual File System"
config BSP_SPIFFS_FORMAT_ON_MOUNT_FAIL
bool "Format SPIFFS if mounting fails"
default n
help
Format SPIFFS if it fails to mount the filesystem.

config BSP_SPIFFS_MOUNT_POINT
string "SPIFFS mount point"
default "/spiffs"
help
Mount point of SPIFFS in the Virtual File System.

config BSP_SPIFFS_PARTITION_LABEL
string "Partition label of SPIFFS"
default "storage"
help
Partition label which stores SPIFFS.

config BSP_SPIFFS_MAX_FILES
int "Max files supported for SPIFFS VFS"
default 5
help
Supported max files for SPIFFS in the Virtual File System.
endmenu

menu "LCD"
config BSP_LCD_RGB_BUFFER_NUMS
int "Set number of frame buffers"
depends on BSP_LCD_SUB_BOARD_480_480 || BSP_LCD_SUB_BOARD_800_480
default 1
range 1 3
help
Let RGB LCD driver create a specified number of frame-size buffers. Only when it is set to multiple can the avoiding tearing be turned on.

choice BSP_LCD_RGB_REFRESH_MODE
prompt "Select the refresh mode for RGB LCD"
depends on BSP_LCD_SUB_BOARD_480_480 || BSP_LCD_SUB_BOARD_800_480
default BSP_LCD_RGB_REFRESH_AUTO
config BSP_LCD_RGB_REFRESH_AUTO
bool "Auto refresh mode"
Expand Down Expand Up @@ -126,6 +141,30 @@ menu "Board Support Package"
bool "Direct mode"
endchoice

choice BSP_DISPLAY_LVGL_ROTATION
depends on BSP_DISPLAY_LVGL_AVOID_TEAR
depends on BSP_LCD_RGB_BUFFER_NUMS = 3
prompt "Select rotation"
default BSP_DISPLAY_LVGL_ROTATION_NONE
config BSP_DISPLAY_LVGL_ROTATION_NONE
bool "Rotation 0"
config BSP_DISPLAY_LVGL_ROTATION_90
bool "Rotation 90"
config BSP_DISPLAY_LVGL_ROTATION_180
bool "Rotation 180"
config BSP_DISPLAY_LVGL_ROTATION_270
bool "Rotation 270"
help
Rotate screen when avoid tearing effect is enabled.
endchoice

config BSP_DISPLAY_LVGL_ROTATION_DEGREE
int
default 0 if BSP_DISPLAY_LVGL_ROTATION_NONE
default 1 if BSP_DISPLAY_LVGL_ROTATION_90
default 2 if BSP_DISPLAY_LVGL_ROTATION_180
default 3 if BSP_DISPLAY_LVGL_ROTATION_270

choice BSP_DISPLAY_LVGL_BUF_CAPS
depends on !BSP_DISPLAY_LVGL_AVOID_TEAR
prompt "Select LVGL buffer memory capability"
Expand Down
Loading

0 comments on commit d05add1

Please sign in to comment.