Embedded Programming
Toolchain and Workflow Comparison
I explored, programmed, and compared multiple microcontroller families using distinct toolchains. The microcontrollers I worked with are:
- Arduino Uno
- Arduino Nano
- ESP8266 NodeMCU
- Seeed Studio XIAO RP2040
- Seeed Studio XIAO ESP32-C3
Feature | Arduino Uno/Nano | ESP8266 NodeMCU | XIAO RP2040 | XIAO ESP32-C3 |
---|---|---|---|---|
IDE Used | Arduino IDE | Arduino IDE | Arduino IDE | PlatformIO |
Compiler Toolchain | AVR-GCC | Xtensa GCC | GCC ARM | RISC-V GCC |
Interface | USB Type-B | Micro-USB | USB-C | USB-C |
Communication | UART, I2C, SPI | UART, Wi-Fi | UART, I2C | UART, Wi-Fi |
Development Speed | Easy | Faster | Fast | Very Fast |
Peripheral Support | Basic | Wi-Fi Libraries | Rich I/O | Extensive |
Simulation | Wokwi | Wokwi | Wokwi | Wokwi |
For this assignment, I explored the ESP32-C3 microcontroller using the Wokwi simulator. The goal was to simulate real-world embedded programming tasks, interact with input/output devices, and document the process. Here's a detailed breakdown of the journey:
Getting Started with Wokwi
Objective: Explore the Wokwi platform and familiarize myself with the ESP32-C3 microcontroller.
- I began by signing into Wokwi and creating a new project. Selected the ESP32-C3 board and Arduino template for the simulation environment.
First Circuit: Blinking LED with Serial Monitor
Objective: Create a simple circuit to blink an LED and send a message to the Serial Monitor.
- Used the XIAO ESP32-C3 board with three LEDs (Red, Green, Blue).
- Wrote an Arduino sketch to blink each LED sequentially and display "Hi, how are you?" on the Serial Monitor.
Joystick-Controlled Dual Servo Motors
Objective: Control two servo motors using a joystick for X and Y-axis movement.
Set up a circuit with: - 2 Servo motors - 1 Joystick module - XIAO ESP32-C3 microcontroller
Programmed the servos to move based on joystick inputs:
- X-axis: Controls Servo 1
- Y-axis: Controls Servo 2
Outcome: Smooth servo movement based on joystick inputs. This simulation demonstrated how real-time analog signals can control physical outputs.