Code repository for Penn State CMPEN482W Engineering Capstone Project: Fall 2022
This repository contains code and instructions for creating a cloud-controlled IoT traffic light intersection using a Nordic Semiconductor Thingy:91, and an ESP32 based microcontroller from HiLETGo.
The IoT protocol empowering this design is oneM2M.
The oneM2M standard provides developers with the ability to rapidly create IoT devices that are scalable, secure, and interoperable.
The currently provided instructions are for Amazon Web Services, however other cloud providers can be easily used.
The code and instructions for programming the Thingy:91 are located in the thingy folder.
The code and instructions for programming the ESP32 are located in the esp32 folder.
There is a simple Python Dash web dashboard located in the py-dash folder.
To install the dependencies: pip install -r py-dash/requirements.txt
To launch: python -m py-dash.__init__ --config py-dash/dashCfg.cfg
We deploy this code onto an AWS EC2 instance with firewall rules setup to allow HTTP traffic through port 80.
This allows users to view and control the traffic lights from any device with any modern web browser and internet connection.
The oneM2M standard requires a oneM2M network to contain a Common Services Entity (CSE).
This CSE provides many different features, but in our case is considered as the database for our application.
Our project uses the ACME CSE, which is developed by Andreas Kraft and other contributors.
We deploy this ACME CSE onto an AWS EC2 instance and open up the firewall to allow traffic through port 8080. To launch the ACME CSE, run the following command:
python3.8 -m acme --headless --no-mqtt --http-port 8080 &
We would like to thank the sponsor for this project, Exacta Global Smart Solutions.
Exacta GSS is a leading edge consultant for oneM2M IoT projects.
We would also like to thank Nordic Semicondictor for their support while developing on their Thingy:91 prototyping platform.