Subsonic For ICS Android 4.0

General discussions.

Moderator: moderators

Re: Subsonic For ICS Android 4.0

Postby NTolerance » Tue May 15, 2012 10:17 pm

I'd like to thank all of the devs for their work to update the Subsonic Android client. I'm running jsr's build and it works great for me.

Does anyone know if it's trivial to set different audio buffer sizes for the Android client during playback? I'm not a developer, but I like to test things and I've been running down a stuttering playback issue that affects at least the Galaxy Nexus, but possibly all Android 4.0 devices. See my detailed post here:

viewtopic.php?f=2&t=4109&start=150#p40882
NTolerance
 
Posts: 33
Joined: Mon Aug 22, 2011 5:13 pm

Re: Subsonic For ICS Android 4.0

Postby disgustipated » Tue May 15, 2012 10:44 pm

hi ntolerance
check my post a page or two back, i mention the hiperformance powersaving which is most likely the cause of the stutter youre seeing.
viewtopic.php?f=5&t=8497&start=120#p40598

check ttabal's build that he put that into, a post after mine


after reading your post that sounds like something else.... i used to get this on the early haxzamatic builds usually in low signal areas where the download wasnt very fast, i havent gotten it too much lately though
Last edited by disgustipated on Tue May 15, 2012 10:47 pm, edited 1 time in total.
disgustipated
 
Posts: 96
Joined: Wed Jan 26, 2011 4:18 pm
Location: US

Re: Subsonic For ICS Android 4.0

Postby ttabbal » Tue May 15, 2012 10:46 pm

disgustipated wrote:hi ntolerance
check my post a page or two back, i mention the hiperformance powersaving which is most likely the cause of the stutter youre seeing.
viewtopic.php?f=5&t=8497&start=120#p40598

check ttabal's build that he put that into, a post after mine



The AVRCP build has it as well. See if it helps... changing the buffering might help as well, but I haven't looked into that.
ttabbal
 
Posts: 33
Joined: Thu May 27, 2010 8:57 pm

Re: Subsonic For ICS Android 4.0

Postby NTolerance » Tue May 15, 2012 11:38 pm

I've tested ttabal's build and unfortunately it has no effect for me.

In my case the screen is typically on while I'm playing music, and it occurs whether using a 54Mbit WLAN or on Verizon's 3G/4G LTE networks. In the test case from my earlier post I'm not using the network at all. I'm playing "pinned" tracks from local disk and I'm also writing files to the same local disk concurrently.

I think that the problem is more likely to occur when you're on a good-performing network like WLAN or 4G LTE where your throughput is good and relatively large files are being written to disk. The music player may be waiting on IO and isn't able to read the file into memory quickly enough to ensure smooth playback. So this is where more buffering could come into play.

Thanks for the builds though. I will continue to help the devs test as more builds are released.
NTolerance
 
Posts: 33
Joined: Mon Aug 22, 2011 5:13 pm

Re: Subsonic For ICS Android 4.0

Postby wesssider » Wed May 16, 2012 8:49 pm

jsr wrote:I took haxzamatic's latest source on git and compiled it. It is located at http://www.ragtop.org/upload/subsonic/Subsonic-05-06-2012.apk. Note that you'll have uninstall and re-install since the keys the APK is signed with are different.

This version includes lighter colored play/pause buttons, notification controls, a better widget, and maybe other stuff. All credit for the new features goes to haxzamatic, all I did was compile the code. I've lightly tested this version, but there might be bugs.
...


jsr, thank you for compiling! Looks good.
User avatar
wesssider
 
Posts: 46
Joined: Thu Aug 05, 2010 2:32 pm

Re: Subsonic For ICS Android 4.0

Postby archrival » Fri May 18, 2012 5:22 pm

Hey all,

I forked haxzamatic's source on github and added a buffer length and network timeout in Settings. The buffer length is the number of seconds to buffer before playback will begin (actually just a calculation of bitrate * buffer length). Previously there was a hard coded value of 5 seconds. This is now an array of values: 2, 5, 8, 10, 12, 15, 20, 30 seconds

In addition I added a network timeout setting. Previously there wasn't a way to set this and the default value was used. This is also an array of values: 15, 30, 45, 60, 75, 90, 105, 120 seconds

I personally would rather take a little longer for the song to start playing if it means it will not stop later to buffer some more. So I up my buffer to 10 or 15. As for the network timeout, I have a very large folder that would always fail to load. I set my timeout to 90 seconds and it solves my problem.

Hopefully this is of use to some people.

Download APK here:
https://github.com/archrival/Subsonic-Android/downloads

Source here:
https://github.com/archrival/Subsonic-Android
archrival
 
Posts: 173
Joined: Wed May 26, 2010 6:02 am

Re: Subsonic For ICS Android 4.0

Postby JBDive » Sat May 19, 2012 7:22 am

OK I know I should be asleep and maybe that's why I am not getting this but where on earth are the settings menu? I'm on a Toshiba Thrive and stuck trying to get into inputting my server info. Had stock app running fine.
JBDive
 
Posts: 23
Joined: Thu Oct 08, 2009 4:04 am

Re: Subsonic For ICS Android 4.0

Postby Maes » Sat May 19, 2012 7:51 am

ttabbal wrote:Well... I managed to apply that patch... It loads up OK. Anyone want to test it with hardware? I don't think I have anything that can do it.


I have been using the android subsonic app on ICS in combination with a scala rider g9 headset for my motorcycle helmet. The 05-06-2012 build has very bad compatibility with the AVRCP protocol. The headset is able to stop the music on the app, but it can not make it play again. This is a problem because it means I have to stop on the side of the road to press the play button on my phone.
I have tested the setting with the app provided in the quoted post above and it works a little bit better but it's not perfect: The app is able to play music on the bluetooth play command and can even skip and rewind to next and previous songs, but can not make the music stop. This means that when I get a call on my headset the music will keep playing through it, it's very annoying.

Could anyone be so kind to release a version with the correct AVRCP code? It would be a tremendous help for me so I can happily listen to music on my bike :)
Maes
 
Posts: 16
Joined: Sat May 19, 2012 7:37 am

Re: Subsonic For ICS Android 4.0

Postby ttabbal » Sat May 19, 2012 1:15 pm

Maes wrote:
ttabbal wrote:Well... I managed to apply that patch... It loads up OK. Anyone want to test it with hardware? I don't think I have anything that can do it.


I have been using the android subsonic app on ICS in combination with a scala rider g9 headset for my motorcycle helmet. The 05-06-2012 build has very bad compatibility with the AVRCP protocol. The headset is able to stop the music on the app, but it can not make it play again. This is a problem because it means I have to stop on the side of the road to press the play button on my phone.
I have tested the setting with the app provided in the quoted post above and it works a little bit better but it's not perfect: The app is able to play music on the bluetooth play command and can even skip and rewind to next and previous songs, but can not make the music stop. This means that when I get a call on my headset the music will keep playing through it, it's very annoying.

Could anyone be so kind to release a version with the correct AVRCP code? It would be a tremendous help for me so I can happily listen to music on my bike :)


It's hard to say what would be "correct" here.. It seems various headsets use slightly different commands.. If I were to create a debug build, would you be able to test with your headset and provide a log? What buttons does your headset have for control? If you press play again, does it pause?
ttabbal
 
Posts: 33
Joined: Thu May 27, 2010 8:57 pm

Re: Subsonic For ICS Android 4.0

Postby JBDive » Sat May 19, 2012 1:47 pm

OK guess I will have to wait until Toshiba pushes ICS to the Thrive for this updated player to work. I did like what I saw, back to app store version.
JBDive
 
Posts: 23
Joined: Thu Oct 08, 2009 4:04 am

Re: Subsonic For ICS Android 4.0

Postby ttabbal » Sat May 19, 2012 2:01 pm

JBDive wrote:OK I know I should be asleep and maybe that's why I am not getting this but where on earth are the settings menu? I'm on a Toshiba Thrive and stuck trying to get into inputting my server info. Had stock app running fine.


Top right, three dots. That should pop up the menu.. It's an ICS thing.
ttabbal
 
Posts: 33
Joined: Thu May 27, 2010 8:57 pm

Re: Subsonic For ICS Android 4.0

Postby Maes » Sat May 19, 2012 2:06 pm

ttabbal wrote:
Maes wrote:
ttabbal wrote:Well... I managed to apply that patch... It loads up OK. Anyone want to test it with hardware? I don't think I have anything that can do it.


I have been using the android subsonic app on ICS in combination with a scala rider g9 headset for my motorcycle helmet. The 05-06-2012 build has very bad compatibility with the AVRCP protocol. The headset is able to stop the music on the app, but it can not make it play again. This is a problem because it means I have to stop on the side of the road to press the play button on my phone.
I have tested the setting with the app provided in the quoted post above and it works a little bit better but it's not perfect: The app is able to play music on the bluetooth play command and can even skip and rewind to next and previous songs, but can not make the music stop. This means that when I get a call on my headset the music will keep playing through it, it's very annoying.

Could anyone be so kind to release a version with the correct AVRCP code? It would be a tremendous help for me so I can happily listen to music on my bike :)


It's hard to say what would be "correct" here.. It seems various headsets use slightly different commands.. If I were to create a debug build, would you be able to test with your headset and provide a log? What buttons does your headset have for control? If you press play again, does it pause?


Thank you for your reply, I would be very happy to help you test these controls.
My headset has the ability to pause, play, skip forward and rewind music. \
The build I quoted in my last post is almost perfect, the headset is able to pause music as well as skip songs and rewind them, it's just the play command that's not working, if you would be able to fix this, we'd be all done!

I think it would be beneficial for you to know that when my headset STOPS the music on your build, the seeker goes back to the beginning of the song (so it's a stop rather than a pause, which is what i'd prefer, because the song would play all over again if you pressed play).

UPDATE: After some research it seems to me that the app is just listening to the wrong events given by ICS. I understand that google changed the bluetooth events in ICS so perhaps all you have to do is change the events the app listens to.
Maes
 
Posts: 16
Joined: Sat May 19, 2012 7:37 am

Re: Subsonic For ICS Android 4.0

Postby Maes » Sat May 19, 2012 2:37 pm

Small follow up on my last post:

If I choose to use the standard MP3-Player app every android phone has by default, all bluetooth controls work perfectly as they should, it is because of this I do not believe the headset is to blame.

Also I understand that all these bluetooth AVRCP devices have to follow a certain standard, so shouldn't they all use the same commands?
Maes
 
Posts: 16
Joined: Sat May 19, 2012 7:37 am

Re: Subsonic For ICS Android 4.0

Postby ttabbal » Sat May 19, 2012 2:40 pm

Maes wrote:
I think it would be beneficial for you to know that when my headset STOPS the music on your build, the seeker goes back to the beginning of the song (so it's a stop rather than a pause, which is what i'd prefer, because the song would play all over again if you pressed play).

UPDATE: After some research it seems to me that the app is just listening to the wrong events given by ICS. I understand that google changed the bluetooth events in ICS so perhaps all you have to do is change the events the app listens to.



That version should be using the ICS events as well as the standard ones, so it should work with any version of Android. It should also have the patch that starts from the pause point rather than starting over. Just to get a baseline, this is the latest on my phone which is working great with the only headset I have, a Motorola S305. I'm on a Galaxy Nexus running AOKP b36 (4.0.4 based). I did remove the newer AVRCP stuff, but that should only affect sending metadata to a control device. Standard button controls are the same, well, should be the same. :D

I'll try to add some logging to the key events so I can see what your headset/ROM is sending to apps that are listening to the events.

Like most standards, there is always wiggle room, and the ROM could change things a bit as well, like Google did with ICS. I doubt it's the headset that's wrong, it's probably just that the key handling code is a little off and needs to be changed to be more compatible. It's finding out WHAT needs to be different that's the catch. There are probably docs for this stuff, but these groups like to charge a lot of money for them. So OSS guys like me can't afford them. And it could just be a bug. :D
ttabbal
 
Posts: 33
Joined: Thu May 27, 2010 8:57 pm

Re: Subsonic For ICS Android 4.0

Postby Maes » Sat May 19, 2012 2:42 pm

Thanks for providing me with a test build this quick, I'm at work now but I'll be home in 2 hours and testing this app is the first thing I'll do.

You mentioned that you made this app log what my headset sends to it, where is this log saved so I can post it on this forum?
Maes
 
Posts: 16
Joined: Sat May 19, 2012 7:37 am

PreviousNext

Return to General

Who is online

Users browsing this forum: No registered users and 7 guests