Moving into our new office space a few months ago turned out to be an amazing experience. Having the entire floor to ourselves with plenty of space to work, play or just rest, undoubtedly was a fresh start.

With a new office comes a new door, this time decorated by a shiny doorknob on the outside. Consequently when the fanatical developer wants to let herself in, she needs a key. With a company of 40+ this proves to be quite inconvenient, not to mention it would also make the office-manager roll her eyes.

The problem tormented us for weeks as we kept the door constantly open. Then one day, as we said goodbye to yet another travelling salesperson that wandered room to room before getting noticed, the solution hit us.

We shall make a mobile application.

As we would soon find out, the timing could not have been better. In the far north corner of our office, plans for our first Hackathon were being put into motion.

Now, none of this would probably ever happen had it not been for our electrician. Just like all electricians, he visits every now and then, figures out where the grey wire connects to the blue wire and bulbs begin to shine. During one of his visits, he dropped a key piece of information on our shiny new office door “yeah, they have a buzzer”.

Fair enough, it didn’t really mean much when he said it. But at that key moment as the busy developer brain was craving for a solution to the never closing door problem, it pulled out this distant memory and gave birth to LetMeIn, which is how we ended up naming our project. As the Hackathon became a reality, we went ahead and devised a solution.

So we knew we can open the door by an electric signal. And we knew a mobile app can send this signal. The thing in between was still missing.

It was revealed to us that there are two wires coming out of a typical door buzzer. Activating the buzzer (thus unlocking the door) is done by short-circuiting these two wires. Buzzer circuit voltage is around 24V. Great, one step closer. So now all we needed was a relay and a controller able to close the short-circuit as it received a signal from our mobile app. At this point, you can pretty much do this in a thousand different ways. Market for microcontrollers, relays and all kinds of embedded systems is huge.

Solution we chose for the prototype was driven by two requirements, doing it as quickly and cheaply as possible.
Decision was made to drive the relay (F30229-12) with an Arduino board we had available, based on a simple relay driving schematic. Arduino would be programmed to activate its digital port on external signaling via USB. Thus we would keep Arduino permanently connected via USB to a PC we had lying around. The PC would run a lightweight Tomcat HTTP service and voilà, we are now in mobile app realm.

You could argue that the solution is quite suboptimal. We would agree and so our next goal towards a more permanent solution is to lose the PC and use an ethernet port on top of Arduino instead. We also plan to replace Arduino with its cheaper version YourDuino as well as drive a new and more compatible relay.

Putting all the pieces together made our prototype alive and entirely functional. Our door finally got to be closed.

You can find the Arduino source code on our GitHub page.

0 comments