Menu

I made an Android app for my ESP32 M5StickC Plus 2: live menu state, file manager and screen text over USB/BLE

#esp32#redditesp32#menu#firmware#base64
Reading 0:00
15s threshold

I wanted to control my M5StickC Plus 2 (ESP32-PICO-V3-02, 8 MB flash, CH9102 USB-UART) from my phone, so I wrote a small C++ bridge for the firmware and a Material 3 Android app.

Why a bridge instead of screen streaming

The firmware exposes its own state over a line-based ASCII protocol, so the app works with real data instead of pixels:

```

CMD:MENU:LIST < MENU:TITLE:<base64> < MENU:ITEM:0:1:<base64 label> < MENU:SEL:-1 < MENU:END ```

Tapping an item sends CMD:MENU:OPEN:n and the firmware opens that menu entry itself. The file manager uses FS:LIST|READ|WRITE|DELETE|MKDIR|RENAME with base64 payloads and 256-byte upload chunks into LittleFS.

ESP32 details

Arduino-ESP32 3.x / PlatformIO, m5stack-cplus2 board, 8 MB flash partition table.

USB CDC at 115200 8N1 through the CH9102, plus BLE using the Nordic UART Service (MTU negotiation, chunked writes) or the firmware's own BLE serial service.

IR output uses the existing NEC/Samsung/Sony encoders on the Stick's IR LED, so pulse timings are…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.