Skip to content

Commit

Permalink
Added ESP32_1732S019N
Browse files Browse the repository at this point in the history
  • Loading branch information
rzeldent committed Dec 5, 2023
1 parent 78a7f29 commit eecbb90
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 3 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ jobs:
- board: "esp32dev"
smartboard: "ESP32_3248S035C"
color16swap: 1
- board: "esp32-s3-devkitc-1"
smartboard: "ESP32_1732S019N"
color16swap: 0
- board: "esp32-s3-devkitc-1"
smartboard: "ESP32_4827S043R"
color16swap: 0
Expand Down
15 changes: 12 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
## LVGL drivers and peripheral interface for Chinese Sunton Smart display boards, alias CYD (Cheap Yellow Display)

These boards have an LCD display and most of them have a touch interface; N = No touch, R = Resistive touch, C = Capacitive touch.
Currently this library supports: 2424S012N/C, 2432S024R/C/N, 2432S028R, 2432S032N/R/C, 3248S035R/C, 4827S043R/C, 8048S050N/C and 8048S070N/C.
Currently this library supports: ESP32_1732S019N, 2424S012N/C, 2432S024R/C/N, 2432S028R, 2432S032N/R/C, 3248S035R/C, 4827S043R/C, 8048S050N/C and 8048S070N/C.

This library supports these boards without any effort.

Expand All @@ -32,6 +32,7 @@ They can be bought in the [Sunton Store](https://www.aliexpress.com/store/110019

| Type | CPU | Display | Size | Controller | Rotate support | Color16 swap | Touch | Audio | Flash | RGB LED | CDS | Link|
|--- |--- |--- |-- |--- |--- |--- |--- |--- |--- |--- |--- |--- |
| ESP32_1732S019N | ESP32-S3 | 170x320 | 1.9" | [ST7796](assets/datasheets/ST7796.pdf) | yes | yes | n/a | no | no | no | no | [Ali Express](https://www.aliexpress.com/item/1005005059421229.html) |
| ESP32-2424S012N | ESP32-C3 | 240x240 | 1.2" | [GC9A01A](assets/datasheets/GC9A01A.pdf) | yes | yes | n/a | no | no | no | no | [Ali Express](https://www.aliexpress.com/item/1005005453515690.html) |
| ESP32-2424S012C | ESP32-C3 | 240x240 | 1.2" | [GC9A01A](assets/datasheets/GC9A01A.pdf) | yes | yes | [CST816S](assets/datasheets/CST816S.pdf) | no | no | no | no | [Ali Express](https://www.aliexpress.com/item/1005005453515690.html) |
| ESP32-2432S024N | ESP32 | 240x320 | 2.4" | [ILI9341](assets/datasheets/ILI9341.pdf) | yes | yes | n/a | yes | [W25Q32JV](assets/datasheets/25Q32JVSSIQ.pdf) | yes | yes | [Ali Express](https://www.aliexpress.com/item/1005005865107357.html) |
Expand Down Expand Up @@ -78,6 +79,7 @@ Be aware that the platform board must also match but this is a requirement for a
- ESP32_2424S012C

- esp32-s3-devkitc-1
- ESP32_1732S019N
- ESP32_8048S043N
- ESP32_8048S043R
- ESP32_8048S043C
Expand Down Expand Up @@ -140,6 +142,7 @@ board = esp32-s3-devkitc-1
build_flags =
${env.build_flags}
# Smartdisplay selection
#-D ESP32_1732S019N
#-D ESP32_4827S043R
#-D ESP32_4827S043C
#-D ESP32_8048S043N
Expand Down Expand Up @@ -255,7 +258,7 @@ tone(AUDIO_PIN, frequency, duration);
To produce "real" audio connect the internal 8 bits D2A converter in the ESP32. Because the speaker is connected to GPIO26, this is the DAC2 (Left Channel).
After that, audio can be streamed to the i2s.
The audio is a bit distorted. HexeguitarDIY has a fix for that by changing the resistor values to prevent distortion.
The audio is a bit distorted. [HexeguitarDIY](https://github.com/hexeguitar/ESP32_TFT_PIO) has a fix for that by changing the resistor values to prevent distortion.
[![HexeguitarDIY Audio mod](https://img.youtube.com/vi/6JCLHIXXVus/0.jpg)](https://www.youtube.com/watch?v=6JCLHIXXVus)
## Demo application
Expand All @@ -265,6 +268,10 @@ This application uses this library and the SquareLine Studio GUI generator.
## Board details
### ESP32_1732S019N
- USB-C
### ESP32-2424S012 N/C
- USB-C
Expand Down Expand Up @@ -345,11 +352,13 @@ The following libraries are used from the EspressIf registry:
## Version history
- December 2023
- Added ESP32_1732S019N
- November 2023
- Major version update: 2.0.0
- Rewrite of the library to support the new ESP32-C3 and ESP32-S3 panels
- Use the new Espressif esp_lcd interface
- Use c instead of cpp
- Use C instead of cpp
- October 2023
- Added support for esp32_8048S034N/C
- Added option for flipped/mirrored TFT's
Expand Down
Binary file added assets/schematics/ESP32-1732S019-LCM-V1.0.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions example/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ board = esp32-s3-devkitc-1
build_flags =
${env.build_flags}
# Smartdisplay selection
#-D ESP32_1732S019N
#-D ESP32_4827S043R
#-D ESP32_4827S043C
#-D ESP32_8048S043N
Expand Down
18 changes: 18 additions & 0 deletions include/esp32_smartdisplay.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,24 @@
#define PWM_BITS_BCKL 8
#define PWM_MAX_BCKL ((1 << PWM_BITS_BCKL) - 1)

// ESP32_1732S019N
#if defined(ESP32_1732S019N)
#define TFT_WIDTH 170
#define TFT_HEIGHT 320
// Backlight
#define PIN_BCKL 14
#define PWM_CHANNEL_BCKL 7
// LCD
#define USES_ST7796
#define ST7796_SPI_HOST SPI2_HOST
#define ST7796_SPI_BUS_CONFIG {.mosi_io_num=13,.sclk_io_num=12,.quadwp_io_num=-1,.quadhd_io_num=-1}
#define ST7796_IO_SPI_CONFIG {.cs_gpio_num=10,.dc_gpio_num=11,.spi_mode=SPI_MODE0,.pclk_hz=24000000,.trans_queue_depth=10,.lcd_cmd_bits=8,.lcd_param_bits=8}
#define ST7796_PANEL_DEV_CONFIG {.reset_gpio_num=-1,.color_space=ESP_LCD_COLOR_SPACE_BGR,.bits_per_pixel=16}
#define PANEL_ROT_NONE_SWAP_XY false
#define PANEL_ROT_NONE_MIRROR_X true
#define PANEL_ROT_NONE_MIRROR_Y false
#endif

// ESP32_2424S012 N/C
#if defined(ESP32_2424S012N) || defined(ESP32_2424S012C)
#define TFT_WIDTH 240
Expand Down

0 comments on commit eecbb90

Please sign in to comment.