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

Could not connect to "AirSonos @ Kitchen" #38

Open
RJ opened this issue Sep 29, 2014 · 14 comments
Open

Could not connect to "AirSonos @ Kitchen" #38

RJ opened this issue Sep 29, 2014 · 14 comments
Labels

Comments

@RJ
Copy link

RJ commented Sep 29, 2014

It detects my sonos, but "could not connect" to whichever one i try. I ungrouped my sonos devices and tried to play on a single-device one, but same problem (none of the devices work, same error).

$ node --version
v0.10.26
rj@tube ~/src
$ npm --version
1.4.3
rj@tube ~/src
$ uname -a
Darwin tube.local 13.4.0 Darwin Kernel Version 13.4.0: Sun Aug 17 19:50:11 PDT 2014; root:xnu-2422.115.4~1/RELEASE_X86_64 x86_64
rj@tube ~/src
$ date
Mon 29 Sep 2014 21:15:04 BST
rj@tube ~/src
$

screenshot 2014-09-29 21 12 42

@stephen
Copy link
Owner

stephen commented Sep 30, 2014

Hey @RJ - In general, these pop up when OS X can't talk to nodetunes properly and gives up on the connection. Would you mind trying the nodetunes example to see if that's working at all?

Something like...

git clone git@github.com:stephen/nodetunes.git
cd nodetunes
npm install
node examples/server_stdout.js

You should see Nodetunes Stdout as an AirPlay device - which, when selected + there's audio playing, should pipe out to stdout in your console (as gibberish) - hopefully can isolate if it's something on the nodetunes side.

@jherskowitz
Copy link

Heh, funny that @RJ and I have the same issue. o/

@RJ
Copy link
Author

RJ commented Sep 30, 2014

Selecting "nodetunes stdout" as my airplay target gives an error message like above:
"Could not connect to 'NodeTunes Stdout'"

It builds fine, the tests all pass if i run gulp.
No output, errors or logging that i can find.

@RJ
Copy link
Author

RJ commented Sep 30, 2014

oh nodetunes is your project too, hah - was about to file a bug over there :)

I'd love to get this working, if you have any suggestions on how to debug i'm happy to dig in.

@JasonSuave
Copy link

I have the same problem and followed @stephen 's instructions. When I try to enable "Nodetunes Stdout" in iTunes I get:

The AirPlay device “NodeTunes Stdout” is not compatible with this version of iTunes.

and the server crashes with this error:

[1]    28263 segmentation fault  node examples/server_stdout.js

All test pass when I run gulp.
(I'm on Yosemite beta). I might try on another device later.

@stephen
Copy link
Owner

stephen commented Oct 16, 2014

@JasonSuave - that's likely a couple other issues: #27 and possibly #33 (that is - Yosemite isn't supported well right now, and you might be using node 0.11.x).

@RJ and @jherskowitz - sorry for the delay here, it seems the core problem is getting nodetunes to play nice with your devices. Unfortunately, I currently don't have great tooling set up in nodetunes for debugging network issues (apart from sticking some console.logs in suspect places.)

Would it be possible to trouble either of you for a wireshark dump of what happens when you try to choose nodetunes from the system audio? Steps would be something like recording on the loopback (lo0) device, and looking for HTTP/RTSP traffic on a port between 5000-5050.

You can then right click on one of those items and -> Follow TCP stream, which would come out looking something like the first image here: https://medium.com/@stephencwan/hacking-airplay-into-sonos-93a41a1fcfbb.

@stephen
Copy link
Owner

stephen commented Nov 23, 2014

Hey @RJ and @jherskowitz -

I've added a --verbose flag that dumps some of the network back and forth that could be useful to debug what's going on here.

Would be appreciated if either of you could try this out and dump the output:

sudo npm install -g airsonos@0.0.21
airsonos --verbose

@jherskowitz
Copy link

It's connecting/working now for me, but the audio is pretty distorted and choppy.

https://gist.github.com/jherskowitz/c0678ff00fc18054784d

@stephen
Copy link
Owner

stephen commented Nov 23, 2014

Hm, any ideas what changed (perhaps networking?) between then and now that made it work?

Not sure about the distorted audio, but it usually hints at: a) poor connectivity, or b) machine isn't powerful enough for the encoding process (i.e. raspberry pi)

(that being said, more intelligent buffering is something that should happen in nodetunes..)

@jherskowitz
Copy link

I was having some bad networking issues (was also causing Airfoil to drop connections repeatedly) that was resolved last week with the OS X 10.10.1 update - maybe related?

FWIW, I'm running on a 2011 Macbook Air (1.8Ghz Core i7).

@RJ
Copy link
Author

RJ commented Feb 13, 2015

just tried master, and it's working now 👍

I have an office zone (2x play3+ sub), and a kitchen zone (1x play5) usually grouped together. it doesn't seem to handle groups or zones with multiple speakers too well. It plays out of all the speakers in my office zone once i select the correct one from the list.
Also it seems to un-group kitchen and office once i start playing via office.

screenshot 2015-02-13 12 52 49

Not sure if there's a nicer way to handle that via airplay, lmk if you want me to do any other debugging.
Anyway, i can listen to spotify radio on my sonos now, so I'm exceedingly pleased.. thanks!

@stephen
Copy link
Owner

stephen commented Feb 16, 2015

Just released 0.1.1 which should support grouped rooms better. Might be some rough edges to work through though.

@stephencwan

On Fri, Feb 13, 2015 at 7:17 AM, Richard Jones notifications@github.com
wrote:

just tried master, and it's working now 👍
I have an office zone (2x play3+ sub), and a kitchen zone (1x play5) usually grouped together. it doesn't seem to handle groups or zones with multiple speakers too well. It plays out of all the speakers in my office zone once i select the correct one from the list.
Also it seems to un-group kitchen and office once i start playing via office.
screenshot 2015-02-13 12 52 49
Not sure if there's a nicer way to handle that via airplay, lmk if you want me to do any other debugging.

Anyway, i can listen to spotify radio on my sonos now, so I'm exceedingly pleased.. thanks!

Reply to this email directly or view it on GitHub:
#38 (comment)

@maheshbalan
Copy link

I have the same issue, here is the output from the vebose setting: When I select the device, it gives the message "the selected device has no output controls":
Airsonos version: 0.1.1
node version: 0.10.33

OS X: 10.9.5

Any ideas ?

Searching for Sonos devices on network...
Setting up AirSonos for Family Room {192.168.0.9:1400}
nodetunes:server starting nodetunes server (Family Room (AirSonos)) +0ms
nodetunes:server broadcasting mdns advertisement (for port 5000) +15ms
nodetunes:rtsp received method OPTIONS (CSeq: 0)
{ cseq: '0',
'x-apple-device-id': '0x3c075471837c',
'apple-challenge': 'nM4Q7VzEBZIN7laBQoxmQA==',
'dacp-id': '1B3DF0FD3C5F58AA',
'active-remote': '3581518223',
'user-agent': 'AirPlay/200.34.4' } +3m
nodetunes:helper building challenge for nM4Q7VzEBZIN7laBQoxmQA== (ip: c0a80010, mac: 545200732823) +1ms
nodetunes:helper computed challenge: UTAIQDzWf+llCEdGr9PiCXskMS7130C9p2oWEzRc8kzSrhmdI3fT94l8sGGF+6zELpzxY608vK6fz2WAWlH1maRtZ1imqLpKw59jd+WQ264wElXBCFGgAwfwh1zB917/9uSx9ZvwzKnwDkTvcNbDlQZALAVTLPyYJuoMGVRDjvGixToy8XxKorsUqyMAXm222OGTlhIXtNL9/14yNxL3QZPtoBePApQ5EyPVBlwhSNTxTUeNY03P9FR24FH8AgaCoK2l5LdfgkNiL+p/MlnxCRjyz2/Xw1zXaKEJAVGVoQ7YBVol2IlhV40QbyQxlMlIcDv+nbfFfnCw4QKxOgRGSw== +66ms
nodetunes:rtsp received method OPTIONS (CSeq: 1)
{ cseq: '1',
'x-apple-device-id': '0x3c075471837c',
'apple-challenge': 'b4ntMs1Nq/0NMX6ikq5+Rg==',
'dacp-id': '1B3DF0FD3C5F58AA',
'active-remote': '1260498677',
'user-agent': 'AirPlay/200.34.4' } +64ms
nodetunes:helper building challenge for b4ntMs1Nq/0NMX6ikq5+Rg== (ip: c0a80010, mac: 545200732823) +0ms
nodetunes:helper computed challenge: 17Ij0ps5vVJvXDft8jvQgcjFfgpCr6fAFODRYJFrPO+7/w5wxlKwBbqPpP8tHlbyItIcTbYAQXtxKdUuV36BFlk10W/nRKAQl3+Nv7ygXW7+i0wGIVQqrA6ovQaKj/QRzKFI1graa4G+vgNEAgplK7m8+H2HVFEwB6XwmF6ObrUrbMmkvPk5TM9nM7VbZDAynYIgeaPB3PlOdMvXS5kVK1rXbsm0PH03TizVv9UBidyC8lX8cWEGBPZ9xKLVoaRsWpCY+AwhatJ18flRRZzNhDJGqzcDI6atBXxCOg/nXXLCcv2yoD/TynA6yKJSLpr50y/FoSIPnUOdjvAHw3v4UQ== +62ms
nodetunes:rtsp received method OPTIONS (CSeq: 2)
{ cseq: '2',
'x-apple-device-id': '0x3c075471837c',
'apple-challenge': '+Ojbm3njghlsWuFGXWEGnA==',
'dacp-id': '1B3DF0FD3C5F58AA',
'active-remote': '1820135293',
'user-agent': 'AirPlay/200.34.4' } +5s
nodetunes:helper building challenge for +Ojbm3njghlsWuFGXWEGnA== (ip: c0a80010, mac: 545200732823) +1ms
nodetunes:helper computed challenge: tK+x0d7Dq0u1O3W/3C90ZRh3gzbCxmhDfduBXoRcQsPQwC5XHnfVTO6nGuEJWzeoQraA5sh3gVbtR0dKr5YDRsX24mCjaz19f3GyTFL5G6Me3ts8U/iaBEhB9SKzQvIG+XEetHrC7FNdRevHEvLuaoenhhZ+8Meod9Mc3ZRb0Nr2QLRYja41xVJvICqkUlgqiF58oF+g40YGa4YDXnFELhnKCaJvv+yQRnToZvrOAfJ7BIEGKMLBA3rYDZe/Z4GnQtAoBnFaeVNhZRsmMpA17+HMpJC2aNu87Esi28qDGnaKNziD0NYg+1V4djYW+zM17/FCHU+qYRZ7St1b6F0BqQ== +61ms
nodetunes:rtsp received method OPTIONS (CSeq: 3)
{ cseq: '3',
'x-apple-device-id': '0x3c075471837c',
'apple-challenge': 'c7szMYX9xtZITpjkrUicGw==',
'dacp-id': '1B3DF0FD3C5F58AA',
'active-remote': '632792760',
'user-agent': 'AirPlay/200.34.4' } +10s
nodetunes:helper building challenge for c7szMYX9xtZITpjkrUicGw== (ip: c0a80010, mac: 545200732823) +1ms
nodetunes:helper computed challenge: 0Vj/iq4YJmrQhsmt5lwqfPzOwMGK7ZVgMasgTN5/aI/UYrG9hzKRJxYDlEyiUgJE9Ja7yoNszj+0gbhY3LXyKzzWDpjztsx/mDruifoQtOV50dcQJ6DBsAYrmyEz2HZKaFIX0/LSx7yCLLj78MRwMW5v6m2ZkyrzC58QXv7FPej2MvSVIQ4NmhqeRdY+iGdxAi6aHI5qn7ZoXZnLoxJ40WNT8nbiDFokBBWm8L5rP45EOT51EFEigh3CZApjBJllVWo0dLiDP/77CHmgkGnbrpStxlvCjCu6hSq5coEHcDXHLthHCkt+bnHBXjVI5cLOOY0GShgY4QLxHfsbRcwPTw== +66ms
nodetunes:rtsp received method OPTIONS (CSeq: 4)
{ cseq: '4',
'x-apple-device-id': '0x3c075471837c',
'apple-challenge': 'K/hhUWjKTy3ivDjIj2rxKA==',
'dacp-id': '1B3DF0FD3C5F58AA',
'active-remote': '3179301172',
'user-agent': 'AirPlay/200.34.4' } +12ms
nodetunes:helper building challenge for K/hhUWjKTy3ivDjIj2rxKA== (ip: c0a80010, mac: 545200732823) +0ms
nodetunes:helper computed challenge: Bq5Pae89KoCdlNe6uTck0b5L55gvCzN7Wwu3refIPeCa+OsHefhV8+KzMZ4i5LCZbC4N49gTnaTS/POjGmlP2MXqijHO6l+j+hM0EPgaAb6FN4aku5Usp7BuTVF3dirSTB2K4CfD5/BpGgy8VzovWBGyQCDD5VZBm0I0mtPMjsV0qvGZTcT9lRrx1k/PWa2EVYPfk5Bev+JagGBAL8oRf1mHUOBZAT2dzmSMFN1vzMdbmN06+fW9EqoquWipNQv8oXTsj4G5D7DAMmZsSDKmhZ0MVTVGrNkrgR0A0ZL6iMpoCQFFrdzFH11+xxt79FA0ADACtue6jmMrMeYLv0ej7g== +54ms

@hilbrink
Copy link

hilbrink commented Apr 3, 2015

I tried to run this with the '--verbose' flag and it worked. however, when i ran the server without the '--verbose' flag it keeps disconnecting after I select the SONOS speakers on the iPhone.

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

No branches or pull requests

6 participants