[nas] Re: debugging help: nas enabled mpg123 sounds slow and scratchy?
srp at tworoads.net
Fri Feb 28 14:47:55 MST 2003
Jon Trulson wrote:>
>>Greg A. Woods wrote:
>>>[ On Friday, February 28, 2003 at 10:45:23 (-0800), Scott Presnell wrote: ]
>>>>Subject: debugging help: nas enabled mpg123 sounds slow and scratchy?
>>I just now checked from host A, and with a different audio card,
>>I have the same audio quality issues running mpg123-nas from a remote
>>host, to my workstation where nasd is running, and the same if I reverse
>>the client and server hosts.
>>And now, unfortunately, to add to the story...
>>With some .wav files from host A to my workstation, auplay also shows
>>the same poor audio quality issues...
> To get this straight... You are getting these dropouts and
> samplerate problems with nasd no matter which machine it's on, and no
> matter what data you send to it?
> Is it only ssamplerate problems, or
> are you getting dropouts as well? Can you use auplay to send a 16b stereo
> wav to the nasd server? Is that messed up as well (local or remote)?
No, not quite: .wav's on the same machine seem OK,
some .wavs across machine, and all .mp3 (at 128kb/44100 Hz) (intra and
inter host) are poor quality
>>So now I'm thinking it's nasd... am I outside the expected performance
>>parameters of nasd?
> No - it should work just fine. What sound card are you using?
> Sometimes tuning the parameters in /etc/nas/nasd.conf can help (fragsize,
> numfrags, etc). On some audio hardware (an ISA soundblaster) I had to
> reduce the output samplerate to 22Khz to get acceptable performance (no
> dropouts). No problem with the PCI variants though - runs at full
> 44.1Khz, 16b stereo...
So here is what I have tried.
I played withg nasd.conf parameters to no avail.
I added a great deal of optimization to the compilation of nasd ("-O4
-mpentium -mieee-fp -fbuiltin -fomit-frame-pointer -funroll-all-loops
-ffast-math", instead of just "-O2"). but that didn't make a difference,
...8/16 bit didn't change things...
so I moved on to playing with sample rates, and found that I must use
less than 44100Hz, 42000Hz seems to be about the threshold intrahost,
about 38000 interhost. This is for a PCI audio card:
eap0 at pci2 dev 12 function 0: Ensoniq CT5880 CT5880C (rev. 0x02)
eap0: interrupting at irq 10
eap0: SigmaTel STAC9708 codec; 18 bit DAC, 18 bit ADC, Rockwell 3D
and for Frederick: the output of audioctl -a is below.
I played with blocksize and hi/lowat while a 44100 sample was playing
intrahost, but I could only make it worse :-(
Thanks for your comments.
More information about the Nas