M5StickC

From Wildsong
Jump to navigationJump to search

M5StickC orange and wearable. I have a few of these because they are cheap, come with lots of sensors, a tiny 80x160 LCD, and are nicely enclosed in a little case.

It uses an ESP32-PICO-M4 processor with 520KB of RAM and 4MB of FLASH. It's supposed to be a wearable so it has a battery. This MCU uses more power than an ESP32S3 if that matters to you.

Initially I set up one with a PIR hat and used it to control a light for about a year. Currently it's offline due to household politics. It works really perfectly for this with an MQTT connection to Home Assistant.

Internal photos (This "plus" version has bigger screen) https://www.gwendesign.ch/kb/m5stack/m5stickcplus/ and https://www.gwendesign.ch/kb/m5stack/m5stickc/

It has some magnets in it so you can stick it to things! Cool.

Batteries - it has an RTC button cell and a tiny (95mAH) LiPo. More of a UPS than a power supply.

Looks like taking it apart is a waste of time, things are pretty packed in there. Don't bother. Have lots of other ESP32 things already.

Development environment

So far I have tried ESPHome, CircuitPython and UIFlow on it so far. I have no interest in UIFlow, but I think since it runs on MicroPython you can ignore "flows" and load code.

Since this board has only 520KB of RAM I will probably not go much further with MicroPython and just break down and use C. ESPHome worked fine for my PIR sensor / MQTT IoT project, that's an option still for C programming.

Peripherals

Grove port GND 5V G32 G33 -- these ports can be used as analog inputs

LCD display

6-axis IMU

PMIC

MIC

RTC

IR LED G9

Red LED G10

Button1 = Power on / off / reset

Button2 = G37

Button3 = G39

Pin header (used for add-ons such as the PIR Hat) -- GND 5VOUT G26 G36 G0 BAT 3V3 5VIN

Temperature

Projects

Motion sensor -- ESPhome + PIR Hat + a spare phone charger = a cheap motion sensor that reports over WiFi + MQTT.

LED strip controller -- working on this soon, to control RGBW strips over WiFi, or maybe I will press on with the Nordic nRF52840's and Zigbee.

Resources

https://docs.m5stack.com/en/core/m5stickc

https://m5stack.oss-cn-shenzhen.aliyuncs.com/resource/docs/datasheet/core/esp32-pico-d4_datasheet_en.pdf

Micropython

UIFlow guidebook