c++ - pjsip new-call error ... Unable to find default audio device (PJMEDIA_EAUD_NODEFDEV) -


i error when try establish new call pjsip:

pjsua_aud.c ..error retrieving default audio device parameters: unable find default audio device (pjmedia_eaud_nodefdev) [status=420006] exception: object: {account <sip:192.168.0.2:54496>}, operation=make_call(), error=unable find default audio device (pjmedia_eaud_nodefdev)

i installed libasound2-dev: sudo apt-get install libasound2-dev, , recompiled pjsip, still, gives me same result .. missing here?

n.b. use ubuntu 11.10 , sound works fine no problems, please don't tell me have problems in sound card


update

i configured , compiled pjsip this:

$ ./configure

$ make && make install

and this:

$ ./configure --enable-shared --disable-static --enable-memalign-hack

$ make && make install

and this:

$ ./configure

$ make dep && make clean && make

and ways gave me same results.


update 2

i made sure of below installed, , still problem persists:

sudo apt-get install portaudio19-dev libportaudio2 pulseaudio alsa-utils liboss4-salsa-dev alsa-base alsa-tools libasound2-plugins libasound2 libasound2-dev binutils binutils-dev libasound-dev pulseaudio-dev


update 3

i ran below, , worked:

pjproject-2.1.0/pjsip-apps/bin/pjsua-i686-pc-linux-gnu --capture-dev=-1 --playback-dev=-1

it can call other party. when run python script gives me error, when set sound device this:

lib.init(log_cfg = pj.logconfig(level=log_level, callback=log_cb)) snd_dev = lib.get_snd_dev() print snd_dev ## returns (-1,-2) lib.set_snd_dev(0,0) 

error is:

12:39:55.753 os_core_unix.c !pjlib 2.1 posix initialized 12:39:55.754 sip_endpoint.c .creating endpoint instance... 12:39:55.754 pjlib .select() i/o queue created (0x93f1a80) 12:39:55.754 sip_endpoint.c .module "mod-msg-print" registered 12:39:55.754 sip_transport. .transport manager created. 12:39:55.754 pjsua_core.c .pjsua state changed: null --> created 12:39:55.769
pjsua_core.c .pjsua version 2.1 linux-3.0.0.17/i686/glibc-2.13 initialized (-1, -2) 12:39:55.770 pjsua_aud.c .error retrieving default audio device parameters: invalid audio device (pjmedia_eaud_invdev) [status=420004] exception: object: lib, operation=set_current_sound_devices(), error=invalid audio device (pjmedia_eaud_invdev)

but weirdly worked, when replaced lib.set_snd_dev(0,0) line lib.set_null_snd_dev(), of course sound not working, i'm setting sound device null !!!

this happens when development packages not installed. error message can tell libasound-development-package not installed. following:

sudo apt-get install libasound2-dev 

pay attention pjsip still fail set default audio device since have done make package missing. need build pjsip once again

at pjsip directory following respectively :

./configure make dep  make clean make make install 

that'd it.


Comments

Popular posts from this blog

c# - Operator '==' incompatible with operand types 'Guid' and 'Guid' using DynamicExpression.ParseLambda<T, bool> -