-
Sonoff Alternative
03/08/2018 at 21:52 • 0 comments@juan11perez has ported this project to Sonoff!
He has nicely documented the build in this PDF.
-
Debugging over the network
11/22/2017 at 19:22 • 1 commentI just posted a new version of the code that also provides a server so that you can check the current status while it is running remotely:
$ telnet 192.168.2.8 Trying 192.168.2.8... Connected to 192.168.2.8. Escape character is '^]'. mqtt_connected = 1 distance_cm = 102 door_open = 1 Connection closed by foreign host.
-
It works!
06/05/2017 at 14:53 • 1 commentI had to modify the code to check the state twice and make sure the values match before sending an event because sometimes there are fluctuations in the sensor that would report it as open for a very small amount of time.
Because making that change involved taking the unit off the ceiling for USB programming, I also added Arduino OTA support so that future updates could be flashed over WiFi.
-
Housing
05/30/2017 at 00:32 • 0 commentsWhile waiting for my Amazon order to arrive, I designed a mount to contain the hardware and hold it to the ceiling:
You can download STL files for 3D printing and IPT files for editing with Autodesk Inventor from the project files. There is a version with holes for a fan on the front (modeled after the cooling fan from a Dell PowerConnect switch), however, I do not have a fan that the ESP8266 can power, so I created a version with passive air vents on that side as well.
-
Wiring
05/29/2017 at 21:42 • 0 commentsHC-SR04 ESP8266 Vcc Vin Trig D1 Echo D2 Gnd GND -
Hardware Selection
05/28/2017 at 14:24 • 0 commentsAll final hardware decisions are listed and Amazon-linked in the components section.
I started with my goal: to remotely check if the garage door is closed for peace-of-mind.
I decided that I didn't want to interfere in any way with the existing opener unit because I'd rather not break it trying to interface with it and I don't want to control it because that introduces a security risk. I decided to use a non-contact sensor to reduce wear on the door and/or sensor as well as any scratching noise or resistance to movement. This left one good option: an ultrasonic distance sensor. I can mount it near the bottom of the door opening or on the ceiling and check if it detects a door close in front of it.
I have an Arduino UNO, however, WiFi shields are expensive and I'd rather keep it available for tinkering. While researching WiFi-enabled microcontrollers, I stumbled across this article about the ESP8266. I found a nicer one for just under $10 on Amazon and now it's on its way.