Hey Paul,
Sorry for the very slow reply (I was on vacation last week). What worked
for me was to disable port audio and always use alsa (thanks to the advice
from others on this list).
I did this by editing this file in the source code:
pjlib/include/pj/config_site.h
and adding the following
#define PJMEDIA_AUDIO_DEV_HAS_ALSA 1
#define PJMEDIA_AUDIO_DEV_HAS_PORTAUDIO 0
Hope that works for you. The issue I'm running into now is the sound
quality is not great. If you have any success on this front, I'd love some
pointers.
-Matt
Date: Wed, 11 Sep 2013 11:47:20 +0200 (CEST)
From: "Paul Schmidt" 8flm6@gmx.de
To: "pjsip list" pjsip@lists.pjsip.org
Subject: Re: [pjsip] Can't find audio device on Raspberry Pi
Message-ID:
<trinity-cae81fbd-0194-4d13-98db-4ffe517227e0-1378892840468@3capp-gmx-bs56
Content-Type: text/plain; charset=UTF-8
Hello Matt,
so far you're the only one who replied to my question. I tried it again
with an USB audio sound card. PJSIP seems to accept the USB sound card:
08:31:23.916 pa_dev.c PortAudio sound library initialized, status=0
08:31:23.917 pa_dev.c PortAudio host api count=2
08:31:23.919 pa_dev.c Sound device count=1
08:31:23.921 conference.c Creating conference bridge with 4 ports
08:31:23.923 Master/sound Using delay buffer with WSOLA.
08:31:23.935 pa_dev.c Opened device C-Media USB Headphone Set: USB
Audio (hw:1,0)(ALSA)/C-Media USB Headphone Set: USB Audio (hw:1,0)(ALSA)
for recording and playback, sample rate=44100, ch=1, bits=16, 882 samples
per frame, input latency=100 ms, output latency=140 ms
08:31:23.937 pa_dev.c Starting C-Media USB Headphone Set: USB Audio
(hw:1,0) stream..
But I don't hear anything when I'm establishing a conference call via the
conference bridge. Apart from that, everything works like it should. RTP
packets are exchanged continuously between the
telephones. Did you ran into similar issues?
regards,
Paul
Hello Matt,
Thanks for your advice. This worked for me indeed. But you are right, the audio quality is very bad. I noticed a very slight improvement when I switched to the GSM codec.
PJSIP returns a lot of
"pb_thread_func: underrun!"
messages. Maybe the audio processing via the USB bus of the raspberry is simply to slow to process each RTP packet. If I make any progress I will let you know.
Regards
Paul
Gesendet: Montag, 23. September 2013 um 17:11 Uhr
Von: "Matthew Cordes" <cordes.matthew@gmail.com>
An: pjsip@lists.pjsip.org
Betreff: Re: [pjsip] Can't find audio device on Raspberry Pi
Hey Paul,
Sorry for the very slow reply (I was on vacation last week). What worked for me was to disable port audio and always use alsa (thanks to the advice from others on this list).
I did this by editing this file in the source code:
pjlib/include/pj/config_site.h
and adding the following
#define PJMEDIA_AUDIO_DEV_HAS_ALSA 1
#define PJMEDIA_AUDIO_DEV_HAS_PORTAUDIO 0
Hope that works for you. The issue I'm running into now is the sound quality is not great. If you have any success on this front, I'd love some pointers.
-Matt
Date: Wed, 11 Sep 2013 11:47:20 +0200 (CEST)
From: "Paul Schmidt" <8flm6@gmx.de>
To: "pjsip list" <pjsip@lists.pjsip.org>
Subject: Re: [pjsip] Can't find audio device on Raspberry Pi
Message-ID:
<trinity-cae81fbd-0194-4d13-98db-4ffe517227e0-1378892840468@3capp-gmx-bs56>Content-Type: text/plain; charset=UTF-8
Hello Matt,
so far you're the only one who replied to my question. I tried it again with an USB audio sound card. PJSIP seems to accept the USB sound card:
08:31:23.916 pa_dev.c PortAudio sound library initialized, status=0
08:31:23.917 pa_dev.c PortAudio host api count=2
08:31:23.919 pa_dev.c Sound device count=1
08:31:23.921 conference.c Creating conference bridge with 4 ports
08:31:23.923 Master/sound Using delay buffer with WSOLA.
08:31:23.935 pa_dev.c Opened device C-Media USB Headphone Set: USB Audio (hw:1,0)(ALSA)/C-Media USB Headphone Set: USB Audio (hw:1,0)(ALSA) for recording and playback, sample rate=44100, ch=1, bits=16, 882 samples per frame, input latency=100 ms, output latency=140 ms
08:31:23.937 pa_dev.c Starting C-Media USB Headphone Set: USB Audio (hw:1,0) stream..But I don't hear anything when I'm establishing a conference call via the conference bridge. Apart from that, everything works like it should. RTP packets are exchanged continuously between the
telephones. Did you ran into similar issues?regards,
Paul