Controlling a garage door remote

Noob question apologies… I’d like to use the spark core to simulate a button press on a garage door remote control.

Would I need to connect a relay to the remote control button that is then switched via the spark?

Thank you.

Something simple like a Solid State Relay will work great!

There’s a post in the past also about remote control modding but I have to dig it up to find the ssr model used :wink:

Here is a great example of exactly that…

which reminds me I need to finish building mine…

1 Like

I would love to know a way to emulate the garage door RF signals :smile:

That would be my preference too. I know there is software for the Raspberry Pi which turns it into an FM radio transmittor - the only hardware required is a 20cm aerial connected to one of the GPIO pins. I’m sure enough of the same must be possible on a Spark Core to be able to buzz a garage door?

Interesting thanks. Any pointers on what an appropriate solid state relay for use with the spark core would be? The ceiling fan project does not mention what component was used :frowning:

A mechanical relay will also work. They are dirt cheap. You can pick them up on ebay for next to nothing and since you aren’t going to be actuating your garage that often they should be good for a long long time. This is actually what I use for my garage control project!

I would go out to your garage and measure the voltage across the two terminal connections that are wired into your garage’s pushbutton. Once you have that measurement you can make sure you are getting the right relay. I don’t have enough data on garage door control voltages but I know I was able to use one of these but I do recognize that it is probably gross “overkill” for what I’m using it for

1 Like

If you have a newer garage door opener, you are probably better off just interfacing to the remote because they typically use rolling codes these days so your garage door signal cannot be intercepted and rebroadcast.

I’m really digging these PhotoMOS SSR’s lately. This one can plug into your breadboard and switch up to 500mA up to 60 VAC or VDC, which should be plenty good for most low current applications like this where you are mainly just switching a voltage. You need to keep the input current below 5mA though, so I would suggest a 470 ohm resistor. (3.3V - 1.14Vf) / 5mA = ~430 ohms, but go a bit higher to ensure < 5mA. For other packages and current capacities, search for “PhotoMOS”


Those are super cool! I went hunting for a cheaper option and found this: any significant difference you see? Picking components is still something I’m not great at yet

Good find! I like half the price :slight_smile: Only thing I see much different is their laziness in specifying the output voltage… they just say 60V, not AC/DC. I would assume it can handle AC and DC though.

Most roller door units will actually have a location in the board to add extra “buttons” to open and close the door

Below are some easy options:

  1. Use a opticoupler and wire directly into the remotes button – This is what I have done my self
  2. Open the garage door unit and hijack the physical button then use a relay to trigger
  3. Find the datasheet and wire in to the garage door unit as it expects you to :smile:

I have also used reed switches which allows me to see if the door is open or closed, or if it never reaches its intended state after a button press etc, can share the code if anyone is interested


Hi semaja2,
I am interested in the code and in looking at how you mounted the reed switches in the door itself!
thanks a bunch

I will get some pictures done tonight and get the code for you, the code aint the prettiest at the moment as I use it to perform multiple functions but I am sure you can work it out :smile:

1 Like

I found it much easier to interface with the door openers directly through the “inside” physical wiring rather than going through a remote (plus you don’t waste a remote attaching it to something that is likely to be stationary). I have not found a garage door opener that doesn’t have a provision to put in physical “door bell” type buttons. I just used 5v 5A NO relays with a simple transistor driver circuit (with flyback diode) and close it for 500ms to open/close the doors.

I’d consider magnetic reed switches on the doors almost mandatory if you’ll be activating the door from a remote location. For instance, if you’re at work and you let someone in through the door, did they close it? If you hit the “internet button” by accident (or multiple times) and not know for sure which position the door is in, you could be opening it with no way to tell.

I mounted the magnets to the doors with VHB and the switch side with a 1" x 9" 20 gauge steel strips so they could be bent to position easily. I mounted my switches on the “high” side of the door to keep wiring out of sight and simple. So the “closed” switch is actually at the top of the door opening and the “open” switch is back toward the opener.

I have several controls: open/close door 1, open/close door 2, open/close both (my doors are positioned in a “drive through” configuration), and an away function (doors only open via normal remotes, another thing you can’t really do if you use a remote). The away function is also wired into the alarm in such a way that if the siren is triggered, the doors will stay in the closed position or will close if open.

Remember to leave the safety systems intact.

*I do not currently use a Spark device for this.

I just threw my code up for my garage control project. Like @semaja2, my code is super dirty so feel free to ask questions if you have them. No pictures yet. I’ll try to update the repo later tonight with pictures and more documentation

Like @BDub said most newer openers (like 1995+) use a control circuit to support multi-function buttons on the remote panel. For example some have the ability to turn on and off the light as well as lock the door with a security mode. These openers use a DC voltage (so a SSR won’t work) and carry digital signal on the line (I think it’s a short 1ms pulse every second). If you ever open up these multi-function panels you will notice there are capacitors that get shorted with the different buttons. These capacitors cause a momentary short across the lines and depending on the capacitance they will ‘short’ the line for a specific amount of time. (there is a resistor in series with the supply line). Based on the amount of time the short occurs the controller determine which button you pressed.

If you are only trying to open and close the door you can just use a mosfet, a transistor or a low power NO relay. You will need additional sensors to know if the door is open or closed, this helps you determine if you had a failure with the closing or opening of the door. For example anything in the way of the optical beam, or any object under the door can obstruct its operation and you will probably want to know if that happened. Simple reed relays can work like @JackANSI suggested.

It’s a fairly simple circuit for just managing the door.

UPDATE: I suggest you take a multimeter and measure A/C and D/C voltage across the wires that run to your control switch. That will tell you if you can use an SSR (for A/C) or a Relay/Mosfet/Transistor (for DC). Some older models of door openers used an A/C voltage on the switch.

I just finished doing exactly this project myself, and I will have a complete Intsructable posted in a couple of days.

In my setup I don’t use the Spark Cloud. Instead I use an Android app to connect to the Spark directly (over a secure AES channel, of course).

I used a transistor (PN2222A) to emulate the garage door button press, hooked up like this:

Feel free to use the Spark code:

Or the Android app code:

There is quite a bit of code there, but that is b/c I had to implement my own security protocol that encrypts the traffic and prevents replay attacks.

The full Instructable:


Hi Vace117,

this is great, thanks for posting your code!

I have one question for you:
did you decide to implement your own security protocol so the android app and the spark core can talk to each other directly, instead of using the spark cloud?
if the answer is yes, any particular reason or you just did not want to use the spark cloud?
thank you!

I just finished my Sparkcore Smart Garage module, you can see photos and the custom board and wiring diagram in my album on Google Plus here:

I used the LCC120 digital relay (had a few left over from a previous project) to operate the button. The way I have mine setup is to control it from my Pebble smartwatch. That way I am using the watch to open and close and even check the status of the door. Right now the Smart Garage module has USB power, and 4 connection wired. Two are to connect to the button and simulate the button being pressed, and two are used to attach to a reed switch to confirm that the door is closed. It is amazingly cool to have the watch be my main control for the house.

Follow me on G+ here if you want to ask any questions about it:

I will be posting the code on GitHub for both the Sparkcore and for the Pebble Watch app later this week.


I love this!! Two great options - one using a cloud/pebble solution and another using customized Spark Core to Android communications. This is the true wonder of this open source platform :wink:

@Steph, these projects really demonstrate the beauty of what you guys have!