I know there are several approaches to verbally asking Google Home what the status of a device is, but what is the most elegant solution. I have a mower that reports as docked or undocked and sometimes I need to verify where it is without walking the property and checking cameras.
“Elegant“ will be subject to the individual. I trigger a virtual switch by asking “[device name] status”. The virtual switch is the trigger for RM rules. If X switch is on, then the voice assistant responds back with response A. If Y switch is on, then the voice assistant responds back with response B. Etc.
Second that. How do you define elegant?
I define elegant per Occam's razor, "Entities should not be multiplied without necessity."
Is “[device name] status” a Google Home command that will work for devices added within Google Home, because that does not work for me.
What are the details of this mower device you’re trying to check the status of? Is it directly paired to hubitat? I’m guessing not (never heard of a zigbee or z-wave lawn mower, LOL), but for any device that’s directly paired to hubitat, it’s relatively easy to check the status of various device attributes and have that reported as a text-to-speech phrase sent to a voice assistant.
Sorry for not adding all the details I used a Smartthings Multi Sensor (see my thread below). Yes it is in Hubitat and Google Home. What I am wanting to do is Ask Google "What is the Mower Status" and it respond with "Docked" or "Undocked".
This is a custom phrase. [device name] implies, the name of your device. For example I will say Alexa, washer status, or dryer status. I don’t have it set up on mine but I could also say hey Google. And then trigger a virtual switch which then triggers the rule. Based on the device status, I will have it send me the appropriate response back. The actual device status is determined by which switch is turned on, or not turned on. So in the case of my dryer status, if it’s running there will be a switch turned ON named “dryer running”, and the response will be “the dryer is running”. If it’s not running, then the response will be “the dryer is not running“.
But this is just an example for a single device. My actual rules are, when I ask “laundry status“. The response back will depend on which machine is running. If both are running the response is “both the dryer and washer are running“, however if neither is running, then the response is “Neither the dryer or washer are running”.
It’s triggered by routines, doesn’t matter whether that’s Alexa or Google Assistant.
Here's a rule example. A couple of notes. The trigger switch, in this example "laundry status", is set in the device details to turn off after 1 second, so it is momentary.
Since I use the official Alexa TTS method, my rule triggers virtual motion sensors using custom code. Alexa reacts to this virtual motion sensor being triggered, and speaks the phrase specified in that Alexa routine. However, with Google Assistant, you would instead use something like the Chromecast integration or Castweb API to speak the message by specifying it right in the rule.
If you're integrating the mower via IFTTT or something like that the easiest thing to do would be to link it being docked or undocked to a virtual switch. Then ask whether the switch is on or off. You can ask google home the status of any switches you have linked to it.
Then you can link that to a virutal switch. when it is closed, it is off and when it's open it's on. Then you can ask the status of the switch directly from Google home. Not the most elegant but the most guaranteed to always work from any google home device. That way, only the google home device you ask will respond also, not all 12, which any Routines or tricky solution would do.
Really?! WTF Google?
Yeah, they're killing it in smart home
Actually, Google Home currently supports contact and motion sensors. But the HE integration is what doesn't currently. So, in this case it's not GH but HE that is the cause of it not working.
And the announcing on all 12 is what happens if you use a workaround with a routine and the broadcast of TTS feature. Unless you use a different phrase depending on what room you are in, it won't know.
Ah OK. So if you use the "Say Something" method in a Google Assistant Routine, it doesn't do that. I see the dilemma. I also didn't realize that contact and motion sensors were supported because in the Google Routines, there's no choice to select them like there is in the Alexa Routines.
If you use the "say something" it would work, but it won't know the status of the device you're asking about. The specific work around I was talking about is where you ask google home a question like, Is John home. That in turns triggers a gh routine which turns on a virtual switch which triggers a rule in HE which broadcasts back to your GH. Unless you set it up to trigger on a different phrase for each speaker and set up a different virtual switch for each speaker, once the info leaves the "googleplex" HE won't know which speaker to send the info back to so it would have to send it to all of them.
Right. Similar to what I was describing with Alexa. However, could you get a motion sensor to trigger a Google Assistant routine then by Asking Google > Trigger virtual switch in HE > HE triggers "virtual motion sensor as a switch" driver > Virtual motion sensor as a switch triggers another routine that speaks the result based on the active virtual switch in HE? Is that possible, albeit overly and needlessly complicated no thanks to Google?
It's a slog just to type. Just one of the reasons I'm not nuts about Google Assistant/Google Home. They just are not doing things relating to Smart Home control as well as Amazon at present.
What about the motion and contact sensors in Google Assistant routines? How do you use them as a trigger for routines when they are a supported type?
Motions sensors are not supported by the Google Home/Hubitat integration yet.
I understand that they are not. But what did you mean by this...
How? What platforms contact and motion sensors can be used in Google Home/Google Assistant to trigger a Google Assistant routine? And how, I don't see the option. I only see that a routine can be triggered by voice and by date/time.
In Smartthings they are currently.