After making the panda project I had ordered some Waveshare eyes because they were smaller and didnt want as much print time on the printer. The board has two round screens, one cable, and using an ESP32 create eyes that blink, look around, and change mood. This project uses the Waveshare 0.71 inch DualEye 0.71inch DualEye LCD Module programmed for a 38-pin ESP32-WROOM in the Arduino IDE. The Waveshare module is a single board with two 160×160 IPS circles. Each circle has its own GC9D01 controller. DIN, CLK, and DC are shared. Chip select, reset, and backlight are separate, so each eye can be started and rotated on its own.

What the eyes do
The pupils breathe, the gaze wanders, and the lids blink, including the occasional double blink. A phone can connect to the board’s Wi-Fi picks the eye design and the emotion. A button on GPIO 32 only walks through the emotions, because there is no dropdown on the glasses. The colors follow the 11-pin connector that comes with them and powers the module from the ESP32 3.3 V pin.
| Color | DualEye pin | ESP32 GPIO | What it does |
|---|---|---|---|
| Red | VCC | 3V3 | Power |
| Black | GND | GND | Ground |
| Brown | DIN | 23 | SPI data |
| Purple | CLK | 18 | SPI clock |
| Blue | CS1 | 5 | Eye 1 chip select, active low |
| Green | CS2 | 4 | Eye 2 chip select, active low |
| Orange | DC | 21 | Data or command |
| Yellow | RST1 | 22 | Eye 1 reset, active low |
| White | RST2 | 17 | Eye 2 reset, active low |
| Black | BL1 | 16 | Eye 1 backlight, on when high |
| Grey | BL2 | 27 | Eye 2 backlight, on when high |
The official Waveshare guide is written for an ESP32-C3 or ESP32-S3 Zero. Those GPIO numbers do not land on the same pins of a 38-pin dev board, so the table above is the one that matches this module on a WROOM. The optional button is a momentary switch from GPIO 32 to GND. The pin is held high inside the chip. Each press advances the emotion and leaves the eye type alone.
The driver
The sketch uses LovyanGFX. The panel class is named Panel_Round_GC9A01_071. The name says GC9A01. The init bytes are the 0.71 inch GC9D01 sequence: 0xFE / 0xEF, registers 0x80–0x8F, and pixel format 0x05. That matches the sequence Waveshare ships in their TFT_eSPI demo, and it matches the GC9D01N datasheet: 160×160, SPI, RGB565. Upload from the Arduino IDE with the board set to ESP32 Dev Module, after the ESP32 board package and LovyanGFX are installed.
The phone page

After the eyes are up, the board opens an open Wi-Fi network named Eyes. There is no password. Join it and open http://192.168.4.1. The phone has no internet while it is on that network.
The page has two controls. Eye type is the dropdown. Select an emotion is the grid of buttons under it. Changing the type redraws the iris, pupil, lids, shine, and gaze, and keeps the emotion you already chose. Changing the emotion keeps the type. Boot starts on Panda, with Normal eyes.
Twenty-one eye types
- Panda is the default. Dark lids, a warm brown iris, a round pupil, and a white sclera with a soft edge shadow.
- Pony is a glossy dark eye with a brown iris. The iris stays put and only the pupil looks around. A light arc sits on the glass. Joy is amber.
- Cow and Glossy Yellow share one yellow glossy eye: a large yellow-green iris on a near-black sclera, a fixed iris, and the same arc.
- Glossy Blue keeps that glossy shape and turns the iris cyan. Joy follows the iris.
- Glossy Pink keeps the glossy shape and turns the iris pink. Joy follows the iris.
- Hearts is a pink iris with a heart-shaped pupil and large catchlights.
- Anime Blue is a tall blue iris, a vertical slit, big highlights, and a high upper lid.
- Cat is a green-yellow iris, a narrow vertical slit, an orange lid, and long streaks through the iris.
- Owl is an amber iris on a dark brown sclera, a slow gaze, and a longer blink.
- Puppy is a brown iris with a sad tilt, a slightly closed upper lid, a raised lower lid, and large highlights.
- Frog is a yellow-green sclera, a gold iris, and a wide horizontal pupil.
- Robot is a small cyan iris on a dark blue sclera, a ring pupil, a short glow, flat lids, and fast blinks.
- Cyborg is a small red iris, a ring pupil, a strong red glow, a half-closed upper lid, and a fast twitchy gaze.
- Goat is a gold iris, a horizontal pupil, a cream sclera, and a slow gaze that often rests in the center.
- Alien is a huge dark iris on a black sclera and a quick gaze.
- Bloodshot is a red-tinted white with branching veins, a small green iris, heavy lids, and a restless gaze.
- Vampire is a red iris, a vertical slit, a pale red sclera with veins, a purple lid, a small red glow, and an angry tilt.
- Werewolf is a gold iris, a tiny round pupil, a cream sclera, a heavy angry tilt, and a partly closed upper lid. The gaze is fast.
- Skeleton is a black sclera, a tiny red pupil, and a wide red glow. Blinks are rare.
- Dragon is a huge orange iris, a very thin vertical slit, a dark red sclera, an orange glow, and a tilted upper lid.
Seventeen emotions
Normal eyes sits on the top row. Under it are Joy, In Love, Starstruck, K.O., Dizzy, Cheerful, Wink, Sad, Crying, Angry, Scared, Excited, Tired, Suspicious, Curious, and Shy.
Joy, In Love, Starstruck, K.O., and Dizzy replace the eyes with a symbol. On Pony, Glossy Blue, and Glossy Pink, the Joy mark uses that type’s color. The other emotions keep the eyes and move the lids, the pupils, and the gaze. A choice stays until the next press or the next tap.
Code
Can be found on my gitlab: https://gitlab.com/illwill/waveshare_eye






























































































Skype
Email
Keybase.io

