g711 g729 g729a g726 g723 gsm questions.

Discussion in 'General' started by j99991, Jan 14, 2009.

  1. j99991

    Joined:
    Dec 16, 2008
    Messages:
    98
    Likes Received:
    0
    hello i would like ot ask questions about codecs.
    i already know the codecs of g729 g711 g726 and g723.however i recently found that there are g729.1 and g729a i would like to ask what are the diffrences betwen them to a RTEGULAR G729 codec. could they help me do high quality converstaions ?
    i also w would liuke to know where can i get an example of the wuality of each of them ? i wouldl ike to get an example before i buy the appliance just to make sure.
    another question is if voip can give me a high quality calls like the ones i get from my corrent analoge lines or even better? i know that this depends on many things but what's the general answer for this question?

    thank you
    j99991
     
  2. Chilling_Silence

    Joined:
    Sep 23, 2008
    Messages:
    488
    Likes Received:
    0
    Using g711, you get ISDN-quality.

    The rest degrade the quality, even g729. Remember, not all call codecs are supported by Asterisk.

    Look in to "MOS" - Mean Opinion Score
     
  3. j99991

    Joined:
    Dec 16, 2008
    Messages:
    98
    Likes Received:
    0
    ok so ..
    in that case what codecs does asterisk allow or support?
    and does isdn quality is bettern then analog phones quality?
    i understan that generally the better codec you use i mean if it is g729 gsm g926 but not g711 the call's wuality is poorer but does it can be changed if you have a better processor? like if i had a really good process and i was using g729 codec could i still had the wuality of g711 but just using less bandwith more cpu?
    and does the quality of g729 is good enough in order to make and recieve calls?
    and the most important where can i find an example to hear of each codec?

    thanks
    j99991
     
  4. Bob

    Bob

    Joined:
    Nov 4, 2007
    Messages:
    2,400
    Likes Received:
    1
    j99991,

    This is more of an overall answer than just answering your direct questions as there are no perfect answers for what your are asking.

    To answer one of your questions re: versions of G729 look at http://en.wikipedia.org/wiki/G.729 . You will also find links to the other versions on the page. But don't spend to much time on it, it is not going to make all that big a difference.

    The main codecs that we use on a widespread basis are the following

    Ulaw/Alaw - better than normal PSTN/POTS quality but does need bandwidth around 80kb/s (each way)
    GSM - Mobile phone quality - still very acceptable for business around 30kb/s (each way)
    G729 - Generally as good as GSM around 25kb/s (each way)

    But be careful with this figures, they are generally for SIP, IAX is different, sampling times on G729 can be different etc...

    G729 we only use where bandwidth is at a premium. CPU is generally not an issue with our systems, so this does not come into play. Whilst all IP comms can be affected by line issues, we find that very intermittent issues are shown up when G729 is used, mainly due to the fact on G729, a 0.5 second dropout, could mean a 1-2 sec loss of voice (sometimes a complete word), whereas on the other codecs, it can mean maybe the loss of one syllable.

    As far as I remember, G729 (on asterisk systems) actually refers to G729a but don't quote me.

    So if you want the best quality that is better (in at least perception) then use the 711U/A. If you want at least Mobile phone quality then select GSM, if you NEED to squeeze as much as possible into a Pipe, then go for G729.

    As for testing each codec, I don't know any system, and it would be useless anyhow as many factors will effect it. The best system to try it on is your own Elastix system.

    Regards

    Bob
     
  5. Mirko87

    Joined:
    Oct 20, 2008
    Messages:
    128
    Likes Received:
    0
    Hi Bob, so that G729 has got some issues?...

    If you watch my topic about in help forum, I'm showing my problems with that codec... Like no audio (Music Hold On) or call Drops... Have you got the same problems?

    Mirko
     
  6. Chilling_Silence

    Joined:
    Sep 23, 2008
    Messages:
    488
    Likes Received:
    0
    I think Bob is right, g729 in asterisk refers to g729a
    The other implementations arent in asterisk AFAIK
     
  7. dicko

    Joined:
    Oct 24, 2008
    Messages:
    4,099
    Likes Received:
    0
    Just my thoughts here:-

    POTS lines are in effect g711, (g711u(correctly the greek letter mu) or g711a are used depending on where you live in the world, they are both absolutely 64kbs) any degradation of this signal is due to "last mile", digital to analog to copper wire attenuation/noise, which in urban centers is usually negligible. (further, ISDN is usually 64kbs but sometimes 56kbs in a "hostile" route and merely extends g711[au] to the NTU, so eliminating that degradation.)

    g711 is the standard telephony codec used since AT&T went digital in the 1960's, there is no compression involved , just pre-/de-emphasis to try and maximize intelligibility of 300-3000Hz analog speech sampled at 8k per second in a digital 64kbs. world (google Nyquist and/or AT&T Laborotories if your confused)

    GSM which is used (almost universally) by cell phones is a newer codec that gives traditional "voice quality, ( 300Hz to 3000Hz.)" in only 32kbs by using compression, this needs processing to decode, luckily cell phones have this, your old analog phone doesn't

    g729, speex, ilbcc et al. are all attempts to compress human voice into smaller bandwidth with a sharp eye on psycho-acoustics.

    Each of the above will likely "worse" than one above, as they are all "lossy" codecs, it's just that as bandwidth goes down loss goes up reciprocally, and processing requirements go up too.

    The problem with speech is that if the stream is interrupted or reorganized in the time domain, it very quickly becomes stressful to listen to (google psycho-acoustics), so if you don't have the bandwidth to support g711 at 64k, it is better to use a lower bandwidth codec that is less likely to be fragmented or delayed.

    Thusly, to j99991, asterisk will handily transcode between any and all codecs that have come up in this discussion, given enough CPU cycles, the problem is not the quality of the codec but the ability to push that data stream through what you have available bandwidth wise without packet loss or delay, and even if you have 128gigabits per sec to your asterisk box it won't sound good if the latency between you and the far end is greater than the psycho acoustical limits of the human ear ( let's say 40 milliseconds, 100 milliseconds greatest) which will show up as delayed audio that a user will find unacceptable.


    p.s. SIP is codec agnostic and supports hi-def codecs audio and video WAY above 64k if the rtp stream is supported by the network. Further after the call has been negotiated and the audio/video path established the overhead of the stream is a function of IP routing and is in effect a percentage of the bandwidth used.


    So, ultimately you need to identify the weak parts of your network, the number of calls you need to make concurrently and choose a codec that is a) supported by both ends, and b) fits in what you have to offer.
     
  8. j99991

    Joined:
    Dec 16, 2008
    Messages:
    98
    Likes Received:
    0
    i would like to thank all of you for your replys.
    unfortunitly i do not have alot of knowledge at the above issue and thus could not totaly understand all you said. however, i do understand know that the g729 is worse then the gsm a fact i didn't know. also i though that there was a codec i think it was g729 or gsm which uses only 8kb.
    regarding the internet we are using we have an adsl 1.5mb\150kb we kinda understand that this will not be sufficient for that purpose if using a codec which makes use of 64kb of the upload stream. thus, we would like to use a coedc which will use less of the bandwith and also because that bandwith in israel is pricy. i understand that having a codec which uses less bandwith also means more cpu performance and we don't mind having a better processor in order to do so. do you think that atom or core dou 2 mhz will be good enough inorder to use such codecs?
    again i will repeate of that fact that i understood that there are codecs i think g729 or gsm that uses only 8kb are they? and by saying 8kb does this means 8kb from the total 150 uload we got again the package of adsl we got is 1.5mbps\150kbps. so if there is a codec which allows us having a call for only 8kb from the total of 150 which means we could have many calls that well be great. generally we will start with 2-3 phones and another 3 softphones which will be installed on 2 cellhpones and 1 pc. however, we hope that in the short come future we will neede to make a use of 12-14 phones and another 2 pcswith softpnhones and 2-4 cellphones with softphones which will ofcourse connect to the appliance from remote hot spots.
    now we need to know.
    1. are there any coedcs that uses 8kb?
    2. does saying 8 kb or 64 kb in case of g711 means 8 out of 150 or 64 out of the 150 kbps we have?
    3. though we really want to have a small bandwith usage using codecs which will take less bandwith and more cpu cycles we also want to have atleast a good quality converstaions this means cellphone qulity or better.
    if any 1 could give us a solution or more information in order to solve this problem that will help us alot.

    thanks
    j99991
     
  9. Mirko87

    Joined:
    Oct 20, 2008
    Messages:
    128
    Likes Received:
    0
    Hi...
    When I was in a voicemail with my Phone with G729,
    I've write this in the CLI> show G729

    And the result is:
    1/0 encoders/decoders of 1 licensed channels are currently in use

    This means that my only one licence is used as an encoder so that I can't decode?

    If my opinion is good, my problems are truly the number of licence...

    Mirko

    ps for j99991: I think that G729 is a good codec if you haven't a lot of bandwidth... but it increase your costs... 10$ at licence.. and you'll should buy 15. So that, try to use it, the quality is good (ok, not like G711).
     
  10. j99991

    Joined:
    Dec 16, 2008
    Messages:
    98
    Likes Received:
    0
    i understand.
    but acctually my real problem is i dunno how does g711 gsm and g729 sound like. are there any example for that so i could be now for sure how it will be like? cause i dunno g729 and gsm is a cellhponequality but i dunno that quaality 2 cause there any many things that changes when using a real cellphone. like if you use gsm cellphone in australia it could give u a diffrent qualiuty if using it in israel it depneds on many things and thus i would like to get anexample of it
    if it's possible.

    and about the g729 i think you can download them from th internet for free.

    thanks
    j99991
     
  11. Mirko87

    Joined:
    Oct 20, 2008
    Messages:
    128
    Likes Received:
    0
    Hi...
    unfortunately there aren't any exaple of the quality around the web...
    You should try all the cedecs... You could start with try gsm...

    Mirko
     
  12. Bob

    Bob

    Joined:
    Nov 4, 2007
    Messages:
    2,400
    Likes Received:
    1
    j99991,

    The G729 is not bad, in fact a lot of systems use it, but it may not be suitable for everything and all equipment and all communications lines.

    You are correct there is an 8kps codec called G729. But it refers to the bandwidth available to the audio. Then you add on the overheads which include RTP and UDP, which finally come up to approx 25kps and then you have to remember that this is for one way. So to be safe, you have to assume that it is possible that audio could be going both ways. so now we are up to 50Kps Bandwidth.

    Now to be fair this is worst case scenario and is not always the case in real life. For instance using IAX2 trunks, using G729, you can bring the typical bandwidth per call down to 40Kps (although IAX is not always possible with some voice providers).

    The only easy way to check (if you are technically inclined) is to setup an Elastix system, implement G729, do a TCPDUMP on the network card. Analyse the TCPDUMP and look to see what the bandwidth it is using. As a general guide I have seen on IAX/G729 systems that the call is less than the figures that I have provided, but I can't give you a blanket answer that it will be the same on yours, which is why I am quoting worst case figures.

    I will be honest and say that your current ADSL line is a little light on for VoIP. Your main issue is the 150kps back haul. The best you can expect to get using sip is 6 calls and that is possibly stretching it (6 x 25 kps outgoing). If you are also using this same ADSL for the rest of your network (E.g you have no actual filters blocking all but SIP traffic), then 6 channels is not going to happen. It would mean the minute one of your machine picks up mail, ends up with a trojan, you would seriously impact your VoIP.

    I would seriously consider moving upto the next level of ADSL (if available to you). If not generally resign yourself to the fact that a few concurrent calls is all you will achieve with this line. There is no other codec that is going to make a difference (not supported anyhow).

    Regards

    Bob
     
  13. Chilling_Silence

    Joined:
    Sep 23, 2008
    Messages:
    488
    Likes Received:
    0
    Again, ask your PBX vendor for examples, they should have a demo system that can be used to show you the call quality both with g729, g711 & gsm.

    Again, you go trying to tell people you know the answer or know better... yet you're the one asking the question? If you knew the answer, why post in the first place? OR if you were able to Google for info on free g729, then why could you not google answers to your other questions?
    Seriously dude, just go back to the PBX vendor and ask them your questions, they're equipped to help and answer all this stuff.
     
  14. dicko

    Joined:
    Oct 24, 2008
    Messages:
    4,099
    Likes Received:
    0
    j99991,

    Your identified limitation is obviously the 150k outbound rate, phone calls take roughly the same bandwidth in and out so g711 plus overhead would limit you to 1 acceptable call maybe two or three with GSM/g729 , my experience is (with a 128k adsl connection) that call quality will rapidly decline after the second call is placed, even if using GSM/729, most VOIP providers support these codecs, few support higher compression codecs, If your talking about as many as 15 calls, this just will not happen. You also need to apply a draconian QOS policy to your router/firewall to even make one call or your twitter/p2p sessions on the one pc you have will screw everything up. I believe skype uses iLBC which is a multirate codec that can adapt to bandwidth conditions so you can subjectively try out high compression low bandwidth quality by setting up skype and trying it with varying loads on your internet connection.

    Also most adsl connections are "best effort" which mean the telco aggregates many subscribers into one dslam (a box the telco provides your dsl from at the wire center) with a fixed rate connection to the internet, expect this 150 to go south in both rate and latency at times of high use on the dslam, which is basically from school's out to bedtime.

    You also mention connecting from wifi hotspots, this will further worsen the situation as each of these calls will use twice the bandwidth, one leg in from the hotspot and one leg out to the dialed number. You could set canreinvite=yes in sip.conf, but that depends on a lot of variables, and forgive me for saying this , I don't think you have enough knowledge to get this going yet.
     
  15. Chilling_Silence

    Joined:
    Sep 23, 2008
    Messages:
    488
    Likes Received:
    0
    A few things come to mind:
    1) You're not allowing for IP overheads, you'll get 3 g729 calls using around 130kbits over a PPPoA / PPPoE connection.
    2) g729 is better than GSM -- Again look up MOS, Mean Opinion Scoring
    3) Ive already recommended you go back to the people trying to sell you an Elastix PBX system and that you:
    a) ask them for a quality demo. If they cant, then forget about them
    b) TRUST them. If you dont trust them, dont use them, find somebody else
    4) Lastly, read over your existing threads, you ask the same question multiple times and it gets answered the same. Yes the Atom will be fine.

    Here's the deal:
    If you're going with Low CPU usage, its going to be high quality (uncompressed g711) but high bandwidth
    If you're going with low bandwidth, its going to be compressed and lower quality and higher CPU usage

    There's no two ways about it. No matter which you choose, the system you've mentioned in other posts will be fine.

    Again, final note here: Please re-read your other posts, you keep repeating yourself.
     
  16. donhwyo

    Joined:
    Aug 8, 2008
    Messages:
    293
    Likes Received:
    0
    Maybe you should look at a hosted system since you want external users and your dsl is so limited.

    Don
     
  17. j99991

    Joined:
    Dec 16, 2008
    Messages:
    98
    Likes Received:
    0
    ok thakns again ofr your replys.

    1. regarding the g729 i only found it by accident and just wanted to get more knowledge.
    2. regarding what dicko said first you are right i think 2 that i do not know enough to deal with the system in that kind of a level so you do not need to be sorry about that.
    however as i understand when a cal is being made the upload usage ies between 9-64 kb depends on the codec, however i noticed that you have doubleds the bandwith usage per call. i would like to ask y so ? i mean that call that you make is only using 1 upload seaseon and one download season which means 8-64 upload and maybe the same for the download right is that what you ment?
    3. regarding you recommandation silnce to go to the pbx provider i would like to ask if i shouldn't go to the vsp provider and not to the pbx provider since they are the ones that give me the sip trunk or line?
    4. we do not mind using a greater cpu usage in order to make low bandwith calls. however i understand that although convertiung the usage from bandwith to more cpu cycles the quality is still being damaged however more cpu cycles are needed. so this is not the same i mean there is no way to use less bandwith and compensate that with more cpu usage and to get the samme quality right?
    5. dicko a qus will be defined for the sip port.hwoever we still have problems which i will let you know about in a diffrent msg.
    6. i will try to srarch for mos.

    thanks
    j99991
     
  18. j99991

    Joined:
    Dec 16, 2008
    Messages:
    98
    Likes Received:
    0
  19. Chilling_Silence

    Joined:
    Sep 23, 2008
    Messages:
    488
    Likes Received:
    0
    No, again, you need to have a greater communication and trust with your PBX Provider, as they're the ones setting you up with the system that will support codecs X, Y & Z.

    Whilst the bandwidth is 64kbps for g711, thats one direction (Calls are two directions) so allow for upload & download bandwidth, plus IP overheads etc
    This page is your friend: http://blog.asteriskguide.com/bandcalc/bandcalc.php

    There is no way to use less bandwidth and get the same quality as g711.

    Also, posting
    doesnt sound the nicest. Try using some real english, such as "Can anybody please help and answer my last questions because I didnt want to spend the time looking through Google?"... Not to mention if my boss put me in charge of telecommunications then saw me writing like that on an internet forum I'd get the sack ;)
     
  20. j99991

    Joined:
    Dec 16, 2008
    Messages:
    98
    Likes Received:
    0
    well i guess you are right. i will try to do so as of now.

    thank you
    j99991
     

Share This Page