Audigy-mixer.txt 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346
  1. Sound Blaster Audigy mixer / default DSP code
  2. ===========================================
  3. This is based on SB-Live-mixer.txt.
  4. The EMU10K2 chips have a DSP part which can be programmed to support
  5. various ways of sample processing, which is described here.
  6. (This article does not deal with the overall functionality of the
  7. EMU10K2 chips. See the manuals section for further details.)
  8. The ALSA driver programs this portion of chip by default code
  9. (can be altered later) which offers the following functionality:
  10. 1) Digital mixer controls
  11. -------------------------
  12. These controls are built using the DSP instructions. They offer extended
  13. functionality. Only the default build-in code in the ALSA driver is described
  14. here. Note that the controls work as attenuators: the maximum value is the
  15. neutral position leaving the signal unchanged. Note that if the same destination
  16. is mentioned in multiple controls, the signal is accumulated and can be wrapped
  17. (set to maximal or minimal value without checking of overflow).
  18. Explanation of used abbreviations:
  19. DAC - digital to analog converter
  20. ADC - analog to digital converter
  21. I2S - one-way three wire serial bus for digital sound by Philips Semiconductors
  22. (this standard is used for connecting standalone DAC and ADC converters)
  23. LFE - low frequency effects (subwoofer signal)
  24. AC97 - a chip containing an analog mixer, DAC and ADC converters
  25. IEC958 - S/PDIF
  26. FX-bus - the EMU10K2 chip has an effect bus containing 64 accumulators.
  27. Each of the synthesizer voices can feed its output to these accumulators
  28. and the DSP microcontroller can operate with the resulting sum.
  29. name='PCM Front Playback Volume',index=0
  30. This control is used to attenuate samples for left and right front PCM FX-bus
  31. accumulators. ALSA uses accumulators 8 and 9 for left and right front PCM
  32. samples for 5.1 playback. The result samples are forwarded to the front DAC PCM
  33. slots of the Philips DAC.
  34. name='PCM Surround Playback Volume',index=0
  35. This control is used to attenuate samples for left and right surround PCM FX-bus
  36. accumulators. ALSA uses accumulators 2 and 3 for left and right surround PCM
  37. samples for 5.1 playback. The result samples are forwarded to the surround DAC PCM
  38. slots of the Philips DAC.
  39. name='PCM Center Playback Volume',index=0
  40. This control is used to attenuate samples for center PCM FX-bus accumulator.
  41. ALSA uses accumulator 6 for center PCM sample for 5.1 playback. The result sample
  42. is forwarded to the center DAC PCM slot of the Philips DAC.
  43. name='PCM LFE Playback Volume',index=0
  44. This control is used to attenuate sample for LFE PCM FX-bus accumulator.
  45. ALSA uses accumulator 7 for LFE PCM sample for 5.1 playback. The result sample
  46. is forwarded to the LFE DAC PCM slot of the Philips DAC.
  47. name='PCM Playback Volume',index=0
  48. This control is used to attenuate samples for left and right PCM FX-bus
  49. accumulators. ALSA uses accumulators 0 and 1 for left and right PCM samples for
  50. stereo playback. The result samples are forwarded to the front DAC PCM slots
  51. of the Philips DAC.
  52. name='PCM Capture Volume',index=0
  53. This control is used to attenuate samples for left and right PCM FX-bus
  54. accumulator. ALSA uses accumulators 0 and 1 for left and right PCM.
  55. The result is forwarded to the ADC capture FIFO (thus to the standard capture
  56. PCM device).
  57. name='Music Playback Volume',index=0
  58. This control is used to attenuate samples for left and right MIDI FX-bus
  59. accumulators. ALSA uses accumulators 4 and 5 for left and right MIDI samples.
  60. The result samples are forwarded to the front DAC PCM slots of the AC97 codec.
  61. name='Music Capture Volume',index=0
  62. These controls are used to attenuate samples for left and right MIDI FX-bus
  63. accumulator. ALSA uses accumulators 4 and 5 for left and right PCM.
  64. The result is forwarded to the ADC capture FIFO (thus to the standard capture
  65. PCM device).
  66. name='Mic Playback Volume',index=0
  67. This control is used to attenuate samples for left and right Mic input.
  68. For Mic input is used AC97 codec. The result samples are forwarded to
  69. the front DAC PCM slots of the Philips DAC. Samples are forwarded to Mic
  70. capture FIFO (device 1 - 16bit/8KHz mono) too without volume control.
  71. name='Mic Capture Volume',index=0
  72. This control is used to attenuate samples for left and right Mic input.
  73. The result is forwarded to the ADC capture FIFO (thus to the standard capture
  74. PCM device).
  75. name='Audigy CD Playback Volume',index=0
  76. This control is used to attenuate samples from left and right IEC958 TTL
  77. digital inputs (usually used by a CDROM drive). The result samples are
  78. forwarded to the front DAC PCM slots of the Philips DAC.
  79. name='Audigy CD Capture Volume',index=0
  80. This control is used to attenuate samples from left and right IEC958 TTL
  81. digital inputs (usually used by a CDROM drive). The result samples are
  82. forwarded to the ADC capture FIFO (thus to the standard capture PCM device).
  83. name='IEC958 Optical Playback Volume',index=0
  84. This control is used to attenuate samples from left and right IEC958 optical
  85. digital input. The result samples are forwarded to the front DAC PCM slots
  86. of the Philips DAC.
  87. name='IEC958 Optical Capture Volume',index=0
  88. This control is used to attenuate samples from left and right IEC958 optical
  89. digital inputs. The result samples are forwarded to the ADC capture FIFO
  90. (thus to the standard capture PCM device).
  91. name='Line2 Playback Volume',index=0
  92. This control is used to attenuate samples from left and right I2S ADC
  93. inputs (on the AudigyDrive). The result samples are forwarded to the front
  94. DAC PCM slots of the Philips DAC.
  95. name='Line2 Capture Volume',index=1
  96. This control is used to attenuate samples from left and right I2S ADC
  97. inputs (on the AudigyDrive). The result samples are forwarded to the ADC
  98. capture FIFO (thus to the standard capture PCM device).
  99. name='Analog Mix Playback Volume',index=0
  100. This control is used to attenuate samples from left and right I2S ADC
  101. inputs from Philips ADC. The result samples are forwarded to the front
  102. DAC PCM slots of the Philips DAC. This contains mix from analog sources
  103. like CD, Line In, Aux, ....
  104. name='Analog Mix Capture Volume',index=1
  105. This control is used to attenuate samples from left and right I2S ADC
  106. inputs Philips ADC. The result samples are forwarded to the ADC
  107. capture FIFO (thus to the standard capture PCM device).
  108. name='Aux2 Playback Volume',index=0
  109. This control is used to attenuate samples from left and right I2S ADC
  110. inputs (on the AudigyDrive). The result samples are forwarded to the front
  111. DAC PCM slots of the Philips DAC.
  112. name='Aux2 Capture Volume',index=1
  113. This control is used to attenuate samples from left and right I2S ADC
  114. inputs (on the AudigyDrive). The result samples are forwarded to the ADC
  115. capture FIFO (thus to the standard capture PCM device).
  116. name='Front Playback Volume',index=0
  117. All stereo signals are mixed together and mirrored to surround, center and LFE.
  118. This control is used to attenuate samples for left and right front speakers of
  119. this mix.
  120. name='Surround Playback Volume',index=0
  121. All stereo signals are mixed together and mirrored to surround, center and LFE.
  122. This control is used to attenuate samples for left and right surround speakers of
  123. this mix.
  124. name='Center Playback Volume',index=0
  125. All stereo signals are mixed together and mirrored to surround, center and LFE.
  126. This control is used to attenuate sample for center speaker of this mix.
  127. name='LFE Playback Volume',index=0
  128. All stereo signals are mixed together and mirrored to surround, center and LFE.
  129. This control is used to attenuate sample for LFE speaker of this mix.
  130. name='Tone Control - Switch',index=0
  131. This control turns the tone control on or off. The samples for front, rear
  132. and center / LFE outputs are affected.
  133. name='Tone Control - Bass',index=0
  134. This control sets the bass intensity. There is no neutral value!!
  135. When the tone control code is activated, the samples are always modified.
  136. The closest value to pure signal is 20.
  137. name='Tone Control - Treble',index=0
  138. This control sets the treble intensity. There is no neutral value!!
  139. When the tone control code is activated, the samples are always modified.
  140. The closest value to pure signal is 20.
  141. name='Master Playback Volume',index=0
  142. This control is used to attenuate samples for front, surround, center and
  143. LFE outputs.
  144. name='IEC958 Optical Raw Playback Switch',index=0
  145. If this switch is on, then the samples for the IEC958 (S/PDIF) digital
  146. output are taken only from the raw FX8010 PCM, otherwise standard front
  147. PCM samples are taken.
  148. 2) PCM stream related controls
  149. ------------------------------
  150. name='EMU10K1 PCM Volume',index 0-31
  151. Channel volume attenuation in range 0-0xffff. The maximum value (no
  152. attenuation) is default. The channel mapping for three values is
  153. as follows:
  154. 0 - mono, default 0xffff (no attenuation)
  155. 1 - left, default 0xffff (no attenuation)
  156. 2 - right, default 0xffff (no attenuation)
  157. name='EMU10K1 PCM Send Routing',index 0-31
  158. This control specifies the destination - FX-bus accumulators. There 24
  159. values with this mapping:
  160. 0 - mono, A destination (FX-bus 0-63), default 0
  161. 1 - mono, B destination (FX-bus 0-63), default 1
  162. 2 - mono, C destination (FX-bus 0-63), default 2
  163. 3 - mono, D destination (FX-bus 0-63), default 3
  164. 4 - mono, E destination (FX-bus 0-63), default 0
  165. 5 - mono, F destination (FX-bus 0-63), default 0
  166. 6 - mono, G destination (FX-bus 0-63), default 0
  167. 7 - mono, H destination (FX-bus 0-63), default 0
  168. 8 - left, A destination (FX-bus 0-63), default 0
  169. 9 - left, B destination (FX-bus 0-63), default 1
  170. 10 - left, C destination (FX-bus 0-63), default 2
  171. 11 - left, D destination (FX-bus 0-63), default 3
  172. 12 - left, E destination (FX-bus 0-63), default 0
  173. 13 - left, F destination (FX-bus 0-63), default 0
  174. 14 - left, G destination (FX-bus 0-63), default 0
  175. 15 - left, H destination (FX-bus 0-63), default 0
  176. 16 - right, A destination (FX-bus 0-63), default 0
  177. 17 - right, B destination (FX-bus 0-63), default 1
  178. 18 - right, C destination (FX-bus 0-63), default 2
  179. 19 - right, D destination (FX-bus 0-63), default 3
  180. 20 - right, E destination (FX-bus 0-63), default 0
  181. 21 - right, F destination (FX-bus 0-63), default 0
  182. 22 - right, G destination (FX-bus 0-63), default 0
  183. 23 - right, H destination (FX-bus 0-63), default 0
  184. Don't forget that it's illegal to assign a channel to the same FX-bus accumulator
  185. more than once (it means 0=0 && 1=0 is an invalid combination).
  186. name='EMU10K1 PCM Send Volume',index 0-31
  187. It specifies the attenuation (amount) for given destination in range 0-255.
  188. The channel mapping is following:
  189. 0 - mono, A destination attn, default 255 (no attenuation)
  190. 1 - mono, B destination attn, default 255 (no attenuation)
  191. 2 - mono, C destination attn, default 0 (mute)
  192. 3 - mono, D destination attn, default 0 (mute)
  193. 4 - mono, E destination attn, default 0 (mute)
  194. 5 - mono, F destination attn, default 0 (mute)
  195. 6 - mono, G destination attn, default 0 (mute)
  196. 7 - mono, H destination attn, default 0 (mute)
  197. 8 - left, A destination attn, default 255 (no attenuation)
  198. 9 - left, B destination attn, default 0 (mute)
  199. 10 - left, C destination attn, default 0 (mute)
  200. 11 - left, D destination attn, default 0 (mute)
  201. 12 - left, E destination attn, default 0 (mute)
  202. 13 - left, F destination attn, default 0 (mute)
  203. 14 - left, G destination attn, default 0 (mute)
  204. 15 - left, H destination attn, default 0 (mute)
  205. 16 - right, A destination attn, default 0 (mute)
  206. 17 - right, B destination attn, default 255 (no attenuation)
  207. 18 - right, C destination attn, default 0 (mute)
  208. 19 - right, D destination attn, default 0 (mute)
  209. 20 - right, E destination attn, default 0 (mute)
  210. 21 - right, F destination attn, default 0 (mute)
  211. 22 - right, G destination attn, default 0 (mute)
  212. 23 - right, H destination attn, default 0 (mute)
  213. 4) MANUALS/PATENTS:
  214. -------------------
  215. ftp://opensource.creative.com/pub/doc
  216. -------------------------------------
  217. Files:
  218. LM4545.pdf AC97 Codec
  219. m2049.pdf The EMU10K1 Digital Audio Processor
  220. hog63.ps FX8010 - A DSP Chip Architecture for Audio Effects
  221. WIPO Patents
  222. ------------
  223. Patent numbers:
  224. WO 9901813 (A1) Audio Effects Processor with multiple asynchronous (Jan. 14, 1999)
  225. streams
  226. WO 9901814 (A1) Processor with Instruction Set for Audio Effects (Jan. 14, 1999)
  227. WO 9901953 (A1) Audio Effects Processor having Decoupled Instruction
  228. Execution and Audio Data Sequencing (Jan. 14, 1999)
  229. US Patents (http://www.uspto.gov/)
  230. ----------------------------------
  231. US 5925841 Digital Sampling Instrument employing cache memory (Jul. 20, 1999)
  232. US 5928342 Audio Effects Processor integrated on a single chip (Jul. 27, 1999)
  233. with a multiport memory onto which multiple asynchronous
  234. digital sound samples can be concurrently loaded
  235. US 5930158 Processor with Instruction Set for Audio Effects (Jul. 27, 1999)
  236. US 6032235 Memory initialization circuit (Tram) (Feb. 29, 2000)
  237. US 6138207 Interpolation looping of audio samples in cache connected to (Oct. 24, 2000)
  238. system bus with prioritization and modification of bus transfers
  239. in accordance with loop ends and minimum block sizes
  240. US 6151670 Method for conserving memory storage using a (Nov. 21, 2000)
  241. pool of short term memory registers
  242. US 6195715 Interrupt control for multiple programs communicating with (Feb. 27, 2001)
  243. a common interrupt by associating programs to GP registers,
  244. defining interrupt register, polling GP registers, and invoking
  245. callback routine associated with defined interrupt register