[How-To] Build the ULTIMATE Garage Door Monitor

BraveSirRobbin

Moderator
IT LIVES...Ultimate Garage Door Monitor Two!
 
I have a much smaller automation system now, mostly Z-Wave lights and Z-Wave Door/Window switches, but I also have an Arduino Mega R3 with an Ethernet 2 Shield installed in a structured cabinet in my garage and use HomeSeer's plugin written by enigmatheatre to get digital inputs and outputs as well as analog inputs into HomeSeer devices.  This is a really nicely written plugin and it will support multiple Arduinos as well.
 
Here is a screen shot of my reduced setup below.
 
Arduino in Garage.jpg
 
I used the same brackets for my potentiometer and used a 4K ohm ten turn rotary pot with a rubber stopper as before.  I placed the rubber stopper in the end of the upper pipe on the garage door and made a bracket as shown below:
 
GD Monitor Hardware.jpg
 
The pot is ten turn and I get a total of 7.5 turns when the garage door goes from full close to full open, so I just made sure those turns are somewhere in the middle of the ten turn capability so the pot will not bottom out against its stops.
 
I hooked this up to an analog input and used the on-board five volt output as the excitation voltage, then set the plugin to read raw 'bits' from the analog to digital input.  I then calibrated the system by measuring distance from the ground vs these bits as shown in the Excel plot below.
 
Excel Graph.png
 
Excel will calculate the slope intercept formula from the line automatically as shown in that graph.
 
So now I have an equation that will convert the bits to inches.  I entered this equation into the plugin (really easy as the plugin provides an entry for this), then spot checked the system by stopping the garage door at various intervals and measured the height from the floor vs the inch reading from HomeSeer.  The value was within an inch no matter where I stopped!
 
I wanted a 'percentage of open' instead of the raw inch value.  Since my total opening was 83 inches, I just divided the entire equation by 83, then multiplied by 100 to get this percent open value. The exact entry into the plugin's analog input for the equation is now (Value * 0.1226 - 14.404) / 83 * 100, where the "Value" is the bit value from the analog to digital input.
 
I already had some icons for 0, 25, 50, 75, and 100% values and used those to represent the various ranges of percent values (again, easy to setup with HomeSeer).
 
GD0.jpg  GD25.jpg  GD50.jpg  GD75.jpg  GD100.jpg
 
I also use HomeSeer mobile and below are some examples of screen shots from my phone showing a couple of values from this system.
 
Screen Shot Closed.jpg   Screen Shot Partially Opened.jpg
 

HomeSeer Mobile is VERY limited, and remains the major Achille's heel with using HomeSeer...
 
 
 
 

BraveSirRobbin

Moderator
TonyNo said:
How do you talk to the Arduino?
 
Pic below of my Arduino Mega R3 with Ethernet 2 Shield.
ArduinoMegaR3wEShield.jpg
 
The HomeSeer plugin can communicate with the Ethernet interface.  The plugin is really easy to setup as there are step by step guidelines onto how to include the needed library files in the HomeSeer directory, setup and download the Arduino sketch (including the version of Arduino software needed to do this), plus how to setup one-wire, analog inputs, and digital inputs and outputs.  The plugin also supports an LCD display!  Details on the plugin can be found here.  I also upgraded to the new Beta version and those details can be found here.
 
I also have an older Arduino with an Ethernet Shield that I'm thinking about interfacing with my sprinkler controller.
 
If anyone needs help setting this up with HomeSeer, or needs additional guidelines on how to hookup the potentiometer, calculations, or anything else, please let me know!
 
Practically, nobody needs to know the location of their garage door's distance from the floor within an inch, but if you can do it, why not? :)  Plus this project started as more of a fun guideline into analog inputs.
 

BraveSirRobbin

Moderator
Here are some additional screen shots of the Arduino plugin for HomeSeer that I'm using:  
 
Setup Screen Shot (I'm using one analog input, plus multiple inputs and outputs)
HomeSeer Arduino Plugin Setup Page.jpg  
 
This results in the following 'devices' for HomeSeer:
HomeSeer Arduino Device Listing.jpg
 
A bit off topic, I found this really cool keypad that uses keychain fobs. It isn't weather proof and I have this inside my garage door beside the entry to the laundry room. I use the 'bell' button to arm the system so I have easy one push button arming and easy disarming via the fobs!
 
I have more of a DIY security system now that uses Z-Wave door/window/motion sensors plus input and outputs (including this keypad) from the Arduino, all controlled by HomeSeer.  Yes, this is not a robust system like my Elk that I had when I lived in Las Vegas, but now I'm living in a town of 6,000 people where I believe there are a handful of homes that have some type of security system installed!
 
Top