Sri Lanka has a lot of Parking Lots Managed by RDA (Road Development Authority) but almost all use paper receipts to maintain Timings of Parked Vehicles. This process is error prone and difficult to keep on days where vehicle come and go out frequently.
This motivated me to do a small PoC on a Low Cost RFID based Parking Solution. I had a HZ-1050 RFID Reader lying around in my Hack Space and 1 RFID Card with 2 RFID Tags so I decided to use those.
Above is the Setup which is really simple, Just need to wire up Raspberry Pi 5v -> HZ-1050 5v, Raspberry Pi Ground -> HZ-1050 Ground, HZ-1050 D0 -> Raspberry Pi Pin 14, HZ-1050 D1 -> Raspberry Pi Pin 15
Finally the Code.
Reading RFID Card/Tag and Storing in Database
I used PiGPIO Library with a Small a Python Script modified from their Example to read the Wiegand Format RFID No and Store it in a SQLite3 Database.
Displaying in Dashboard
This motivated me to do a small PoC on a Low Cost RFID based Parking Solution. I had a HZ-1050 RFID Reader lying around in my Hack Space and 1 RFID Card with 2 RFID Tags so I decided to use those.
Finally the Code.
Reading RFID Card/Tag and Storing in Database
I used PiGPIO Library with a Small a Python Script modified from their Example to read the Wiegand Format RFID No and Store it in a SQLite3 Database.
Displaying in Dashboard
I wrote a small Dashboard which has a PHP backend and runs on Light Web Server and connect to the same SQLite3 Database to display data. The Front End Bootstrap with JQuery and Javascript.
Following is a Demonstration on everything working together. I will upload code once I clean those up. This can store different Vehicle Types and their Charges for the First Hour and Additional Hours and Calculate the Duration and Charge. Which will be great for the Parking Operator.
References
Parts can be bought at IoT Researcher Shop
- HZ-1050 RFID Reader - http://shop.iotresearcher.com/index.php/en/sensors-c-1/hz-1050-rfid-reader-p-9
- RFID Card - http://shop.iotresearcher.com/index.php/en/accessories-c-3/rfid-card-p-7
- RFID Tag - http://shop.iotresearcher.com/index.php/en/accessories-c-3/rfid-tag-p-6
- Hackaday - http://hackaday.com/2016/11/21/faulty-parking-meter-tracking-system-rfid-to-the-rescue/
- BricoGeek - http://blog.bricogeek.com/noticias/raspberry-pi/control-de-parking-con-rfid-y-raspberry-pi/
1 comment:
Post a Comment