This project simulates a simple Dispatch and Receive Unit system using RFID tags and an STM32F401CCU6 board. The system tracks product dispatch and receipt with timestamps, logging information to the Serial Monitor.
- 🔌 Connect the MFRC522 module to your STM32/Arduino board using SPI.
- 📤 Upload the
dispatch_code.inoto the dispatch unit andreceive_code.inoto the receiving unit. - 🖥️ Open the Serial Monitor at a baud rate of 9600.
- 🖥️ Install Arduino IDE or STM32CubeIDE for STM32F401CCU6 development.
- 📦 Install MFRC522 Library:
- In Arduino IDE, go to Sketch > Include Library > Manage Libraries, and search for MFRC522.
- Install the latest version.
- 📇 Scan an RFID tag.
- 🖥️ View the UID, product name, and current date-time in the Serial Monitor.
💡 Note: Programming RFID tags? Do it as a task for yourself.
The dispatch unit continuously checks for the presence of a new RFID card. Upon detection, it reads the UID, identifies the product, and logs the dispatch date and time using the software clock. This information is printed to the serial monitor for monitoring or logging purposes.
The receive unit waits for a card to be scanned. Once detected, it logs the received date and time, matches the UID to a known product, and displays all related details on the serial monitor.
Here are the pin connections for the MFRC522 module with the STM32F401CCU6:
| MFRC522 Pin | STM32F401CCU6 Pin | Description |
|---|---|---|
| SDA | PA4 | SPI Slave Select (SS) |
| SCK | PA5 | SPI Clock (SCK) |
| MOSI | PA7 | SPI Master Out Slave In (MOSI) |
| MISO | PA6 | SPI Master In Slave Out (MISO) |
| RST | PB0 | Reset Pin |
| GND | GND | Ground |
| VCC | 3.3V | Power (3.3V) |
- The system successfully simulates real-time tracking without an RTC.
- It correctly identifies product UIDs, displays accurate timestamps, and handles calendar rollovers (including leap years and month changes).
- The scan delay prevents duplicate logging within a short time frame.
- Small-scale inventory tracking
- Educational demonstrations of RFID systems
- Event attendance systems (e.g., check-in/check-out)
- Local warehouse operations
- The system relies on software time tracking, which may drift over extended periods.
- Data is not stored persistently; adding EEPROM or SD card logging could improve reliability.
- Future versions may include real-time synchronization or network-based data storage.
- 📖 Arduino MFRC522 Documentation
- 📘 STM32 SPI Peripheral Usage
- 📝 millis() Based Software Clocks, Embedded Journal
This project was developed by Krishnaelectrovoltz.
Student | Electronics & Communication Engineer | Hardware Enthusiast
Feel free to reach out for contributions or suggestions.