pjsip audio problems - alsa

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

Having problems with alsa and pjsip.  Using the oss device /dev/dsp
things seem to work fine.  When I try and use alsa devices, it all falls
over in a pear-shaped heap.  I have been looking over the mailing list
and google for some time now and can't find a solution.  All alsa
devices (0-11 below) report the same error, while the oss device (12)
works fine.  If I need to RTFM, a nudge in the right direction would be
great.

 

Some additional info:

Originally tried the pjsip 1.4 release.  This would only show oss
devices, but would work fine with that.

Checked out the svn trunk today, built with ./configure && make dep &&
make

Ubuntu 9.04

Audio hardware as shown below

All alsa devices are working fine with other tools (aplay, arecord, etc)

 

--- output from auddemo

 

demo at demo-blacktop:~/apps/pjsip-trunk/pjsip-apps/bin/samples/i686-pc-lin
ux-gnu$ ./auddemo

 18:13:50.858 os_core_unix.c  pjlib 1.4-trunk for POSIX initialized

PortAudio sound library initialized, status=0

PortAudio host api count=2

Sound device count=13

Found 13 devices:

  0: PA [HDA Intel: STAC92xx Analog (hw:0,0)] (2/6)

  1: PA [HDA Intel: INTEL HDMI (hw:0,3)] (0/8)

  2: PA [front] (0/6)

  3: PA [surround40] (0/6)

  4: PA [surround41] (0/128)

  5: PA [surround50] (0/128)

  6: PA [surround51] (0/6)

  7: PA [surround71] (0/6)

  8: PA [hdmi] (0/8)

  9: PA [headset] (1/1)

 10: PA [sco] (1/1)

 11: PA [dmix] (0/2)

 12: PA [/dev/dsp] (16/16)

 

Audio demo menu:

-------------------------------

  l                        List devices

  i ID                     Show device info for device ID

  t RID PID CR PTIM [CH]   Perform test on the device:

                             RID:  record device ID (-1 for no)

                             PID:  playback device ID (-1 for no)

                             CR:   clock rate

                             PTIM: ptime in ms

                             CH:   # of channels

  r RID [FILE]             Record capture device RID to WAV file

  p PID [FILE]             Playback WAV file to device ID PID

  d [RLAT PLAT]            Get/set sound device latencies (in ms):

                             Specify no param to get current latencies
setting

                             RLAT: record latency (-1 for default)

                             PLAT: playback latency (-1 for default)

  v                        Toggle log verbosity

  q                        Quit

 

Enter selection: p 0 /home/demo/apps/pjsip-trunk/input.8.wav

File player '/home/demo/apps/pjsip-trunk/input.8.wav' created:
samp.rate=8000, ch=1, bufsize=4KB, filesize=67KB

PA message: Expression 'SetApproximateSampleRate( pcm, hwParams, sr )'
failed in 'src/../../../portaudio/src/hostapi/alsa/pa_linux_alsa.c',
line: 1291

 

PA message: Expression 'PaAlsaStreamComponent_InitialConfigure(
&self->playback, outParams, self->primeBuffers, hwParamsPlayback,
&realSr )' failed in
'src/../../../portaudio/src/hostapi/alsa/pa_linux_alsa.c', line: 1865

 

PA message: Expression 'PaAlsaStream_Configure( stream, inputParameters,
outputParameters, sampleRate, framesPerBuffer, &inputLatency,
&outputLatency, &hostBufferSizeMode )' failed in
'src/../../../portaudio/src/hostapi/alsa/pa_linux_alsa.c', line: 1986

 

Error opening the sound device: Invalid sample rate (err=469996)

 

--- output from pjsip w/log level 5 (default alsa device)

 

 17:00:53.886 sip_endpoint.c  Module "mod-pjsua-log" registered

 17:00:53.886 sip_endpoint.c  Module "mod-tsx-layer" registered

 17:00:53.886 sip_endpoint.c  Module "mod-stateful-util" registered

 17:00:53.886 sip_endpoint.c  Module "mod-ua" registered

 17:00:53.886 sip_endpoint.c  Module "mod-100rel" registered

 17:00:53.886 sip_endpoint.c  Module "mod-pjsua" registered

 17:00:53.886 sip_endpoint.c  Module "mod-invite" registered

 17:00:54.001       pa_dev.c  PortAudio sound library initialized,
status=0

 17:00:54.001       pa_dev.c  PortAudio host api count=2

 17:00:54.001       pa_dev.c  Sound device count=13

 17:00:54.001          pjlib  select() I/O Queue created (0x89267e4)

 17:00:54.001   conference.c  Creating conference bridge with 254 ports

 17:00:54.024 sip_endpoint.c  Module "mod-evsub" registered

 17:00:54.024 sip_endpoint.c  Module "mod-presence" registered

 17:00:54.024        evsub.c  Event pkg "presence" registered by
mod-presence

 17:00:54.024 sip_endpoint.c  Module "mod-refer" registered

 17:00:54.024        evsub.c  Event pkg "refer" registered by mod-refer

 17:00:54.024 sip_endpoint.c  Module "mod-pjsua-pres" registered

 17:00:54.024 sip_endpoint.c  Module "mod-pjsua-im" registered

 17:00:54.024 sip_endpoint.c  Module "mod-pjsua-options" registered

 17:00:54.024   pjsua_core.c  1 SIP worker threads created

 17:00:54.034   pjsua_core.c  pjsua version 1.4-trunk for
i686-pc-linux-gnu initialized

 17:00:54.034 sip_endpoint.c  Module "mod-default-handler" registered

 17:00:54.035   pjsua_core.c  SIP UDP socket reachable at
10.126.10.41:5060

 17:00:54.035   udp0x8937138  SIP UDP transport started, published
address is 10.126.10.41:5060

 17:00:54.035    pjsua_acc.c  Account <sip:10.126.10.41:5060> added with
id 0

 17:00:54.035    tcplis:5060  SIP TCP listener ready for incoming
connections at 10.126.10.41:5060

 17:00:54.035    pjsua_acc.c  Account
<sip:10.126.10.41:5060;transport=TCP> added with id 1

 17:00:54.035  pjsua_media.c  RTP socket reachable at 10.126.10.41:4000

 17:00:54.035  pjsua_media.c  RTCP socket reachable at 10.126.10.41:4001

 17:00:54.036  pjsua_media.c  RTP socket reachable at 10.126.10.41:4002

 17:00:54.036  pjsua_media.c  RTCP socket reachable at 10.126.10.41:4003

 17:00:54.036  pjsua_media.c  RTP socket reachable at 10.126.10.41:4004

 17:00:54.036  pjsua_media.c  RTCP socket reachable at 10.126.10.41:4005

 17:00:54.036  pjsua_media.c  RTP socket reachable at 10.126.10.41:4006

 17:00:54.036  pjsua_media.c  RTCP socket reachable at 10.126.10.41:4007

 17:00:59.424  pjsua_media.c  Opening sound device PCM at 16000/1/20ms

 17:00:59.424       pa_dev.c  PA message: Expression
'SetApproximateSampleRate( pcm, hwParams, sr )' failed in
'src/../../../portaudio/src/hostapi/alsa/pa_linux_alsa.c', line: 1291

 

 17:00:59.424       pa_dev.c  PA message: Expression
'PaAlsaStreamComponent_InitialConfigure( &self->capture, inParams,
self->primeBuffers, hwParamsCapture, &realSr )' failed in
'src/../../../portaudio/src/hostapi/alsa/pa_linux_alsa.c', line: 1862

 

 17:00:59.424       pa_dev.c  PA message: Expression
'PaAlsaStream_Configure( stream, inputParameters, outputParameters,
sampleRate, framesPerBuffer, &inputLatency, &outputLatency,
&hostBufferSizeMode )' failed in
'src/../../../portaudio/src/hostapi/alsa/pa_linux_alsa.c', line: 1986

 

 17:00:59.424       pa_dev.c  PA message: Expression
'SetApproximateSampleRate( pcm, hwParams, sr )' failed in
'src/../../../portaudio/src/hostapi/alsa/pa_linux_alsa.c', line: 1291

 

 17:00:59.424       pa_dev.c  PA message: Expression
'PaAlsaStreamComponent_InitialConfigure( &self->capture, inParams,
self->primeBuffers, hwParamsCapture, &realSr )' failed in
'src/../../../portaudio/src/hostapi/alsa/pa_linux_alsa.c', line: 1862

 

 17:00:59.424       pa_dev.c  PA message: Expression
'PaAlsaStream_Configure( stream, inputParameters, outputParameters,
sampleRate, framesPerBuffer, &inputLatency, &outputLatency,
&hostBufferSizeMode )' failed in
'src/../../../portaudio/src/hostapi/alsa/pa_linux_alsa.c', line: 1986

 

 17:00:59.424  pjsua_media.c  Opening sound device PCM at 44100/1/20ms



'member of the CSR plc group of companies. CSR plc registered in England and Wales, registered number 4187346, registered office Churchill House, Cambridge Business Park, Cowley Road, Cambridge, CB4 0WZ, United Kingdom'
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20090825/4a29736f/attachment-0001.html>


[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux