I have a fun one. The front door to my house had an automatic door opener, paired with a single-button remote control to unlock and open the door. The remote control was annoying to carry and use. (This was before IoT became a thing.)
I pried open the remote, soldered on an extra circuit bypassing the push switch, and hooked it up to an Arduino. When a packet is sent over serial, the Arduino simulates a button push:
This was paired with a tiny web server to do the serial write:
#!/opt/bin/python2.6
PORT = 5525
import BaseHTTPServer, SocketServer
class LoccaHTTPRequestHandler(BaseHTTPServer.BaseHTTPRequestHandler):
server_version = "LoccaServer/1.0"
def do_GET(self):
if self.path.startswith("/trigger"):
serial.write('A')
self.send_response(200)
else:
self.send_error(404)
serial = open("/dev/ttyACM0", 'wb', 0)
httpd = SocketServer.TCPServer(("", PORT), LoccaHTTPRequestHandler, False)
httpd.allow_reuse_address = True
httpd.server_bind()
httpd.server_activate()
httpd.serve_forever()
Finally I threw together an iPhone app with the most basic UI imaginable: a static full-screen photo of the remote; tap once, it fires off a HTTP request, and the door swings open:
At one point I had a gist with a bunch of links to a web server that controlled some home automation stuff. Add a link to your Home Screen and you’re good to go! Easy to share as well
I pried open the remote, soldered on an extra circuit bypassing the push switch, and hooked it up to an Arduino. When a packet is sent over serial, the Arduino simulates a button push:
This was paired with a tiny web server to do the serial write: Finally I threw together an iPhone app with the most basic UI imaginable: a static full-screen photo of the remote; tap once, it fires off a HTTP request, and the door swings open: That's basically all of the code. Considering how much of a janky hack this is, it worked great.Ancient write-up with some photos: https://web.archive.org/web/20120103180640/http://ghughes.co...