dsPIC/PIC24 G.711 Speech Encoding/Decoding Library
Buy/Sample Options SW300026
Contact Microchip
Development Tool Selector
Microchip Advanced Parts Selector (MAPS)
CiSAR (Service Request)
dsPIC/PIC24 G.711 Speech Encoding/Decoding Library 
Part Number: SW300026

The PIC24/dsPIC® Digital Signal Controller (DSC) G.711 Speech Encoding/Decoding Library performs toll-quality voice compression and voice decompression. The library is an implementation of the ITU-T G.711 standard on the dsPIC DSC. The encoding algorithm used is either A-law or μ-law companding (user-selectable), and features a 2:1 compression ratio. G.711 uses minimal computational resources, and a well-defined API makes it easy to integrate with the application.
The G.711 library can be used for both half-duplex and full-duplex systems. However, due to its high output data rate, it is most suitable for full-duplex communications applications that do not need to store the encoded speech for subsequent playback. Some target applications include:

  • Intercoms
  • Emergency phones
  • Walkie-talkies
  • Mobile hands-free kits
  • Digital radios
  • Voice-over-IP telephony

A flexible analog interface gives your design several options to consider. The speech encoder samples speech at 8 kHz using either an external codec or the on-chip 12-bit Analog-to-Digital Converter (ADC). The speech decoder plays decoded speech through an external codec or the on-chip Pulse Width Modulator (PWM). Storing compressed speech for playback requires 8 KB of memory for each second of speech.
A PC-based Speech Encoder Utility program creates encoded speech files for playback. Encoded speech files are made from either a PC microphone or existing WAV file. Once the encoded speech files are created, they are added to an MPLAB® IDE project, just like a regular source file, and built into the application.

Resource Requirements
Please refer to user’s guide for resource requirements

Key features of the G.711 Speech Encoding/Decoding Library:

  • Fixed 8 kHz input sample rate
  • Fixed 64 kbps output data rate
  • PESQ-based Mean Opinion Score (MOS): 4.3 to 4.5 (out of 5.0)
  • A-law or μ-law based coding
  • Two analog input interfaces — codec or on-chip ADC
  • Two analog output interfaces — codec or on-chip PWM
  • Playback-only applications benefit from the Speech Encoder Utility. Encoded files can be created from the desktop using a PC microphone or WAV file.
  • Storing compressed speech requires 8 KB of memory per second of speech
  • FREE library
  • Full compliance with Microchip's MPLAB® C30 C compiler language tools
  • PIC24/dsPIC DSC G.711 Speech Encoding/Decoding Library User's Guide assists in using the library
  • Designed to run on dsPICDEMTM 1.1 General Purpose Development Board

Devices Supported

  • PIC24HJXXXGPXXX
  • PIC24E
  • PIC24FJXXXAXXX
  • dsPIC30F6014
  • dsPIC30F6014A
  • dsPIC30F6013
  • dsPIC30F6013A
  • dsPIC30F6012
  • dsPIC30F6012A
  • dsPIC30F6011
  • dsPIC30F6011A
  • dsPIC30F5013
  • dsPIC30F5011
  • dsPIC33FXXXGPXXX
  • dsPIC33E
Downloads