[SOLVED] Beginner Sonos problem

Hi Everybody, new user here and I’m just getting an initial setup going to start testing components and integration for a new house. I’ve worked my way through a bunch of stuff already (this forum is awesome), but I’ve hit the first snag that I can’t seem to work past…

No matter what commands I issue to my Sonos player through the interface, nothing is happening to the control of the physical device. I’m sure it’s just my inexperience with the platform and hopefully it’s an easy answer. I’ve kept the setup deliberately simple for debugging and I’ll try to provide as much info as possible below.

-I have the sonos binding installed, and the .things/items/sitemap files have been manually defined. Haven’t added anything through paperUI.

-The controller UI elements from the sitemap shows up correctly in both basic and paperUI, however ‘Status’ and ‘Now Playing’ don’t appear to be polling correctly (it just shows “-”).

(edited with better info)
-Initially was able to see the commands (play, pause, volume changes etc) propagating into the logs, and they were erroring due to wrong (retained/stale) channels. Cleared those out and now the commands appear in the logs correctly when controlled through paperUI & basicUI…
i.e. ‘2017-01-23 07:35:49.089 [ItemStateChangedEvent ] - Sonos_Controller changed from PLAY to PAUSE’

-Below are the contents of the relevant files:

Thing sonos:PLAY5:living [ udn=“RINCON_000E588F58XXXXXXX”, refresh=60 ]

Group Sonos

Player Sonos_Controller “Controller” (Sonos) {channel=“sonos:PLAY5:living:control”}
Dimmer Sonos_Volume “Volume [%.1f %%]” (Sonos) {channel=“sonos:PLAY5:living:volume”}
Switch Sonos_Mute “Mute” <soundvolume_mute> (Sonos) {channel=“sonos:PLAY5:living:mute”}
Switch Sonos_LED “LED” (Sonos) {channel=“sonos:PLAY5:living:led”}
String Sonos_CurrentTrack “Now playing [%s]” (Sonos) {channel=“sonos:PLAY5:living:currenttrack”}
String Sonos_State “Status [%s]” (Sonos) {channel=“sonos:PLAY5:living:state”}

sitemap sonos label=“Main Menu”
Frame label=“Sonos” {
Default item=Sonos_Controller
Slider item=Sonos_Volume
Switch item=Sonos_Mute
Switch item=Sonos_LED
Text item=Sonos_CurrentTrack
Text item=Sonos_State

-In the karaf console, I see the following output:
#smarthome:things list
sonos:PLAY5:living (Type=Thing, Status=OFFLINE, Label=PLAY 5, Bridge=null)

#smarthome:items list
Sonos (Type=GroupItem, Members=6, State=UNDEF, Label=null, Category=player)
Sonos_Controller (Type=PlayerItem, State=PAUSE, Label=Controller, Category=null, Groups=[Sonos])
Sonos_Volume (Type=DimmerItem, State=74, Label=Volume, Category=soundvolume, Groups=[Sonos])
Sonos_Mute (Type=SwitchItem, State=UNDEF, Label=Mute, Category=soundvolume_mute, Groups=[Sonos])
Sonos_LED (Type=SwitchItem, State=UNDEF, Label=LED, Category=switch, Groups=[Sonos])
Sonos_CurrentTrack (Type=StringItem, State=UNDEF, Label=Now playing, Category=text, Groups=[Sonos])
Sonos_State (Type=StringItem, State=UNDEF, Label=Status, Category=text, Groups=[Sonos])

#smarthome:links list
Sonos_Volume -> sonos:PLAY5:living:volume
Sonos_State -> sonos:PLAY5:living:state
Sonos_Controller -> sonos:PLAY5:living:control
Sonos_LED -> sonos:PLAY5:living:led
Sonos_CurrentTrack -> sonos:PLAY5:living:currenttrack
Sonos_Mute -> sonos:PLAY5:living:mute

Everything seems in order to my newbie eye, not really sure where to go next…can’t find any relevant posts for this one unfortunately. I double checked the upd for the player and it’s correct from what I can see. Any help is greatly appreciated (it’s probably something super newb that I missed!). Thanks!

I don’t see anything obvious either, however I’m not using the things-file (so I may be blind on that spot)
I’m using PaperUI to setup my things and do the setup of my items manually using files. That way I can use the PaperUI control page to check if the connections are working. for all connected channels this controlpage shows a control that should be working.

@opus, thanks for the input Jurgen.

It’s actually interesting… None of my sonos units show up in the ‘Inbox’ in paperUI (even when I force discovery). The sitemap shows up in ‘Control’, but it’s the same story as basicUI…elements are visually functional but they don’t do anything.

Your sitemap is showing up on PaperUI-Control???

I’m lost on that, for me only the Channel of Things that are online showing there! Is that because you have created your Things via file??? Or do you have only Items that reflect used channels of your things on the sitemap?

It’s very possible that I’m mistaken/misunderstanding how the sitemap is being used? Just based on my initial exploration, my assumption was that it’s being used to construct the UI elements for control that are then displayed in basicUI/paperUI. Those elements then appear to be connected to item/channels.

Perhaps that is not correct?

Sounds correct exemt for Paper UI, this one meant to control the setup and is not meant as a UI for controlling OPENHAB. The control page of PAPERUI is only to check.

Thanks for taking a look and the info Jurgen…

I’ve been thinking about the problem a bit more and I think that it’s a telling indicator that I’m not able to discover my sonos players through paperUI. There’s something that is preventing communication with them… From my understanding, the paperUI discovery is using UPNP so I’m not sure if the commands that are being issued are also using that protocol (I don’t really know how it functions.).

I did read that upnp communicates through port 1900, so perhaps I need to manually open that port via iptables in order to allow OH2 to communicate with sonos? I’m going to give that a shot tonight.

This was a straight up iptables problem and had absolutely nothing to do with openhab, good times.