Professional Automatic Sliding Gate opener And Motor Manufacturer For Many Years 


raspberry pi 3 garage door opener

by:LSDD     2020-01-07
Open, close and monitor the garage door with Raspberry Pi and smartphone.
Opening and closing the door is by using
Signed certificate installed on home phone.
Send a text message if the garage door should not be opened (SMS)
On the phone.
Garage doors have been in constant use since the end of 2014.
I have been trying to update these changes over the years.
There is an appendix that describes the changes to the structure.
The goal of this project is: the foundation of this garage door opener is derived from the exaggerated Raspberry table: Raspberry Pi garage door opener.
It turned out that I used B Raspberry Pi and then moved to B Raspberry Pi 2. now I use Raspberry Pi 3.
I communicate with Raspberry Pi with my MacBook, but any computer is available.
There\'s no compelling reason to build this device, but it\'s fun.
It\'s more cost-effective to buy one.
Similar equipment can be purchased for about $130.
Note: purchase or collect parts and tools (prices in USD). My total: $172.
00I has the following sections, tools, and services: some type of setup is required for all Raspberry Pi projects.
I like to use the same set of instructions, and there is a place where they can be updated if necessary.
Set Raspberry Pi with the following instructions: do not set Raspberry Pi with monitor or keyboard. The above instructions include optional steps in the appendix.
Please make sure to perform the following steps: add client-
Close the Raspberry PiOnce and remove these is no longer needed.
Run commands on Raspberry Pi using wifi, ssh, and terminal windows on Mac Book.
Unplug the power and plug it back in and the Raspberry pi should reboot.
Install the terminal window on the Wiring PiOpen Mac Book.
Log in to the Raspberry Pi, then download, compile, install the Wiring Pi.
The software allows control of the GPIO pins. Here is a step-by-
Step Guide: is the condensed version of the instructions: run the gpio command to check the installation: The above command should give you some confidence in the normal operation of the wiiringpi.
Install Apache and PHPRun the following command: to verify that the web server is working, open the browser and enter it in the URL box:♣Raspberry-pi-
Ip♣The default site for Apache is to \"it works!
\"Open a terminal window on the Mac Book.
Log in to the Raspberry Pi and delete the default index.
Html file, change the permissions on the website directory, and edit the file named index. php.
And enter the following code: CTRL-
O and enter write file, CTRL-
X exit the editor.
High permissions to change file grabs-
Resolution remote garage door opener from network.
Use the Mac brush to modify the image as you wish.
In the picture above, the sprite garage opener with high resolution was used, the Raspberry pi logo was added and the led was removed.
A picture is the background (remote-background. jpg)
The other is the active image (remote-press. jpg).
The plan is to press the button and the raspberry flashes instead of flashing the led.
I simplified the website.
Copy the image to Raspberry pi: there is only one button for the site.
To verify, open the browser and enter♣Raspberry-pi-ip♣.
Instead of the default site for Apache, it says \"it works!
\", The button should appear. Press it.
To facilitate remote access to the garage door opener, I used a dynamic DNS name.
Because I don\'t like to remember IP addresses.
With this feature, I entered♣Dynamichostname♣. getmyip.
Com in the URL field of the browser.
Note: the IP on the home router may change without notification, but this rarely happens.
I chose to use DynDNS.
You need to know the public IP address of the router. U-
Router IP:♣Uverse-public-
Ip♣You can view your host name and DynDNS Pro account details.
Here are some tips for getting started: Once done, the web server will work from the Internet.
To verify, enter♣Dynamic
Host Name♣You should see the garage door open button.
For the code provided (step 4 and 6)
I\'m using the GPIO pin 7.
It is a coincidence that the GPIO 7 is the same as the wiringPi pin 7.
In PHP code, the wiring Pi PIN number is used instead of the GPIO pin number.
You can use any one you want, but be sure to change the code.
I tried using twisted wires, but the relay couldn\'t hold well on the twisted wires.
The real line is better.
I created three connection cables the first time I tried (female-to-male).
Here\'s a better way to create a connection cable (female-to-male)
: Connect the relay to the pi, as shown in the figure: Most relays, including the purchased relay, operate like this: if the Raspberry Pi is powered off, the relay has a safety mechanism to keep the circuit closed.
Problems may occur when the Rapberry Pi and relay restore power, but before the Raspberry Pi completes the boot to turn on the signal that needs to turn off the circuit.
You can wake up in the morning and the garage is open and there may be a few new friends!
However, the relay will not actually initialize until the GPIO pin mode is set through the following command: the gpio Mode 7 out.
Also, if the GPIO pin is ON (gpio write 7 1)
Once initialized, the relay will remain turned off before the GPIO mode is set.
To make this initialization run at startup and not wake up new friends, use the following startup-up script.
Then paste this script: Save: CTRL-
O, enter and exit the nano, CTRL-
X make the file executable: now tell your pi to run this script at startup :(
Note: you can safely ignore the \"lost LSB tag\" warning. )
Make sure the startup script is running open browser and click open.
Relay should be clicked.
Be sure to run when moving Raspberry Pi: you may want to power off the garage.
So, the doorbell opener won\'t power you :).
The real reason is that every time you short The Wire, the door moves up and down.
Loosen the screws on the wall from the doorbell opener that connects the doorbell to the wall.
Poke a hole in the house from the garage behind the doorbell opener.
In Texas, Raspberry Pi should not be in the garage, and the temperature change in the garage is beyond the operating specifications of Raspberry Pi.
Pass the relay line through the hole (
Using hangers).
Release the two screws on the back of the doorbell opener.
Two ends of the relay line: 1)
The relay side of about 1/8 \"inch, the upper side of about half\" inch doorbell.
Bend the doorbell of the wire into a half ring large enough to fit the back screw.
Connect a relay line to each screw on the back of the doorbell and tighten the screw.
The connection is the image shown in the figure.
Since the relay isolated the circuit, the direction of the relay connected to which screw is not even important.
My family and I were on vacation before I finished the code and I opened the browser.
The last thing my browser sees is the garage door opener-page refresh and the garage door opens.
A few days later, a neighbor called and asked if the garage door should be opened?
Luckily, I can turn it off 500 miles away.
This confusion forces me to change the code so that this doesn\'t happen and add a sensor and garage door status to the site.
This is the link to add the original Instructure of the sensor.
However, given all the work that has been done, installing sensors can be greatly simplified, rather than adding a few lines of code to the index using python. php.
The magnet is attached to the left-
Hand, top interior side of garage door, sensor attached to garage wall.
So, I had to run a solid constant temperature line from the sensor to the Raspberry pi.
This requires a hole from the garage to the attic, from the attic to the wall containing the garage door opener (Doorbell switch).
I inserted a blue junction box between SECO-
LARM sensor and real line.
In my house, there is a 18 inch gap between the ceiling on the first floor and the bottom on the second floor.
I think this is where the heating and cooling pipes run.
I need a drill extension long enough to go through the second floor and the Front 2x4 (top plate)
There\'s a doorbell inside.
The most important part is that when drilling into the wire from the attic will flow to the area where the garage door opener, do not drill.
It\'s not fun to solve this problem.
It is very exciting to see the sparks and let the lights go out!
The sensor requires two solid thermostat wires or invisible dog fence wires.
There are multiple pin descriptions for Raspberry Pi (
BCM of physics, wPi).
The code uses the wiring pi pin number.
To view all pins, as well as pin mapping and pin values, enter: For the gpio manual, enter: in the original instruction, the physical pin 9 is grounded and connected to SECO-LARM leads.
However, this does not work for me.
Instead, connect leads to physical pins 15 and 17 physical pins 15 (wPi pin 3)goes to 3.
3 V when SECO-
The LARM sensor is turned off.
The physical pin 17 is 3. 3v.
If it doesn\'t work then switch the connection on SECOLARM. Attach SECO-
From the gate to the garage and the walls.
Run the wire and connect to the Raspberry Pi.
If the garage door should not be opened, send a text message to the phone.
Install and configure simple SMTP.
I have AT&T phones and use♣Cell-phone-number♣@txt. att.
Net for text messages.
I also have a gmail account, the example below uses♣Gmail-account♣@gmail. com.
If you are using a different service then please make the appropriate changes.
For the $ command below, open a terminal window on your MacBook and log in to your Raspberry Pi.
Make sure the repository is up-to-
Date: Install simple SSMTP and mail utility: Edit the SSMTP profile: as shown below: Edit the SSMTP alias file: create a line for each user who can send an email.
For example: set permissions for the SSMTP profile: permissions for the file/etc/ssmtp.
Conf decides who can send an email from Raspberry Pi.
By default, the file is owned by the user root, and the Group of the file is also the root.
Edit the SSMTP alias file, which contains data about the email account: Once the above setup and configuration process is completed, test it by sending an email from the command line.
Create a script to check if the garage door is open when it should not be opened and then send a text message.
Then add the following: then add the crontab to run within the required time: and add: go to next if everything is OK.
Put the raspberry skin in the cheats
I bought this at Michael for about $7.
I cut some small holes in the wire and power cord.
Sunfoundry monthly 24 v relay Shield module Arduino UNO 2560 1280 arm pic avr camera 21feb20603apr204apr205apr205apr201may201may201611nov201621jan201disk space usdlast line shows all disk space usage.
8 gb SD card.
If you have a problem, then try this: if the email is set up correctly, then you should receive an email in your gmail account.
If you encounter an authentication failure: you may need to reduce the security of your account.
However, it is not recommended to reduce security.
Google will send an email with a link to lower security settings.
You can switch from the current email reader to using www. gmail.
Access com for your account (recommended)
Or change your settings so that your account is no longer protected by modern security standards.
I do not recommend lowering your safety standards.
If you encounter an authorization failure: the most likely reason is that you have specified the wrong username or password for your gmail account in/etc/ssmtp. conf file.
Check again the values of the AuthUser and AuthPass fields.
If the connection is lost during processing: it is likely that you specified the wrong port for Google smtp somewhere in/etc/ssmtp.
Conf or in/etc/ssmtp/revalidate.
Check the last line of the log.
There should be some relevant error message: the garage door will not open if everything is OK, it will stop and then try to restart.
If it doesn\'t work, unplug the power cord from the Raspberry Pi and restore the power.
The Raspberry Pi should be restarted in less than 2 minutes and everything should work properly.
This is usually caused by a power outage at the residential gateway.
The best way to do this if there is any problem is to use the following command: logging into the raspberry pi from MacBookterminal is the MacBook utility: Disk/application/utility/terminal.
I put the terminal application on the dock.
On the MacBook, open the terminal to log in to the home gateway on the MacBook, open the browser URL =♣Raspberry-pi-
Password♣If there is a problem with the logs, please check if there are errors, warnings, or other problems with these logs.
MAC Directory on MacBook for storing website files =/user/♣My macbook♣/Desktop/wi-
Home with fi enabled/garage door opener with wifi enabled/website password =♣Raspberry-pi-
Password♣RAM and CPU using ctrl-
C, exitRaspberry Pi network♣Raspberry-pi-ip♣ = 192. 168. 1.
93 director of raspberry pie website
Ram stopped working on Seco-01MAY2016.
Ram stopped working.
This is the third time the sensor stops working.
Correctly, the physical pin 15 on the Raspberry Pi stops detecting 3. 3v input. I tried 3.
3 v physical pins 1 and 17, both are still outputting 3. 3v.
I switch from physical pin 15 to another GPIO physical pin 16 (GPIO 4)
It started working again.
So, there\'s nothing wrong with Seco. larm.
The problem seems to be on the Raspberry Pi.
The physical pin 15 is dead.
This is a very good post on how to test the GPIO pins.
I switched from GPIO 3 to GPIO 4 and changed the code accordingly.
I don\'t know why the GPIO pin stopped working.
Here are two possible reasons:
I have AT&T U-
But any service should be effective. If the U-
The Verse Gateway is restarted or powered off and may need to restart the Raspberry Pi. U-
Public IP for Verse residential gateway =♣Router-public-ip♣A U-
The public IP of the Verse residential gateway can be changed, but it is very rarelyU-
Home page of Verse residential gateway = 192. 168. 1. 254U-
SSID of wireless access point of Verse router =♣Ssid♣WiFi throughput is slower than expected.
All circuit providers adjust everyone\'s wifi to Channel 1 by default.
Change to use less channels such as 11.
Try using odd numbers.
Note: I told a few neighbors what I did to improve wi
Now everyone is on the 9 th or 11 th, so I moved back to the 1 Th.
You should always use a strange channel. Open a browser. For U-
Poem, enter 192168. 1.
254 in the URL box.
Select channels 6 or 11 by clicking on the wireless link.
There is a smartphone app called wifi analyzer.
One of the displays shows all nearby wifi access points broadcast on a particular channel.
In my community, everyone is set to Channel 1.
Custom message
Chat Online 编辑模式下无法使用
Chat Online inputting...