Skip to content

Instantly share code, notes, and snippets.

@decibelkaos
Last active April 25, 2025 17:30
Show Gist options
  • Save decibelkaos/7462f93d6c68c9bcf38212ab0f4535a8 to your computer and use it in GitHub Desktop.
Save decibelkaos/7462f93d6c68c9bcf38212ab0f4535a8 to your computer and use it in GitHub Desktop.
Waveshare ESP32-S3-Touch-LCD-1.28 Detailed Document

Waveshare ESP32-S3-Touch-LCD-1.28 Complete Documentation

[This document is still being updated, I'm a little slow at reading schematics. -Carl]

Board Overview

  • Manufacturer: Waveshare
  • PCB Thickness: 1.0mm
  • Display Size: 1.28" Round LCD
  • Display Resolution: 240×240 pixels
  • Main Processor: ESP32-S3R2
  • Display Controller: GC9A01
  • Touch Controller: CST816T
  • IMU Sensor: QMI8658C
  • MEMS Microphone: SPM1423
  • USB Controller: CH343P
  • Flash Memory: W25Q128JVS
  • Battery Management: IP5209

Physical Specifications

Parameter Value Notes
Board Diameter 38.51±0.05mm Total board size
Display Area 33.40±0.10mm Viewable area (VA)
Total Height 40.36mm Including components
USB Location Bottom edge Type-C connector
Battery Port JST 1.25mm 2-pin connector

Core Components Breakdown

1. ESP32-S3R2 Microcontroller

Specifications

Parameter Value Notes
CPU Dual-core LX7 Up to 240MHz
SRAM 512KB Internal memory
PSRAM 2MB External memory
Wi-Fi 802.11 b/g/n 2.4 GHz
Bluetooth BLE 5.0 Dual-mode
USB OTG Type-C interface

GPIO Assignments (Verified Working Pins)

Function GPIO Pin Notes
TFT Backlight GPIO2 PWM capable
TFT DC GPIO8 Data/Command
TFT CS GPIO9 Chip Select
TFT SCLK GPIO10 SPI Clock
TFT MOSI GPIO11 SPI Data Out
TFT MISO GPIO12 SPI Data In
TFT RST GPIO14 Reset

2. GC9A01 Display Controller

Specifications

Parameter Value Notes
Resolution 240×240 Round format
Color Depth 16-bit 65K colors
Interface 4-wire SPI Up to 80MHz
Viewing Angle 170° All directions
Driver GC9A01 Single chip

Pin Configuration

Signal Name GPIO Pin Description
BL GPIO2 Backlight control
DC GPIO8 Data/Command
CS GPIO9 Chip Select
SCL GPIO10 SPI Clock
SDA GPIO11 SPI Data
RST GPIO14 Reset

3. QMI8658C IMU Sensor

Specifications

Parameter Value Notes
Gyroscope Range ±2000°/s Programmable
Accelerometer ±16g Programmable
Resolution 16-bit ADC
Interface I2C 400kHz
Address 0x6B 7-bit I2C address

Pin Configuration

Signal Name GPIO Pin Description
SCL GPIO7 I2C Clock
SDA GPIO6 I2C Data
INT GPIO13 Interrupt

4. CST816T Touch Controller

Specifications

Parameter Value Notes
Touch Points 5-point Multi-touch
Interface I2C 400kHz
Address 0x15 7-bit I2C address
Resolution 240×240 Matches display

Pin Configuration

Signal Name GPIO Pin Description
SCL GPIO7 I2C Clock
SDA GPIO6 I2C Data
INT GPIO5 Interrupt
RST GPIO4 Reset

5. SPM1423 MEMS Microphone

Specifications

Parameter Value Notes
Sensitivity -38dB ±1dB @94dB SPL
SNR 64dB A-weighted
Interface PDM Digital output
Supply 1.6V-3.6V Typical 3.3V
Current 600µA Typical

Pin Configuration

Signal Name GPIO Pin Description
CLK GPIO16 PDM Clock
DATA GPIO15 PDM Data

6. CH343P USB Controller

Specifications

Parameter Value Notes
USB Version 2.0 Full Speed
Baud Rate 300-2M bps Programmable
Interface UART Serial
Flow Control Hardware/Software RTS/CTS

Pin Configuration

Signal Name GPIO Pin Description
USB D+ GPIO19 USB Data Plus
USB D- GPIO20 USB Data Minus
TXD Internal UART Transmit
RXD Internal UART Receive

7. W25Q128JVS Flash Memory

Specifications

Parameter Value Notes
Capacity 16MB 128Mbit
Interface SPI Up to 133MHz
Sectors 4KB Erase size
Pages 256B Program size

Pin Configuration

Signal Name GPIO Pin Description
CS GPIO21 Chip Select
SCK GPIO17 Clock
SDO GPIO18 Data Out
SDI GPIO3 Data In

8. IP5209 Battery Management

Specifications

Parameter Value Notes
Input 5V USB-C Power input
Battery 3.7V Li-Po Single cell
Charging 500mA max Programmable
Protection Multiple Over-voltage/current

Programming Information

Arduino IDE Settings

Board: ESP32S3 Dev Module
Flash Mode: QIO
Flash Size: 16MB
PSRAM: OPI PSRAM
CPU Frequency: 240MHz
USB CDC On Boot: Enabled
Upload Mode: USB-CDC
*// For proper serial output, boards.txt needs to be manually modified.
*// find:      waveshare_esp32s3_touch_lcd_128.build.cdc_on_boot=1
*// change to: waveshare_esp32s3_touch_lcd_128.build.cdc_on_boot=0

Required Libraries

  • TFT_eSPI (Display)
  • Wire (I2C Communication)
  • QMI8658C (IMU)
  • CST816T (Touch)

Notes and Recommendations

  1. I2C bus is shared between touch controller and IMU
  2. Battery voltage can be monitored via GPIO1 (ADC)
  3. Display requires special initialization for GC9A01
  4. Boot button (GPIO0) is used for firmware flashing
  5. USB-C port supports both power and programming

Note: All pin assignments and specifications have been verified against the schematic to the best of my knowledge, and I am currently testing for innacuracy. Always refer to the official documentation for the most current information.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment