Page 3 of 3

Re: Android voice control "Ok Google" like "Google Home" for free!

Posted: Monday 21 August 2017 23:38
by Wob76
Hi Han,

Thanks for the reply, I have managed to get Google Assistant to Domotizs to work, using similar steps to you. But I thought you were able to get a response to a request for temperature.

At the moment the part really missing is "Ok Google, What is the temperature in the room?" I have read this may be possible with Google Translate and using the Chromecast function of the Home, but it will require some middleware to work.

Wob

Sent from my SM-G935F using Tapatalk


Re: Android voice control "Ok Google" like "Google Home" for free!

Posted: Tuesday 22 August 2017 8:36
by DutchHans
Hi Wob,

Here is what I did.
I created a dummy switch, for example SpeakLivingroomTemp.
To get notifications on my Android device I installed AutoRemote.
Than I created a very little script like this:

Code: Select all

commandArray = {}
 
LivingroomTemp = otherdevices_svalues['Temperature Livingroom']:match("([^;]+)")
LivingroomTemp = tonumber(LivingroomTemp)

LivingroomTempText = "The temperature in the livingroom is " .. LivingroomTemp .." degrees Celcius."
LivingroomTempURLtext = string.gsub( LivingroomTempText, " ", "%%20")

if devicechanged[' SpeakLivingroomTemp'] == 'On' then
   
  commandArray['OpenURL']='https://autoremotejoaomgcd.appspot.com/sendnotification?key=XXXXXXXXXXXXXXXXXXXX&title=Message%20of%20the%20house&text='..LivingroomTempURLtext..'&url=xxxxxxxxxxx.myfritz.net:8080'
  commandArray[' SpeakLivingroomTemp']='Off'

end 

return commandArray
In IFTTT I've made an applet as described in my previous post.
So now I can switch the dummy(SpeakLivingroomTemp) to On with my voice which results in a notification on my phone.
Than to let it speak the notification I installed Voice Notify on my phone. A free Android app that is highly configurable and speaks the notifications out loud the moment they arrive. I only let it speak the message, not the title...

Result:
OK Google
[bleep]
What is the livingroom temperature?
Hold on, I will check
The temperature in the livingroom is 21 degrees Celcius.


That is all.
Cheers, Hans

Re: Android voice control "Ok Google" like "Google Home" for free!

Posted: Tuesday 22 August 2017 8:45
by Wob76
Thanks for the info Han,

I might look at a combination of what you have done for phones and look into using Google Translate\Chromecast to make the Google Home speak.

It would be nice if IFTTT could read web responses back, it has "This" support for webhooks, but no "That" support for google assistant.

Hopefully Domoticz might get more inbuilt Google Assistant support in the future.

Wob

Re: Android voice control "Ok Google" like "Google Home" for free!

Posted: Tuesday 22 August 2017 8:52
by DutchHans
I'd rather have the notifications on my phone.. I have them everywhere, garden, upstairs, even when I am not at home.

Re: Android voice control "Ok Google" like "Google Home" for free!

Posted: Thursday 25 April 2019 18:31
by Kruu
Cant get it to work, the link is OK, work in a browser. But when activate "OK Google" it say that there are no devices added to google home.

Re: Android voice control "Ok Google" like "Google Home" for free!

Posted: Monday 03 June 2019 19:59
by megamarco83
mlamie wrote: Tuesday 20 December 2016 14:04

It is really simple and works great! I will impress my family during the christmas holiday :lol:
hi, i'm using automate app as sugested in first post, and all woks very good.
now i would like to implement a new command:
"set blind one at 6%"
how i can use automate app to recognize the "double command"? (i mean percentage associate to a blind)

for eample:
i say OK Goole
then the command: set blind one at 6%
automate should reconize the command and send this json:
192.168.0.105:8080/json.htm?type=command&param=switchlight&idx=70&switchcmd=Set%20Level&level=6

(id=70 is my adress of blind one)

how i can use block inside automate app to recognize that?
thanks