Introduction: Arduino WiFi Garage Door Opener

Picture of Arduino WiFi Garage Door Opener

Ever come home in the rain to find the door locked and your keys elsewhere? No? Lucky you then! For those who have had such an experience or never wish to, this project will let you open your garage door with nay but a smartphone/tablet/laptop/WiFi-thing and your super secret password! After all, who leaves their smartphone at home nowadays. The very idea!

All it takes is a network capable Arduino, a relay, a long network cable and a few other bits 'n bobs like wire and a soldering iron.

So how does it work? I'm so glad you asked! The Arduino hosts a little web page on your local network which you can access from any other device on the network, such as your smartphone, just like a normal website. When you input your password, the Arduino triggers a relay that acts like a wired garage door remote that you often see next to the internal door. This sets the garage door opening mechanism into motion, letting you through with the a new felt sense of control over your home!

So, shall we get started then?...

Step 1: Needed Things

Picture of Needed Things

Parts:

  • A Freetronics EtherTenor other network capable Arduino board -This is the brains of the operation. It hosts the web page you connect to when you want to open the door and triggers the garage door opener (via the relay) when the correct password is entered.
  • A Relay Board to activate the opener - This acts like a wall switch or button but the EtherTen 'pushes' it instead of you. In this case it will emulate the switch in the wall mounted or portable remote that you currently use to open the garage door. This can work alongside the existing buttons and remotes. Either buy one such as this one from dealextreme that I used in my case or make your own with: a relay, a transistor (any small signal one such as a 2N2222 or 2N3904 should do) to turn the relay on and off, and a flyback diode to protect the transistor and EtherTen from the voltage spike generated by the inductive load of the relay coil when it is turned off (such as a 1N4001).
  • A Case -For those with access to a 3D printer or who feel like giving a 3D printing service such as Ponoko, i.materialise, Sculpteo or Shapeways a try, you can make the "EtherTen Enclosure" used in this project. This is available on this projects GitHub repository will house both the Freetronics EtherTen and dealextreme relay board nicely. Just hit the "Download ZIP" button on the bottom right to download it and other necessary project files. You will need to print off a top, a base and 4 clips. To mount things together you will need 12, M3 sized, 6 mm long (shaft length) screws and an M3 tap or 12 self-tapping screws of the similar size. Sometimes I've gotten away with using 'normal' (machine) screws instead of self -tapping but it depends on how soft the plastic is. The reason four of the screws that can be seen in the image above are plastic is so that the colour matches the case and looks nice.
  • A Connector andDual Conductor cable to go between the relay board and the opener or remote you wire it to - I used a 3.5 mm jack and plug usually used for audio equipment and some thicker than needed wire. The length of wire required depends on the distance between the opener or remote you will wire into, as informed by the next step, and the nearest convenient spot to place the box containing the relay board and EtherTen. If you are truly averse to soldering you could omit this and instead open the box up and unscrew the terminals each time you wish to disconnect it.
  • Three Male to Female Jumper Wires to connect the relay board to the EtherTen with.
  • Network Access - This can be a long Ethernet cable as in my case or an old wireless access point or router.
  • A Power Supply to power the EtherTen. This needs to be around 6-9 V DC (7.5 V ideally) and at least 300 mA for the EtherTen to be happy. See Appendix A (Step 10) for how to check if any old wall plug packs that might be lying around will do the job. Advanced makers may be able to get some Power over Ethernet (PoE) thing to work instead but that is beyond my knowledge.


Tools that will be needed are:

  • A multimeter
  • Flat head and philips screw drivers
  • A ruler

Tools that will be useful are:

  • A pair of pliers
  • A wire stripper
  • A soldering iron

Step 2: Check Your Opener

Picture of Check Your Opener

Before getting started you should find the best way to connect to your garage door opener.

Option 1, terminals on the opener: Take a look at the garage door opener its self. This is the box that houses the motor and usually makes a loud hum when operating. On this there is usually several terminals for connecting other bits and pieces. Find the ones used for a wired remote. In my case they are labeled P B (likely short for "push button") and GND (short for ground) but are most easily identified by the wires connecting them and the remote. If your opener doesn't have these, your only choice is option 3. To test these terminals for suitability grab a multimeter and measure the voltage across the two terminals. If you get a nice low value like the 3.66 V I obtained, it should be safe to connect the relay to these terminals. Any voltage in the 100-240 V region is far too high. If you don't already have a wired wall remote, use this as your connection point and go to the next step. Otherwise go to option 2.

Option 2, the wired remote: If you do have a wired wall mounted remote, usually found on the wall by the internal door of the garage, it may be a more convenient connection point. Carefully pop off the cover and see if the points where the wires from the opener terminate are easily accessible as in image above. If so then connecting the relay here should function just the same if you were to connect it to the terminals on the opener its self but will save having to run another pair of wires to the opener. This is where I chose to connect to in my case. If this will work for you then choose it as your connection point and go to the next step. Otherwise use the terminals on the opener or as a last resort the method described in option 3.

Option 3, the wireless remote (advanced): If your opener lacks wired remote capability or it's tricky to connect the relay to the opener or wired remote, a wireless remote is the remaining, more advanced, option. These differ significantly by manufacturer but as long as it has a button you can push to open the door, it should work. Open it up and see if you can get at the legs of said button. Soldering one of the wires from the relay to each side of this should do the job. If it has four legs things get more complicated. Use the continuity function of your multimeter to find the pairs of legs are electrically on the same side of the button. These are connected to the other pair of legs only when the switch is pressed. Solder one of the relay wires to each pair, so that the pairs are connected either when the button is pressed or when the relay triggers (closes).

Once you have chosen a place to connect our device to, find a convenient spot to put it. Every situation is different. The device needs a network connection, power, and of course, a connection to the opener or remote. Choose a spot that you can route these things to with the least difficulty. In my case I used a wired wall remote that was handily near a mains power socket, so I put the device on the bench that was under them.



Now we know how we will connect to the opener, it's time to do some soldering!

Step 3: Soldering

Picture of Soldering

Time to solder up our relay-to-opener connector. If this is a three leg 3.5 mm female connector like the one I'm using, the third leg is usually used to detect whether anything is plugged into it or not, something we have no interest in.

First we need to figure out which two legs to use. To do this take the plastic back off the male connector and stick the remainder in the female one. Use the continuity function of your multimeter to find out which legs on the female connector connect to the two legs of the male connector. If the male connector has more than two legs, use any two that connect to legs on the female side. Take note of which legs connect through so we can solder to them.

Second, we solder some wire to the female connector to go to the relay. To do this, cut a section of wire to go between the female connector and the relay board from the stuff to be used to connect to the opener/remote. For the 3D printed case that goes with this project I recommend 140 mm. Solder this onto the useful legs of the female connector. The recommended method is to separate the conductors, strip the insulation back about 5 mm, 'tin' the connector legs and wire ends by melting some solder onto them separately, then solder each wire to its corresponding leg.

Finally, we solder the wires that will connect to the opener or remote to the legs of the male connector. This is much the same as for the female connector but you may have to cut one wire shorter than the other if, like me, you're not using coaxial cable. Remember to clamp the metal fins around the cable if you have them as it will take any strain put on the cable instead of the solder joints.


Now that we've done the messy stuff, it's time to bring things together!

Step 4: Mounting the Parts in the Case

Picture of Mounting the Parts in the Case

The below instructions apply to the 3D printed case designed for this project. If you intend to use/make your own case or mounting medium skip to the next step.

Unscrew the panel mounting ring from the front of the female connector we just soldered up and push it through the round hole in the top half of the case until you can get the mounting ring back on from the outside. Tighten this up and the connector should be securely mounted.

In my case the hole was too small so I put the case in a vice with some cardboard and drilled the hole bigger. The hole has since been made bigger in the 3D model available so this should no longer be a problem.

If you're using a tap and machine screws, thread the four free standing and the taller of the pairs of internal mounting pillars. Pop the relay board on the four free standing ones and screw it down. For the EtherTen you need to line it up on the lower of the pairs of pillars and then insert the four 3D printed mounting pins. The pin part goes through the EtherTen mounting holes and into the lower pillars. The hole part goes over the taller pillars which you then screw down as seen above.


Now the components are mechanically connected, our next task is the electrical connections and closing the case!

Step 5: Wiring It Up

Picture of Wiring It Up

First connect the relay board to the EtherTen using jumper wires. The S (signal) pin on the relay board connects to the Digital I/O socket 7 on the EtherTen, the + pin to a +5V socket and the - pin to a GND socket.

Next connect the wires from the case mounted relay-opener connector to the two screw terminals on relay board that are either side of the "NO" (normally open) text. Which wire goes in which doesn't matter, what does is that only when the relay is activated that they will be connected.

Now the internals are done, put the lid and the base together and secure the lid on by screwing the remaining four screws into the holes on the sides of the case.


Now that the hardware is ready, it's time to setup the software.

Step 6: Downloads and Arduino Program Explanation

Picture of Downloads and Arduino Program Explanation

If you haven't already, head over to the Arduino website and download the latest version of the Arduino IDE. At the time of writing this is version 1.0.5. While that's downloading head over to the EtherTen drivers page and follow the install instructions including doing the board and port selection part under the "Eleven, EtherTen, USBDroid" heading once the Arduino IDE has installed. The standard Arduino drivers also seem to work fine for our purposes but the Freetronics instructions are good.

(An alternative to the Arduino IDE for the adventurous is the experimental Visual Studio Arduino build tool detailed here)

Head here to download and install the trial of MegunoLink Pro, a useful piece of software we will use a few steps ahead to communicate with the program we will upload to the EtherTen.

The source code for the Arduino program and the MegunoLink interface file is on the project GitHub. If you have not already, click on the "Download ZIP" button in the bottom right to download all the files. Extract them when the download finishes. If you are just interested in getting the thing going and not what each part of the code is, skip to the next step, otherwise read on.

The Arduino program for this project consists of several parts:

  • Program.cpp: This has the setup and loop functions which call functions from other files to run the serial command processing and the web server.
  • Webserver.h/Webserver.cpp: This handles the web server stuff such as supplying the form where we will enter our password and checking the entered password is correct.
  • CommandProcessing.h/CommandProcessing.cpp: This handles the processing of incoming serial commands, triggering the required function(s) to make the right things things happen.
  • PasswordManager.h/PasswordManager.cpp: This saves and loads the passwords from the EtherTen's EEPROM (storage memory). It also impediments the grace period that gives us time to shut the door after us without having to re-enter our password.
  • AccessControl.h/AccessControl.cpp: This handles the triggering of the relay.
  • WebPages.h/WebPages.cpp: This provides the web page bits needed by the web server to make the interface we see when we log in.
  • HardwareConfiguration.h: This is an important one for us. It contains the MAC and IP addresses the EtherTen will use to connect to the network (which we will likely have to change) and the pin the relay is attached to.

These files are all tied together by GarageDoorOpener.ino.

CommandProcessing.h/CommandProcessing.cpp is the useful serial command library created by Steven Cogswell. The program uses this to decode the incoming serial commands and to send replies back.

Now we have the program bits downloaded and partially understood, its time to get it running!

Step 7: Arduino Program Compiling and Configuration

Picture of Arduino Program Compiling and Configuration

Time to get the program ready to be put on the EtherTen. Launch the Arduino IDE and go File>Open... then navigate to the extracted files from the project GitHub and look in the GarageDoorOpener folder for the file GarageDoorOpener.ino. Once opened, click on the tab selection button (square with down arrow) in the top right and select HardwareConfiguration.h. Scroll down until you see the line:

#define LOCAL_IP_ADDRESS { 192, 168, 15, 22};

The next thing to do is to find and input a valid and unique, static local IP address on your network that we can put in these brackets so we can connect to the EtherTen and always know where to find it on the network. To find such an address (assuming you don't know a valid IP address for your network off the top of your head) we can use a computer connected to the same hub/switch/router/'network thing' as the EtherTen will be. On a Windows machine (for others try "find local ip {your operating system}"), hit {windows key}+ R to open the run menu, type in "cmd" (no quotes) and hit OK to open the command prompt (Another way of doing this is to search from the start menu/screen for "cmd"). Once in the command prompt, type "ipconfig" followed by Enter.In the following data look for the IPv4 Address of the network adaptor your connected to the hub with. There are two parts of this address as far as we are concerned. The first part is the first three numbers (as underlined in blue in the above image) which varies between hubs. This part we copy directly into the brackets only with ,'s instead of .'s. The second part consists of the last number of the address (as underlined in yellow) and varies between devices connected to the same hub. This part we must change in order that we don't screw up the connection of another device that was 'legitimately' assigned its IP address. My recommendation is to take the number and add 100 to it, as long as the result is under 255, or just pick a random number between 1 and 255. In my case I couldn't be bothered changing it from 22 so I ended up with the address below:

#define LOCAL_IP_ADDRESS { 192, 168, 0, 22};

In the remote chance you use two EtherTen's running this program on the same network you should change this and the MAC address to make it local network unique.

Assuming the EtherTen is connected over USB and you have selected the correct board and port as in the EtherTen driver instructions, you should now be ready to upload the program. Hit the Save button (down arrow with "..." underneath in a square) followed by Upload (right pointing arrow in a circle). If this is successful, well done! If not, try putting the resulting error message through the search engine of your choice.

Before moving on, check your IP address setting works by opening up a web browser and typing in the IP address you entered in HardwareConfiguration.h like you would for a normal website except without any "www." business. If it works you should see a page like in the image above, fantastic! If not:

  • Check the lights on the EtherTen network connector are on, if not you may have a bad connection to the hub or there is not enough power being supplied (such as if running off USB) to run that part of the EtherTen
  • Try a different IP address in HardwareConfiguration.h
  • Check your hub settings

At this point you may want to make a bookmark or a note of this IP address on your smartphone so you don't have to remember it.

We have a working EtherTen, great! Now we need to establish communications and input some super secret passwords!

Step 8: Connecting to the EtherTen

Picture of Connecting to the EtherTen

To talk to the program on the EtherTen instead of uploading a new one, we need a different piece of software. The software recommended for this is MegunoLink Pro as one of its best features is how it allows us to easily create a user interface with which we can interact with programs over serial communications, which I have done already.

Assuming MegunoLink Pro has been installed, launch "Garage door opener config interface.mlx", the project file containing the configuration interface, from the top level of the project files we downloaded from the project GitHub repository earier. As per the instructions contained in it, connect to the EtherTen, initialise the EEPROM, store a password and check it saved by listing the stored passwords. Once a password has been stored, load the program's web page using the IP address again and try the password. If successful, you should hear a satisfactory click from the relay and see the above page!

Now we have the controller ready to roll, all we have to do is plug it in!

Additional for the technically minded:

For those who would rather do things without the handy MegunoLink interface, the commands for the EtherTen program are as follows:

  • init-pwd\r This initialises the EEPROM for storing passwords, overwriting any that were previously stored.
  • list-pwd\r This will trigger a list of the currently stored passwords to be sent back over the serial connection.
  • set-pwd {NewPasswordSlot} {NewPassword}\r This stores the password specified to the slot specified (1-10).

Step 9: Installation

Picture of Installation

Time to hook it up! Run a long network cable from your hub to your spot for the EtherTen. Connect the wires from the male relay-opener connector to the control point of the opener system chosen in Step 2. As mentioned before, it makes no difference which of the two wires goes to a specific terminal as all the relay does is connect both ends to each other.

Finally, place the case housing the EtherTen and relay board in the chosen position and plug in it's opener connection, network connection and power supply.

And there you have it! You should now be able to open your garage door with your smartphone!

Step 10: Appendix A: Finding a Suitable Power Supply

Picture of Appendix A: Finding a Suitable Power Supply

The EtherTen needs a 6-9 V, DC, 300 mA or higher power supply with a 5.5 mm OD (outer diameter), 2.5 mm ID (inner diameter), positive center hole barrel connector. To those without much electrical knowledge the previous sentence would have made as much sense as a horse wearing a floral dress flying first class on a transatlantic flight. Luckily we don't need to understand it all to find a suitable power supply, we just have to match some numbers and a symbol.

If your looking around in a box of old power supplies, first collect all the ones which have connectors that will fit. Next look to the "Output:" line on each. These usually follow the format of: {voltage value}V {current type} {current value}mA. The EtherTen requires a voltage value of between 6 to 9 V (volts), 7.5 V being ideal, current type "DC" (direct current), and a current value of at least 300 mA (0.3 amps). DC is frequently represented by a solid line over a dashed line. AC, the current type we don't want as the output, is frequently represented by a squiggly line (~).

The final thing to check is that the center hole of the connector is the positive terminal. This is usually represented by a symbol of a dot inside 3/4ths of a circle, each with a line leading to either a positive or negative sign. The EtherTen needs one where the center dot is connected to the positive sign. If no such symbol is present but everything else is suitable, the EtherTen should come to no harm by you plugging it in to test. Those with confidence could always cut the cable and wire it back up reversed but it is not the ideal solution.

The above images give examples of four unsuitable power supplies and one that should work nicely (the first one). Things underlined in red make the power supply unsuitable. All the underlined output properties must be suitable (green) for the power supply to be suitable.

Comments

Angi1 (author)2016-08-06

I think this project is great, and certainly cheaper that buying a unit.

I am new to Arduino/ I have seen all projects using Ethernet. I don't want to run Ethernet into my garage, so I bought a ESPDunio (Arduino+WiFi from ESP8266)

So my question. How do I change, or what do I change to have this script, to operate as WIFI.

AhmadC12 (author)Angi12017-07-23

If you haven’t done the project yet, just buy a wifi repeater and place it near the board and hook an Ethernet cable from the repeater to the board and then you can do this project normally

MegunoLink (author)Angi12016-08-06

Hi Angi1, im not sure what it would take to port it across but there seems to be plenty of esp8266 garage door examples if you google it.

Cheers
Phil

Angi1 (author)MegunoLink2016-08-12

I have been looking for days. I have found others, but this project is better. I prefer this setup. The only thing this project is missing is the magnet switches which identify if the door is open or closed. I am looking to convert the only network portion of the device from Ethernet to WIFI. I will keep on fiddling with it.

MohnishC (author)Angi12016-10-16

@Angi1 Give particle.io a try. $20 Wifi cloud connected and managed board. As for detecting garage door state, garage openers already keep that state. Check if the chain/belt triggers some switch upon stop.

mdshann (author)MohnishC2016-11-01

I'm assuming he wants to be able to tell if the door is open or not through the web app, in case he forgets to close it. In that case, he will need to attach a limit switch somewhere on the door mechanism and program a couple of I/O pins to the switch and then program the arduino to output the state of the switch to the web page.

MohnishC (author)mdshann2016-11-02

@mdshann I understood that. I've this implemented solutions myself. I detect the garage state by tapping into the limit switch inbuilt into the garage unit. The belt/chain triggers this inbuilt limit switch and that's how the unit knows when to stop. We can tap into this existing mechanism to detect the state.

Angi1 (author)mdshann2016-11-01

Thanks guys, I got up created using 8266. I have some tweets to be performed I will update this blog in a couple of weeks on the code.

joon874 (author)2017-06-25

Hello!

This is Lawrence from WIZnet.

Before, I did post your great project to WIZnet Museum (http://wiznetmuseum.com)

Now, I want to let you know about IoT Constest.

I think your poject will be enough to get won.

That contest is called ‘Curation is Creation’

And onething you have to concern is using ARM mbed-enabled WIZwiki-W7500 platform & WizFi310 shield.

Those things are posted in http://www.cybermakerspace.com/ with How To.

As I know, there are only few participants.

So I do not want you are missing this change.

The total price is $15,000 !!

Hurry to join it!

All things are in http://www.cybermakerspace.com/

Sincerely,

Best Regards

Kaushikn6 (author)2016-06-16

When I enter the IP address [which i made sure i did the rite way] , i get a blank page, can someone help,
Am using an Uno with Ethernet Shield combo, am sure the device is working as the Ethernet examples in the IDE work perfectly.

smigs (author)Kaushikn62016-10-31

I do too. Any resolution to the issue? I managed to copy a bit of code from the DhcpAddressPrinter (specifically the printMyAddress() method) into the Webserver.cpp class and the arduino is getting the correct IP address that I set in HardwareConfiguration.h. Otherwise I'm stumped.

ydoucare (author)2015-07-07

Great project!

I made something very similar with an Arduino Uno, W5100 Ethernet shield, a relay, door sensor, and dht11 temp & humidity sensor. I can monitor the status of the door, open & close it, and view the current temperature and humidity inside my garage.

Instead of hosting the page directly on the Arduino (or in your case the EtherTen) and serving static pages, I just host the page on my own server and get the needed information from the Arduino using AJAX. The button is protected by a PIN code and temperature, humidity, and door status data is logged to MySQL every 10 minutes. It will also send me an e-mail if I leave my door open past 10PM.

I made a simple Android webview app so I can easily control it via my phone (see attached screenshot). Using AJAX, I can see the status of the door change without needing to refresh the page (polls every 2 seconds).

acarmona_mty (author)ydoucare2016-03-24

Do you have the project to share ? I'm very interesting to do it.

chimeranzl. (author)acarmona_mty2016-04-18

You can view my project that is similar to this here if it helps http://www.chimera.co.nz/electronics/arduino-garage-door.htm

ydoucare (author)acarmona_mty2016-04-11

I do not have an instructable currently, sorry. I'm currently in the process of re-building the entire setup using a Raspberry Pi, which will do everything (webserver, database, control the relays, etc), instead of having to run a separate webserver. I recently got a 3D printer and just finished designing and printing the final version of the case. I may consider doing an instructable in the future.

ThothLoki (author)ydoucare2016-04-11

ydoucare,

I am interested as well. I am in the process of building something similar but with an Arduino MKR1000. The MKR1k will monitor my garage door and control it (with leftover pins for temp, humidity, light sensor etc). I would like it to report back to a RPi running flask. Any suggestions on how to get the two to communicate to each other over my local ethernet? I am assuming html GET and POST?

ydoucare (author)ThothLoki2016-04-12

ThothLoki, in my case, I just send GET requests using jquery/javascript in the browser to a PHP script sitting on the webserver which sends the actual GET requests locally over the LAN to the Arduino which returns back the data to the PHP script, which gets returned back to the javascript code. Then I just manipulate the DOM with jquery to update the client with the new data. Same thing goes with controlling the relay. I just send a GET request to the Arduino using a PHP script and instead of returning data, I just have the Arduino cycle the relay. I have no experience with the MKR1000, but the code on the Arduino side to respond to HTTP over the network is pretty small and simple. But again, i'm moving the whole solution to a Pi to consolidate it down into one device which will handle the relay control and sensor reading along with serving up the website and logging the data. It's probably 95% there already, I just need to do the swap and pull my DHT22 temp sensor from my Arduino and hook it up to the Pi and update my code from the DHT11 I currently am using. I've got a hacked together authentication system so some random person can't just take the url and play with my garage door, but i'm not confident enough in it at this point to post it.

ThothLoki (author)ydoucare2016-04-12

Just think of the MKR1000 as a Arduino 101 with wifi shield except for half the size of an UNO

ThothLoki (author)ydoucare2016-04-12

Thanks. I am hoping to set my Pi up as a hub for more than one location. This should be a fun start. I agree with you though, security will be an issue.

BrianF65 (author)ydoucare2015-11-28

I am interested in how you built your project. Do you have a post anywhere showing the steps? Can you post your code?

Thanks, great project!

BenW24 (author)ydoucare2015-08-31

Awesome! I would like to pursue something more similar to what you did. Do you happen to have your own instructions?

ron.bowes (author)2015-09-17

I just built this and was wondering why when I log into the "Speak friend, and enter:" website, the garage door automatically opens/closes? I ask because I embedded some code for a network video camera and would like to see if the garage door is closed or open.

ron.bowes (author)ron.bowes2015-09-21

I created a solution that seems to be working, just in case anyone else needs it. I'm sure there is a much better way to do it though, but here is what I added. The items I added are bold.

************************************************************************************

Webserver.cpp:

boolean boolDoorActive = false; // This is a global variable that is used between the different libraries. false = the door will not open, true = the door will open

// --------------- Initialization and processing.

void InitializeGarageDoorWebserver()

{

boolDoorActive= false;

************************************************************************************

WebPages.cpp

void SendLoginPage(WebServer &rServer)

{

extern boolean boolDoorActive; //This is getting the global variable value

boolDoorActive= false; //this is set to false so the garage door does not open. So if you Lock the page and then sign back in later, the flag gets set to false and the door will not open.

************************************************************************************

AccessContrl.cpp

void ActivateGarageDoor()

{

extern boolean boolDoorActive;

Serial.println(F("Door activated.")); //Door activated - is the Serial monitor

if (boolDoorActive== true) { //when you are signed into the page, initially the value will be set to false and the door will not open. However, when you click the Activate button then this code will be implemented.

digitalWrite(PIN_INDICATOR, HIGH); // set the LED on

digitalWrite(PIN_DOOR, HIGH); // Open door.

delay(DOOR_ACTIVATION_PERIOD);

digitalWrite(PIN_INDICATOR, LOW); // set the LED off

digitalWrite(PIN_DOOR, LOW); // Door will continue to open by itself.

}

else

{

boolDoorActive= true; //if you just signed into the website then the value will initially be false. This step changes the value to true, so when you press the Activate button the door will open/close. Since there is no other code in this step, the garage door will not open.

}

}

************************************************************************************

DexterE4 (author)2015-09-07

Can i use Bluetooth and Arduino WiFi together? When the internet or my WiFi running slow? Thank you for the answer! :)

joon874 (author)2015-09-02

It is so great project for other makers.

The hardware you did is so powerful.

Keep it up!!!

JarrettD (author)2015-08-13

What kind of modifications do i need to do to use a plain arduino uno and ethernet shield instead of an etherten module?

BenW24 (author)JarrettD2015-08-31

I would also be interested if this would work so that I don't need to buy a new unit.

austerepenny413 (author)2015-08-15

I need help for the 3D printed case; when I go to the suggested website do I ask them to print it in cm, mm, or inches?

Hi, one problem with creating the model in blender is that it came out 10x smaller (when opened in UP! 3D Printing software at least). If you can scale it somehow so that the final dimensions are 120mm x 95mm x 50mm (height x width x depth).

Hi MegunoLink:

I sent the dimensions to my designer and he asked: Are those the dimensions for all 3 files?

So, are they the dimensions for the entire box, or do they apply to the base, top, and brackets?

EricP8 (author)2015-03-01

What if I DON'T want to use my wifi or home network or smartphone, but instead want to make my own regular common radio-clicker garage door opener, like from a Genie or Liftmaster or Craftsman or something? Is there a radio shield for Arduino that will take a radio input from a clicker? I'm trying to build a gate opener for a heavy gate with speed control and programmable accel-decel to ease the stress on the drive screw. But there's no network available there.

I guess I could use bluetooth but again, I want to just use a clicker not a smartphone. There is a clicker built into most cars these days so you don't even need a separate clicker. I think other people would find this useful because you can use this switch built into your car to signal the arduino, like this could signal your entire house or other location that you have arrived even if you don't want to get your phone out.

scottinnh (author)EricP82015-08-05

I'd suggest then you simply install a small wireless router at the gate, and pair your phone to that. Don't assume a router must be connected to the Internet - it can be an island (or you could go ad hoc network). Then you can leverage this guide without bigger "unknowns".

MinaksheeS (author)2015-07-11

what will be total cost of this project

SkynetHome (author)2015-06-01

How can I use OpenHab to control this instead of Megunolink?

vadipp (author)2014-04-02

You have to consider security for this project.

1. Be sure your Internet router doesn't have any known vulnerabilities that would allow an attacker to enter your internal network.

2. Be sure to use a WPA-encrypted WiFi with a secure password.

3. Additionally, it's better to use HTTPS on the Arduino server, because this way even if an attacker somehow gets inside your network, they will not be able to see your password in plaintext.

Ethylene32 (author)vadipp2015-04-13

You could also work with Bluetooth, the Bluetooth API for Android is relatively simple and easy to send/receive information with the Arduino.

EdDziuk (author)vadipp2015-03-22

I don't believe an Aurdino can accommodate HTTPS. It doesn't have enough memory. I think a good solution is a VPN server in front of the Aurdino.

EdDziuk (author)2015-03-22

I've gotten the project working. I've got a Raspberry Pi VPN server in front of it so that I can let non-family members open the garage, and easily turn off their access, as well as access the opener from anywhere in the world. My son said he can print the case on a maker bot, but needs the dimensions. The commercial printers wanted a few hundred to print it, and the price varied over a wide range.

Mudgee (author)2015-03-21

Hi,

I've downloaded the most recent Arduino IDE V1.6.1 and the Garage Opener Zip file. I've adjusted the IP address as instructed and when I compile I receive the error below - can anyone advise? I'm lost. Any assistance appreciated.

In file
included from
/Applications/Arduino.app/Contents/Java/libraries/Ethernet/src/Ethernet.h:7:0, from
Webserver.cpp:3:

/Applications/Arduino.app/Contents/Java/libraries/Ethernet/src/EthernetClient.h:
In member function 'int WebServer::read()':

/Applications/Arduino.app/Contents/Java/libraries/Ethernet/src/EthernetClient.h:27:16:
note: candidate 1: virtual bool EthernetClient::operator==(bool)

virtual bool
operator==(const bool value) { return bool() == value; }

^

In file included from
/Applications/Arduino.app/Contents/Java/hardware/tools/avr/avr/include/avr/eeprom.h:570:0,

from
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/USBAPI.h:25,

from
/Applications/Arduino.app/Contents/Java/hardware/arduino/avr/cores/arduino/Arduino.h:224,

from
Webserver.h:6,

from
Webserver.cpp:1:

Webduino.h:729:19: note: candidate 2: operator==(int, int)
<built-in>

if (m_client ==
NULL)

^

Sketch uses 20,152 bytes (62%) of program storage space.
Maximum is 32,256 bytes.

Global variables use 1,405 bytes (68%) of dynamic memory,
leaving 643 bytes for local variables. Maximum is 2,048 bytes.

dhayez (author)2015-03-15

I've tried to build this project with slightly different hardware. Arduino Uno and Ethernet Shield only because I already had the hardware on hand. Do you know what changes I need to make in the configuration in order to use the Arduino Uno and Ethernet Shield?

asdadeel (author)2015-03-12

thank you

csresale (author)2014-12-05

what if gagrage is detached and it be wireless?

MegunoLink (author)csresale2014-12-08

You could use one of the many wireless arduino shields available now. The code would need to be modified to suit but it should work.

ArmandoG (author)2014-12-08

These relays have three inputs so that you can use an external power supply. How many relays can I have off of the arduino powered by 12v 350 ma transformer. I was reading that you can power 200 ma from the arduino powered from a transformer with each relay requiring 40 ma. Can I use a high digital pin to power the relay and also triger the relay? Wiring the + pin and the data pin to the programmed arduino digital pin. The relay would only receive power when being triggered and relays not being used would not be using any power unless needed. I also need to power an HC-06 bluetooth and would like to power everything from the arduino.
Thanks in advance,
Armando

MegunoLink (author)ArmandoG2014-12-08

Hi Armando, you would be better off driving the relay through a MOSFET like the ones available here (http://www.dx.com/p/5v-relay-module-for-arduino-bl... The Arduino could then control a larger number of relays without exceeding its own pin current rating.

Glenn OveB (author)2014-11-26

I have a garage that is not connected to my apartment. And I am not able to connect a Ethernet cord to the Arduino unit. I not even sure if my wifi signal reaches to my garage. I will check that later today. What are my options then?

I wish to use my Android phone.

ArmandoG (author)2014-11-16

If you use the above relay, do you still need the diode and transistor? Isn't the relay optically isolated from electric back flow?

MegunoLink (author)ArmandoG2014-11-25

No you don't, the relay used in the pictures above already has the diode incorporated.

Cheers

Benjamink1 (author)2014-08-28

I am ben and student. I use servo motor but i don't know how to write code. Would u help me to write code, please?

#include <Servo.h>

#include "AccessControl.h"

Servo myservo

{

void setup()

{

myservo.attach(9);

}

void locked()

{

if()

{

digitalWrite(PIN_DOOR, HIGH);

myservo.write(90);

}

else

{

digitalWrite(PIN_DOOR,LOW);

myservo.write(0);

}

}

I write this coding. It show error "function definition does not declare parameters".

I want to know what coding is wrong.

Juniorb1 (author)2014-08-23

I am a newbie and just recetly purchased an Pcduino 2 that has wifi and ethernet, a linkerkit base , T- board v2 and a 5v linker relay , also has the Arduino Ide installed, would this project work on this board? If so would it be hard to implement?

I have tried another project wriiten in python for the Pcduinco and have not been able to get it up and running due to code errors iAttributeError: 'module' object has no attribute 'pinMode) and can't seem to get any help.

About This Instructable

294,321views

1,016favorites

More by MegunoLink:Arduino WiFi Garage Door Opener
Add instructable to: