Home‎ > ‎News‎ > ‎

Fancy DoorBell

posted 15 Nov 2013, 11:11 by Jan Larsson
Ever wanted a more fancy doorbell? This is how to do it. You only need

1 Rasberry Pi with Domoticz
1 RFXcom
1 Nexa 433 MHz wireless doorbell.
1 HTPC with yaVDR

We will skip some parts and assume you got all the other stuff installed already. The Nexa Doorbell is installed in the Domoticz and named as a swtich 'DoorBell'.

1. set up ssh private and public keys so we don't need passwords.

2. From Domoticz server create a LUA script to trigg on the DoorBell
/home/user/Domoticz/scripts/lua/script_device_door.lua

----------------------------
-- Jan Larsson 2013-11-15
-- Info@janlarsson.net

commandArray = {}

        if (devicechanged['DoorBell']) then
                print ('Door bell script executed')
                os.execute('sudo ssh root@10.10.10.10 /home/user/door.sh')
        end
return commandArray
----------------------------

3. On the yaVDR TV box create a script to notify about the doorbell, this script will mute the TV and echo a text on the screen. TV box IP is 10.10.10.10

/home/user/door.sh
------------------------
!#/bin/bash
svdrpsend VOLU mute
sleep 1
svdrpsend MESG "Door Bell!!!!"
svdrpsend MESG "Go open the door"
sleep 5
svdrpsend VOLU mute
------------------------

4. done!
Comments