从pjsip-app示例运行streamutil.c和playfile

时间:2013-04-11 14:01:29

标签: pjsip

我正在尝试从示例中运行streamutil.c和playfile但是我在运行它们时遇到错误。 在运行streamutil时,我收到了这个错误:

19:07:43.822 os_core_unix.c !pjlib 2.1 for POSIX initialized
PJLIB INIT COMPLETE
19:07:43.825       pa_dev.c  PortAudio sound library initialized, status=0
19:07:43.825       pa_dev.c  PortAudio host api count=1
19:07:43.825       pa_dev.c  Sound device count=0
19:07:43.825          pjlib  select() I/O Queue created (0x7c87b8)
a.out: ../src/pjmedia/codec.c:53: pjmedia_codec_param_clone: Assertion `pool && src' failed.

在运行playfile时,我收到以下错误:

19:08:35.703 os_core_unix.c !pjlib 2.1 for POSIX initialized
19:08:35.705       pa_dev.c  PortAudio sound library initialized, status=0
19:08:35.705       pa_dev.c  PortAudio host api count=1
19:08:35.705       pa_dev.c  Sound device count=0
19:08:35.706          pjlib  select() I/O Queue created (0x13db7b8)
19:08:35.706   wav_player.c  File player '/home/udit/pjsip/alarma.wav' created: samp.rate=22050, ch=1, bufsize=4KB, filesize=265KB
19:08:35.706     playfile.c  Unable to open sound device: Unable to find default audio device (PJMEDIA_EAUD_NODEFDEV) [code=420006]

我经常搜索并尝试了很多解决方案,但没有一个能够解决问题。我认为我的音频设备有问题,但音频设备很好(用aplay-l等命令检查)。 请有人告诉我该怎么办才能让它运行起来。

1 个答案:

答案 0 :(得分:1)

Ubuntu的解决方案是:

1-安装 libasound2-dev sudo apt-get install libasound2-dev

2-重新编译Pjsip包

解决了我的问题!!