RaspberryPi Door Opener

I would add an in-call feature and mapping

TrySystem

http://www.asteriskdocs.org/en/2nd_Edition/asterisk-book-html-chunk/asterisk-APP-B-228.html

command to try thhe system with

`TrySystem(/usr/bin/mosquitto_pub -h 192.168.1.3 -t "doorlock "-m “opensesame”)

mapping gpio to mqtt with

and add a

You could of course use ssh instead but that is a very round-about way of going from a human pressing a dtmf button to powering a door latch somewhere else on the internet (use ssl if you go that route, mqtt is really quite secure if done properly) , . Use an open access mqtt broker and you can let the cleaning lady in while your at the pub. And it cost you 2x$5 for the pi zeros and another 5 for the relay, add in a few hours of R&D and you “learned to fish a bit”.

Then learn how to do it with thge AGI library straight to mqtt and there is no messing with the dialplan
or ssh or bash or routing or . . . needed as you can intercept the DTMF in there as needed.

1 Like