for playfile find this block of code: /* Create sound player port. */ status = pjmedia_snd_port_create_player( pool, /* pool */ -1, /* use default dev. */ PJMEDIA_PIA_SRATE(&file_port->info),/* clock rate. */ PJMEDIA_PIA_CCNT(&file_port->info),/* # of channels. */ PJMEDIA_PIA_SPF(&file_port->info), /* samples per frame. */ PJMEDIA_PIA_BITS(&file_port->info),/* bits per sample. */ 0, /* options */ &snd_port /* returned port */ ); change -1 to 0 and try it On Apr 11, 2013, at 6:40 AM, Udit Agarwal <uditiiita at gmail.com> wrote: > Hello, > I am trying to run streamutil.c and playfile from samples but i am getting the errors on running them. > On running streamutil, I got this error: > > 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. > > And on running playfile, I got the following error: > 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] > > I have searched a lot in the lists and tried many solutions but none them worked. I thought there is some problem with my audio device but audio device is fine(checked with some commands like aplay-l, etc). > Please someone tell me what should I do to make it run. > Thanking you > > -- > Udit Agarwal > B.Tech. ( Information Technology ) , 8th Semester, > Indian Institute of Information Technology > Allahabad - 211012, India > Email : uditiiita at gmail.com > Mobile: +91-9411656264 > _______________________________________________ > Visit our blog: http://blog.pjsip.org > > pjsip mailing list > pjsip at lists.pjsip.org > http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20130411/1c75fd9d/attachment-0001.html>