My very own door opener, using simple servo (taken from Arduino projects), glued to the domophone. :)
Controlled via Telegram bot command or simple HTTP request to secret endpoint. Under the hood it uses Pi-Blaster to set PWM (for servo angle control).
- Create Telegram bot: https://core.telegram.org/bots
Set below commands for your bot (using BotFather):
open - Open door
-
Install Golang.
-
Install Pi-blaster.
-
Install
dooropener
service:
cd ~
git clone https://github.com/erkexzcx/dooropener
cd dooropener
go build -ldflags="-s -w" -o dooropener ./cmd/dooropener/dooropener.go
cp dooropener.example.yml dooropener.yml
vim dooropener.yml
sudo cp dooropener.service /etc/systemd/system/
sudo vim /etc/systemd/system/dooropener.service
systemctl start dooropener.service
systemctl enable dooropener.service
Upgrade dooropener
using below commands:
cd ~/dooropener
git pull
go build -ldflags="-s -w" -o dooropener ./cmd/dooropener/dooropener.go
systemctl restart dooropener.service