[Release] Google Assistant Relay V2.0 - Google Home Audio Notifications!

tts
requires_server
googleassistant
googlehome

#144

Thanks! At least I know three now. :slight_smile:
I will report if I figure out some more this weekend.

“wake up”
“dinner time”
“arrived home”


(Eric) #145

My AR has gone down and will not restart. The error I get when trying to start it is ELIFECYCLE. Nothing changed on my config it just stopped working.


#146

This error message indicates that something (probably another instance of AR) is already running.


(Eric) #147

THANK YOU!!! Yes it is up and running. Google has unceremoniously removed all my mini’s from my account. I tried to share my home in the new google home app with my wife and I think that was the cause. Now smartthings is completely disconnected from my google account in an effort to fix that. I am trying to reconnect smartthings with very little luck. Smartthings might not have been the best name for this! :rofl:


#148

FYI, these presets are not from Google Assistant Relay, they’re built into the broadcast facility.

The full list can be found here:

https://support.google.com/googlehome/answer/7531913?co=GENIE.Platform%3DAndroid&hl=en


(Greg) #149

I’ve built the preset broadcasts into AR.

The readme lists them all.


(Garrett) #150

I have this up and running but can’t figure out a way to make dynamic messages so I don’t have to make rules for every device. Does anyone have a piston they could share that would do something like this when my contact sensors open?

“[Device name] has opened”


(Greg) #151

I don’t have an example and I didn’t even know you could do it, but someone made a piston that takes some parameters and makes the AR call .

Might be what you’re looking for?


(Eric) #152

I use this for my doors in the evening.


Edited because I learned a new way. Thanks milkman671!


#153

Here is the webCoRE piston that I am using for door opened/closed announcements. The command variable is set dynamically using variables from the event.


(Mohammad Subhan) #154

Any help?
I started over again but back to the same results.


#156

I figured out something about “Preset” functionality after doing some more tests.

  1. Whatever I do, {“preset”:preset commands in readme"} doesn’t work.
  2. Instead, {“command”:“broadcast preset command with space”} works.

For example,

{“command”:“broadcast wake up”} successfully triggers the preset “wakeup” message.

In the same manner, all these work.

{“command”:“broadcast dinner time”}
{“command”:“broadcast time to leave”}
{“command”:“broadcast on my way”}

Also, I found my-side mistake of putting quatation marks inside the command string. I guess I am still new to webCoRE…

Anyways, now everything works as expected.

Hope this helps.


(Greg) #157

The “broadcast (preset)” is default Assistant functionality.

I’ll have a look this week, but the AR shortcuts for relay should work


#158

The problem is likely that you are returning if there’s no command in routes.post in routes.js:

 if(!command) return res.status(400).json({success: false, error: "No command given"})

The example you give in the documentation:

preset: <command>
user: <user in config>

has no command, so of course it’s going to short-circuit and return rather than hitting your switch statement.


(Greg) #159

Ahhhhh crap! Well spotted!

I’ll try and push a fix tomorrow for that. Easy enough just to add an OR in

 if(!command || !preset) return res.status(400).json({success: false, error: "No command given"})

I must have had a command parameter in by mistake when testing.


(Greg) #160

So apparently I didn’t fix the bug!

I’ve pushed a new update out that can be found in the releases section. v2.1.1
It has a new configuration file, so make sure you read the instructions on how to configure this

There are some new features too thanks to joeqread

New in V2.1.1

  • Quiet Hours - thanks joeqread
  • Mute Startup - thanks joeqread
  • Bug fix for presets

#161

First time user here and I have just installed v2.1.1. I received the successful acknowledgement announcement after install - “Assistant Relay is now setup and running”.

I can’t seem to formulate the correct POST commands. No voice comes from the household Mini’s.

I remember that v1.0 had some example POSTMAN commands in a collection. Would it be possible to produce another collection of POSTMAN commands to assist with fault-finding? (ie. the v2.0 endpoint structure).


(Greg) #162

I’ve updated the Postman collection, although not tested yet!

https://www.getpostman.com/collections/42fe420662d38f74a45e

They should look like the below

image


#163

Thanks Greg. The Postman collection was very helpful. I tested all the examples and they work fine.

I’ve now got it running well in my home automation system (I’m not using SmartThings…:smiling_imp:…but instead using a system called Loxone). The Assistant Relay is hosted on a headless Raspbian lite system called Loxberry.

Thanks for making the Assistant Relay as ‘open’ as it is. The biggest challenge from my perspective was just working out how to make the Loxone system build the POST commands correctly.


(Greg) #164

Great news.

That’s why I wanted to keep AR as open as possible, without locking it to SmartThings.