Using Google Mini's & Home for Doorbell

Hello All,

Appreciate any help and feedback, I am new to all of this.

I recently purchased a Ubiquiti G4 Doorbell ( Australia ) and I don’t have a Chime as they are not common here.

I have 2 Google Mini’s and a Google Home Hub that I would like to use as the Doorbell Chime.

I am running Home Assistant on my Synology NAS via Docker.

I have installed HACS and have the UniFi Protect Integration installed.

I have been doing a lot of googling and found a reddit thread that i have attempted to copy to get this working.

Here is my Automation Config:

id: '1638451139326'
alias: DoorBell Test
description: Test Doorbell to Google Speakers
trigger:
  - platform: device
    device_id: 66a862d3ba8f51ee1e5e95b10195d875
    domain: select
    entity_id: select.infrared_g4_pro_front
    type: current_option_changed
condition: []
action:
  - service: media_player.volume_set
    target:
      entity_id: media_player.home_group
    data:
      volume_level: 0
  - service: media_player.turn_on
    target:
      entity_id: media_player.home_group
  - service: media_player.volume_set
    target:
      entity_id: media_player.home_group
    data:
      volume_level: 0.9
  - service: media_player.play_media
    target:
      entity_id: media_player.office_speaker
    data:
      media_content_id: http://192.168.XXX.XXX:8123/local/audio/doorbell.mp3
      media_content_type: music
  - delay:
      hours: 0
      minutes: 0
      seconds: 5
      milliseconds: 0
  - service: media_player.volume_set
    target:
      entity_id: media_player.home_group
    data:
      volume_level: 0.3
  - service: media_player.turn_off
    target:
      entity_id: media_player.home_group
mode: single

The group for all the media players is called “home_group” , The Doorbell isn’t powered yet so I’m using my camera to sit in place as a filler for the trigger. When i hit run actions, I can see the Audio set to 0 ( this is meant to stop the doink noise from the google, but it doesn’t ), I can see the volume change on the google mini to 90%, wait 5 secs and change back to 30% but the Audio doesn’t play.

When I browse to http://192.168.XXX.XXX:8123/local/audio/doorbell.mp3 on my PC it works, and the audio plays. I have tested changing the IP from 192.168 to home.assistant/local:8123 etc and still isn’t working.

For testing, I’ve adjusted it to only cast the audio to “office_speaker” instead of “home_group”

The audio file is an Mp3 and is saved on /volume1/docker/home-assistant/config/www/audio/doorbell.mp3

I’ve looked at multiple different posts and I believe i have it correct, any guidance would be appreciated it.

Pretty sure the file needs to be publicly accessible

It can be a local URL if it does not rely on DNS, e.g. you use the IP address.

However… it requires an https URL.

Screenshot 2021-12-03 at 15-35-45 Google Cast

Thank you, I will follow this and give it a go.

Does anybody have any guides they can suggest I can follow so i can made this link https and resolve this issue.

Thanks again,

In my case, I used TTS instead of door chime. Just because it sound better and you can make a random messages.

1 Like