maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Maemo 5 / Fremantle (https://talk.maemo.org/forumdisplay.php?f=40)
-   -   Stuttering audio when multitasking? (https://talk.maemo.org/showthread.php?t=56945)

dushkin 2010-06-23 17:01

Stuttering audio when multitasking?
 
Hello there everyone,

I've seen this come up here and there in the darker corners of the interwebs, that some N900 users have stuttering audio issues.

I, myself, wanting to buy an N900 would like to know a bit more.

I'm specifically getting the N900 because I like to tinker with stuff, and I'm on old school Linux user.

Can anyone enlighten me on this issue?

Flandry 2010-06-23 17:10

Re: Stuttering audio when multitasking?
 
"Some" is probably an understatement. I'd wager most of those who use their N900 for FM radio, web radio, or local music playback have encountered this on multiple occasions.

It happens very frequently for me. I guess renicing apps might help but i haven't tried that. Basically, whenever i am using N900 while music is playing, i expect to have a few blips or stutters. It doesn't usually happen if it's just in my pocket.

dushkin 2010-06-23 17:19

Re: Stuttering audio when multitasking?
 
Well, is it a serious problem?

Does it happen during calls too, or when you're listening to music but not doing anything?

radiosw 2010-06-23 17:20

Re: Stuttering audio when multitasking?
 
This happens even with just the media player on but I am 2 updates behind thanks to vodafone so not sure if pr1.2 helps?

woodyear99 2010-06-23 17:29

Re: Stuttering audio when multitasking?
 
PR 1.2 made it worse for me, made this video last month......also happens when web browsing, viewing photos etc.

http://www.youtube.com/watch?v=IKd7Gko2dak

kylepsp 2010-06-23 17:29

Re: Stuttering audio when multitasking?
 
happens constantly with me, especially when web browsing

fnordianslip 2010-06-23 17:34

Re: Stuttering audio when multitasking?
 
Audio handling seems to be a big let down, IMHO.

woody14619 2010-06-23 17:35

Re: Stuttering audio when multitasking?
 
I've only had this issue when I get something that spikes the processor, or tries to play a compeating sound, while listing to audio. A good example would be an incoming MMS message, or gPodder doing a poorly timed sync/update. :) I have the same issue on my computer at work though, so it's not surprising. Any time you heavily load a system doing audio playback you have a chance of causing skipping.

I've read some threads (search is your friend!) here that people have pretty much eliminated this by renicing some of the processes around playback and/or by overclocking. It just hasn't been worth the effort for me to bother with, since it doesn't happen often, and isn't that annoying to me when it does.

Oh: And I've never had it happen during a call with call audio. I've only ever had it happen with audio playback from the device (mp3s, etc).

pycage 2010-06-23 17:45

Re: Stuttering audio when multitasking?
 
There are two kinds of stuttering. The first happens with non-Nokia applications when, e.g., locking the screen or rotating the phone. Nokia thought it would be very clever to actually freeze all applications it doesn't trust (i.e. all except those made by Nokia and explicitly whitelisted in the OS) to ensure smooth transitions. It turned out to be not so clever after all, esp. since the GStreamer sound pipe is prone to die during freezing (causing e.g. FM-Radio to sometimes not playing anything after thawing, until you pull and reinsert the headphones to force a restart of the GStreamer pipe).

The second kind of stuttering affects all applications. The pulseaudio sound system is a resource hog, and along with other resource hogs that kick in from time to time without being asked for (like hildon-thumbnailerd) it causes stuttering. Renicing pulseaudio to a low level below zero helps to relieve this a bit.

Nokia should've done their research with renicing and kernel parameters, but obviously they haven't.

zimon 2010-06-23 18:01

Re: Stuttering audio when multitasking?
 
Maybe Apple and Steve Jobs are just right in this issue. Multitasking is not suitable for mobile devices with these current hardware resources - still.

I had serious problems during this week trying to just use Mappero and µBrowser at the same time during visiting a foreign city abroad. (PR 1.2)
Yet trying to take photos while those two are in the background, will make N900 unresponsible and a few times I had to reboot by removing the battery. It is irritating!

N900 does not have enough RAM-memory perhaps, or kernel is jut not suitable. It shouldn't (thinking it is a Linux system) go so dead just multitasking 3 applications!

Nokia Maps was useless, as it cannot route or find locations offline and even if routes and locations are found when connected to WLAN, one cannot save them anyway, so you will probably loose them when going outside the WLAN zone. Mappero would work, but it is perhaps too big program to be usable in N900 - one wants to take photos also while tracking.

I must say, I was very dissapointed during this week. Should have taken my old N95 with me instead.

Joorin 2010-06-23 18:01

Re: Stuttering audio when multitasking?
 
Quote:

Originally Posted by pycage (Post 726618)
The first happens with non-Nokia applications when, e.g., locking the screen or rotating the phone. Nokia thought it would be very clever to actually freeze all applications it doesn't trust (i.e. all except those made by Nokia and explicitly whitelisted in the OS) to ensure smooth transitions.

How is this done? To "freeze" an application, you need to not schedule it for time in the processor and that sounds like a very dodgy hack in the kernel.

Laughing Man 2010-06-23 18:06

Re: Stuttering audio when multitasking?
 
Quote:

Originally Posted by zimon (Post 726637)
Maybe Apple and Steve Jobs are just right in this issue. Multitasking is not suitable for mobile devices with these current hardware resources - still.

I had serious problems during this week trying to just use Mappero and µBrowser at the same time during visiting a foreign city abroad. (PR 1.2)
Yet trying to take photos while those two are in the background, will make N900 unresponsible and a few times I had to reboot by removing the battery. It is irritating!

N900 does not have enough RAM-memory perhaps, or kernel is jut not suitable. It shouldn't (thinking it is a Linux system) go so dead just multitasking 3 applications!

Nokia Maps was useless, as it cannot route or find locations offline and even if routes and locations are found when connected to WLAN, one cannot save them anyway, so you will probably loose them when going outside the WLAN zone. Mappero would work, but it is perhaps too big program to be usable in N900 - one wants to take photos also while tracking.

I must say, I was very dissapointed during this week. Should have taken my old N95 with me instead.

I've found that multi-tasking when anything heavy is downloading (Mappero, Gpodder downloads, FeedingIt if your having it download images) is impossible. My favorite thing to do at night is to have Gpodder and FeedingIt update at the same time to see how slow the system crawls (haha).

Which makes sense if you think about all the hardware that's needed when downloading things. But it's fine for me when I use apps (not games) or browse the web. I only get skipping when using panucci.

jackie_jagger 2010-06-23 18:08

Re: Stuttering audio when multitasking?
 
I brought up a topic regarding same a few days back:
It'd be fair to merge em I guess !
http://talk.maemo.org/showthread.php?t=56804

leetut 2010-06-23 18:10

Re: Stuttering audio when multitasking?
 
audio has never skipped for me since pr1.2
it happened all the time previously
media player now works 99% of the time
but..
email still refreshes when it feels like it (usually never!)
i often hear ringtones i have not set
and call volume still drops to almost silent after approx 2mins
apart from that the phone is awesome

stlpaul 2010-06-23 18:37

Re: Stuttering audio when multitasking?
 
Mine stutters all the time, in playing local files, internet radio, FM radio... I think it has gotten worse since PR1.2 but it was always bad.

It especially stutters when first starting to play a file. First 5-10 seconds of the song are basically ruined.

When listening to audio & some background task happens like checking email, it stutters too. And if you're really doing any real multitasking like web browsing or something just forget about it. It is bad.

JorgeFX 2010-06-23 18:58

Re: Stuttering audio when multitasking?
 
open a terminal, login as root and write:
killall pulseaudio

This help cause it restart the audio process, but after PR1.2 this have to be done very often for me, and it doesn't seem to be just a pulseadio anymore

Lullen 2010-06-23 19:15

Re: Stuttering audio when multitasking?
 
Quote:

Originally Posted by zimon (Post 726637)
Maybe Apple and Steve Jobs are just right in this issue. Multitasking is not suitable for mobile devices with these current hardware resources - still.

I think not, the problem I think (for me at least) is that the OS is buggy. Let say you listen to 5 songs, 2 of them lag a bit, for me it does not matter if I have none or a few apps running but the application handler is always causing a big slow down for some reason. And to go on with that it's nokia that sucks just look at the browser, it was perfect(bit slow tho) on the relese PR but on PR 1.2 when nokia made it faster it sometimes do not open web pages, make the whole phone unusable etc etc.

To continue this off-topic post: Maemo is open-source right? From what I've heard the community helps to fix bugs, is this then implanted when nokia release their new PR? Is it not possible for the community to release new updates on the maemo-core?

pycage 2010-06-23 19:37

Re: Stuttering audio when multitasking?
 
Quote:

Originally Posted by Joorin (Post 726639)
How is this done? To "freeze" an application, you need to not schedule it for time in the processor and that sounds like a very dodgy hack in the kernel.

On Unix you can send a SIGSTOP to a process to freeze it, and a SIGCONT to thaw.
For example
Code:

killall -STOP hildon-thumbnailerd
would freeze the hildon-thumbnailer, and
Code:

killall -CONT hildon-thumbnailerd
would thaw it.
The kill commands don't kill processes but send signals, with the default being the ABORT signal.

kazuki 2010-06-23 19:51

Re: Stuttering audio when multitasking?
 
i use the native media player by nokia. it never stuttered until pr 1.2

woody14619 2010-06-23 20:06

Re: Stuttering audio when multitasking?
 
Quote:

Originally Posted by zimon (Post 726637)
I had serious problems during this week trying to just use Mappero and µBrowser

So, you're actively doing GPS, while browsing the internet, AND taking pictures, and are surprised that it's laggy and stuttering? Most laptops (or desktop PCs) would have problems doing all that at once! That's expecting an awful lot out of a pocket-sized device, no?

If you're just playing audio, it does well. If you want to browse the web, while GPS navigating, and listening to MP3s, and taking a picture, then go get a... wait.. nothing else can do all that at once either. Go buy a GPS, a digital camera and a cheep mp3 player, then use the N900 to browse. It'll all be much happier that way. :)

dbrodie 2010-06-23 20:09

Re: Stuttering audio when multitasking?
 
I was also very disappointed this week. I use the audio and FM transmitter regularly in the car. I finally got around to try and use mappero. Boy is that app CPU hungry. The whole device kept on freezing and unfreezing and the audio wouldn't stop stuttering.
Ended up having to powerbutton+end current task.

Laughing Man 2010-06-23 20:10

Re: Stuttering audio when multitasking?
 
Actually it is possible to do GPS navigation, music, and browsing the web at the same time with no stuttering audio. Though opening the camera usually causes the problem.

Joorin 2010-06-23 21:03

Re: Stuttering audio when multitasking?
 
Quote:

Originally Posted by pycage (Post 726749)
On Unix you can send a SIGSTOP to a process to freeze it, and a SIGCONT to thaw.
For example
Code:

killall -STOP hildon-thumbnailerd
would freeze the hildon-thumbnailer, and
Code:

killall -CONT hildon-thumbnailerd
would thaw it.
The kill commands don't kill processes but send signals, with the default being the ABORT signal.

Oh, I totally misinterpreted "freeze an application".

How do you know that Nokia added/uses this freezing of processes while rotating?

qwerty12 2010-06-23 21:07

Re: Stuttering audio when multitasking?
 
Quote:

Originally Posted by Joorin (Post 726840)
How do you know that Nokia added/uses this freezing of processes while rotating?

https://bugs.maemo.org/show_bug.cgi?id=6203

OHM is open-source, Nokia's plugins for it are not. Go figure.

As for the sound stuff, https://bugs.maemo.org/show_bug.cgi?id=6694 is our best lead due to Nokia's silence and the fact that it's all implemented in closed source stuff.

xomm 2010-06-23 21:30

Re: Stuttering audio when multitasking?
 
Thread moved to Maemo 5 / Fremantle.

Personally it only happens to me when doing something CPU intensive at the same time.

zimon 2010-06-23 23:56

Re: Stuttering audio when multitasking?
 
Quote:

Originally Posted by woody14619 (Post 726774)
So, you're actively doing GPS, while browsing the internet, AND taking pictures, and are surprised that it's laggy and stuttering? Most laptops (or desktop PCs) would have problems doing all that at once! That's expecting an awful lot out of a pocket-sized device, no?

If you're just playing audio, it does well. If you want to browse the web, while GPS navigating, and listening to MP3s, and taking a picture, then go get a... wait.. nothing else can do all that at once either. Go buy a GPS, a digital camera and a cheep mp3 player, then use the N900 to browse. It'll all be much happier that way. :)

Well OK, that IS a lot to ask, but still I think OS should not get to state where it is unresponsive to any user input for several minutes. Once I waited over 20 minutes to get control back to my device, but nothing worked and battery had to be taken out to make N900 reboot. Other times I just waited few minutes because I was sure it will never recover as in this first time.

The common thing in these lock ups were Mappero. It maybe is just too resource hungry program for N900, but it is the same time necessary because Nokia Maps is so bad in offline use.

With N95 I used to be able to use Nokia Maps with navigation, web browser and camera all at the same time without needing to reboot. And I thought Symbian should be worse than Linux in multitasking.

OS should not get unresponsive due to some userspace application; Mappero in this case.
Ok, Mappero should be fixed also so it wouldn't take OS down.

Laughing Man 2010-06-24 00:06

Re: Stuttering audio when multitasking?
 
Mappero is rather aggressive with downloading maps. I guess the only solution to avoid non-response is to be more aggressive about asking to close apps. That or if you really want it, find a way to implement Android task killing.

dushkin 2010-06-24 03:40

Re: Stuttering audio when multitasking?
 
In short, would you guys still recommend N900 as a good overall phone?

noipv4 2010-06-24 04:19

Re: Stuttering audio when multitasking?
 
It's an awesome phone dushkin.
Seriously I have never seen the hardware so exposed to the OS previously.
Just wish the baseband code were open source. Rapuyama... nice name :P

Joorin 2010-06-24 05:47

Re: Stuttering audio when multitasking?
 
Quote:

Originally Posted by qwerty12 (Post 726848)

This one is talked about as fixed in PR1.1 in the comments with reports of it actually working, are non-whitelisted processes still stopped while doing other things?

rich c 2010-06-24 05:57

Re: Stuttering audio when multitasking?
 
Quote:

Originally Posted by dushkin (Post 727152)
In short, would you guys still recommend N900 as a good overall phone?

Going back to your OP & the reason you say you want an N900, yes deffo a great phone for tinkering with.

Tedri Mark 2010-06-24 06:12

Re: Stuttering audio when multitasking?
 
Yep. Amazing fone..

lifenexus 2010-06-24 06:21

Re: Stuttering audio when multitasking?
 
i posted a solution a while back. edit the following file
/etc/pulse/daemon.conf
change value of nice level to -20.
save and reboot

gkuenning 2010-06-24 06:56

Re: Stuttering audio when multitasking?
 
Thanks, lifenexus. Just did that edit; it'll be interesting ot see if/how much it helps.

I always get a stutter when I leave home and get out of WLAN range. But the worst was when I was moving a bunch of files onto the phone over WLAN via sshfs (not the most efficient approach, but very handy for my needs). The music first stuttered, then stopped completely, playing one fractional-second snippet perhaps every minute. The misbehavior lasted until about 5-10 minutes AFTER the download finished. Wow! I'll never do that again.

wongdong 2010-06-24 07:25

Re: Stuttering audio when multitasking?
 
I still recommend the phone. And look at it this way: For this price
you can not get another phone which can

a) ...multitask
b) ...do pretty much everything you want
c) ...has that good a community
d) ...is heavy enough to beat someone to death, in case you get robbed.

For the stuttering. Yes it happens, but its not annoying IMHO. When i put it in my car, start up media player, connect to UMTS, Skype, ICQ, Facebook and MSN and simultaneously launch the navigation app (yes i do these things), then I have little trouble accepting some sound stuttering.

Cthulhu 2010-06-24 12:18

Re: Stuttering audio when multitasking?
 
I don't know if this has been posted in this thread before, so apologies if this is old news.

It appears that a bug has recently been fixed regarding this issue: Bug #7190: music stutters while multi-tasking, especially browsing web

Besides, I agree with the others saying this:
IMHO this is the best phone money can buy ATM. Despite it's short-comings it just does so much more than competing products.

lifenexus 2010-06-24 12:56

Re: Stuttering audio when multitasking?
 
Quote:

Originally Posted by gkuenning (Post 727260)
Thanks, lifenexus. Just did that edit; it'll be interesting ot see if/how much it helps.

I always get a stutter when I leave home and get out of WLAN range. But the worst was when I was moving a bunch of files onto the phone over WLAN via sshfs (not the most efficient approach, but very handy for my needs). The music first stuttered, then stopped completely, playing one fractional-second snippet perhaps every minute. The misbehavior lasted until about 5-10 minutes AFTER the download finished. Wow! I'll never do that again.

sure buddy. let me know how it goes. it works for me now. what "nice" in linux means is, how nice should this process be to other processes. its from -20 to 20. the smaller number means, pulse audio is not be nice to other processes and use its share of the cpu most! and u set it to -20 so its good for helping pulse audio run well

Flandry 2010-06-24 14:26

Re: Stuttering audio when multitasking?
 
Quote:

Originally Posted by Cthulhu (Post 727547)
I don't know if this has been posted in this thread before, so apologies if this is old news.

It appears that a bug has recently been fixed regarding this issue: Bug #7190: music stutters while multi-tasking, especially browsing web

Besides, I agree with the others saying this:
IMHO this is the best phone money can buy ATM. Despite it's short-comings it just does so much more than competing products.

Thanks. Let me summarize that bug tracker to save others time:
User1: My n900 audio stutters alot when browsing and doing other things
User2: Mine too!
User3: Some fixes are coming in PR1.2
User4-5: PR1.2 made it worse
Klapper: Yes, we know. Fixed in pulseaudio version xxxxx. No, you can't get it before it's put into a major PR, which may not be the next one. No, there's no information on what was actually done so you can guess if this is likely to fix the problem you have or implement it yourself in advance.

Taomyn 2010-06-24 14:42

Re: Stuttering audio when multitasking?
 
I certainly noticed this get worse from PR1.1.1 to PR1.2 especially as I mainly use gpodder + panucci - really getting fed up of losing parts of the conversation in a podcast when an email comes in.

I've mitigated the issue somewhat by using the tweaked kernel that bumps the clock speed up to 850, but it's still not perfect. I also hear that the next release of Panucci for the N900 will renable the option to use the native audio decoder instead of it's own which is meant to be less buggy. That may help.

What I do know is that using the native media player does at least put the phone in a mode where alerts get changed to a simple background beep rather than the full alert tone set for the profile. this certainly would help panucci if it did the same.

ndi 2010-06-24 17:11

Re: Stuttering audio when multitasking?
 
Quote:

Originally Posted by Flandry (Post 727681)
Thanks. Let me summarize that bug tracker to save others time:

Which bug is that? :)

Ha. Well, mine stuttered like nuts on 1.0 and 1.1, still does in 1.2. As long as it isn't usable as background audio, does it matter by how much?

My worst offender is audio stutter while browsing the web. Two light activities and it should be clear that audio should come first. Still borks.

Anyway, I just wanted to say that OC to 900 MHz helps none. It's not a matter of power.


All times are GMT. The time now is 05:24.

vBulletin® Version 3.8.8