Heos (Denon) support

Thanks Kristof!

For now some simple rules like playing music once I enter my home is fine which was working already on older versions. However I am always looking for new and improved stuff so looking forward to M4 :slight_smile:

NoTechi

Well I am on the openhab snapshot release now where the heos binding can be installed via paper ui and I am trying to use my heos as audio sink.
I got the bridge and my group of two players configered as thing and they show online. When I use them as audio sink with MaryTTS or now Google TTS there is nothing played. Looking within the heos app I get a error message “Kann das Medium nicht wiedergeben. Bitte versuchen sie es später noch einmal” which basically means “Can’t play the url stream”. And the Heos player app shows a URL Stream with leangth of 0:00.
Logfile shows a warning “[WARN ] [.googletts.internal.GoogleTTSService] - Audio format OGG_OPUS is not yet supported.” but that seams to be normal since others reported this as well already but it’s working anyhow for them.
Any ideas what I could try?

Another question is in regards to the Heos help documentation. It says the “Within the binding the callback URL can be set”. Where can i find this setting?

NoTechi

Update: No clue what I have changed I just worked my way through some not heos related errors in the log files and now … it’s working … sounds like magic but I don’t question it :slight_smile:

Hi,
installed 2.5.0 snapshot but do not get active in OH:
openhab.log:

Error while starting bundle: file:/usr/share/openhab2/addons/org.openhab.binding.heos-2.5.0-SNAPSHOT.jar

Karaf Console shows in bundle list:

237 │ Installed │ 80 │ 2.5.0.201910280952 │ openHAB Add-ons :: Bundles :: Heos Binding

Bundle:start 237

Error executing command: Error executing command on bundles:
Error starting bundle 237: Could not resolve module: org.openhab.binding.heos [237]
Unresolved requirement: Import-Package: com.google.gson; version=“[2.8.0,3.0.0)”

My environment: openHAB 2.4.0 (Release Build) on Raspberry PI3 with Raspbian Jessie.

Any ideas?

Regards,
Andy

On 2.4 the GSON lib is not included by default. You need to add the gson as a seperate jar (drop it in the addons folder as well).

http://central.maven.org/maven2/com/google/code/gson/gson/2.8.5/gson-2.8.5.jar

Maybe you need to restart openhab for everything to work. After you upgrade to 2.5, you can remove this jar from the addons folder.

Thank you @rkrisi for fast reply.
I installed the gson jar but when trying to activate the HEOS binding in Karaf Console another package was required:

Could not resolve module: org.openhab.binding.heos [185]
Unresolved requirement: Import-Package: org.apache.commons.net.telnet; version="[3.6.0,4.0.0)

Possibly due to EHS reintegration into OH2 core now there are more dependencies.
How could I find out which add-on dependencies needs to be installed - and from where to download?

A similar discussion I found here.

Regards,
Andy

Maybe this helps:

What brings a:

 feature:list|grep openhab.tp-commons-net

and this here:

.
And do this:

feature:list|grep openhab-runtime-base
feature:list|grep openhab-transport-upnp

It should bring you this (from all the 3 different queries):

openhab.tp-commons-net                            | 2.5.0.SNAPSHOT   | x        | Started     | distro-2.5.0-SNAPSHOT                | The Apache Commons Net

openhab-runtime-base                              | 2.5.0.SNAPSHOT   | x        | Started     | distro-2.5.0-SNAPSHOT                | openHAB Runtime Base

openhab-transport-upnp                            | 2.5.0.SNAPSHOT   |          | Started     | distro-2.5.0-SNAPSHOT                | UPnP Transport

@Celaeno1 Thanks for your help.
As I’m on openHAB 2.4.0 (Release Build) the results look different:

openhab.tp-commons-net      (no result)
openhab-runtime-base         x 2.4.0            x x        x Started     x distro-2.4.0            x openHAB Runtime Base
openhab-transport-upnp       x 2.4.0            x          x Started     x distro-2.4.0            x UPnP Transport

Does that mean I can not install HEOS 2.5.0 snapshot before I update OH to 2.5.0 snapshot?

Regards,
Andy

I would suggest you to update to 2.5M4. Lots of changes since 2.4 (mostly good ones, bug fixes and others) and you can install it easily. Are there anything which holding you back from not updating?

No, not necessarily.

What brings a:

feature:list|grep ommons

If the result is something is this:

(no result)

Then you need the “Apache Commons Net 3.6”, you can download it here.

You need the commons-net-3.6.jar.

Apache library was installed with OH 2.4, obviously based on ESH:

esh.tp-commons-net     x 0.10.0.oh240     x          x Started     x distro-2.4.0        x The Apache Commons Net library

But it seems that new HEOS snapshot can not deal with it.

@rkrisi Update to 2.5M4 is an option for me, but 5 days error handling after my last release change to OH 2.4 kept me from updating to 2.5 so far.

It seems to be an older version.

You can try uninstalling esh.tp-commons-net and installing “Apache Commons Net 3.6”, but maybe other bindings (or even OH2) will not run!! Make a backup before you try this!!

Sooner or later I would have to change to OH 2.5, therefore I’ll give it a try now as playing around with the current installation I think will be also time-consuming. If I face numerous issues I could switch back to my weekly backup (thanks to this tool).

@Celaeno1 Thanks for support.

Regards,
Andy

1 Like

Hi there,

sorry for the long time without response. But today I pushed a change to openHAB that should fix the issue with the library. You can find the request here:

Cheers,
Wire82

1 Like

Hi!
I’m having trouble getting my favorites to work.
I’m using OpenHAB 2.5 with the HEOS Binding in version 2.5.
I added the Bridge, logged into my HEOS account and added my AVR (X3500H) as a player.
Controls like play, pause, volume and mute are working just fine. I can also switch inputs.
But when I try to play a favorite radio station, nothing happens.

In PaperUI, the radio station is listed as a channel:

heos:player:-1644029134:s96189

I configured a switch

Switch TestHEOSFav "Play Favorite" {channel="heos:player:-1644029134:s96189"}

and on the sitemap:

Switch item=TestHEOSFav

When I hit the switch, nothing happens. Logs:

Item 'TestHEOSFav' received command ON
2019-12-19 11:52:12.867 [nt.ItemStatePredictedEvent] - TestHEOSFav predicted to become ON
2019-12-19 11:52:12.878 [vent.ItemStateChangedEvent] - TestHEOSFav changed from OFF to ON

I’m out of ideas what else to try…
Any help would be greatly appreciated!

1 Like

having the same issue as the previous poster plus creating linked items in paper ui also doesn’t work (won’t show up as linked), someone before already had that issue

@jakaZ @tknaller

Yes I can confirm that. It seems that there is a issue with detecting the favorite channel within the binding. I think I found a solution for this and will provide an updated version of the binding as soon as possible.
Unfortunately this will not directly included within OpenHAB so I have to provide the jar file and you have to manually install it within OpenHAB.
Hope that works for you.

The updated file can be downloaded here:

Please test this release an give me a feedback if everything works as expected.

Wire82

@Wire82
Hi! I just installed the updated jar and according to my quick test it seems to be working perfectly.
Thanks a lot for your work! :smile:

Are you going to create a PR for this fix in the openhab-addons repo?

Yes. I already prepared it but had no time to test the changes more than a few minutes.
But as soon as I’m sure that all things are working I will issue a PR.