7

I am trying to use a Raspberry Pi as a VoIP phone. Sadly the USB bug causes a very bad audio quality if I use an external usb soundcard. I tried to set the usb to 1.1 only and to reduce the sample rate to 8khz, but still have too much glitches etc. My current DAC is an TI PCM2912 (other tested devices are causing the same problems).

I tried Asterisk and linphonec with OSS and ALSA, pjsua with portaudio and ALSA and Freeswitch with portaudio. Using portaudio with an ALSA device causes silence in both directions, portaudio with OSS works (with errors as described above).

Knows anybody a working trick to get a good voice quality? Maybe an asound.conf/.asoundrc with fitting values for buffer and sample rate?

Piotr Kula
  • 17,336
  • 6
  • 66
  • 105
am1337
  • 81
  • 1
  • 1
  • 3

3 Answers3

2

What I would suggest is to use an IP Phone instead. It may save you the whole sound problem headache but I hope you will see the benefits. This would mean installing Asterisk on your Raspberry Pi and resigning from using the Pi as a VoiP "IP" Phone.

Also, having an IP Phone means you can directly connect the IP Phone to your VoiP provider defeating the purpose you have in mind. You can get fairly cheap IP Phones that run off LAN or WiFi.

enter image description here

The upside of installing Asterisk on your Pi means you can make your own private telephone exchange. THis means you could use VoiP client on your smartphone, have several phones in the house connect to the Pi over LAN - All of which can be accessible by dialing an extension number like. 100, 10 or any custom code you like.

With a bit of configuring you can even install IP Phones at your moms house, you relatives that life in another country or have your friends connect to your Asterisk system. They will all be able to call each other and yourself for free, provided they are connected to the internet. Even 3G calls are supported using the GSM codec. (Other codecs are also available)

You might have several VoiP providers that offer various prices or even free calls. You can then set up rules that choose least cost routes for normal telco/mobile numbers.

I would suggest installing FreePBX GUI on top of Asterisk as it really makes configuring asterisk much easier!

uElasitx is a nice image dedicated for Raspberry that has a nice GUI to help your configure everything.

You can also get RasPBX installer or image

I use voipcheap as my VoiP provider. Really great speeds, free calls with top ups and must be one of the cheapest out there.

I am in no way affiliated with any product or service. I use them or tested them and find them to be very effective.

Piotr Kula
  • 17,336
  • 6
  • 66
  • 105
1

UV4L supports two-way live Audio/Video P2P Calls from any browser, phone, tablet to Raspberry Pi 2. Jitsi Meet Web Conferences are also supported.Screenshot. Both local and remote cameras can be rendered on the screen (touch or HDMI). An USB soundcard for Audio-in. Audio-out is played through speakers. No plugin's required and just works.

prinxis
  • 276
  • 3
  • 4
1

Best way to get a working audio input seems to be using an I2S codec. I had success using WM8731. See http://blog.koalo.de/2013/05/i2s-support-for-raspberry-pi.html for more information.

am1337
  • 81
  • 1
  • 1
  • 3