[pulseaudio-discuss] pacat sometimes produce no sound

Simon Deziel sdeziel at revolutionlinux.com
Wed Jun 25 06:48:42 PDT 2008


Hi all, 

I'm working for the Mille-xterm project (large scale LTSP) and I want to use PulseAudio to eventually use VoIP client in a thin client setup. My test script use a slightly modified version of pacat to simulate a 2-way conversation (playback/recording) and collect latency statistics. The custom version of the utility allow me to specify the buffer attributes of the PulseAudio server and output latency info in a more convenient manner for me (see below for an example of output). The argument "-l" set the stream's flags to PA_STREAM_INTERPOLATE_TIMING | PA_STREAM_AUTO_TIMING_UPDATE to minimize communication between client and server (taken from padsp.c). My script collect latency informations using different buffer parameters. Most of the times everything works fine but _sometimes_ pacat reports latency of 0 (like below) and no sound is played. This problem seems to be related to the stream's flag and is really random. When this occurs, I don't see anything special on the PulseAudio server running in debug. It does not depends on the buffer parameters I use because when I'm not using "-l" everything is 100% reliable. I'd like to know why this problem happens _only sometimes_ and if there is a way to fix it because using those flags produce less network traffic.

Thanks in advance.
Simon Deziel

# pacat_custom -v --rate 8000 --maxlength 282 --tlength 188 --prebuf 0 --minreq 16 -l -p $PLAY_FILE
Setting the stream's flags to :PA_STREAM_INTERPOLATE_TIMING | PA_STREAM_AUTO_TIMING_UPDATE
Opening a playback stream with sample specification 's16le 1ch 8000Hz'.
Connection established.
Using manual buffer parameters.
Stream successfully created.
Buffer metrics: maxlength=282, tlength=188, prebuf=0, minreq=14
Using sample spec 's16le 1ch 8000Hz', channel map 'mono'.
Connected to device alsa_output.hw_0 (0, not suspended).
9995 62245 40715 95840 140601 171508 204789 236490 291615 331276 362916 364716 396099 428174 365622 365116 395922 427274 482399 470167 0 0 0 0 0 40039 75209 5343 57593 109843 162093 202565 204249 235630 267825 299414 300872 331739 364443 395307 429397 428744 460317 515442 0 0 0 0 75524 127774 127774 0 10434 12469 67594 107229 141547 138326 171238 202572 204847 236446 266814 269381 299978 236333 268089 299689 301338 324444 333219 388219 428548 428414 459324 490914 524752 521943 0 0 12556 44142 75711 106179 109333 139617 172037 203582 235054 237469 268453 268451 235622 237296 269141 324266 363331 365059 420184 459031 517156 0 80958 Got signal, exiting.





More information about the pulseaudio-discuss mailing list