We have a typical garage door setup in our suburban home. So we regularly end up crawling into bed, wondering if maybe we forgot to close a door, which are difficult to see from inside the house, and impossible from the second story. In addition, we didn’t have any way to check the security or close doors remotely, nor open them if a visitor needs access to the house. There are a number of commercial solutions for things like this, but where’s the fun in that??


Janus is a project that implements a server component running on a RaspberryPi mounted in the garage, as well as an iOS app that views images from the garage and provides buttons to trigger opening and closing the doors.

Server Side

View the Source Code

Garage Door Raspberry Pi Server

Running the a RaspberryPi in the garage, and equipped with the RPi Camera module, a nodejs app is running, taking a regular stream of photos, uploading them to Google Cloud Storage, and waiting for requests via Firebase messages from the iOS client app. Those messages may include:

  • Get the latest image of the garage interior.
  • Push a garage door button (which it does via digital relay and wires attached to the same garage door opener terminals as the interior garage push buttons.)

iOS App

View the Source Code

Meanwhile, the iOS app, written in Swift, authenticates for only users who live in our house (security!), let’s us check to see what the status of the garage door is, and we can put a button to open/close either door remotely.

iOS Screenshot


This demo is a bit dated, but made just after I retooled the backend to use Google authentication and Firebase (prior it was using PubNub and AWS). Should give a flavor of what’s going on here, though.

Future Improvements - AI/ML powered

The primary next step in this setup will be to capture a regular set of images into an archival storage bucket, and then tag each of them with a label representing which doors are open and which are closed. Feeding those tagged images to Google’s AutoML Engine, we can train a Tensorflow model to “understand” which doors are open. That will allow us to have a single button, or a voice command, that issues a “close all doors” command. The server will feed the current image through the ML model to ascertain which doors are open by “looking” at them, and then will push the button combination necessary to close any open doors. A fun and simple application of AI!