home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #19 / NN_1992_19.iso / spool / comp / dsp / 2029 < prev    next >
Encoding:
Internet Message Format  |  1992-08-26  |  2.4 KB

  1. Path: sparky!uunet!gatech!concert!aurs01!gingell
  2. From: gingell@aurs01.UUCP (Mike Gingell)
  3. Newsgroups: comp.dsp
  4. Subject: Re: mu-law encoding - definition?
  5. Keywords: mu-law
  6. Message-ID: <61087@aurs01.UUCP>
  7. Date: 26 Aug 92 17:25:10 GMT
  8. References: <1992Aug22.190716.2600@athena.mit.edu>
  9. Sender: news@aurs01.UUCP
  10. Reply-To: gingell@aurw6b.aur.alcatel.com.UUCP (Mike Gingell)
  11. Organization: Alcatel Network Systems, Raleigh NC
  12. Lines: 52
  13.  
  14. In article <1992Aug22.190716.2600@athena.mit.edu> parasite@athena.mit.edu (Vince) writes:
  15. >
  16. >I have a set of data which is mu-compressed from
  17. >12 bits to 8 bits.  I need to maniulate it in
  18. >its 12-bit form and I'm not sure what the
  19. >conversion process between the two is.  All of
  20. >the books I've looked in for an explanation have
  21. >a few graphs displaying the wonderful properties
  22. >of mu-encoding but no direct explanation of how to
  23. >go from one to another.
  24. >
  25. >Does anyone out there know the definitions of the 
  26. >encoding algorithm and wish to tell me what it is?
  27. >If it makes a difference, this data was taken off 
  28. >of the audio port of a Sun Sparcstation (/dev/audio).
  29. >
  30.  
  31. mu-law is a code developed by Bell Labs about 30 years ago
  32. for use in PCM telephony. It compresses a 13 bit dynamic
  33. range into an 8 bit pseudo logarithmic form. The MSB is the sign
  34. the next 3 bits are a scale factor and the least 4 are the
  35. magnitude.  The spec is defined in various Bell & ATT documents
  36. as well as CCITT Rec. G.711 and probably countless text books.
  37.  
  38. To paraphrase the table in CCITT G711
  39.  
  40. Segment  # of intervals     value at               code
  41.                          segment end points
  42.                            8159                  10000000
  43.    8      16 * 256                               1000xxxx
  44.                            4063                             
  45.    7      16 * 128                               1001xxxx
  46.                            2015
  47.    6      16 * 64         
  48.                             991
  49.    5      16 * 32
  50.                             479
  51.    4      16 * 16
  52.                             223
  53.    3      16 * 8
  54.                              95
  55.    2      16 * 4
  56.                              31
  57.    1      15 * 2
  58.            1 * 1
  59.                               0                   11111111
  60.  
  61. This just shows the positive side - screwy isn't it?
  62.  
  63. Mike Gingell, Alcatel, Raleigh, NC USA  (919) 850-6444
  64. UUCP:       ...!mcnc!aurgate!aurfs1!gingell
  65. Internet:   gingell%aurfs1%aurgate@mcnc.org
  66.