If someone’s interested in how to easily get the image from a jpg camera on your Google Home hub screen, I’ve been using this automation for some time and it works great.
I have a Doorbird doorbell installed, and this automation simply plays a sound on my Google Home in the living room and sends the live stream to my Google Home hub, when someone pushes the doorbell button. Be aware that it is the jpg livestream, so not super smooth, but about 1-2 fps. Still good enough to see who’s outside!
Feel free to ask if you have any questions
automations.yaml:
- alias: 'Doorbell'
hide_entity: True
trigger:
- platform: event
event_type: doorbird_hoveddr_button
action:
#Play 'Ding' sound on Google Home speaker in living room
- service: media_player.play_media
data:
entity_id: media_player.google_home
media_content_id: https://ha-address:port/local/mp3/ding.mp3
media_content_type: audio/mp3
#Show image on Google Home Hub
- service: media_player.play_media
data_template:
entity_id: media_player.googlehomehub4524
media_content_id: "https://ha-address:port/api/camera_proxy_stream/camera.hoveddr_live?token={{ states.camera.hoveddr_live.attributes.access_token }}"
media_content_type: image/jpg
- delay: '00:00:30'
#Turn off image after 30 secs
- service: media_player.turn_off
data:
entity_id: media_player.googlehomehub4524
There is an open PR to add the stream URLs to the event data for Doorbird events. May be able to improve the video quality if you bypass the camera proxy and use the stream direct from the device (assuming that the stream formats are supported).
As far as I understand, the format is the problem. I guess that’s also why people use solutions like BlueIris to get the videostream on cast-devices. But for my use, this is plenty, and very fast to set up That being said, I am of course welcoming any advancements, as long as it doesn’t make things too complex!
Thanks for posting this. I have the second part of your automation working correctly; if I manually trigger it, the video feed is sent to my Hub. However, the button event is not registering in HA (i.e., automation is not triggered and the Logbook does not show the event) and I cannot find any way to troubleshoot that problem. Any insight is appreciated.
Sorry to be a pain, but found this thread and am desperate to link my new doorbird video doorbell to my google home mini’s in the house as the chimes being sent to our mobile phones aren’t loud enough as well as the fact our phones can be on silent of a night.
Without being able to code or even knowing where the hell I would start to paste that code… can someone offer me a solution? Have above average basic tech knowledge if that helps lol
Just need a chime or sound played through google home when doorbird activated by a guest … help!
Cheers
Craig
Also, is there a way, using google home, to open the door or speak to visitor through google home ?
automations.yaml:
- alias: 'Doorbell'
hide_entity: True
trigger:
- platform: event
event_type: doorbird_hoveddr_button
action:
#Play 'Ding' sound on Google Home speaker in living room
- service: media_player.play_media
data:
entity_id: media_player.google_home
media_content_id: https://ha-address:port/local/mp3/ding.mp3
media_content_type: audio/mp3
First find a sound file you would like to play on your Google Home or Chromecast group.
Then create a ‘www’ (without quotes) in your /config folder (the www-folder is called local, when used in HA, as you can see in the automation).
Now place the sound file in the www-folder (/config/www/<soundfile.mp3>)
Now as soon as you’ve adapted the automation to your own entity-names, you should be good to go. Good luck.
I’m sure it is possible to use google assistant to open it, but I haven’t seen that done yet. I am a beginner with home assistant, so I can’t really help with that. You should probably start a new thread, as this one is pretty old. But I can try to help you with the notification on Google Home Mini. I am assuming you don’t know what Home Assistant is, but please excuse me if you already know. So DoorBird and many other companies don’t support things like Google assistant, or things like that. So Home Assistant is like a server software that can be installed on an extra computer with barely any power, or something like the $35-ish USD Raspberry Pi computer. Home Assistant lets you connect a lot of devices and make them work together. So you can make it so when someone activates it, it plays the video on a smart display, or plays a chime on a google home mini, or even something random like blast music and turn off all the lights. Anyways, since you are new to the forum I would guess that you don’t already use Home Assistant. Again, forgive me if you already do. I would personally recommend buying this raspberry pi kit, and this micro sd card (unless you already have one). If you are outside the US, pricing is probably different. Anyways once you get them, you need to insert the card in your PC or mac or whatever and install this software: http://bit.ly/2XIwCnM (there is instructions). Now you connect it and everything, time to setup the automation. you could just take the card out again to write automations, but i reccomend installing the “Configurator” addon. It lets you edit the files remotely from your pc or phone. The most reliable way to access it is type this in the browser: (ip address):8123. Go to configurator and you need to see home-assistant.io/components/doorbird/ and copy that code and paste it in the configuration.yaml file. Change the username and passowrd and token there. Save. Now go to automations.yaml and type something like:
`hide_entity: True
trigger:
- platform: event
event_type: doorbird_hoveddr_button
action:
#Play sound in Google Home Mini
- service: media_player.play_media
data:
entity_id: media_player.google_home
media_content_id: http://(ip-address-of-DoorBird)/bha-api/notify.mp3
media_content_type: audio/mp3`
Your going to want to change the entity id if you can’t figure it out, I or someone else can help. I have to leave now I’ll be back later, bye. You can also change the sound to play to whatever you want whether that would be youtube music or Google Text to speech. You can also upload files and have it play them. Can someone follow up and try to explain to this person better please? thanks i suck at this. One thing is i don’t know if there is a way to control google home mini volume in home assistant.
- alias: Doorbell
hide_entity: True
trigger:
- platform: event
event_type: doorbird_hoveddr_button
action:
#Play 'Ding' sound on Google Home speaker in living room
- service: media_player.play_media
data:
entity_id: media_player.salle_a_manger
media_content_id: http://[ip-doorbird]/bha-api/notify.mp3
media_content_type: audio/mp3
#Show image on Google Home Hub
- service: media_player.play_media
data_template:
entity_id: media_player.salle_a_manger
media_content_id: "http://[ip-nas]:8123/api/camera_proxy_stream/camera.hoveddr_live?token={{ states.camera.hoveddr_live.attributes.access_token }}"
media_content_type: image/jpg
- delay: '00:00:30'
#Turn off image after 30 secs
- service: media_player.turn_off
data:
entity_id: media_player.salle_a_manger
Configurations.yaml
# Configure a default setup of Home Assistant (frontend, api, etc)
default_config:
# Uncomment this if you are using SSL/TLS, running in Docker container, etc.
# http:
# base_url: example.duckdns.org:8123
# Text to speech
tts:
- platform: google_translate
group: !include groups.yaml
automation: !include automations.yaml
script: !include scripts.yaml
doorbird:
devices:
- host:ip_doorbird
username:username
password:pass
token:token
camera:
- platform: doorbird
Issue :
Configuration invalideVÉRIFIER LA CONFIGURATION
Error loading /config/configuration.yaml: mapping values are not allowed here in “/config/automations.yaml”, line 2, column 16
’
entity_id: media_player.nest_hub
media_content_id: http://IPHERE:8123/api/camera_proxy/camera.inkom_live?token={{ states.camera.inkom_live.attributes.access_token }}
media_content_type: image/jpg
’
It doesn’t work. When I then go to templates and enter the full url, it adds the token correctly. Anyone has an idea?
Unfortunately it doesn’t work.If I use your line and edit out the states section and replace it with the token. Then it streams immediately. I’m really stuck on figuring out why this does not work.
When I enter the line in the template section (to test it), it completes the string with the correct token. So I’m not sure why this doesn’t work when using it. It looks like HA doesn’t send it correctly to the device when I use the states parameter.
works just fine: media_content_id: "http://myip:8123/api/camera_proxy_stream/camera.inkom_live?token=tokenhere"
doesn’t work: media_content_id: "http://myip:8123/api/camera_proxy_stream/camera.inkom_live?token={{ states.camera.inkom_live.attributes.access_token }}"
This is driving me up the wall. Also doesn’t matter which camera I use, all have the same problem.
I really hope someone can point me in the right direction.
Ok might have found out why, now I need to find out why this happens:
Login attempt or request with invalid authentication from 192.168.1.130
11:32 components/http/ban.py (WARNING) - bericht kwam voor het eerst om 7 december 2019 15:36 en verschijnt 23 malen
This is my google nest hub that is being blocked when using the states.
//works now. The in build editor for the automations doesn’t have the option to define the data_template parameter instead of “data”. Thanks guys at discord!
Running into an odd issue… added the appropriate information to configurations.yaml to add my Doorbird device (as per https://www.home-assistant.io/integrations/doorbird/); however, enabling the camera results in 401 Unauthorized error in the DESCRIBE method of libav.rtsp
Any ideas? If it helps, on the overview display, there are still previews from the camera, but clicking in to the live preview results in a never ending loading state.
Edit: Restarting the Doorbird device rectified the issue.
I have the event called out in my HA config.yaml file. Likewise, I have added the schedule for this event in the doorbird app but the automation does not trigger upon pressing the ring button on the doorbird. Is there somewhere in the app that I need to identify/associate the somebody_pressed_the_button event with the relay?
I am trying to determine if “somebody_pressed_the_button” is a known event trigger within the doorbird system or if I need to do something from a setup standpoint within the doorbird app. I have activated the HTTPS calls for all these event triggers in the “schedule for doorbell” within the app.
Anything else I am missing or should any use of the doorbell button now auto trigger all 4 of those events?