hmm, I did get it to broadcast once when I first was setting up. However, I have not retested that part, using it mostly for sending commands. I will try it out later tonight if I remember and let you know.
Community Hass.io Add-on: Google Assistant Webserver (broadcast messages without interrupting music)
Thanks !!!
Sorry to bug you, just checking to see if you had a chance to confirm broadcasting works.
Checked last night and wasnât sure if DND time might be an issue. Tried again just now and broadcast did not work. Looking at myactivity I do see the call come in but it says it doesnât know what to do or something like that.
ouch. Thanks for letting me know. will start looking for a new solutionâŚ
As a workaround for broadcasting no longer working I installed Android-x86 in a Hyper-V VM, installed Google Assistant, Tasker, AutoInput, and Tasker Network Event Server.
I followed the guide here to get Tasker/AutoInput set up to send Assistant commands, then just tweaked things a bit so that I could send an HTTP GET to the IP of the VM with the command.
I then added the URL as a rest_command in Home Assistant and use a template in the URL to pass the variables I set everything up with.
So far itâs been working, but this is a huge hack because basically Home Assistant sends the web request, Tasker Network Event Server picks it up and triggers the Tasker task, then AutoInput literally simulates touches in the app to open the manual text entry, type in the command, hit send. The one advantage is that I can send literally any command that can be sent on Google Assistant on a phone, including playing music. I expect itâs not going to be very reliable thoughâŚ
This should work with really any Android device (that supports all apps required) so anyone who doesnât want to mess with the VM could use an old phone or buy one and just keep it plugged in at home and accomplish the same thing.
i assume you would be able to set up multiple apps like this in the same VM? i.e. for other âsmartâ things that can only be controlled by an app
Yes for sure, the Tasker web server can filter based on the parameters sent, so it can trigger different tasks based on whatâs being sent.
For those who meet the requirements of the Google Assistant Library (i.e. arch linux-armv7l or linux-x86_64, audio capture and playback), feel free to try this workaround:
Disclaimer: this is not an Hassio add-on and I donât intend to create one as I donât use Hassio myself.
The following Python script is provided âas isâ. With some linux knowledge this script can be run as a system daemon.
-
You will need first to follow this guide âEmbed the Google Assistantâ:
https://developers.google.com/assistant/sdk/guides/library/python/ -
Once youâve successfully installed the SDK and run the sample code, install Flask in the same virtual environment:
pip3 install --upgrade flask flask-restful
-
You may now run this Python script hotword_webserver.py
I slightly modified the provided sample code to include the web server code from @AndBobsYourUncle add-on. The web server URLs remain the same, so from Home Assistant perspective it can be a drop-in replacement.
N.B: In the Google Assistant settings on your phone, you should now see the new device registered in the previous steps. Make sure to provide an address for this device otherwise broadcasting wonât work. Optionally you can also setup the default media output for remote casting.
Enjoy!
According to ânamdohâ (Supposedly a Google Assistant employee) in this thread, a fix is coming soon. Looks like next Friday is the ETA. Fingers crossed.
Did we get a fix for this yet?
I believe the ETA was for next Friday based on the posts in my link.
Hmm cant wait to get this feature back soon. Google tts is horrible comapared to the natural speaking
The broadcast stopped working, how to troubleshoot?
Read the previous posts. It is broken until Google fixes it.
Hope they fix it, was one of the coolest feature of HASS.
Shall we revert back to TTS?
Which Friday?
I also get this message, any solution?