blob: 5b7a5487d5057401fae3635f6d3cf4a8a58a7fc8 [file] [log] [blame]
Thibault Le Meurf8c78b82007-07-12 11:26:35 +02001 Guide to using M-Audio Audiophile USB with ALSA and Jack v1.4
Thibault LE MEURe3113342006-03-14 11:44:53 +01002 ========================================================
3
4 Thibault Le Meur <Thibault.LeMeur@supelec.fr>
5
6This document is a guide to using the M-Audio Audiophile USB (tm) device with
7ALSA and JACK.
8
Thibault Le Meurf8c78b82007-07-12 11:26:35 +02009History
10=======
11* v1.4 - Thibault Le Meur (2007-07-11)
12 - Added Low Endianness nature of 16bits-modes
13 found by Hakan Lennestal <Hakan.Lennestal@brfsodrahamn.se>
14 - Modifying document structure
15
16
Thibault LE MEURe3113342006-03-14 11:44:53 +0100171 - Audiophile USB Specs and correct usage
18==========================================
Thibault Le Meurf8c78b82007-07-12 11:26:35 +020019
Thibault LE MEURe3113342006-03-14 11:44:53 +010020This part is a reminder of important facts about the functions and limitations
21of the device.
22
23The device has 4 audio interfaces, and 2 MIDI ports:
24 * Analog Stereo Input (Ai)
Thibault LE MEUR19739fe2006-03-21 11:06:40 +010025 - This port supports 2 pairs of line-level audio inputs (1/4" TS and RCA)
26 - When the 1/4" TS (jack) connectors are connected, the RCA connectors
27 are disabled
Thibault LE MEURe3113342006-03-14 11:44:53 +010028 * Analog Stereo Output (Ao)
29 * Digital Stereo Input (Di)
30 * Digital Stereo Output (Do)
31 * Midi In (Mi)
32 * Midi Out (Mo)
33
Charis Kouzinopoulos5732e7a2006-04-18 15:42:29 +020034The internal DAC/ADC has the following characteristics:
Thibault LE MEURe3113342006-03-14 11:44:53 +010035* sample depth of 16 or 24 bits
36* sample rate from 8kHz to 96kHz
Thibault Le Meurf8c78b82007-07-12 11:26:35 +020037* Two interfaces can't use different sample depths at the same time.
38Moreover, the Audiophile USB documentation gives the following Warning:
39"Please exit any audio application running before switching between bit depths"
Thibault LE MEURe3113342006-03-14 11:44:53 +010040
41Due to the USB 1.1 bandwidth limitation, a limited number of interfaces can be
42activated at the same time depending on the audio mode selected:
Thibault Le Meurf8c78b82007-07-12 11:26:35 +020043 * 16-bit/48kHz ==> 4 channels in + 4 channels out
Thibault LE MEURe3113342006-03-14 11:44:53 +010044 - Ai+Ao+Di+Do
Thibault Le Meurf8c78b82007-07-12 11:26:35 +020045 * 24-bit/48kHz ==> 4 channels in + 2 channels out,
46 or 2 channels in + 4 channels out
Thibault LE MEURe3113342006-03-14 11:44:53 +010047 - Ai+Ao+Do or Ai+Di+Ao or Ai+Di+Do or Di+Ao+Do
Thibault Le Meurf8c78b82007-07-12 11:26:35 +020048 * 24-bit/96kHz ==> 2 channels in _or_ 2 channels out (half duplex only)
Thibault LE MEURe3113342006-03-14 11:44:53 +010049 - Ai or Ao or Di or Do
50
51Important facts about the Digital interface:
52--------------------------------------------
Charis Kouzinopoulos5732e7a2006-04-18 15:42:29 +020053 * The Do port additionally supports surround-encoded AC-3 and DTS passthrough,
54though I haven't tested it under Linux
Thibault LE MEURe3113342006-03-14 11:44:53 +010055 - Note that in this setup only the Do interface can be enabled
56 * Apart from recording an audio digital stream, enabling the Di port is a way
Thibault LE MEUR19739fe2006-03-21 11:06:40 +010057to synchronize the device to an external sample clock
Thibault LE MEURe3113342006-03-14 11:44:53 +010058 - As a consequence, the Di port must be enable only if an active Digital
59source is connected
60 - Enabling Di when no digital source is connected can result in a
61synchronization error (for instance sound played at an odd sample rate)
62
63
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200642 - Audiophile USB MIDI support in ALSA
65=======================================
Thibault LE MEURe3113342006-03-14 11:44:53 +010066
Thibault Le Meurf8c78b82007-07-12 11:26:35 +020067The Audiophile USB MIDI ports will be automatically supported once the
Thibault LE MEURe3113342006-03-14 11:44:53 +010068following modules have been loaded:
69 * snd-usb-audio
Thibault LE MEURe3113342006-03-14 11:44:53 +010070 * snd-seq-midi
71
Charis Kouzinopoulos5732e7a2006-04-18 15:42:29 +020072No additional setting is required.
Thibault LE MEURe3113342006-03-14 11:44:53 +010073
Thibault Le Meurf8c78b82007-07-12 11:26:35 +020074
753 - Audiophile USB Audio support in ALSA
76========================================
Thibault LE MEURe3113342006-03-14 11:44:53 +010077
78Audio functions of the Audiophile USB device are handled by the snd-usb-audio
79module. This module can work in a default mode (without any device-specific
Charis Kouzinopoulos5732e7a2006-04-18 15:42:29 +020080parameter), or in an "advanced" mode with the device-specific parameter called
Thibault LE MEURe3113342006-03-14 11:44:53 +010081"device_setup".
82
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200833.1 - Default Alsa driver mode
84------------------------------
Thibault LE MEURe3113342006-03-14 11:44:53 +010085
Thibault Le Meurf8c78b82007-07-12 11:26:35 +020086The default behavior of the snd-usb-audio driver is to list the device
87capabilities at startup and activate the required mode when required
88by the applications: for instance if the user is recording in a
8924bit-depth-mode and immediately after wants to switch to a 16bit-depth mode,
90the snd-usb-audio module will reconfigure the device on the fly.
Thibault LE MEURe3113342006-03-14 11:44:53 +010091
Thibault Le Meurf8c78b82007-07-12 11:26:35 +020092This approach has the advantage to let the driver automatically switch from sample
93rates/depths automatically according to the user's needs. However, those who
94are using the device under windows know that this is not how the device is meant to
95work: under windows applications must be closed before using the m-audio control
96panel to switch the device working mode. Thus as we'll see in next section, this
97Default Alsa driver mode can lead to device misconfigurations.
98
99Let's get back to the Default Alsa driver mode for now. In this case the
100Audiophile interfaces are mapped to alsa pcm devices in the following
101way (I suppose the device's index is 1):
Thibault LE MEURe3113342006-03-14 11:44:53 +0100102 * hw:1,0 is Ao in playback and Di in capture
103 * hw:1,1 is Do in playback and Ai in capture
104 * hw:1,2 is Do in AC3/DTS passthrough mode
105
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200106In this mode, the device uses Big Endian byte-encoding so that
107supported audio format are S16_BE for 16-bit depth modes and S24_3BE for
10824-bits depth mode. One exception is the hw:1,2 port which is reported
109to be Little Endian compliant (supposedly supporting S16_LE) but processes
110in fact only S16_BE streams.
Thibault LE MEURe3113342006-03-14 11:44:53 +0100111
112Examples:
113 * playing a S24_3BE encoded raw file to the Ao port
114 % aplay -D hw:1,0 -c2 -t raw -r48000 -fS24_3BE test.raw
115 * recording a S24_3BE encoded raw file from the Ai port
116 % arecord -D hw:1,1 -c2 -t raw -r48000 -fS24_3BE test.raw
117 * playing a S16_BE encoded raw file to the Do port
118 % aplay -D hw:1,1 -c2 -t raw -r48000 -fS16_BE test.raw
119
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200120If you're happy with the default Alsa driver mode and don't experience any
Thibault LE MEURe3113342006-03-14 11:44:53 +0100121issue with this mode, then you can skip the following chapter.
122
Thibault Le Meurf8c78b82007-07-12 11:26:35 +02001233.2 - Advanced module setup
124---------------------------
Thibault LE MEURe3113342006-03-14 11:44:53 +0100125
126Due to the hardware constraints described above, the device initialization made
127by the Alsa driver in default mode may result in a corrupted state of the
128device. For instance, a particularly annoying issue is that the sound captured
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200129from the Ai interface sounds distorted (as if boosted with an excessive high
130volume gain).
Thibault LE MEURe3113342006-03-14 11:44:53 +0100131
132For people having this problem, the snd-usb-audio module has a new module
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200133parameter called "device_setup" (this parameter was introduced in kernel
134release 2.6.17)
Thibault LE MEURe3113342006-03-14 11:44:53 +0100135
Thibault Le Meurf8c78b82007-07-12 11:26:35 +02001363.2.1 - Initializing the working mode of the Audiophile USB
Thibault LE MEURe3113342006-03-14 11:44:53 +0100137
Charis Kouzinopoulos5732e7a2006-04-18 15:42:29 +0200138As far as the Audiophile USB device is concerned, this value let the user
Thibault LE MEURe3113342006-03-14 11:44:53 +0100139specify:
140 * the sample depth
141 * the sample rate
142 * whether the Di port is used or not
143
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200144When initialized with "device_setup=0x00", the snd-usb-audio module has
145the same behaviour as when the parameter is omitted (see paragraph "Default
146Alsa driver mode" above)
147
148Others modes are described in the following subsections.
149
1503.2.1.1 - 16-bit modes
151
152The two supported modes are:
153
Thibault LE MEURe3113342006-03-14 11:44:53 +0100154 * device_setup=0x01
155 - 16bits 48kHz mode with Di disabled
156 - Ai,Ao,Do can be used at the same time
157 - hw:1,0 is not available in capture mode
158 - hw:1,2 is not available
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200159
Thibault LE MEURe3113342006-03-14 11:44:53 +0100160 * device_setup=0x11
161 - 16bits 48kHz mode with Di enabled
162 - Ai,Ao,Di,Do can be used at the same time
163 - hw:1,0 is available in capture mode
164 - hw:1,2 is not available
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200165
166In this modes the device operates only at 16bits-modes. Before kernel 2.6.23,
167the devices where reported to be Big-Endian when in fact they were Little-Endian
168so that playing a file was a matter of using:
169 % aplay -D hw:1,1 -c2 -t raw -r48000 -fS16_BE test_S16_LE.raw
170where "test_S16_LE.raw" was in fact a little-endian sample file.
171
172Thanks to Hakan Lennestal (who discovered the Little-Endiannes of the device in
173these modes) a fix has been committed (expected in kernel 2.6.23) and
174Alsa now reports Little-Endian interfaces. Thus playing a file now is as simple as
175using:
176 % aplay -D hw:1,1 -c2 -t raw -r48000 -fS16_LE test_S16_LE.raw
177
1783.2.1.2 - 24-bit modes
179
180The three supported modes are:
181
Thibault LE MEURe3113342006-03-14 11:44:53 +0100182 * device_setup=0x09
183 - 24bits 48kHz mode with Di disabled
184 - Ai,Ao,Do can be used at the same time
185 - hw:1,0 is not available in capture mode
186 - hw:1,2 is not available
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200187
Thibault LE MEURe3113342006-03-14 11:44:53 +0100188 * device_setup=0x19
189 - 24bits 48kHz mode with Di enabled
190 - 3 ports from {Ai,Ao,Di,Do} can be used at the same time
191 - hw:1,0 is available in capture mode and an active digital source must be
192 connected to Di
193 - hw:1,2 is not available
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200194
Thibault LE MEURe3113342006-03-14 11:44:53 +0100195 * device_setup=0x0D or 0x10
196 - 24bits 96kHz mode
197 - Di is enabled by default for this mode but does not need to be connected
198 to an active source
199 - Only 1 port from {Ai,Ao,Di,Do} can be used at the same time
200 - hw:1,0 is available in captured mode
201 - hw:1,2 is not available
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200202
203In these modes the device is only Big-Endian compliant (see "Default Alsa driver
204mode" above for an aplay command example)
205
2063.2.1.3 - AC3 w/ DTS passthru mode
207
208This mode is untested, I have no AC3 compliant device to test it. I uses:
209
Thibault LE MEURe3113342006-03-14 11:44:53 +0100210 * device_setup=0x03
211 - 16bits 48kHz mode with only the Do port enabled
212 - AC3 with DTS passthru (not tested)
213 - Caution with this setup the Do port is mapped to the pcm device hw:1,0
214
Thibault Le Meurf8c78b82007-07-12 11:26:35 +02002153.2.2 - How to use the device_setup parameter
216----------------------------------------------
Thibault LE MEURe3113342006-03-14 11:44:53 +0100217
218The parameter can be given:
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200219
Thibault LE MEURe3113342006-03-14 11:44:53 +0100220 * By manually probing the device (as root):
221 # modprobe -r snd-usb-audio
222 # modprobe snd-usb-audio index=1 device_setup=0x09
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200223
Thibault LE MEURe3113342006-03-14 11:44:53 +0100224 * Or while configuring the modules options in your modules configuration file
225 - For Fedora distributions, edit the /etc/modprobe.conf file:
226 alias snd-card-1 snd-usb-audio
227 options snd-usb-audio index=1 device_setup=0x09
228
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200229CAUTION when initializaing the device
230-------------------------------------
231
232 * Correct initialization on the device requires that device_setup is given to
233 the module BEFORE the device is turned on. So, if you use the "manual probing"
234 method described above, take care to power-on the device AFTER this initialization.
235
236 * Failing to respect this will lead in a misconfiguration of the device. In this case
237 turn off the device, unproble the snd-usb-audio module, then probe it again with
238 correct device_setup parameter and then (and only then) turn on the device again.
239
240 * If you've correctly initialized the device in a valid mode and then want to switch
241 to another mode (possibly with another sample-depth), please use also the following
242 procedure:
Charis Kouzinopoulos5732e7a2006-04-18 15:42:29 +0200243 - first turn off the device
244 - de-register the snd-usb-audio module (modprobe -r)
245 - change the device_setup parameter by changing the device_setup
246 option in /etc/modprobe.conf
Thibault LE MEURe3113342006-03-14 11:44:53 +0100247 - turn on the device
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200248 * A workaround for this last issue has been applied to kernel 2.6.23, but it may not
249 be enough to ensure the 'stability' of the device initialization.
Thibault LE MEURe3113342006-03-14 11:44:53 +0100250
Thibault Le Meurf8c78b82007-07-12 11:26:35 +02002513.2.3 - Technical details for hackers
252-------------------------------------
253This section is for hackers, wanting to understand details about the device
254internals and how Alsa supports it.
255
2563.2.3.1 - Audiophile USB's device_setup structure
Thibault LE MEURe3113342006-03-14 11:44:53 +0100257
258If you want to understand the device_setup magic numbers for the Audiophile
259USB, you need some very basic understanding of binary computation. However,
Charis Kouzinopoulos5732e7a2006-04-18 15:42:29 +0200260this is not required to use the parameter and you may skip this section.
Thibault LE MEURe3113342006-03-14 11:44:53 +0100261
262The device_setup is one byte long and its structure is the following:
263
264 +---+---+---+---+---+---+---+---+
265 | b7| b6| b5| b4| b3| b2| b1| b0|
266 +---+---+---+---+---+---+---+---+
267 | 0 | 0 | 0 | Di|24B|96K|DTS|SET|
268 +---+---+---+---+---+---+---+---+
269
270Where:
271 * b0 is the "SET" bit
272 - it MUST be set if device_setup is initialized
273 * b1 is the "DTS" bit
274 - it is set only for Digital output with DTS/AC3
275 - this setup is not tested
276 * b2 is the Rate selection flag
277 - When set to "1" the rate range is 48.1-96kHz
278 - Otherwise the sample rate range is 8-48kHz
279 * b3 is the bit depth selection flag
280 - When set to "1" samples are 24bits long
281 - Otherwise they are 16bits long
282 - Note that b2 implies b3 as the 96kHz mode is only supported for 24 bits
283 samples
284 * b4 is the Digital input flag
285 - When set to "1" the device assumes that an active digital source is
286 connected
287 - You shouldn't enable Di if no source is seen on the port (this leads to
288 synchronization issues)
289 - b4 is implied by b2 (since only one port is enabled at a time no synch
290 error can occur)
291 * b5 to b7 are reserved for future uses, and must be set to "0"
292 - might become Ao, Do, Ai, for b7, b6, b4 respectively
293
294Caution:
295 * there is no check on the value you will give to device_setup
296 - for instance choosing 0x05 (16bits 96kHz) will fail back to 0x09 since
297 b2 implies b3. But _there_will_be_no_warning_ in /var/log/messages
298 * Hardware constraints due to the USB bus limitation aren't checked
299 - choosing b2 will prepare all interfaces for 24bits/96kHz but you'll
300 only be able to use one at the same time
301
Thibault Le Meurf8c78b82007-07-12 11:26:35 +02003023.2.3.2 - USB implementation details for this device
Thibault LE MEURe3113342006-03-14 11:44:53 +0100303
Charis Kouzinopoulos5732e7a2006-04-18 15:42:29 +0200304You may safely skip this section if you're not interested in driver
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200305hacking.
Thibault LE MEURe3113342006-03-14 11:44:53 +0100306
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200307This section describes some internal aspects of the device and summarizes the
Charis Kouzinopoulos5732e7a2006-04-18 15:42:29 +0200308data I got by usb-snooping the windows and Linux drivers.
Thibault LE MEURe3113342006-03-14 11:44:53 +0100309
Thibault LE MEUR19739fe2006-03-21 11:06:40 +0100310The M-Audio Audiophile USB has 7 USB Interfaces:
Thibault LE MEURe3113342006-03-14 11:44:53 +0100311a "USB interface":
Thibault LE MEUR19739fe2006-03-21 11:06:40 +0100312 * USB Interface nb.0
313 * USB Interface nb.1
Thibault LE MEURe3113342006-03-14 11:44:53 +0100314 - Audio Control function
Thibault LE MEUR19739fe2006-03-21 11:06:40 +0100315 * USB Interface nb.2
Thibault LE MEURe3113342006-03-14 11:44:53 +0100316 - Analog Output
Thibault LE MEUR19739fe2006-03-21 11:06:40 +0100317 * USB Interface nb.3
Thibault LE MEURe3113342006-03-14 11:44:53 +0100318 - Digital Output
Thibault LE MEUR19739fe2006-03-21 11:06:40 +0100319 * USB Interface nb.4
Thibault LE MEURe3113342006-03-14 11:44:53 +0100320 - Analog Input
Thibault LE MEUR19739fe2006-03-21 11:06:40 +0100321 * USB Interface nb.5
Thibault LE MEURe3113342006-03-14 11:44:53 +0100322 - Digital Input
Thibault LE MEUR19739fe2006-03-21 11:06:40 +0100323 * USB Interface nb.6
Thibault LE MEURe3113342006-03-14 11:44:53 +0100324 - MIDI interface compliant with the MIDIMAN quirk
325
326Each interface has 5 altsettings (AltSet 1,2,3,4,5) except:
327 * Interface 3 (Digital Out) has an extra Alset nb.6
328 * Interface 5 (Digital In) does not have Alset nb.3 and 5
329
330Here is a short description of the AltSettings capabilities:
331 * AltSettings 1 corresponds to
332 - 24-bit depth, 48.1-96kHz sample mode
333 - Adaptive playback (Ao and Do), Synch capture (Ai), or Asynch capture (Di)
334 * AltSettings 2 corresponds to
335 - 24-bit depth, 8-48kHz sample mode
336 - Asynch capture and playback (Ao,Ai,Do,Di)
337 * AltSettings 3 corresponds to
338 - 24-bit depth, 8-48kHz sample mode
339 - Synch capture (Ai) and Adaptive playback (Ao,Do)
340 * AltSettings 4 corresponds to
341 - 16-bit depth, 8-48kHz sample mode
342 - Asynch capture and playback (Ao,Ai,Do,Di)
343 * AltSettings 5 corresponds to
344 - 16-bit depth, 8-48kHz sample mode
345 - Synch capture (Ai) and Adaptive playback (Ao,Do)
346 * AltSettings 6 corresponds to
347 - 16-bit depth, 8-48kHz sample mode
348 - Synch playback (Do), audio format type III IEC1937_AC-3
349
Charis Kouzinopoulos5732e7a2006-04-18 15:42:29 +0200350In order to ensure a correct initialization of the device, the driver
Thibault LE MEURe3113342006-03-14 11:44:53 +0100351_must_know_ how the device will be used:
Charis Kouzinopoulos5732e7a2006-04-18 15:42:29 +0200352 * if DTS is chosen, only Interface 2 with AltSet nb.6 must be
Thibault LE MEURe3113342006-03-14 11:44:53 +0100353 registered
354 * if 96KHz only AltSets nb.1 of each interface must be selected
355 * if samples are using 24bits/48KHz then AltSet 2 must me used if
356 Digital input is connected, and only AltSet nb.3 if Digital input
357 is not connected
358 * if samples are using 16bits/48KHz then AltSet 4 must me used if
359 Digital input is connected, and only AltSet nb.5 if Digital input
360 is not connected
361
362When device_setup is given as a parameter to the snd-usb-audio module, the
Charis Kouzinopoulos5732e7a2006-04-18 15:42:29 +0200363parse_audio_endpoints function uses a quirk called
Thibault LE MEURe3113342006-03-14 11:44:53 +0100364"audiophile_skip_setting_quirk" in order to prevent AltSettings not
365corresponding to device_setup from being registered in the driver.
366
Thibault Le Meurf8c78b82007-07-12 11:26:35 +02003674 - Audiophile USB and Jack support
Thibault LE MEURe3113342006-03-14 11:44:53 +0100368===================================
369
370This section deals with support of the Audiophile USB device in Jack.
Thibault LE MEURe3113342006-03-14 11:44:53 +0100371
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200372There are 2 main potential issues when using Jackd with the device:
373* support for Big-Endian devices in 24-bit modes
374* support for 4-in / 4-out channels
Thibault LE MEURe3113342006-03-14 11:44:53 +0100375
Thibault Le Meurf8c78b82007-07-12 11:26:35 +02003764.1 - Direct support in Jackd
377-----------------------------
378
379Jack supports big endian devices only in recent versions (thanks to
380Andreas Steinmetz for his first big-endian patch). I can't remember
381extacly when this support was released into jackd, let's just say that
382with jackd version 0.103.0 it's almost ok (just a small bug is affecting
38316bits Big-Endian devices, but since you've read carefully the above
384paragraphs, you're now using kernel >= 2.6.23 and your 16bits devices
385are now Little Endians ;-) ).
386
387You can run jackd with the following command for playback with Ao and
388record with Ai:
389 % jackd -R -dalsa -Phw:1,0 -r48000 -p128 -n2 -D -Chw:1,1
390
3914.2 - Using Alsa plughw
392-----------------------
393If you don't have a recent Jackd installed, you can downgrade to using
394the Alsa "plug" converter.
Thibault LE MEURe3113342006-03-14 11:44:53 +0100395
396For instance here is one way to run Jack with 2 playback channels on Ao and 2
397capture channels from Ai:
398 % jackd -R -dalsa -dplughw:1 -r48000 -p256 -n2 -D -Cplughw:1,1
399
Thibault LE MEURe3113342006-03-14 11:44:53 +0100400However you may see the following warning message:
401"You appear to be using the ALSA software "plug" layer, probably a result of
402using the "default" ALSA device. This is less efficient than it could be.
403Consider using a hardware device instead rather than using the plug layer."
404
Thibault Le Meurf8c78b82007-07-12 11:26:35 +02004054.3 - Getting 2 input and/or output interfaces in Jack
Charis Kouzinopoulos5732e7a2006-04-18 15:42:29 +0200406------------------------------------------------------
407
408As you can see, starting the Jack server this way will only enable 1 stereo
409input (Di or Ai) and 1 stereo output (Ao or Do).
410
411This is due to the following restrictions:
412* Jack can only open one capture device and one playback device at a time
413* The Audiophile USB is seen as 2 (or three) Alsa devices: hw:1,0, hw:1,1
414 (and optionally hw:1,2)
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200415
Charis Kouzinopoulos5732e7a2006-04-18 15:42:29 +0200416If you want to get Ai+Di and/or Ao+Do support with Jack, you would need to
417combine the Alsa devices into one logical "complex" device.
418
419If you want to give it a try, I recommend reading the information from
420this page: http://www.sound-man.co.uk/linuxaudio/ice1712multi.html
421It is related to another device (ice1712) but can be adapted to suit
422the Audiophile USB.
423
424Enabling multiple Audiophile USB interfaces for Jackd will certainly require:
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200425* Making sure your Jackd version has the MMAP_COMPLEX patch (see the ice1712 page)
426* (maybe) patching the alsa-lib/src/pcm/pcm_multi.c file (see the ice1712 page)
Charis Kouzinopoulos5732e7a2006-04-18 15:42:29 +0200427* define a multi device (combination of hw:1,0 and hw:1,1) in your .asoundrc
428 file
429* start jackd with this device
430
Thibault Le Meurf8c78b82007-07-12 11:26:35 +0200431I had no success in testing this for now, if you have any success with this kind
432of setup, please drop me an email.