Firmware-only codec

Go To Last Post
6 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

One of our customers wants to add a VOIP feature to an existing board. This device is already equipped with a microphone connected to ADC, and they already succeeded in sampling the voice, sending it over the Ethernet and playing it back.

 

The problem is that they send the samples as raw data and there is no QoS management.  So the communication channel is unable to support the data flow and a good part of the packets is lost.

 

My first suggestion (use a hardware codec like TLV320) is not possible because the board is in full production and they can't change it.

 

So I am exploring the firmware only option.

 

I suppose that Speex could be a good option, as we only need to exchange voice, but I was unable to find any actual proof of successful porting to UC3.

 

According to Speex documentation, the codec should run on any MCU with enough core speed + ability to natively multiply two 16-bit words...

 

Any suggestions or hints?

 

Thanks

 

--kalbun

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

first of all we need to know:

Quality needed

Max delay (packet size). (is this a 1 or 2 way system?)

Speed of data channel

 

If the ADC are linear then change the data to log.(that alone can cut the data rate with about 30% without a person can hear the difference).

 

First shoot try some DPCM, ADPCM

next would be some of the cellphone modes.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

kalbun wrote:
I suppose that Speex could be a good option, as we only need to exchange voice, but I was unable to find any actual proof of successful porting to UC3.
Speex runs on an ARM Cortex-M3 so likely possible on a UC3 though would take some effort.

kalbun wrote:
Any suggestions or hints?
Consider moving to the Opus codec as Opus has been integrated into web browsers.


Speex Audio Codec

by Administrator Nari ‎10-01-2014 04:31 AM - edited ‎10-02-2014 03:18 AM

Original Posting Date: October 10, 2012

http://community.silabs.com/t5/Official-Blog-of-Silicon-Labs/Speex-Audio-Codec/ba-p/131388

Opus Codec

Opus Interactive Audio Codec

http://www.opus-codec.org/

"Dare to be naïve." - Buckminster Fuller

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

sparrow2 wrote:
First shoot try some DPCM, ADPCM
IIRC that's in ASF DSPLIB.

"Dare to be naïve." - Buckminster Fuller

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quality: we can sample as low as 8 kHz/s, 12 bit (perhaps even 8 bit could be enough)

Delay: 200-300 ms sounds reasonable. 500 ms is the maximum accepted

Data channel: the board uses TCP/IP over Ethernet, so the effective speed depends from traffic on the network (rather modest).

 

sparrow2 wrote:

first of all we need to know:

Quality needed

Max delay (packet size). (is this a 1 or 2 way system?)

Speed of data channel

 

If the ADC are linear then change the data to log.(that alone can cut the data rate with about 30% without a person can hear the difference).

 

First shoot try some DPCM, ADPCM

next would be some of the cellphone modes.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

gchapman wrote:
Consider moving to the Opus codec as Opus has been integrated into web browsers.

 

Opus could be another option, but AFAIK it fits best in scenarios requiring a higher quality, including sound and music. My initial guess is that porting Opus would be harder than porting Speex - of course I can be wrong