Logic & sequencing
Traffic light
Beginner25 min
Three LEDs, a realistic cycle, and a clean introduction to state machines.
What you get
A junction cycling green, amber and red with correct timings, without blocking the program.
Parts (simulated)
- Arduino UNO board
- Red, amber and green LEDs
- 3 × 220 Ω resistors
- Breadboard
Nothing to buy: every component here is simulated in the browser.
Project steps
- 01Wire the three LEDs with their resistors.
- 02Write the simple cycle with delays.
- 03Replace blocking waits with the millis() pattern.
- 04Restructure it as a readable state machine.
What you learn
- Multiple digital outputs
- Non-blocking timing
- State machines
Other projects
- ⌚ Smartwatch
Build a complete watch: OLED screen, DS3231 real-time clock, navigation buttons, then the printed board that goes with it.
- 📺 Mini colour TV (SPI TFT)
The finish line of a 10-project display series: from a single pixel to a colour panel driven over SPI.
- 📻 Digital PMR446 walkie-talkie
A full radio link on the PMR446 band: modulation, channel, noise, demodulation and quality measurement.
- 📱 4G/LTE cellular phone
Understand how a phone attaches to a cell: OFDM modulation, mobility, echoes and useful throughput.