ESP32-C3 micro board with a round Touch Display
The ESP32-C3 processor is a single-core SoC based on the open-source 32-bit RISC-V architecture.
The module is made by Shenzhen Jingcai Intelligent Co. <www.jczn1688.com> with the number
ESP32-2424S012
using the ESP32-C3-MINI-1U module by espressif offering 4MB Flash Memory and
direct USB-C connectivity.
Arduino Board Configuration
The Arduino Board Manager supports this board by installing the esp32 by espressif
package.
It can be used with the following settings:
- Board: ESP32C3 Dev Module
- Upload Speed: 921600
- USB CDC On Boot: Enabled
- CPU Frequency: 160 MHz
- Flash Frequency: 80MHz
- Flash Mode: QIO
- Flash Size: 4MByte (32Mbit)
- Partition Scheme: Default 4MB with spiffs (1.2MB App/1.5MB SPIFFS)
- Core Debug Level: None
- Erase All Flash: Disabled
- JTAG Adapter: Integrated USB JTAG
The ESP32 Upload function is trying to upload a sketch even when the size is too big. If you see fast repeated log output like below build a smaller ketch by removing un-required elements.
ESP-ROM:esp32c3-api1-20210207
Build:Feb 7 2021
rst:0x3 (RTC_SW_SYS_RST),boot:0xc (SPI_FAST_FLASH_BOOT)
Saved PC:0x403cf91a
SPIWP:0xee
mode:DIO, clock div:1
load:0x3fcd5810,len:0x438
load:0x403cc710,len:0x90c
load:0x403ce710,len:0x25f4
entry 0x403cc710
Device configuration
The SPI pins are used internally for connecting the display.
“spi-scl”: “6”, “spi-mosi”: “7”
Display
The IPS Display is based on the GC9A01 chip and connected via the standard SPI bus. The special pins for the chip communication and the Backlight controlling pin are defined on the element.
{
"DisplayGC9A01": {
"0": {
"title": "Display",
"height": "240",
"width": "240",
"rotation": "180",
"ips": "1",
"background": "black",
"border": "red",
"color": "#6699FF",
"busmode": "spi",
"spidc": "2",
"spics": "10",
"lightpin": 3
}
}
}
Display Touch (CST816D) Controller
https://github.com/fbiego/CST816S ?
#define I2C_ADDR_CST816D 0x15
sda = 4 scl = 5 int = 0 rst = 1
Battery Management
System configuration
This env.json file can be used as a starting point for configuring this board type.
{
"device": {
"0": {
"name": "round",
"title": "ESP32-2424S012",
"description": "240*240 Round Touch Panel from JCZN",
"loglevel": "2",
"button": "9",
"logfile": 1,
"safemode": "false",
"homepage": "/board.htm",
"xcache": "max-age=600",
"i2c-SCL": "5",
"i2c-SDA": "4",
"spi-scl": "6",
"spi-mosi": "7"
}
},
"ota": {
"0": {}
},
"ntptime": {
"on": {
"zone": "CET-1CEST,M3.5.0,M10.5.0/3"
}
},
"diag": {
"0": {}
},
"DisplayGC9A01": {
"0": {
"title": "Display",
"height": "240",
"width": "240",
"rotation": "180",
"ips": "1",
"background": "black",
"border": "red",
"color": "#6699FF",
"busmode": "spi",
"spidc": "2",
"spics": "10",
"lightpin": 3
}
},
"DisplayTouchCST816": {
"0": {
"address": "0x15",
"height": "240",
"width": "240",
"rotation": "180"
}
}
}
See Also
- ESP32-C3 processor
- https://forum.lvgl.io/t/implement-squareline-lvgl-project-to-esp32-2424s012-module-ga9a01-cst816d-drivers/13150
- https://github.com/arendst/Tasmota/discussions/19487
- https://www.espressif.com/sites/default/files/documentation/esp32-c3-mini-1_datasheet_en.pdf
- https://www.tindie.com/products/adz1122/esp32-c3-arduino-lvgl-128-inch-lcd-smart-display