g729

Using the g729 codec within your Fonality PBX requires purchasing a license from Digium.  Fonality charges customers a pass-through rate for each g729 license - we make no money on the cost.  Any customer wishing to use g729 should be familiar with the technology and understand why a license must be purchased.  Please read the information below, taken from two online knowledge bases, before deciding to purchase one or multiple g729 licenses.

 

 

Pros & Cons

The Good 

  • g729 requires less bandwidth than g711.  This allows more calls through on smaller trunks (especially in remote areas that do not have many options for Internet service, as long as it's a stable, low-latency connection)

The Bad 

  • g.729 is very susceptible to jitter (variation in latency) on your Internet connection.  It packs more information into less space, but the trade-off is that if that packet is delayed or dropped, the impact is far more noticeable.  Whole words or parts of sentences may go missing from a g729 call, where a g711 call would just stutter or miss a syllable.

  • The audio quality of g729 is inferior to g711 - words are slightly less clearly enunciated, for example.

  • You must pay-per-license in order to use g729, and the codec's complex formula increases the overall load on your system's CPU.

The following information is taken directly from wikipedia

G.729 is an audio data compression algorithm for voice that compresses voice audio in chunks of 10 milliseconds. Music or tones such as DTMF or fax tones can only be transported reliably with thiscodec using the RTP Payload for DTMF Digits, Telephony Tones, and Telephony Signals as specified inRFC 2833, and thus use G.711 or out-of-band methods to transport these signals.

G.729 is mostly used in Voice over IP (VoIP) applications for its low bandwidth requirement. Standard G.729 operates at 8 kbit/s, but there are extensions, which provide also 6.4 kbit/s and 11.8 kbit/s rates for marginally worse and better speech quality respectively. Also very common is G.729a which is compatible with G.729, but requires less computation. This lower complexity is not free since speech quality is marginally worsened.

The annex B of G.729 is a silence compression scheme, which has a VAD module which is used to detect voice activity, speech or non speech. It also includes a DTX module which decides on updating the background noise parameters for non speech (noisy frames). These frames which are transmitted to update the background noise parameters are called SID frames. A comfort noise generator (CNG) is also there because in a communication channel, if transmission is stopped, because it's not speech, then the other side may assume that link has been cut. This is also taken care of by the annex B standard.

Recently, G.729 has been extended to provide support for wideband speech and audio coding, i.e., the transmitted acoustic frequency range is extended to 50 Hz - 7 kHz. The respective extension to G.729 is referred to as G.729.1. The G.729.1 coder is hierarchically organized: Its bit rate and the obtained quality are adjustable by simple bitstream truncation.

G.729 includes patents from several companies and is licensed by Sipro (http://www.sipro.com/). In a number of countries, the use of G.729 may require a license fee and/or royalty fee.

This info has been taken directly from voip-info.org

How to license G.729 codec for use in Asterisk

G.729 requires a license per channel unless it is used in pass-thru mode.  This license is purchased from Digium.  Contact Digium directly if you would like to use g729.

After you have contacted Digium, do the following:

  1. Open a Support ticket with Fonality

  2. Supply the g729 License Key within the ticket

  3. Supply the URL that you received from Digium with a link where we can download the g729 codec (they may update this link from time to time - it's important you give us the link they gave you)

  4. Tell us when we can install the codec - this will require that we take your system offline.

This license is keyed to all NICs in the system. If any NICs changed/added/removed then need to re-register. This can only be done once without contacting Digium.  When upgrading the number of licenses, Digium will have to merge the old licences with the new & provide a new license file.  Reboot the server to be sure that the license is seen correctly.

Study or experiment with G.729 for free

Under patent law, it is a legitimate use to study or experiment with a patented technology without paying for a patent license. You only have to pay royalty fees if you sell a product based on the technology or use the technology in products internally (this includes using the codec in a commercial setting, even if you aren't selling your platform, but only a service).

Opensource implementation

An opensource implementation of G.729 codec exists, but Fonality will not link directly to the codec nor will we install it on your behalf because this may violate Patent Law.  Please Google for 'open source g729' if you would like to learn more about this codec.

Please note:

You might still have to pay royalty fees to the G.729 patent holders for using their algorithm and to Intel for using their libraries!

Warning

Please see Marks response on the user list (dated 25 Sep 2004) regarding use of G.729 codec from other sources. In short, this violates the GPL license and jeopardizes the asterisk project, specifically because the advocacy of its use may be seen by patent lawyers as contributory infringement. If you do choose to use this module, please be aware of the restrictions on using it without purchasing licenses, and do not advocate its use on any Digium-sponsored mailing lists (again, this could be seen as contributory infringement, if Digium resources are used to encourage its use).

There is some disagreement about whether this truly does violate the GPL. The FSF, in particular, has rendered the legal opinion that it does not violate the GPL even if the modules are not GPL compatible. The GPL violation would occur only if GPL and non-GPL compliant code is distributed together or if the module links to GPL code (use ldd to verify what it links to) or is derived from GPL code (see http://copyright.gov for US copyright law on derivative works; look to your own countries' laws potentially in addition to the US laws since Digium is in the US). There is a page on this wiki that talks about asterisk GPL compliance and another that talks about how to make non GPL modules for asterisk legally.

GPL Myth Note: the GPL is a distribution license, not a use license. If you downloaded Asterisk from someone else and are using it, the person you downloaded Asterisk from must comply with the GPL. If you combine a static G.729 binary (non-GPL compatible licensed) with GPL software, YOU DO NOT VIOLATE THE GPL UNTIL YOU DISTRIBUTE THE COMBINATION. You ARE, however, allowed to use it yourself. Acceptance of the GPL is NOT required to download and use Asterisk, either by itself or in combination with the above G.729 implementation. Therefore, if you're not planning on giving copies of Asterisk away to others, the above GPL violation statement doesn't apply to you. For more information, please see theGPL FAQ.

Old Voiceage codec info:

This license is keyed to inodes on an IDE disk (hard disk or CD-ROM in drive), which can be reused up to 3 times (e.g. if HDD dies) before having to contact Digium.

Older versions needed IDE disk to be one of hda, hdb, hdc, hdd and wouldn't work on SCSI-only systems. This is no longer true for new versions.

Need to run Asterisk with a console (this can be done in the background, by using safe_asterisk or screen).

Which devices support g729?

  1. Fonality softphones do not support g729.

  2. All IP Phones support g729

How to count the number of licences required?

A license is required only when the codec functionality is *actually* in use

i.e. when asterisk needs to transcode g729 into anything else, or the other way around

During a transcoded g729 call both directions (encoding and decoding) count as 1 license (but there could also be bugs crawling around in VA code regarding this matter)

You need 2 licenses to use 2 Cisco 7960s at the same time, assuming they are not calling each other at that moment. Accessing Voicemail counts as any other regular call

A license is required for any other "internal" asterisk function (C7960 to IVR, C7960 to MOH, Voicemail, etc), unless you could record all your IVR prompts in g729, in which case you would not need a VA license to play them to a g729 phone.

If you record Voicemails in g729 (which is possible with * by using format_g729.c) and all your phones used g729, you would not need a license, however you would need a license to access the Voicemail from PSTN!

If your g729 C7960 calls someone, and the called party places the callee on hold with MOH, a total of *2* licenses will be necessary — 1 for the call and 1 for MOH;

What if I run out of licenses?

If you run out of g729 licenses, due to Digium's implementation you will have silent calls as you can not encode or decode further g729 calls. We can not fall back to g711. This is a limitation of their codec and nothing to do with Fonality.

To confirm your purchased G.729 license key works:

Run the Asterisk console and check:

# asterisk -r *CLI> show g729

If this gave an error message, then either you have not run the Digium-supplied register utility, something about your system hardware changed (particularly Ethernet adapters), or there was a problem preventing the g729 codec from loading.

If you run Asterisk as an user other than root (highly recommended!), you may also need to ensure the user you run it under has access to the license information.

This assumes you run Asterisk with the asterisk user and asterisk group

# chown -R asterisk:asterisk /var/lib/asterisk/licenses

If codec installation and license key works, you should see something like this — e.g. for three purchased licenses:

# asterisk -r *CLI> show g729 0/0 encoders/decoders of 3 licensed channels are currently in use

 

Return to Documentation Home I Return to Sangoma Support