5,600,483 Members 32,712 Now Online
XDA Developers Android and Mobile Development Forum

[App][Project][Cool] JsChiSurf's "OpenSezMe" Android Garage Door Opener Application

Tip us?
 
JsChiSurf
Old
#1  
JsChiSurf's Avatar
Recognized Developer - OP
Thanks Meter 1074
Posts: 2,333
Join Date: Feb 2010
Location: Hacksville

 
DONATE TO ME
Default [App][Project][Cool] JsChiSurf's "OpenSezMe" Android Garage Door Opener Application

I wanted to create this post to show fellow XDA members a cool project I've been working on, and figured that like-minded XDA members (techno-geeks) would think it was pretty sweet as well, so this post is nothing more than to "show off" what I've done and perhaps inspire others to do something similar once they see how I accomplished this .

I set out to develop a simple android application to turn my phone into a "virtual" garage door remote, with the requirements that the application only successfully function when / if I am within a 1 block quadrant of my home, and be protected by a pin code. Both of these requirements help to prevent accidental opening / closing of my garage both at home, or in some remote location half-way around the world. You will see the end product from the application side in the youtube demo video at the end of this post.

I happen to have an old linux box running as a mail / web server in my garage that also has a serial port. So I said to myself, "self", wouldn't it be cool if I could interface the serial port on the linux box to a relay switch that would enable me to send commands out, via the serial port, to toggle the relay switch on/off, with the goal of mimicking the button press of a garage door pad on your garage wall, and control all of this via my phone?

So, I picked up a cheap serial port relay controller and connected it to my linux box's rs232 port. The controllers are available in a variety of interfaces, such as USB, ethernet, etc, but for me, serial was the way to go due to my existing setup, and ease of programming to the port, etc.

I then wrote a set of serial port communication classes in PHP for sending the necessary commands out the serial port, as outlined in the relay controller's specs, for toggling the relay on/off.

I tie it together by having the android application I wrote first look for the correct PIN code and geolocation, and when correct / within range, present a "virtual remote" on screen. When the remote is pressed, it makes an HTTP call to the webserver in my garage, that when called successfully issues the necessary serial port commands to toggle the relay switch.

The end result? A pretty bad ass virtual garage door opener app I call "OpenSezMe" that allows my phone to double as my opener. When I go on walks, jogs, etc, upon return, I can simply open my garage via my phone for entry back into the house. I know I could install a keypad, but what's the fun it that?

This application is very specific to my needs / setup, so doesn't really have any value for anyone else. I just thought it was pretty cool and figured you guys would too, and, at a minimum, could spur you to come up with something similar, unique to your environment.

Twitter: @JsChiSurf

Enable your phone to be detected as a tablet: [Module][Xposed] TabletMetrics: Report screen > 7"

Word Nerd? Check out my "Word of the Day" DashClock Extension

Some of my other work: KitKat Media Rescan Widget, Fast Charge USB Widget, Chicagoer,"Daily Horoscope" DashClock Extension

Like my work? Buy me a coffee.
The Following User Says Thank You to JsChiSurf For This Useful Post: [ Click to Expand ]
 
Mast3rpyr0
Old
#2  
Mast3rpyr0's Avatar
Senior Member
Thanks Meter 0
Posts: 282
Join Date: Jan 2010
Location: Columbus
Very cool! I would love something like this, you know, if I actually had a garage. :P But maybe something for my lights in my room, I hate getting up to turn them off :P
Sprint HTC Evo 4G - Rooted Stock ROM
Pre-Ordered HTC Dream (G1) - Rooted Cyanogen Mod 6
 
JsChiSurf
Old
#3  
JsChiSurf's Avatar
Recognized Developer - OP
Thanks Meter 1074
Posts: 2,333
Join Date: Feb 2010
Location: Hacksville

 
DONATE TO ME
Quote:
Originally Posted by Mast3rpyr0 View Post
Very cool! I would love something like this, you know, if I actually had a garage. :P But maybe something for my lights in my room, I hate getting up to turn them off :P
That's the cool thing about it, and the world of possibilities it opens.

You can get these cool controllers that have multiple (dozens) of relays to control different things. I just got a cheap single relay controller to start, but with a multiple relay controller, you can start building an app to control lights, the garage, or anything else you want.
Twitter: @JsChiSurf

Enable your phone to be detected as a tablet: [Module][Xposed] TabletMetrics: Report screen > 7"

Word Nerd? Check out my "Word of the Day" DashClock Extension

Some of my other work: KitKat Media Rescan Widget, Fast Charge USB Widget, Chicagoer,"Daily Horoscope" DashClock Extension

Like my work? Buy me a coffee.
 
Rydah805
Old
#4  
Rydah805's Avatar
Recognized Contributor
Thanks Meter 1082
Posts: 3,713
Join Date: Oct 2008
Location: Ventura County

 
DONATE TO ME
Quote:
Originally Posted by JsChiSurf View Post
That's the cool thing about it, and the world of possibilities it opens.

You can get these cool controllers that have multiple (dozens) of relays to control different things. I just got a cheap single relay controller to start, but with a multiple relay controller, you can start building an app to control lights, the garage, or anything else you want.
Awesome but don't think my patents would let me wire **** up and I don't have a lenix box.

Sent From My HTC Evo 4G Using Tapa Talk Pro!



ThisIzRydah.com
Check Me Out On The Google Play Store!!!
Check Me Out On iTunes!!!
Check Me Out On Amazon MP3!!!
Check Me Out On Zune!!!
HTC One (M8) - Amber Gold
HTC One (M7) - Half Stealth Black/Half Glacier Silver
Samsung Galaxy S4

 
JsChiSurf
Old
#5  
JsChiSurf's Avatar
Recognized Developer - OP
Thanks Meter 1074
Posts: 2,333
Join Date: Feb 2010
Location: Hacksville

 
DONATE TO ME
Quote:
Originally Posted by Rydah805 View Post
Awesome but don't think my patents would let me wire **** up and I don't have a lenix box.

Sent From My HTC Evo 4G Using Tapa Talk Pro!
This is just my specific setup, but you could have any type of environment, just depends on what you have / know how to use, etc.

At any rate, thought it was a fun project that, for no other reason, would hopefully inspire others to try it out, or do something similar, if they have the wherewithal.
Twitter: @JsChiSurf

Enable your phone to be detected as a tablet: [Module][Xposed] TabletMetrics: Report screen > 7"

Word Nerd? Check out my "Word of the Day" DashClock Extension

Some of my other work: KitKat Media Rescan Widget, Fast Charge USB Widget, Chicagoer,"Daily Horoscope" DashClock Extension

Like my work? Buy me a coffee.
 
fachadick
Old
#6  
Senior Member
Thanks Meter 655
Posts: 2,291
Join Date: Jul 2010
Location: Northern NJ

 
DONATE TO ME
This...is AWESOME! I don't blame you for wanting to show off - this what android and open source is all about!

Sent from my blah blah blah blah
Always wanted a DropBox account? Sign up here.
"Surrealism is the best kind of ism" - Potato Cumberbund.
"What if we die and it turns out God is a big chicken?? What then?!" - Calvin.
 
JsChiSurf
Old
#7  
JsChiSurf's Avatar
Recognized Developer - OP
Thanks Meter 1074
Posts: 2,333
Join Date: Feb 2010
Location: Hacksville

 
DONATE TO ME
Quote:
Originally Posted by fachadick View Post
This...is AWESOME! I don't blame you for wanting to show off - this what android and open source is all about!

Sent from my blah blah blah blah
Ha, thanks! It was fun to do, and very rewarding when it all came together, seeing the door open/close on the inaugural button press .
Twitter: @JsChiSurf

Enable your phone to be detected as a tablet: [Module][Xposed] TabletMetrics: Report screen > 7"

Word Nerd? Check out my "Word of the Day" DashClock Extension

Some of my other work: KitKat Media Rescan Widget, Fast Charge USB Widget, Chicagoer,"Daily Horoscope" DashClock Extension

Like my work? Buy me a coffee.
 
jagox5
Old
#8  
jagox5's Avatar
Senior Member
Thanks Meter 16
Posts: 154
Join Date: Jun 2007
Default wow

wow nice job!
 
Sporkman
Old
#9  
Sporkman's Avatar
Senior Member
Thanks Meter 2
Posts: 2,598
Join Date: Mar 2009
that was pure win !!! nice work !

https://www.dropbox.com/referrals/NTE5MjkzMTY5
I SHOULD NOT HAVE TO PRESS 1 FOR ENGLISH. WE ARE IN THE UNITED STATES, LEARN THE LANGUAGE!!
 
JsChiSurf
Old
#10  
JsChiSurf's Avatar
Recognized Developer - OP
Thanks Meter 1074
Posts: 2,333
Join Date: Feb 2010
Location: Hacksville

 
DONATE TO ME
Quote:
Originally Posted by Sporkman View Post
that was pure win !!! nice work !
Thanks. The discerning eye will notice that it's speaker cable wire that I used to hook up the relay to the opener. Didn't have any "standard" low voltage wire lying around, so I made due with the speaker cable .
Twitter: @JsChiSurf

Enable your phone to be detected as a tablet: [Module][Xposed] TabletMetrics: Report screen > 7"

Word Nerd? Check out my "Word of the Day" DashClock Extension

Some of my other work: KitKat Media Rescan Widget, Fast Charge USB Widget, Chicagoer,"Daily Horoscope" DashClock Extension

Like my work? Buy me a coffee.

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


XDA PORTAL POSTS

TasGear: A Tasker Extension for the Samsung Galaxy Gear

With wearable technology taking center stage this year, one can only expect more … more

Intelligently Place Contacts on Your Home Screen with CallWho Widget

There are plenty of ways to get your contacts to show up on your … more

Control TWRP from within Android with TWRP Coordinator

You may recall that back when TWRP2 introduced a couple of years ago, it brought with … more

Keep Track of Everything Your Device Does with Event Logger

Regardless of their OS choice, computing power users generally share one common … more