Robotinc

Part 1: Setting up M5Stick C Plus

The M5Stick C Plus is a compact ESP32-based IoT device with a built-in screen, battery and WiFi. It’s cheap (~£30), easy to program and perfect for prototyping Physical AI systems. The device can do far more (sensors, motion, networking), but we’re keeping it basic to focus on the Physical AI concept itself.

M5Stick C Plus

What You’ll Need

Step 1: Install Arduino IDE

Download from arduino.cc

Step 2: Add M5Stack Board Support

  1. Open Arduino IDE
  2. Go to File → Preferences
  3. Add to “Additional Board Manager URLs”:
    https://m5stack.oss-cn-shenzhen.aliyuncs.com/resource/arduino/package_m5stack_index.json
    
  4. Go to Tools → Board → Boards Manager
  5. Search “M5Stack” and install

Step 3: Install M5StickCPlus Library

  1. Go to Sketch → Include Library → Manage Libraries
  2. Search “M5StickCPlus”
  3. Install the library

Step 4: Basic Blue Screen Test

Create new sketch and paste:

#include <M5StickCPlus.h>

void setup() {
  M5.begin();
  M5.Lcd.setRotation(3);
  M5.Lcd.fillScreen(TFT_BLUE);
}

void loop() {
  M5.update();
}

Step 5: Upload to M5Stick

  1. Connect M5Stick via USB-C
  2. Select Tools → Board → M5Stick-C-Plus
  3. Select Tools → Port (usually /dev/cu.usbserial-* on Mac)
  4. Click Upload button

Our M5Stick screen should turn blue!

Lessons Learned

Next Steps

Part 2: Why MQTT for IoT Communication →