Thanks for the idea. I don't think it's a slow processor though-- it's an Intel Atom 1.6 Ghz-- well yeah, not the fastest available but it's a proper i686 architecture desktop processor. And it is a desktop computer with 1Gb of ram. There's definitely something odd going on with ALSA though. I reinstalled Linux from scratch and set it up with a 1.3 version-- just like the first PC that works well but that doesn't help and it still has the same symptoms. I did find a workaround though: if I launch pjsua with these settings: --snd-clock-rate=8000 --snd-auto-close=0 --auto-answer=200 --log-level=6 --log-file=fname --playback-dev=5 (--playback-dev=5 can be a device number with anything between 1 and 8 but not the default -1 or 0) then it seems to be working fine-- picks up the call immediately without waiting for the sound to initialize and it works. However I haven't got a clue at what sample rate does it play that sound now. I must have installed something on the first PC that fixed the ALSA issue and made it work at 8kHz and it's obviously not present on the current one. I've been experimenting with all sorts of stuff prior PJSUA on the first PC-- libjingle, tapioca, pidgin, ekiga, freeswitch, asterisk, Ice, farsight, mumble, telepathy and qt. God only knows now which of those installed a codec (or sorted out ALSA somehow) that made it work on the first PC. Archie > Date: Mon, 24 Aug 2009 21:57:21 +0100 > From: bennylp@xxxxxxxxx > To: pjsip at lists.pjsip.org > Subject: Re: painfully slow loading of PCM at 44100/1/20ms? > > 2009/8/23 Arthur Elksnis <archie1983 at hotmail.co.uk>: > > Hi, > > Sorry if you receive this the second time-- I hadn't registered yet when > > I sent this email first time. > > > > I have an OpenSuse 11 system-- all latest updates. It is an Intel Atom > > motherboard and the the sound device is: ALC662 Analog : ALC662 Analog : > > playback 1 : capture 1 (contents of "/proc/asound/pcm"). When I start PJSUA > > (v.1.4)-- it seems to be working all fine but when I try to initiate a call > > (doesn't matter whether it's incoming or outgoing), it gives these two > > messages: > > > > [quote] > > 20:06:29.072 pjsua_media.c Opening sound device PCM at 16000/1/20ms > > 20:06:29.074 pjsua_media.c Opening sound device PCM at 44100/1/20ms > > [/quote] > > > > and sits there for at least a minute before finally starts playing the > > incoming stream. I've tried it with several other options like: > > > > [quote] > > --snd-clock-rate=8000 --snd-auto-close=0 --auto-answer=200 > > [/quote] > > > > and: --dis-codec=PCM at 8000 > > > > but it's all the same except the first line is shows the frequency that I > > specify: > > > > [quote] > > 20:06:29.072 pjsua_media.c Opening sound device PCM at 8000/1/20ms > > 20:06:29.074 pjsua_media.c Opening sound device PCM at 44100/1/20ms > > [/quote] > > > > The root cause I think is because your sound device does not support > sampling rate 8Khz or 16Khz, and because of this, PJSUA-LIB tries to > open it in other sampling rates. That's what happening above. > > > > It seems that it really doesn't like "PCM at 44100/1/20ms" and loads it > > extremely slow and anything else (e.g. PCM at 8000/1/20ms) can't be loaded at > > all. > > > > That could happen with relatively slow processor, and especially if > you enable things like echo canceller. Even without it, your processor > would be working hard already with sample rate conversion between > 44.1Khz and the default native 16Khz used throughout pjmedia. > > > > I have a PJSUA version 1.3 running on another OpenSuse machine and that one > > works fine: > > > > the only difference that I noticed is that when I finish the call, the old > > and working version prints out this: > > > > [quote] > > 22:38:08.206 pjsua_media.c Media session for call 0 is destroyed > > 22:38:08.206 pjsua_media.c Closing sound device after idle for 0 seconds > > 22:38:08.206 pjsua_media.c Closing default sound playback device and > > default sound capture device > > [/quote] > > > > while the new, non-working version prints this: > > > > [quote] > > 22:41:41.912 pjsua_media.c Media session for call 0 is destroyed > > 22:41:41.912 pjsua_media.c Closing sound device after idle for 0 seconds > > 22:41:41.912 pjsua_media.c Closing HDA Intel: ALC662 Analog (hw:0,0) > > sound playback device and HDA Intel: ALC662 Analog (hw:0,0) sound capture > > device > > [/quote] > > > > It could be that between the version upgrade your sound device > settings have changed, and now it looks like ALSA is picked up by > default. I don't recall we made changes to pjmedia-audiodev in 1.4. > > Cheers > Benny > > > > Thanks in advance, > > Arthur > > ________________________________ > > Internet Explorer 8 - accelerate your Hotmail. Download Internet Explorer 8 > > _______________________________________________ > > Visit our blog: http://blog.pjsip.org > > > > pjsip mailing list > > pjsip at lists.pjsip.org > > http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org > > > > > > _______________________________________________ > Visit our blog: http://blog.pjsip.org > > pjsip mailing list > pjsip at lists.pjsip.org > http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org _________________________________________________________________ Windows Live Messenger: Celebrate 10 amazing years with free winks and emoticons. http://clk.atdmt.com/UKM/go/157562755/direct/01/ -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20090825/247f18b6/attachment.html>