MetroExpress is a modular embedded firmware project developed for the Digital Egypt Cubs Initiative (DECI) – Embedded Systems Level 5. It simulates a self-service railway ticket machine running on an ATmega32 microcontroller using SimulIDE.
The application is built on top of the provided MCAL drivers and follows a finite state machine (FSM) architecture with separate modules for application control, passenger interaction, and event logging.
- Modular firmware architecture (App, Controller, Passenger, Logger)
- Finite State Machine (FSM) implementation
- Destination selection with LEDs
- Ticket quantity selection using ADC
- UART maintenance logging (9600 baud, 8N1)
- Emergency cancellation using external interrupts
- Inactivity timeout using hardware timers
- SimulIDE simulation support
- CMake-based build system
This project was developed as part of the Digital Egypt Cubs Initiative (DECI) educational program and is intended for learning and demonstration purposes.
git clone --depth 1 https://github.com/Sief-Ali/metro-express.git
cd metro-expressIf you already have the repository and want the latest changes:
git pull origin mainInstall the following tools before building:
- AVR-GCC Toolchain
- CMake
- SimulIDE
Configure the project:
cmake \
-B build \
-DCMAKE_TOOLCHAIN_FILE=cmake/toolchains/avr-gcc.cmakeBuild the firmware:
cmake --build buildThe generated firmware will be located at:
build/src/metro-express.hex
- Launch SimulIDE.
- Open the project:
.simulide/main-v1.sim1
- Load the generated firmware:
build/src/metro-express.hex
- Start the simulation.
.
├── src/
│ ├── app/
│ ├── board/
│ ├── hal/
│ ├── mcal/
│ └── utils/
├── cmake/
├── docs/
├── .simulide/
└── CMakeLists.txt
