AntiPhotonz / tunesremote-plus

Automatically exported from code.google.com/p/tunesremote-plus
0 stars 0 forks source link

Cannot pair with Rhyhmbox 0.13.2 #25

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Open Rhythmbox 0.13.2 on a networked PC running Ubuntu 10.10
2. Open TunesRemote+ on android (HTC Incredible running CM 6.1)
3. Attempt to pair over wifi using provided code.

What is the expected output? What do you see instead?
Expected to see the android pair with rhythmbox.

Instead, tunesremote+ continuously tries to pair. Rhythmbox accepts the pairing 
but then tunesremote+ tries to repair with a different name.. prompmting user 
to enter the key again.

What version of the product are you using? On what operating system?
PC is running Ubuntu 10.10 with rhythmbox 0.13.2
Android is running CyanogenMod 6.1 and  TunesRemote+ 2.0.8

Original issue reported on code.google.com by sean...@gmail.com on 29 Dec 2010 at 3:15

GoogleCodeExporter commented 8 years ago
Are you sure Rhythmbox has a DACP Server to be used with TunesREmote+?   The 
only information on Rhythmbox I can find is the Telepathy DAAP Server but DAAP 
and DACP are not the same thing so that would explain why TunesRemote+ does not 
work with Rhythmbox. 

Can you send me a link to the author of the DACP plugin for Rhythmbox or any 
other information?   

Original comment by mellowaredev on 29 Dec 2010 at 3:46

GoogleCodeExporter commented 8 years ago
Oh sorry. The feature is rather new.

Here's a link to the commit notes:
http://mail.gnome.org/archives/ftp-release-list/2010-October/msg00166.html

Note - it requires libdmapsharing-2

Original comment by sean...@gmail.com on 29 Dec 2010 at 3:49

GoogleCodeExporter commented 8 years ago
OK I did find this?

http://live.gnome.org/SummerOfCode2010/AlexandreRosenfeld_Rhythmbox

So the last step that seems not to be working is when TunesRemote+ must get a 
callback from RhythmBox on TCP Port 1024.  It seems that last step of the 
communication is the part that is not working.

This has been tested against FooRemote, MonkeyTunes, and iTunes so my guess is 
the bug in the logic is either your firewall blocking Port 1024 or a bug in the 
RhythmBox DACP code?

Original comment by mellowaredev on 29 Dec 2010 at 3:50

GoogleCodeExporter commented 8 years ago
The commit was:

* Support for DACP (iTunes remote) (Alexandre Rosenfeld's GSoC project)

And here's the project page: 

http://live.gnome.org/SummerOfCode2010/AlexandreRosenfeld_Rhythmbox

Original comment by sean...@gmail.com on 29 Dec 2010 at 3:50

GoogleCodeExporter commented 8 years ago
Sorry for the triple post.. but I also found this information on pairing issues 
with DACP. It may or may not be the root cause of our problems.

http://jsharkey.org/blog/2009/06/21/itunes-dacp-pairing-hash-is-broken/

Original comment by sean...@gmail.com on 29 Dec 2010 at 3:53

GoogleCodeExporter commented 8 years ago
Nope that post is 2 years old and Apple hasn't changed the Pairing process 
since then.  THey have too many Apple Tv's and other hardware in production to 
change the pairing process!

I just posted to Alex's blog pointing him here so he can help debug the issue.

http://arosenfeld.wordpress.com/2010/08/06/dacp-in-rhythmbox-week-11/

It seems like this is still a work in progress on the RhythmBox side as that 
post is from August?

Original comment by mellowaredev on 29 Dec 2010 at 4:00

GoogleCodeExporter commented 8 years ago
You might want to also create an issue on the RhythmBox side as well to get the 
ball rolling.

Original comment by mellowaredev on 29 Dec 2010 at 4:04

GoogleCodeExporter commented 8 years ago
I am able to manually add the server and it seems to pair, but then the client 
crashes immediately. It throws an out of memory error at 
org.tunesremote.a.f.a(Unknown Source) called by org.tunesremote.a.t.run(Unknown 
Source)

Also, a bug report has been filed on the gnome side of things.

https://bugzilla.gnome.org/show_bug.cgi?id=638410

Original comment by sean...@gmail.com on 31 Dec 2010 at 4:12

GoogleCodeExporter commented 8 years ago
OK the only thing I could think that would throw an out of memory is if your 
album covers are possibly huge and the server side is not scaling them to the 
size requested by the Android client.  Typically it asks for an album cover 
like 120x120 or 300x300 so if your cover is say huge 4000x4000 it scales it 
down to send a smaller image to the mobile device.

it could be something else though.  I might install an Ubuntu Virtual Box 
instance so I can test this if I get time!  But let me know what the RhythmBox 
team says.

Original comment by mellowaredev on 31 Dec 2010 at 4:24

GoogleCodeExporter commented 8 years ago
OK I installed a Virtual Box instance of Ubuntu 10.10 and ran all the latest 
updates and it says my RhythmBox 13.1 is up to date.  I think the DACP stuff 
isn't included until 13.2 but I am a Unix noob and wasn't quite sure how to get 
13.2 on my machine?

Original comment by mellowaredev on 31 Dec 2010 at 5:31

GoogleCodeExporter commented 8 years ago
So glad you're taking some time to look into it!

The latest rhythmbox will be included in the next release of Ubuntu (Natty)

To install it now, you can use the webupd8 repositories:

In a gnome-terminal window:
  sudo add-apt-repository ppa:webupd8team/rhythmbox
  sudo apt-get update
  sudo apt-get install rhythmbox libdmapsharing2

(taken from: 
http://www.webupd8.org/2010/11/install-rhythmbox-0132-in-ubuntu-1010.html)

Original comment by sean...@gmail.com on 31 Dec 2010 at 6:20

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
I got 13.2 installed and change my networking to bridged so now I see the 
Bonjour broadcasting from RhythmBox!

Original comment by mellowaredev on 31 Dec 2010 at 8:24

GoogleCodeExporter commented 8 years ago
OK I ran in the debugger.  RhythmBox is not sending the proper response for the 
Now Playing request.  I would paste this into the RhythmBox ticket you created. 
 Here is what TunesRemote+ reports which proves they have a malformed response. 
It looks like after the CACI field is returned the next field has the wrong 
incorrect length or the previous record is off by 1 because it appears to then 
get shifted and then the request for the LENGTH is now incorrect reporting a 
giant array of 1761607680 instead of the string length or byte length.

DEBUG/class org.tunesremote.daap.RequestHelper(1016): 
http://192.168.1.9:3689/ctrl-int/1/playstatusupdate?revision-number=1&session-id
=2911768946
DEBUG/class org.tunesremote.daap.RequestHelper(1016): started 
request(remote=http://192.168.1.9:3689/ctrl-int/1/playstatusupdate?revision-numb
er=1&session-id=2911768946)
DEBUG/class org.tunesremote.daap.ResponseParser(1016): ResponseParser 
performParse...
12-31 16:11:19.786: DEBUG/class org.tunesremote.daap.ResponseParser(1016): key 
= cmst length = 226
DEBUG/class org.tunesremote.daap.ResponseParser(1016): key = mstt length = 4
DEBUG/class org.tunesremote.daap.ResponseParser(1016): key = cmsr length = 4
DEBUG/class org.tunesremote.daap.ResponseParser(1016): key = caci length = 1
DEBUG/class org.tunesremote.daap.ResponseParser(1016): key = cac length = 
1761607680
DEBUG/class org.tunesremote.daap.ResponseParser(1016): key = ca length = 
1667825664
WARN/class org.tunesremote.daap.Status(1016): java.lang.NullPointerException

Original comment by mellowaredev on 31 Dec 2010 at 9:14

GoogleCodeExporter commented 8 years ago
In fact here are the attached HTTP dumps of the exact same remote request one 
against iTunes 10.1.1.4 and the other against RhythmBox 13.2.  

It is against the exact same track Hold Steady's Boys and Girls in America.  
This should help the RhythmBox team figure out why their response is corrupt.

Original comment by mellowaredev on 1 Jan 2011 at 4:02

Attachments:

GoogleCodeExporter commented 8 years ago
Thanks so much for your debugging efforts.

I have forwarded this information over to the libdmapsharing devs.

Here is the link:

https://bugzilla.gnome.org/show_bug.cgi?id=638410

Original comment by sean...@gmail.com on 1 Jan 2011 at 4:57

GoogleCodeExporter commented 8 years ago
I have also verified it crashes with HyperFine REmote For Itunes but it does 
work the iPhone Apple Remote.  So for some reason the iPhone Apple Remote is 
gracefully ignoring this error but all of the other DACP clients cannot because 
we stick to the spec exactly with no loose interpretations.

Original comment by mellowaredev on 2 Jan 2011 at 2:48

GoogleCodeExporter commented 8 years ago
Normally I don't do this, but this bug report is rather quiet.. so I'm going to 
ask here:

Did you test with itunes on Windows? I can verify that works. But my friend has 
a Mac and the same thing happens with his version of iTunes (10.0-67)

I enter the key given by my android and itunes says it's paired, but then my 
android sends another request. I don't have the tools or experience to see 
what's exactly is being transferred.. but I'm pretty sure something similar is 
going on..

Original comment by sean...@gmail.com on 14 Jan 2011 at 4:04

GoogleCodeExporter commented 8 years ago
Yep I tested on iTunes 10.1.1.4 and on MonkeyTunes 1.4 and both pair properly.

Your friend's problem is 100% his firewall.  See this FAQ:

http://code.google.com/p/tunesremote-plus/wiki/ConnectionProblems

Original comment by mellowaredev on 14 Jan 2011 at 11:52

GoogleCodeExporter commented 8 years ago
Any news on this bug?

Original comment by rolandju...@googlemail.com on 4 Apr 2011 at 9:48

GoogleCodeExporter commented 8 years ago
If you go to this RhythmBox bug they have not touched the bug since it was 
reported in December.

https://bugzilla.gnome.org/show_bug.cgi?id=638410

It is definitely a problem with RhythmBox and not with TunesRemote+

Original comment by mellowaredev on 6 Apr 2011 at 12:02

GoogleCodeExporter commented 8 years ago
Yea.. the rhythmbox project is a mess.. I hope Banshee will implement a better 
dacp

Original comment by sean...@gmail.com on 6 Apr 2011 at 12:06

GoogleCodeExporter commented 8 years ago
Do you know if banshee is actively working on supporting it?  I will add them 
to the TunesRemote+ homepage when they do have an implementation.

Original comment by mellowaredev on 6 Apr 2011 at 1:19

GoogleCodeExporter commented 8 years ago
Hey guys, I'm the original developer of DACP in Rhythmbox and it's probably my 
fault there is no response in Rhythmbox's bug report. I now have an Android 
phone so I might be able to help debug this issue. 
The faulty response might be a Rhythmbox bug or a problem we had with the 
library we are using for http connections, libsoup. A newer version of this 
library might help, which is included in newer versions of Linux distributions, 
such as Fedora 15 and Ubuntu 11.04.
Not sure what is different from the Apple Remote and TunesRemote+ that makes it 
work in one and not in the other. Probably Remote doesn't care about the faulty 
response or TunesRemote+ sends something different in the request that unveils 
the bug in Rhythmbox.

Original comment by airm...@gmail.com on 3 May 2011 at 3:08

GoogleCodeExporter commented 8 years ago
Apple Remote is more graceful with its parser and how it handles the HTTP 
responses where you will find 3rd parties like TuneRemote+ and Win7 Remote are 
more strict in their HTTP Repsonse parsing.

I am actually shocked this didn't fail in the Apple Remote!

Original comment by mellowaredev on 3 May 2011 at 4:17

GoogleCodeExporter commented 8 years ago
Assigning to RhythmBox developer.

Original comment by mellowaredev on 4 May 2011 at 5:17

GoogleCodeExporter commented 8 years ago
I made some changes to libdmapsharing with respect to this bug. Please see the 
corresponding GNOME bug report at:

https://bugzilla.gnome.org/show_bug.cgi?id=638410

Original comment by m...@flyn.org on 18 May 2011 at 6:35

GoogleCodeExporter commented 8 years ago
Can someone try this with TunesRemote+ to do some testing?

I saw your note on Bugzilla about needing at least one playlist to have the 
Library work properly.   I am not sure if I encountered that as long as I 
always returned these two static libraries.

// the first two playlists are special playlists needed by Apple Remote
// this was gleaned by reverse engineering the DACP calls to Itunes
                PlaylistNode node = new PlaylistNode();
                node.Miid = CURRENT_PLAYLIST_ID;
                node.Mper = (ulong)node.Miid;
                node.Minm = Environment.MachineName + " Library";
                node.Abpl = 1;
                node.Mimc = 1;
                playlistResponse.Mlcl.AddLast(node);
                node = new PlaylistNode();
                node.Miid = 99999998;
                node.Mper = (ulong)node.Miid;
                node.Minm = "Music";
                node.Aesp = 1;
                node.Aeps = 6;
                node.Mimc = 1;
                playlistResponse.Mlcl.AddLast(node);

Original comment by mellowaredev on 18 May 2011 at 10:54

GoogleCodeExporter commented 8 years ago
has anyone been able to test the latest Rhythmbox with TunesRemote+?

Original comment by mellowaredev on 7 Jun 2011 at 11:48

GoogleCodeExporter commented 8 years ago
Since no one has reported back I will close this ticket.

Original comment by mellowaredev on 24 Dec 2011 at 2:20