Hi all, i’m posting my config as i always wanted to implement smart doorbell, but i knew that would be expensive and i would may face difficulties due my home main gate being about 30m (100ft) from my house.
For whom may interest and face similar situation i’ve made as follows:
Hardware:
1 - sonoff mini: as sonoff mini has S1 and S2 terminals i knew i could use them to trigger as someone pressed my doorbell, that way performing any automation.
2 - 110v NC relay: this was my solution for the distance problem. sonoff mini S1 and S2 has 3v between contacts, and due the distance, there is huge voltage drop, i couldn’t trigger the sonoff from distance, this way i needed to use the 110v relay to close contact next to the sonoff. so i did this way.
why doing this way? as i said the main factor was distance, i could install the sonoff or esp8266 at the doorbell switch, but the distance would impact on wifi signal badly, so i decided going this way, and i would have to install another wire to the switch, i decided that was not an option.
Alexa:
for the automation i firstly created a routine on Alexa that increases my echo volume, rings the bell from Amazon sound effects database (ding dong style), saying that someone rang the doorbell then lowers the volume.
now i can access that routine from HA.
Home Assistant:
Created an automation on HA, and my trigger was the sonoff (pulse mode) to do the following.
1 - call the Alexa routine created
2 - opening security camera live feed on my TV for 20s and stopping the feed
3 - saving a snapshot from security camera
4 - send this snapshot to HA app on both, my wife and my phone.
Automation Code:
- id: '1604945323753'
alias: Doorbell
description: ''
trigger:
- platform: state
entity_id: switch.sonoff_1000e5705c
from: 'off'
to: 'on'
condition: []
action:
- data:
entity_id: media_player.echo_de_henry
media_content_id: Doorbell
media_content_type: routine
entity_id: media_player.echo_de_henry
service: media_player.play_media
- service: camera.snapshot
data:
entity_id: camera.main_gate
filename: /config/www/images/main_gate.jpg
entity_id: camera.main_gate
- delay: 00:00:05
- service: notify.mobile_app_sm_a530f
data_template:
title: Ding Dong!
message: '{{now().strftime("%H:%M:%S")}} Someone is at the door !
'
data:
image: /local/images/main_gate.jpg
- service: notify.mobile_app_sm_a515f
data_template:
title: Ding Dong!
message: '{{now().strftime("%H:%M:%S")}} Someone is at the door !
'
data:
image: /local/images/main_gate.jpg
- service: media_player.play_media
data:
entity_id: media_player.tv
media_content_id: http://192.168.x.x:xxxx
media_content_type: image/jpeg
entity_id: media_player.tv
- delay: 00:00:20
- service: media_player.turn_off
data: {}
entity_id: media_player.tv
mode: single
This way i could perform what i wanted. There are other ways doing this, i know, but i preferred the way i could spend less time doing (like soldering hardware or programming esp’s would be very time consuming for me) and not spending lots of money on other solutions.
If you think you could help someone that may reach out this topic with a better solution feel free and post it.
I found many solutions for my automations on this forum, so i thought i could help a little bit, even being a beginner. So, thanks a LOT.