Skip to content
This repository has been archived by the owner on Jun 4, 2023. It is now read-only.

Stereo Pair shows up 3 times #8

Closed
stephen opened this issue Apr 23, 2014 · 12 comments · Fixed by #82
Closed

Stereo Pair shows up 3 times #8

stephen opened this issue Apr 23, 2014 · 12 comments · Fixed by #82
Milestone

Comments

@stephen
Copy link
Owner

stephen commented Apr 23, 2014

Once for each speaker, and once for the stereo pair as whole. Reported by Bernhard via Email.

Need to write up some diagnostics code to help debug this since I don't have a second Sonos device to play with.

@iBender70
Copy link

Same here. I have a Sonos Playbar with two Play 1 as surround speakers in my living room. In the Sonos app this is just displayed as one room called "Living Room". In AirSonos I see three times "Living Room" and only one of them works, the other two will not do anything at all when selected, so I have to test which one works. But as soon as I select the right one playing music via AirSonos is working fine and also the surround speakers are used just as it should be when I use the Sonos App.
The other Sonos speakers (Kitchen & Bath) show up as supposed to and work fine too.

BTW: this is really a great solution! I'm really excited. Keep on the great work. Thank you guys.
Let me know if I can do something to help you troubleshoot this little problem.

@stephen
Copy link
Owner Author

stephen commented Apr 23, 2014

Definitely agree that this is an issue, but currently only have a single Play:3 so I'm unable to test a solution with my setup.

Will be writing up a quick diagnostics sometime today/tomorrow to help me figure out how to make this better. Would you mind running when I finish that?

@iBender70
Copy link

Hi Stephen,
I will be glad to help. AirSonos adds some real value to my Sonos speakers. So just let me know as soon as you have it ready for testing.

@scherii
Copy link

scherii commented Apr 24, 2014

I'll be happy to help as well. My setup consists of a Playbar, a SUB and 2x Play:3. As of 0.0.9 it was displayed as 4 individual AirPlay speakers. Now (0.0.10) there are 3 left.

Thanks and keep up the good work :)

@stephen
Copy link
Owner Author

stephen commented Apr 25, 2014

All,

I've added a quick SonosNet diagnostics output to version 0.0.11; would love if you guys could send back the output so I can see what the data says on Stereo pairs and living room setups.

Instructions:

  1. Update to version 0.0.11 (npm update -g airsonos or nom install -g airsonos)
  2. Check AirSonos version (airsonos --version) and make sure you're on 0.0.11
  3. Run diagnostics (airsonos --diagnostics)

The diagnostics script queries all of the devices it can find, and outputs some of the SonosNet metadata. Will greatly help me figure out the structure for Sonos zones.

Cheers,
Stephen

@teejteej
Copy link

Hello,

I get the following error as soon as I choose one of my two Sonos Play-5 outputs for playback (not a stereo pair):

$ airsonos
Searching for Sonos devices on network...
Setting up AirSonos for Front {192.168.1.3:1400}
Setting up AirSonos for Back {192.168.1.4:1400}

/usr/local/lib/node_modules/airsonos/node_modules/nodetunes/lib/rtsp.js:41
    this.methodMapping[m.method](response, m.headers, m.content);
                                ^
TypeError: Property '
SETUP' of object #<Object> is not a function
    at RtspServer.<anonymous> (/usr/local/lib/node_modules/airsonos/node_modules/nodetunes/lib/rtsp.js:41:33)
    at EventEmitter.emit (events.js:95:17)
    at Socket.<anonymous> (/usr/local/lib/node_modules/airsonos/node_modules/nodetunes/node_modules/httplike/index.js:61:11)
    at Socket.EventEmitter.emit (events.js:95:17)
    at Socket.<anonymous> (_stream_readable.js:746:14)
    at Socket.EventEmitter.emit (events.js:92:17)
    at emitReadable_ (_stream_readable.js:408:10)
    at emitReadable (_stream_readable.js:404:5)
    at readableAddChunk (_stream_readable.js:165:9)
    at Socket.Readable.push (_stream_readable.js:127:10)

Here's my diagnostic information (mac and serial redacted):

AirSonos Diagnostics
node version     v0.10.24
operating sys    darwin (x64)

Searching for Sonos devices on network...

Device  {"host":"192.168.1.4","port":1400} (ZPS5)
`- attrs:   {"CurrentZoneName":"Back",
        "CurrentIcon":"x-rincon-roomicon:living",
        "CurrentConfiguration":"1"}
`- info:    {"SerialNumber":"XX-XX-XX-XX-XX-XX:5",
        "SoftwareVersion":"26.1-76160",
        "DisplaySoftwareVersion":"5.0",
        "HardwareVersion":"1.16.4.1-2",
        "IPAddress":"192.168.1.4",
        "MACAddress":"XX:XX:XX:XX:XX:XX",
        "CopyrightInfo":"© 2004-2007 Sonos, Inc. All Rights Reserved.",
        "ExtraInfo":"OTP: 1.1.1(1-16-4-zp5s-0.5)",
        "HTAudioIn":"0"}


Device  {"host":"192.168.1.2","port":1400} (BR100)
`- attrs:   {"CurrentZoneName":"BRIDGE",
        "CurrentIcon":"x-rincon-roomicon:viper",
        "CurrentConfiguration":"1"}
`- info:    {"SerialNumber":"XX-XX-XX-XX-XX-XX:D",
        "SoftwareVersion":"26.1-76160",
        "DisplaySoftwareVersion":"5.0",
        "HardwareVersion":"1.5.0.0-2",
        "IPAddress":"192.168.1.2",
        "MACAddress":"XX:XX:XX:XX:XX:XX",
        "CopyrightInfo":"© 2004-2007 Sonos, Inc. All Rights Reserved.",
        "ExtraInfo":"",
        "HTAudioIn":"0"}


Device  {"host":"192.168.1.3","port":1400} (ZPS5)
`- attrs:   {"CurrentZoneName":"Front",
        "CurrentIcon":"x-rincon-roomicon:living",
        "CurrentConfiguration":"1"}
`- info:    {"SerialNumber":"XX-XX-XX-XX-XX-XX:G",
        "SoftwareVersion":"26.1-76160",
        "DisplaySoftwareVersion":"5.0",
        "HardwareVersion":"1.16.4.1-2",
        "IPAddress":"192.168.1.3",
        "MACAddress":"XX:XX:XX:XX:XX:XX",
        "CopyrightInfo":"© 2004-2007 Sonos, Inc. All Rights Reserved.",
        "ExtraInfo":"OTP: 1.1.1(1-16-4-zp5s-0.5)",
        "HTAudioIn":"0"}

@stephen
Copy link
Owner Author

stephen commented Apr 25, 2014

@teejteej - that looks closer to #2; moving to that conversation..

@iBender70
Copy link

So here is the result of the diagnostics:

AirSonos Diagnostics
node version     v0.10.26
operating sys    darwin (x64)

Searching for Sonos devices on network...

Device  {"host":"10.0.1.22","port":1400} (ZPS1)
`- attrs:   {"CurrentZoneName":"Küche",
        "CurrentIcon":"x-rincon-roomicon:kitchen",
        "CurrentConfiguration":"1"}
`- info:    {"SerialNumber":"XX-XX-XX-XX-XX-5E:9",
        "SoftwareVersion":"26.1-76160",
        "DisplaySoftwareVersion":"5.0",
        "HardwareVersion":"1.8.3.7-2",
        "IPAddress":"10.0.1.22",
        "MACAddress":"XX:XX:XX:XX:XX:5E",
        "CopyrightInfo":"© 2004-2007 Sonos, Inc. All Rights Reserved.",
        "ExtraInfo":"OTP: ",
        "HTAudioIn":"0"}


Device  {"host":"10.0.1.16","port":1400} (BR100)
`- attrs:   {"CurrentZoneName":"BRIDGE",
        "CurrentIcon":"x-rincon-roomicon:viper",
        "CurrentConfiguration":"1"}
`- info:    {"SerialNumber":"XX-XX-XX-XX-XX-5A:9",
        "SoftwareVersion":"26.1-76160",
        "DisplaySoftwareVersion":"5.0",
        "HardwareVersion":"1.5.0.0-2",
        "IPAddress":"10.0.1.16",
        "MACAddress":"XX:XX:XX:XX:XX:5A",
        "CopyrightInfo":"© 2004-2007 Sonos, Inc. All Rights Reserved.",
        "ExtraInfo":"",
        "HTAudioIn":"0"}


Device  {"host":"10.0.1.21","port":1400} (ZPS9)
`- attrs:   {"CurrentZoneName":"Wohnzimmer",
        "CurrentIcon":"x-rincon-roomicon:living",
        "CurrentConfiguration":"1"}
`- info:    {"SerialNumber":"XX-XX-XX-XX-XX-04:4",
        "SoftwareVersion":"26.1-76160",
        "DisplaySoftwareVersion":"5.0",
        "HardwareVersion":"1.9.1.10-2",
        "IPAddress":"10.0.1.21",
        "MACAddress":"XX:XX:XX:XX:XX:04",
        "CopyrightInfo":"© 2004-2007 Sonos, Inc. All Rights Reserved.",
        "ExtraInfo":"OTP: ",
        "HTAudioIn":"21"}


Device  {"host":"10.0.1.17","port":1400} (ZPS1)
`- attrs:   {"CurrentZoneName":"Bad",
        "CurrentIcon":"x-rincon-roomicon:bathroom",
        "CurrentConfiguration":"1"}
`- info:    {"SerialNumber":"XX-XX-XX-XX-XX-14:B",
        "SoftwareVersion":"26.1-76160",
        "DisplaySoftwareVersion":"5.0",
        "HardwareVersion":"1.8.3.7-2",
        "IPAddress":"10.0.1.17",
        "MACAddress":"XX:XX:XX:XX:XX:14",
        "CopyrightInfo":"© 2004-2007 Sonos, Inc. All Rights Reserved.",
        "ExtraInfo":"OTP: ",
        "HTAudioIn":"0"}


Device  {"host":"10.0.1.25","port":1400} (ZPS1)
`- attrs:   {"CurrentZoneName":"Wohnzimmer",
        "CurrentIcon":"x-rincon-roomicon:living",
        "CurrentConfiguration":"1"}
`- info:    {"SerialNumber":"XX-XX-XX-XX-XX-XX:1",
        "SoftwareVersion":"26.1-76160",
        "DisplaySoftwareVersion":"5.0",
        "HardwareVersion":"1.8.3.7-2",
        "IPAddress":"10.0.1.25",
        "MACAddress":"XX:XX:XX:XX:XX:XX",
        "CopyrightInfo":"© 2004-2007 Sonos, Inc. All Rights Reserved.",
        "ExtraInfo":"OTP: ",
        "HTAudioIn":"0"}


Device  {"host":"10.0.1.24","port":1400} (ZPS1)
`- attrs:   {"CurrentZoneName":"Wohnzimmer",
        "CurrentIcon":"x-rincon-roomicon:living",
        "CurrentConfiguration":"1"}
`- info:    {"SerialNumber":"XX-XX-37-XX-XX-C8:4",
        "SoftwareVersion":"26.1-76160",
        "DisplaySoftwareVersion":"5.0",
        "HardwareVersion":"1.8.3.7-2",
        "IPAddress":"10.0.1.24",
        "MACAddress":"XX:XX:37:XX:XX:C8",
        "CopyrightInfo":"© 2004-2007 Sonos, Inc. All Rights Reserved.",
        "ExtraInfo":"OTP: ",
        "HTAudioIn":"0"}

And this is the corresponding information I get from "About Sonos"

Verknüpfter ZP: 10.0.1.21 << "Verknüpft" German word for "linked" 
---------------------------------
PLAY:1: Bad
Seriennummer: XX-XX-XX-XX-XX:B
Version: 5.0 (Build 26176160)
Hardwareversion: 1.8.3.7-2
IP-Adresse: 10.0.1.17
OTP: 
---------------------------------
BRIDGE: BRIDGE
Seriennummer: XX-XX-XX-XX-XX:9
Version: 5.0 (Build 26176160)
Hardwareversion: 1.5.0.0-2
IP-Adresse: 10.0.1.16
---------------------------------
PLAY:1: Küche
Seriennummer: XX-XX-XX-XX-XX:9
Version: 5.0 (Build 26176160)
Hardwareversion: 1.8.3.7-2
IP-Adresse: 10.0.1.22
OTP: 
---------------------------------
PLAYBAR: Wohnzimmer
Seriennummer: XX-XX-XX-XX-XX:4
Version: 5.0 (Build 26176160)
Hardwareversion: 1.9.1.10-2
IP-Adresse: 10.0.1.21
Audioeingang: 
OTP: 
---------------------------------
PLAY:1: Wohnzimmer (RL)
Seriennummer: XX-XX-XX-XX-XX:1
Version: 5.0 (Build 26176160)
Hardwareversion: 1.8.3.7-2
IP-Adresse: 10.0.1.25
OTP: 
---------------------------------
PLAY:1: Wohnzimmer (LL)
Seriennummer: XX-XX-XX-XX-XX:4
Version: 5.0 (Build 26176160)
Hardwareversion: 1.8.3.7-2
IP-Adresse: 10.0.1.24
OTP: 

Interesting is the very first line here which says "Linked ZP 10.0.1.21" which is the IP of the Sonos Playbar in my living room.
In the diagnostics you can see "HTAudioIn":"21" set for the Playbar. Looks like this is the indication the Speaker with the IP ending with 21 is the receiver for the linked speakers "Wohnzimmer" (living room). So it looks like that the one speaker from Wohnzimmer with HTAudioIn != 0 is the right one. But this is just a guess from my side.

@horvath
Copy link

horvath commented Oct 12, 2014

Also having this issue: https://twitter.com/peterhorvath/status/521357768390082561
Here is my setup: https://gist.github.com/horvath/74eaf14c25b212ebf792
And my diagnostics: https://gist.github.com/anonymous/3ae650a4b0ae4866fcc5

I was able to create a workaround for my specific setup (1 playbar, 2 surrounds, sub, bridge). The volume control is all in tact and works perfectly. The trick is to just ignore the ZPS1 model: horvath@8e04df7

screen shot 2014-10-12 at 2 38 45 pm

You could do a more sophisticated conditional to work universally with other setups. Just a thought but could you add a conditional to ignore all ZPS1 models as a device if both ZPS9 and ZPS1 are both present on the same zone?

The next challenge is to turn this into a daemon so it doesn't requiring terminal to stay open. Stephen, thoughts?

@horvath
Copy link

horvath commented Oct 12, 2014

It was able to launch airsonos as a daemon using forever: https://www.npmjs.org/package/forever

Everything works perfectly, thanks!

@stephen
Copy link
Owner Author

stephen commented Oct 16, 2014

@horvath - could you clarify what devices showed up before you made the change to ignore the ZPS1? Were there only 2 devices shown for your playbar + everything setup?

@horvath
Copy link

horvath commented Oct 16, 2014

@stephen Before I ignored the ZPS1, I had all three devices show up in AirPlay: the playbar and my two surround speakers (I had 3x AirSonos @ Living Room)

By the way, my entire setup (1 playbar, 2 surrounds, 1 sub) is all contained in the same zone.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants