No, what you found is an old thing. I will remove that.
Inputs are supported by the binding since the last release. A short description can be found on GitHub
I do it like that:
Just create an item which is connected to the “Inputs” channel of the player :
If you now activate the button which shows “Aux In” ,it sends “aux_in_1” to the player channel which lets the player switch to the aux 1 input. Regarding on the player you have several inputs are available. I added a list to the binding description in GitHub
Do you mean having a channel at each player for the favorites and then activating them by numbers?
The same approach like for the inputs is not so easy i think. Because favorites can be played on each player and are provided centralized by the bridge. So you have to select the player where you want to play the favorite station and you have to know the id of the favorite.
But maybe something similar like for the playlists might be possible…
Nevertheless I did an selection for the favorites by a rule and an extra item…
rule"Favorites AZ"
when
Item HeosAZ_Favorites received command
then
var Number num = receivedCommand as DecimalType
if (num == 1) {
sendCommand(HeosBridge_Play_AZ, ON)
sendCommand(HeosBridge_Fav1, ON)
sendCommand(HeosBridge_Fav1, OFF)
sendCommand(HeosBridge_Play_AZ, OFF)
} else if (num == 2) {
sendCommand(HeosBridge_Play_AZ, ON)
sendCommand(HeosBridge_Fav2, ON)
sendCommand(HeosBridge_Fav2, OFF)
sendCommand(HeosBridge_Play_AZ, OFF)
} else if (num == 3) {
sendCommand(HeosBridge_Play_AZ, ON)
sendCommand(HeosBridge_Fav3, ON)
sendCommand(HeosBridge_Fav3, OFF)
sendCommand(HeosBridge_Play_AZ, OFF)
}
end
The binding is pretty stable now,however I have an issue that the players are not present on the Bridge. It seems to happen after a restart. Is there a way to trigger the repopulation of the players on the bridge. I don’t want to delete the players and re-add them.
About the favourites, what I did was to have a channel on each player. Like the inputs, then I did a string compare on the text that was sent to that channel towards all of the favourites. If I found a match I used that. You could also compare it against the ID. Since you currently can get the ID from the channels on the bridge.
good to hear that the binding is running stable.
Do you have some groups active which are not existing during restart? As I noticed there is a bug in the release where the binding is trying to find the group and doesn’t stop… This is already fixed for the next release.
So maybe you can have a look into the log if the binding is trying to find something which isn’t where?
Regarding the favorites I think this could be an idea. But then you have to know the exact name of the favorite. This could be a problem… Or you can just use numbers…
Same problem here. I get no player channels at the bridge. And I see nothing in the Strings title, interpret und album.
But controlling my Heos 1 with the Player item, mute Switch and volume Dimmer works fine.
Some error messages can be found in the openhab.log:
2017-02-23 21:58:49.988 [INFO ] [l.discovery.HeosDiscoveryParticipant] - Found HEOS device with UID: heos:bridge:5ff6bb67-9b60-b82a-0d7b-2413d1e5770a
2017-02-23 21:58:49.992 [INFO ] [l.discovery.HeosDiscoveryParticipant] - Found HEOS device with UID: heos:bridge:5ff6bb67-9b60-b82a-0d7b-2413d1e5770a
2017-02-23 21:58:50.090 [INFO ] [nx.internal.connection.KNXConnection] - Established connection to KNX bus on 192.168.0.4:3671 in mode TUNNEL.
2017-02-23 21:58:50.091 [INFO ] [l.discovery.HeosDiscoveryParticipant] - Found HEOS device with UID: heos:bridge:5ff6bb67-9b60-b82a-0d7b-2413d1e5770a
2017-02-23 21:58:50.134 [INFO ] [l.discovery.HeosDiscoveryParticipant] - Found HEOS device with UID: heos:bridge:5ff6bb67-9b60-b82a-0d7b-2413d1e5770a
2017-02-23 21:58:50.637 [INFO ] [ing.heos.internal.HeosHandlerFactory] - Register discovery service for HEOS player and HEOS groups by bridge '5ff6bb67-9b60-b82a-0d7b-2413d1e5770a'
2017-02-23 21:58:50.974 [INFO ] [nding.heos.handler.HeosBridgeHandler] - Initit Brige 'HEOS 1' with IP '192.168.0.55'
2017-02-23 21:58:50.994 [ERROR] [org.openhab.binding.heos ] - FrameworkEvent ERROR - org.openhab.binding.heos
org.osgi.framework.BundleException: Could not resolve module: org.openhab.binding.heos [185]
Another singleton bundle selected: osgi.identity; osgi.identity="org.openhab.binding.heos"; type="osgi.bundle"; version:Version="0.1.2.-SNAPSHOT"; singleton:="true"
at org.eclipse.osgi.container.Module.start(Module.java:434)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1582)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1562)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.doContainerStartLevel(ModuleContainer.java:1533)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1476)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
2017-02-23 21:58:51.085 [ERROR] [org.openhab.binding.heos ] - FrameworkEvent ERROR - org.openhab.binding.heos
org.osgi.framework.BundleException: Could not resolve module: org.openhab.binding.heos [186]
Another singleton bundle selected: osgi.identity; osgi.identity="org.openhab.binding.heos"; type="osgi.bundle"; version:Version="0.1.2.-SNAPSHOT"; singleton:="true"
at org.eclipse.osgi.container.Module.start(Module.java:434)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1582)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1562)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.doContainerStartLevel(ModuleContainer.java:1533)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1476)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
and
2017-02-23 21:58:51.214 [INFO ] [.openhab.binding.heos.api.HeosSystem] - HEOS command line connected at IP 192.168.0.55 @ port 1255
2017-02-23 21:58:51.349 [INFO ] [.openhab.binding.heos.api.HeosSystem] - HEOS event line connected at IP 192.168.0.55 @ port 1255
2017-02-23 21:58:51.357 [INFO ] [.openhab.binding.heos.api.HeosSystem] - Heos heart Beat startet
2017-02-23 21:58:51.804 [INFO ] [.openhab.binding.heos.api.HeosSystem] - Found: 0 Player in Group
2017-02-23 21:58:51.807 [INFO ] [nding.heos.handler.HeosBridgeHandler] - Logging in to HEOS account.
2017-02-23 21:58:54.640 [ERROR] [ome.core.thing.internal.ThingManager] - Exception occured during bridge handler ('heos:bridge:5ff6bb67-9b60-b82a-0d7b-2413d1e5770a') notification about handler initialization of child 'heos:player:1002170733': UID segment 'HEOS Player' contains invalid characters. The last segment of the channel UID must match the pattern [A-Za-z0-9_-#]*.
java.lang.IllegalArgumentException: UID segment 'HEOS Player' contains invalid characters. The last segment of the channel UID must match the pattern [A-Za-z0-9_-#]*.
at org.eclipse.smarthome.core.thing.ChannelUID.validateSegment(ChannelUID.java:165)[105:org.eclipse.smarthome.core.thing:0.9.0.b3]
at org.eclipse.smarthome.core.thing.UID.<init>(UID.java:69)[105:org.eclipse.smarthome.core.thing:0.9.0.b3]
at org.eclipse.smarthome.core.thing.ChannelUID.<init>(ChannelUID.java:43)[105:org.eclipse.smarthome.core.thing:0.9.0.b3]
at org.openhab.binding.heos.handler.HeosBridgeHandler.addPlayerChannel(HeosBridgeHandler.java:318)[184:org.openhab.binding.heos:0.1.2.-SNAPSHOT]
at org.openhab.binding.heos.handler.HeosBridgeHandler.childHandlerInitialized(HeosBridgeHandler.java:180)[184:org.openhab.binding.heos:0.1.2.-SNAPSHOT]
at org.eclipse.smarthome.core.thing.internal.ThingManager$13.run(ThingManager.java:873)[105:org.eclipse.smarthome.core.thing:0.9.0.b3]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)[:1.8.0_121]
at java.util.concurrent.FutureTask.run(FutureTask.java:266)[:1.8.0_121]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)[:1.8.0_121]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)[:1.8.0_121]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)[:1.8.0_121]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)[:1.8.0_121]
at java.lang.Thread.run(Thread.java:745)[:1.8.0_121]
I found the issue. The player channels are removed if the binding adds the favorite channels to the bridge. There was a typo within the code which is corrected now. So the change is included within the next release. (At the moment I still waiting with uploading the new code to git hub. Sorry for that). But I will release the new version tomorrow or the day after.
@thorem
The error message I see is an other issue. It seems to me that openhab sees an old heos binding (v0.1. 2). Which version do you use?
Please ensure that you have removed the old binding from the addons folder when adding a new version. The best way to have a clear start is to remove the binding, shutting down openhab, restart it and then add the new binding. (or something equal to that).
I also had some trouble with an old binding version staying registered on openhab in the past.
If you want to be check if two bindings are installed, check it via the console (http://docs.openhab.org/administration/console.html) with command {bundle:list}.
Wire82
Can you please check if the second error disappears if you using the new version? If not can you copy an extract of the log if you searching for players and send it to me?
I also know this problem but I thought to remove the bug with some changes during generating the UID for the player. The error message says that your UID contains invalid characters. But normaly the UID is created from the player PID which contains, as far as I know, only numbers and this shouldn’t be a problem.
I started using the binding with version 0.1.2
When updating to 0.1.3 und 0.1.4 I stoped openhab-service removed the old jar from addons-folder an copied the new version. After that, I started openhab. Seems not to be the right way…
I released the next version of the binding V0.1.5. So feel free to test it and give feedback.
I also updated the description for the binding to give a little bit more explanation for some topics.
The version can be found here:
I added some release notes which can also be found by the release.
Meanwhile the bindings does not load anymore. In openhab.log you can see the message. The only change I remeber: in did a apt-get install dist-upgrade on my RasPi. Could there be a c update?
2017-03-05 12:37:05.175 [ERROR] [org.openhab.binding.heos ] - FrameworkEvent ERROR - org.openhab.binding.heos
org.osgi.framework.BundleException: Could not resolve module: org.openhab.binding.heos [190]
Bundle was not resolved because of a uses contraint violation.
org.osgi.service.resolver.ResolutionException: Uses constraint violation. Unable to resolve resource org.openhab.binding.heos [osgi.identity; osgi.identity="org.openhab.binding.heos"; type="osgi.bundle"; version:Version="0.1.5.-SNAPSHOT"; singleton:="true"] because it is exposed to package 'javax.annotation' from resources org.eclipse.osgi [osgi.identity; osgi.identity="org.eclipse.osgi"; type="osgi.bundle"; version:Version="3.10.101.v20150820-1432"; singleton:="true"] and javax.annotation-api [osgi.identity; osgi.identity="javax.annotation-api"; type="osgi.bundle"; version:Version="1.2.0"] via two dependency chains.
Chain 1:
org.openhab.binding.heos [osgi.identity; osgi.identity="org.openhab.binding.heos"; type="osgi.bundle"; version:Version="0.1.5.-SNAPSHOT"; singleton:="true"]
require: (osgi.wiring.bundle=org.eclipse.osgi)
|
provide: osgi.wiring.bundle: [org.eclipse.osgi, system.bundle]
org.eclipse.osgi [osgi.identity; osgi.identity="org.eclipse.osgi"; type="osgi.bundle"; version:Version="3.10.101.v20150820-1432"; singleton:="true"]
Chain 2:
org.openhab.binding.heos [osgi.identity; osgi.identity="org.openhab.binding.heos"; type="osgi.bundle"; version:Version="0.1.5.-SNAPSHOT"; singleton:="true"]
import: (osgi.wiring.package=com.google.common.collect)
|
export: osgi.wiring.package=com.google.common.collect; uses:=javax.annotation
com.google.guava [osgi.identity; osgi.identity="com.google.guava"; type="osgi.bundle"; version:Version="18.0.0"]
import: (osgi.wiring.package=javax.annotation)
|
export: osgi.wiring.package: javax.annotation
javax.annotation-api [osgi.identity; osgi.identity="javax.annotation-api"; type="osgi.bundle"; version:Version="1.2.0"]
at org.eclipse.osgi.container.Module.start(Module.java:434)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1582)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1562)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.doContainerStartLevel(ModuleContainer.java:1533)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1476)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)[org.eclipse.osgi-3.10.101.v20150820-1432.jar:]
I don`t know if the problem still exists, so I updated the dependencies of the binding which hopefully fixes that problem. I was not able to simulate the problems you have. So please check out the last release:
The error I posted last week disappeared when I did a apt-get uninstall openhab2 from testing repository an reinstall it form stable. Don’t know why this has any effect on the your heos binding, but afterwards the version 0.1.5 works properly.
Now I installed 0.1.6 and still everything seems to be ok.
now I tested some more things and also tried to locally build the project to may support you implementing some features / bugfixes. I found several issues and would be happy if you could take a look on GitHub, documented them all there. Especially this one is a little bit annoying as it prevents me from building
Hi, very nice fast progress on this. I’m having some thoughts of getting Denon reciever and Heos speaker for multiroom. I have a Sonos Play:1 today, from openhab I am able to use it as a sink, use say commands and so.
Is this also possible (or going to be) in this binding?
I also want to be able to take the sound from the receiver (hdmi) and stream it to my Heos speakers. Would this also be possible?
@NoTechi Thank you! Thats good to hear! I´m thinking about doing this. If I have a little bit more time in the future I will work on that.
Until then, I will start to fix some small problems which @pfink finds during testing. Again thank you for that! @Fredrik_Andersson I was thinking of adding the support as a sink. But this will maybe introduced in a later version after the current one has reached a stable state.
As I know it is possible to route the sound from the HDMI AV HEOS Receiver to every speaker in your home. But I can’t say for sure because I don’t own an HEOS AV Receiver
@Fredrik_Andersson: Yes, routing HDMI sound to HEOS speakers is possible with the HEOS-integrated Denon and Marantz receivers. But I’d recommend you to pick the HEOS AVR rather than the 4300H or 6300H, because the integration is more seamless there.