Background
DoorMe was a group submission (with my friend Ryan Chan) to NewHacks, a 24-hour hackathon that ran in November 2021.
DoorMe is a QR code and knock-based automated deadbolt locking system that allows you to control who does and doesn’t have access to your dorm room without illegally creating extra keys.

How We Built It
The deadbolt mechanism was CADed in Solidworks, then 3D printed. It uses a servo to push a bolt horizontally. For QR code detection, we first used an ESP32-CAM but after running into resolution complications opted to tape a tablet to our dorm door. The camera is streamed through a server to any of our laptops where the feed is then run through some image processing using OpenCV, for example fixing the door's natural fish-eye warp. The new corrected feed is then passed to a QR code reading library and reads a name to be checked against our guest list. If they are on this list, our laptop sends a packet over serial to an Arduino which drives the servo motor, unlocking the door. We used python to create an app that generates QR codes for a given list of names, this also becomes the guest list that we compare scanned QR codes to when checking if DoorMe should unlock/not unlock the door. The door can also be controlled by knocks or sequences of knocks through a volume sensor and Arduino code, which allows the door to be locked from the outside easily.
Challenges We Ran Into
Our biggest challenge was probably trying to get a sharp enough image on the ESP32-CAM and the tablet camera to read the Vaccine QR codes, but unfortunately neither had a large enough resolution to scan the Vaccine QR passport successfully. We also realized the importance of maintaining a consistent development environment so that our code behaves the same across different laptops. This issue mostly came up as a result of our python modules not having the same versions.
Accomplishments that we're proud of
DoorMe successfully reads a QR code, compares it to the generated list, and then unlocks. DoorMe also locks when hearing a specific knocking pattern making it easy to lock your dorm door. Basic image processing that fixes the fish-eye warp caused by the peephole's lens. Successfully decoded Vaccine QR codes.
What we learned
We learned how the ESP32-CAM works as well as how the libraries for QR code scanning work. We also learned about optical distortion, specifically fish-eye warps & the polynomial math required to fix it. We learned how to clean up a signal from a noisy volume sensor into clear individual knocks.