Back to Explorer

esp32-CYD

Project Information

Author

Mikrobot.pl

Board

ESP32 Dev Module

SDK Version

3.3.6

Platform

ESP32

Created

Updated

Description

Cycles the full screen of an ESP32-2432S028 (Cheap Yellow Display, ST7789 variant) through ten colors, one per second, using LovyanGFX with all pin configuration defined directly in the sketch.

Flash to Device

Login required: You need to login or create an account to flash this project.

Sorry, your browser doesn't support Web Serial.Web Serial requires HTTPS.

README

ESP32 CYD Color Cycle Test

Full-screen color test for the Cheap Yellow Display using LovyanGFX

This sketch turns an ESP32-2432S028 (Sunton "Cheap Yellow Display") into a simple display tester.
After power-up, the whole screen cycles through 10 colors, one per second, in an endless loop.
It's a quick way to check that the panel, backlight and color order work correctly.


⭐ Features

  • Full-screen color cycle
    • Red, green, blue, yellow, cyan, magenta, white, orange, purple, black
    • 1-second interval, endless loop
  • Self-contained configuration
    • All pins and panel settings are defined in the sketch itself
    • No need to edit any library files (unlike TFT_eSPI)
    • Works the same in Arduino IDE and in cloud tools like FlashESP
  • PWM backlight control at full brightness

πŸ“¦ Hardware requirements

  • ESP32-2432S028 (Cheap Yellow Display, 2.8" 240x320)
  • USB cable for programming

The sketch is configured for the ST7789 panel variant (usually the version with two USB ports: micro-USB + USB-C).

Pin configuration used in the code:

Function GPIO
SCLK 14
MOSI 13
MISO 12
DC 2
CS 15
Backlight 21

πŸ“š Library

LovyanGFX (by lovyan03).

πŸ”§ Troubleshooting

  • Wrong colors (red ↔ blue swapped): set cfg.rgb_order = true.
  • Inverted colors (white shows as black): set cfg.invert = true.
  • Shifted or garbled image: your board may use an ILI9341 panel instead. Replace Panel_ST7789 with Panel_ILI9341.
  • Upload fails with "Unable to verify flash chip connection": lower Tools β†’ Upload Speed to 115200 or 460800.