Official Google Assistant Integration for openHAB

I have a Pull Request and am currently running with a fork that works perfectly (for me…it should be tested).

I am not an expert coder so needs to be confirmed before going into production, but so far been using it for 2-3 weeks with no issues.

4 Likes

@MARZIMA: any way to add an audio (music, radio, …) feature so that we could control Sonos or Squeezebox (for example) through their openHAB bindings ? I could understand that it could require new code in these bindings.

Not sure if it’s possible with the current implementation of Home Graph, see here:

Ok I see, what offers Google is still very limited.

I was able to “coerce” my audio amp logic to work with the current traits/tags available (I put [ “Lighting” ] tags on my volume sliders for example, and while Google Home tells me it’s setting my audio amp’s “brightness” to 25%, it’s actually controlling the volume).

The Modes trait is what I hope gets implemented soon. As that will directly map to our Selection sitemap entries, and allow me to control multi-modal devices like my Led strip effects or audio amp sources.

1 Like

Thanks @MARZIMA for all of the hard work on this!

Quick question…I have a thing (dimmable light switch) with two channels - dimmer and switch. Right now I have the item for the dimmer set with the “Lighting” tag and everything is working great through my Google Home devices. I can control the brightness and turn it on/off.

However, if I ask Google how many lights are on, it tells me that it cannot reach this device.

Is there any way to assign both the Switchable and Lighting tag to one item? Or is there another way to fix this?

2 Likes

@Ian_Bishop I had the same error as yourself. I managed to get mine working by:

  1. Removing all .items file tags
  2. Added a test item in PaperUI
  3. Tagged that test item via the console:
 smarthome:items addTag MickTest Lighting
  1. Restart OpenHAB service
  2. After making sure I had removed any previous allowed applications from openHAB Cloud - Went through the google assistant linking process again.
  3. MickTest item showed up in Google Assistant :slight_smile:
  4. Re-added tags in .items files
  5. Told google assistant to: sync my devices

They’re all there!

I hope this helps. Thanks @MARZIMA for all of your hard work even through very hard times.

1 Like

Hey i did the same but still no luck …

I delete all google app in myopenhab but leave ifttt there is this ok ?

Check if your .items file is valid in the log of OpenHAB (on port 9001).

Mine had an error. After fixing that error everything worked when pairing
with assistant.

Is this service currently only working in English or also with other Languages?

Works with other languages.

I had a linking problem at first, but I was able to link after making sure my tags were only for “switchable” or “lighting”. This action should be a good boost to Google Home. Thanks @Marzima for a great job!

english only, for now.

Do the items have to be exposed to myopenhab.org? None of mine are and I’ve had no luck following all the steps here.

Wrong, I confirm like @Lolodomo that it is working in French for instance :slight_smile:

2 Likes

The process is linking your Google account to your Myopenhab.org account, so you need to expose all your items you want to control via Google Assistant on myopenhab Cloud. Once this is done, follw the steps and it should work.

i was going off what the author posted. Good to hear it works with other languages.

1 Like

Other Languages are supported too.
It is depending on Google Assistant language support/country rollout.
So I think German, English, French etc. been in the rollout wave of GA 3-4 months ago.

BR Mehmet

I did not have to expose my Items to myopenhab.org. I just had to add the tags to my Items and they showed up. I don’t even have an openhabcloud.cfg nor do I have any Items listed in the PaperUI config.

I will note that I did have to add the tags first before connecting the accounts. I think Google will drop the connection if it doesn’t find anything it can control. I linked it several times but it wasn’t until I added the tags that openHAB showed up as a linked service and my devices appeared in the list of devices to control.

1 Like

thanks, this is working great although it is very slow compared to a local switch. Getting 2 second + delays from when command is finished spoken to when it actuates. Is there a way to do speech control on a local server with openhab?