UNIVERSITY OF WEST ATTICA
SCHOOL OF ENGINEERING
DEPARTMENT OF COMPUTER ENGINEERING AND INFORMATICS
University of West Attica · Department of Computer Engineering and Informatics
Internet of Things
Vasileios Evangelos Athanasiou
Student ID: 19390005
Angelos Vasileios Mantzoukas
Student ID: 19390128
Christos Pylarinos
Student ID: 20390278
Supervision
Supervisor: Panagiotis Karkazis, Associate Professor
Co-supervisor: Rania Garofalaki, Laboratory Teaching Staff
Athens, January 2025
This guide explains how to install, configure, and run the IoT Traffic Lights project using Arduino UNO, ESP-01 (ESP8266), and ThingSpeak.
- Arduino UNO
- ESP-01 (ESP8266) WiFi module
- Breadboard
- Jumper wires (Male–Male, Male–Female)
- Resistors for voltage divider (e.g., 1.8kΩ and 3.3kΩ)
- USB cable (Arduino ↔ PC)
Warning:
ESP-01 uses 3.3V logic. A voltage divider is required between Arduino TX (5V) and ESP-01 RX.
- Operating System: Windows / Linux / macOS
- Arduino IDE (v1.8.x or newer)
- USB drivers (CH340 or ATmega16U2, depending on board)
- Internet connection
- ThingSpeak account: https://thingspeak.com
- Download from: https://www.arduino.cc/en/software
- Install with default options.
- Launch Arduino IDE.
- Connect Arduino UNO via USB.
- In Arduino IDE:
- Tools → Board → Arduino UNO
- Tools → Port → Select correct port
- Upload the Blink example to verify functionality.
| Arduino UNO | ESP-01 | Description |
|---|---|---|
| 3.3V | VCC | Power |
| GND | GND | Common ground |
| TX (Pin 1) | RX | Via voltage divider |
| RX (Pin 0) | TX | Direct |
| 3.3V | CH_PD | Enable |
- Arduino TX → 1.8kΩ → ESP-01 RX
- ESP-01 RX → 3.3kΩ → GND
- Log in to ThingSpeak.
- Create a new channel.
- Enable fields:
- Field 1: Red
- Field 2: Orange
- Field 3: Green
- Field 8: Remote Control
- Navigate to Channel Settings → API Keys
- Copy:
- Write API Key
- Read API Key
git clone https://github.com/Internet-of-Things-aka-Uniwa/Traffic-Lights.git
cd Traffic-LightsOpen one of the following in Arduino IDE:
src/A4/A4.inosrc/B/B.inosrc/C1/C1.inosrc/C2/C2.ino
AT+CWJAP="YOUR_SSID","YOUR_PASSWORD"String writeAPIKey = "YOUR_WRITE_API_KEY";
String readAPIKey = "YOUR_READ_API_KEY";- Temporarily disconnect ESP-01 TX/RX.
- Click Upload in Arduino IDE.
- Reconnect ESP-01 after upload completes.
- Open Tools → Serial Monitor
- Set correct baud rate (as defined in code).
- Verify:
- WiFi connection
- Data transmission to ThingSpeak
- JSON responses
- ThingSpeak Field 8 = 0
- Sequence: Red → Green → Orange
- ThingSpeak Field 8 = 1
- Orange light only
- ESP-01 not responding: Check 3.3V supply and voltage divider
- No ThingSpeak data: Verify API keys and WiFi credentials
- Upload errors: Disconnect ESP-01 TX/RX during upload
- Navigate to the
docs/directory - Open the report corresponding to your preferred language:
- English:
Electrical-Signal-Light.pdf - Greek:
Ηλεκτρικός-Φωτεινός-Σηματοδότης.pdf
- English:

