Skip to content

piyopiyoex/hello_atomvm_lcd_spi

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Hello AtomVM LCD SPI Example

This is a tiny Elixir/AtomVM demo for the Seeed XIAO-ESP32S3 featuring:

  • A 480×320 ILI9488 LCD driven over SPI
  • FAT-formatted SD card support with automatic image loading
  • A lightweight HH:MM:SS clock overlay
  • Resistive touch input via XPT2046/ADS7846 (with a small on-screen cursor + x:y readout)

Hardware Overview

This project uses a custom breakout board designed for the XIAO-ESP32S3, with connectors for:

  • ILI9488 LCD
  • XPT2046/ADS7846 touch controller
  • SD card (shared SPI bus)

Two board revisions are supported:

  • v1.5 or lower — original wiring
  • v1.6 or higher — same board, except LCD-CS and SD-CS are swapped

These are the boards shown in the photos below.


Wiring

Base wiring for v1.5 (and lower):

Function XIAO-ESP32S3 pin ESP32-S3 GPIO
SCLK D8 7
MISO D9 8
MOSI D10 9
LCD CS 43
Touch CS 44
LCD D/C D2 3
LCD RST D1 2
SD CS D3 4

For v1.6 (and higher), these two swap:

  • LCD CS → GPIO4
  • SD CS → GPIO43

Build & Flash

# 1. Install dependencies
mix deps.get

# 2. Select board version (default: v1.6)
export PIYOPIYO_BOARD=v1.5
# or
export PIYOPIYO_BOARD=v1.6

# 3. Build the AVM image
# NOTE: Run `mix clean` whenever you change PIYOPIYO_BOARD.
mix clean
mix atomvm.packbeam   # outputs _build/atomvm/main.avm

# 4. Flash to the ESP32-S3
mix atomvm.esp32.flash --port /dev/ttyACM0 --baud 115200

.RGB Images

  • Raw RGB888 (no header), top-left origin
  • Exact size: 480 × 320 × 3 = 460,800 bytes
  • Place the files at the SD card root; a fallback priv/default.rgb is used if none are found

About

ILI9488 + SD + Touch (AtomVM / XIAO-ESP32S3)

Topics

Resources

License

Stars

Watchers

Forks

Contributors 2

  •  
  •  

Languages