Squeezebox favorites

Tags: #<Tag:0x00007f6173809360> #<Tag:0x00007f6173809298>

Hmm. What is that? I didn’t see it in your list above, and it doesn’t appear to be in the distribution.

This likely is the same issue as the Sony binding. Given that Home Connect uses state options, and that the squeezebox favorites started working immediately after you disabled Home Connect, I’m assuming its implementation of getStateDescription is broken. We need to get the Home Connect developer to fix the binding.

If interested, you can read more about the issue here.

@DUSAG0211 Is this what you’re using?

I found the PR for Home Connect and will try to get this fixed.

See here.

yes that is the one. Actually not really using it as I found out that the API lacks functions I need.
But the beta binding was still active.

Indeed not listed before since I kind of forgot about it.

Glad we got it sorted out. A while back I went through all the bindings in the distro looking for ones that had broken getStateDescription implementations. Since you weren’t using the Sony binding, I knew it had to be something else…

Hi all,

I seem to have a similar problem, but i can’t figure it out.
Running OH 2.5.4-1 freshly installed 2 days ago after a corrupted SD card…

installed bindings
-Astro
-Hue
-MQTT
-MTP
-Samsung TV
-Sonos
-Squeezebox (the fixed version mentioned above)
-Z-wave

The restart of the binding gives the following messages:

2020-05-13 16:49:21.254 [DEBUG] [SqueezeBoxPlayerDiscoveryParticipant] - Request player job scheduled to run every 60 seconds
2020-05-13 16:49:21.321 [DEBUG] [rnal.handler.SqueezeBoxServerHandler] - initializing server handler for thing squeezebox:squeezeboxserver:squeezeserver
2020-05-13 16:49:21.338 [DEBUG] [rnal.handler.SqueezeBoxServerHandler] - listener connection started to server 192.168.0.146:9090
2020-05-13 16:49:21.371 [DEBUG] [rnal.handler.SqueezeBoxServerHandler] - Sending command: players 0
2020-05-13 16:49:21.376 [DEBUG] [rnal.handler.SqueezeBoxServerHandler] - Sending command: listen 1
2020-05-13 16:49:21.413 [DEBUG] [rnal.handler.SqueezeBoxServerHandler] - Sending command: b8:27:eb:42:2c:f4 status - 1 subscribe:10 tags:yagJlNKjc
2020-05-13 16:49:21.501 [DEBUG] [rnal.handler.SqueezeBoxPlayerHandler] - player thing squeezebox:squeezeboxplayer:squeezeserver:b827eb422cf4 initialized with mac b8:27:eb:42:2c:f4
2020-05-13 16:49:24.375 [DEBUG] [rnal.handler.SqueezeBoxServerHandler] - Sending command: favorites items 0 100
2020-05-13 16:49:31.260 [DEBUG] [rnal.handler.SqueezeBoxServerHandler] - Sending command: players 0
2020-05-13 16:50:31.262 [DEBUG] [rnal.handler.SqueezeBoxServerHandler] - Sending command: players 0
2020-05-13 16:55:36.106 [TRACE] [rnal.handler.SqueezeBoxPlayerHandler] - Player b8:27:eb:42:2c:f4 updating favorites list with 4 favorites

Item is set and linked to channel but is not populated and empty in my sitemap.

Does anyone have a clue?

Kind regards,
Tedje

Please run this on the console and report back the output.

services | grep StateDescriptionProvider

Hi Mark,

Thanks for helping me!

This is the output:

[org.eclipse.smarthome.core.thing.type.DynamicStateDescriptionProvider, org.openhab.binding.mqtt.generic.MqttChannelStateDescriptionProvider]
[org.eclipse.smarthome.core.thing.type.DynamicStateDescriptionProvider, org.openhab.binding.sonos.internal.SonosStateDescriptionOptionProvider]
[org.eclipse.smarthome.core.thing.type.DynamicStateDescriptionProvider, org.openhab.binding.squeezebox.internal.SqueezeBoxStateDescriptionOptionsProvider]

Those bindings all have well-behaved StateDescriptionProviders, so that doesn’t appear to be an issue.

And from the log you posted, the SqueezeBoxServerHandler clearly is sending the favorites to the Player Handler.

Can you share your item and sitemap definitions for the Player Handler’s playFavorite channel?

Also, if you have an item linked to the SqueezeBox Server’s favoritesList channel, can you share the state of that item?

From the console, run this and post the result.

smarthome:items list | grep NameOfTheItem

The output from the console:

wkradio_fav (Type=StringItem, State=NULL, Label=Play Favorite, Category=null)

Item:

String wkradio_fav    "Play Favorite [%s]"  { channel="squeezebox:squeezeboxplayer:squeezeserver:b827eb422cf4:playFavorite" }

Sitemap:

Selection item=wkradio_fav label="Favorites" icon="office"

Item and sitemap look OK.

But I actually was looking for the state of the server’s favoritesList channel.

Also, can you try doing a restart of the binding.

bundle:restart org.openhab.binding.squeezebox

The output for the server:

serverfav (Type=StringItem, State=NULL, Label=null, Category=null)

And if i change the checkbox in PaperUI:

serverfav (Type=StringItem, State=0="NPO Radio 2",1="Omroep Venlo",2="Radio 10 103.8 (Classic Hits)",3="Arrow Classic Rock (Classic Rock)", Label=null, Category=null)

The favorites do show up and are working in my player in the PaperUI btw.

Restart does not change anything, tried it several times.

I’m running out of ideas…

Can you try removing the label tag on the sitemap Selection widget?

Tried removing label, icon and restart the binding, but nothing happens…
And i ran out of ideas a few hours ago :wink:

I’m now officially out of ideas. If I can think of anything else to try I’ll post back here.

Thanks for your help, i’ll try installing a second raspberry pi and try some more.

Hi! Some update from myself after upgrading Openhab to latest version. So, after I did it OH restarted and the favorites don’t show under their assigned item. However they are going back when I add or remove one of the favorites on LMS. I didn’t try restarting LMS so I can’t tell now if this would be enough. Restart of OH doesn’t fix it. I don’t know how it works, but does the binding request for favorities update when starting?

The binding requests the favorites when the binding starts, and when the favorites are changed on the LMS.

In the released version of the binding, there’s a race condition at startup where sometimes the player handler is not fully initialized when the server handler tries to send it the favorites. This is fixed in a PR that hasn’t been merged yet.

1 Like