Embedded & IoT
Write ESP32 sketches that read sensors, drive actuators, survive faults, sleep on batteries and report to the cloud.
ESP32 sketches, sensors, buses and power for battery devices.
Before you start: Electronics Fundamentals
Start the course in the labFree. Sign in only if you want your progress on every device.
Module 1: First sketches
Extra practice:
- Light sensor (LDR divider)
- Arduino Uno: upload your first sketch
- Reading a button: floating inputs and INPUT_PULLUP
- analogRead and PWM: a pot dims an LED
- Strapping pins: when the board will not boot
Module 2: Buses and sensors
- I²C scanner
- 16×2 I²C LCD
- I²C sensor: accelerometer tilt
- I²C sensor: temperature, humidity, pressure
- SPI bus: MAX7219 display
Extra practice:
- Bidirectional I²C level shifter (BSS138)
- Load-cell scale front end
- ADC front end: reference and anti-alias filter
Module 3: Actuators
- PWM actuator: hobby servo
- PWM actuator: DC motor through a MOSFET
- Inductive load and the flyback diode
Extra practice:
- H-bridge motor driver
- H-bridge: PWM speed, direction and braking
- ULN2003 driver array for a stepper
- Opto-isolated mains switching (zero-cross SSR)
- Motion-activated light
- Arduino Nano on a breadboard: a servo sweep
Module 4: Reliability
- Interrupts and debouncing
- Watchdog timer
- Settings that survive a reset (NVS)
- Monitoring a supply rail with the ADC
Extra practice:
Module 5: Power for battery devices
Extra practice:
- USB cable voltage drop
- LDO vs buck: choosing a 3.3 V rail
- SEPIC: output above and below the input
- ESP32 battery sensor node
- USB power bank
- 10,000 mAh power bank · 2 × 21700
- Powering an Arduino: USB, VIN and the regulator