quirk for Pioneer DJ DJM-250MK2 usb sound card
PATCH 1/1 quirk for Pioneer DJ DJM-250MK2 usb sound card
Hello,
I have created a quirk that adds support for the Pioneer DJ DJM-250MK2 mixer (acts like a USB sound card, but Vendor Specific Class).
Output (from computer to card) is working: 8 channels, 48 000 Hz, S24_3LE.
Input is not working. I tried, but I was unable to make it working even under an officially supported OS with Pioneer drivers - Audacity or Mixxx see the channels, but there is no signal. It probably works only with Pioneer proprietary application. But I hope that even mere output support will be useful for someone. (it is usable for playback, just not for DVS)
Franta
---
sound/usb/quirks-table.h | 42 ++++++++++++++++++++++++++++++++++++++++++
1 file changed, 42 insertions(+)
sound/usb/quirks-table.h +0 -0
@@ -3592,5 +3592,47 @@ AU0828_DEVICE(0x2040, 0x7270, "Hauppauge", "HVR-950Q"),
}
}
},
+{
+ /*
+ * Pioneer DJ DJM-250MK2
+ * PCM is 8 channels out @ 48 fixed (endpoints 0x01).
+ * The output from computer to the mixer is usable.
+ *
+ * The input (phono or line to computer) is not working.
+ * It should be at endpoint 0x82 and probably also 8 channels, + * but it seems that it works only with Pioneer proprietary software. + * Even on officially supported OS, the Audacity was unable to record + * and Mixxx to recognize the control vinyls.
+ */
+ USB_DEVICE_VENDOR_SPEC(0x2b73, 0x0017),
+ .driver_info = (unsigned long) &(const struct snd_usb_audio_quirk) { + .ifnum = QUIRK_ANY_INTERFACE,
+ .type = QUIRK_COMPOSITE,
+ .data = (const struct snd_usb_audio_quirk[]) {
+ {
+ .ifnum = 0,
+ .type = QUIRK_AUDIO_FIXED_ENDPOINT, + .data = &(const struct audioformat) { + .formats = SNDRV_PCM_FMTBIT_S24_3LE, + .channels = 8, // outputs
+ .iface = 0,
+ .altsetting = 1,
+ .altset_idx = 1,
+ .endpoint = 0x01,
+ .ep_attr = USB_ENDPOINT_XFER_ISOC| + USB_ENDPOINT_SYNC_ASYNC, + .rates = SNDRV_PCM_RATE_48000, + .rate_min = 48000,
+ .rate_max = 48000,
+ .nr_rates = 1,
+ .rate_table = (unsigned int[]) { 48000 } + }
+ },
+ {
+ .ifnum = -1
+ }
+ }
+ }
+},
#undef USB_DEVICE_VENDOR_SPEC
Dne 24. 02. 20 v 17:29 František Kučera napsal(a):
Quoted 65 lines
Hello,
I have created a quirk that adds support for the Pioneer DJ DJM-250MK2 mixer (acts like a USB sound card, but Vendor Specific Class).
Output (from computer to card) is working: 8 channels, 48 000 Hz,
S24_3LE.Input is not working. I tried, but I was unable to make it working even under an officially supported OS with Pioneer drivers - Audacity or Mixxx see the channels, but there is no signal. It probably works only with Pioneer proprietary application. But I hope that even mere output support will be useful for someone. (it is usable for playback, just not for DVS)
Franta
Signed-off-by František Kučera <[email protected]>---
sound/usb/quirks-table.h | 42 ++++++++++++++++++++++++++++++++++++++++++1 file changed, 42 insertions(+)sound/usb/quirks-table.h +42
-0@@ -3592,5 +3592,47 @@ AU0828_DEVICE(0x2040, 0x7270, "Hauppauge", "HVR-950Q"), } } }, +{ + /* + * Pioneer DJ DJM-250MK2 + * PCM is 8 channels out @ 48 fixed (endpoints 0x01). + * The output from computer to the mixer is usable. + * + * The input (phono or line to computer) is not working. + * It should be at endpoint 0x82 and probably also 8 channels, + * but it seems that it works only with Pioneer proprietary software. + * Even on officially supported OS, the Audacity was unable to record + * and Mixxx to recognize the control vinyls. + */ + USB_DEVICE_VENDOR_SPEC(0x2b73, 0x0017), + .driver_info = (unsigned long) &(const struct snd_usb_audio_quirk) { + .ifnum = QUIRK_ANY_INTERFACE, + .type = QUIRK_COMPOSITE, + .data = (const struct snd_usb_audio_quirk[]) { + { + .ifnum = 0, + .type = QUIRK_AUDIO_FIXED_ENDPOINT, + .data = &(const struct audioformat) { + .formats = SNDRV_PCM_FMTBIT_S24_3LE, + .channels = 8, // outputs + .iface = 0, + .altsetting = 1, + .altset_idx = 1, + .endpoint = 0x01, + .ep_attr = USB_ENDPOINT_XFER_ISOC| + USB_ENDPOINT_SYNC_ASYNC, + .rates = SNDRV_PCM_RATE_48000, + .rate_min = 48000, + .rate_max = 48000, + .nr_rates = 1, + .rate_table = (unsigned int[]) { 48000 } + } + }, + { + .ifnum = -1 + } + } + } +},
Quoted 3 lines
#undefUSB_DEVICE_VENDOR_SPEC
Can anyone review this patch please?
Franta
Jaroslav Kysela
maintainerDne 04. 03. 20 v 17:03 František Kučera napsal(a):
Quoted 67 lines
Dne 24. 02. 20 v 17:29 František Kučera napsal(a):
Quoted 66 lines
Hello,
I have created a quirk that adds support for the Pioneer DJ DJM-250MK2 mixer (acts like a USB sound card, but Vendor Specific Class).
Output (from computer to card) is working: 8 channels, 48 000 Hz,
S24_3LE.Input is not working. I tried, but I was unable to make it working even under an officially supported OS with Pioneer drivers - Audacity or Mixxx see the channels, but there is no signal. It probably works only with Pioneer proprietary application. But I hope that even mere output support will be useful for someone. (it is usable for playback, just not for DVS)
Franta
Signed-off-by František Kučera <[email protected]>--- sound/usb/quirks-table.h | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+)sound/usb/quirks-table.h +42
-0@@ -3592,5 +3592,47 @@ AU0828_DEVICE(0x2040, 0x7270, "Hauppauge", "HVR-950Q"), } } }, +{ + /* + * Pioneer DJ DJM-250MK2 + * PCM is 8 channels out @ 48 fixed (endpoints 0x01). + * The output from computer to the mixer is usable. + * + * The input (phono or line to computer) is not working. + * It should be at endpoint 0x82 and probably also 8 channels, + * but it seems that it works only with Pioneer proprietary software. + * Even on officially supported OS, the Audacity was unable to record + * and Mixxx to recognize the control vinyls. + */ + USB_DEVICE_VENDOR_SPEC(0x2b73, 0x0017), + .driver_info = (unsigned long) &(const struct snd_usb_audio_quirk) { + .ifnum = QUIRK_ANY_INTERFACE, + .type = QUIRK_COMPOSITE, + .data = (const struct snd_usb_audio_quirk[]) { + { + .ifnum = 0, + .type = QUIRK_AUDIO_FIXED_ENDPOINT, + .data = &(const struct audioformat) { + .formats = SNDRV_PCM_FMTBIT_S24_3LE, + .channels = 8, // outputs + .iface = 0, + .altsetting = 1, + .altset_idx = 1, + .endpoint = 0x01, + .ep_attr = USB_ENDPOINT_XFER_ISOC| + USB_ENDPOINT_SYNC_ASYNC, + .rates = SNDRV_PCM_RATE_48000, + .rate_min = 48000, + .rate_max = 48000, + .nr_rates = 1, + .rate_table = (unsigned int[]) { 48000 } + } + }, + { + .ifnum = -1 + } + } + } +},
Quoted 3 lines
sound/usb/quirks-table.h AU0828_DEVICE(0x2040, 0x7270, "Hauppauge", "HVR-950Q"), · line 3638
Quoted 2 lines
sound/usb/quirks-table.h +0
-0#undef USB_DEVICE_VENDOR_SPECCan anyone review this patch please?
Takashi, could you put this patch to sound-next ? A partial support is better than no support.
Jaroslav
Signature · 2 lines
Jaroslav Kysela <[email protected]> Linux Sound Maintainer; ALSA Project; Red Hat, Inc.
Quoted 72 lines · Jaroslav Kysela
Dne 04. 03. 20 v 17:03 František Kučera napsal(a):
Quoted 61 lines
Dne 24. 02. 20 v 17:29 František Kučera napsal(a):
Quoted 60 lines
Hello,
I have created a quirk that adds support for the Pioneer DJ DJM-250MK2 mixer (acts like a USB sound card, but Vendor Specific Class).
Output (from computer to card) is working: 8 channels, 48 000 Hz,
S24_3LE.Input is not working. I tried, but I was unable to make it working even under an officially supported OS with Pioneer drivers - Audacity or Mixxx see the channels, but there is no signal. It probably works only with Pioneer proprietary application. But I hope that even mere output support will be useful for someone. (it is usable for playback, just not for DVS)
Franta
Signed-off-by František Kučera <[email protected]>--- sound/usb/quirks-table.h | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+)sound/usb/quirks-table.h +37
-0@@ -3592,5 +3592,47 @@ AU0828_DEVICE(0x2040, 0x7270, "Hauppauge", "HVR-950Q"), } } }, +{ + /* + * Pioneer DJ DJM-250MK2 + * PCM is 8 channels out @ 48 fixed (endpoints 0x01). + * The output from computer to the mixer is usable. + * + * The input (phono or line to computer) is not working. + * It should be at endpoint 0x82 and probably also 8 channels, + * but it seems that it works only with Pioneer proprietary software. + * Even on officially supported OS, the Audacity was unable to record + * and Mixxx to recognize the control vinyls. + */ + USB_DEVICE_VENDOR_SPEC(0x2b73, 0x0017), + .driver_info = (unsigned long) &(const struct snd_usb_audio_quirk) { + .ifnum = QUIRK_ANY_INTERFACE, + .type = QUIRK_COMPOSITE, + .data = (const struct snd_usb_audio_quirk[]) { + { + .ifnum = 0, + .type = QUIRK_AUDIO_FIXED_ENDPOINT, + .data = &(const struct audioformat) { + .formats = SNDRV_PCM_FMTBIT_S24_3LE, + .channels = 8, // outputs + .iface = 0, + .altsetting = 1, + .altset_idx = 1, + .endpoint = 0x01, + .ep_attr = USB_ENDPOINT_XFER_ISOC| + USB_ENDPOINT_SYNC_ASYNC, + .rates = SNDRV_PCM_RATE_48000, + .rate_min = 48000, + .rate_max = 48000, + .nr_rates = 1, + .rate_table = (unsigned int[]) { 48000 } + } + }, + {Quoted 8 lines
sound/usb/quirks-table.h AU0828_DEVICE(0x2040, 0x7270, "Hauppauge", "HVR-950Q"), · line 3638
Quoted 7 lines
sound/usb/quirks-table.h +5
-0+ .ifnum = -1 + } + } + } +}, #undef USB_DEVICE_VENDOR_SPECCan anyone review this patch please?
Quoted 2 lines
Takashi, could you put this patch to sound-next ? A partial support is better than no support.
František, could you resend the patch in a proper format? The original post couldn't be applied via git-am, as it was malformed.
Also, please try to adjust the subject line and the changelog text to be suitable for merging to the tree.
thanks,
Takashi
PATCH 1/1 ALSA: usb-audio: Add Pioneer DJ DJM-250MK2 quirk
From: František Kučera <[email protected]>
Pioneer DJ DJM-250MK2 is a mixer that acts like a USB sound card. The MIDI controller part is standard but the PCM part is "vendor specific". Output is enabled by this quirk: 8 channels, 48 000 Hz, S24_3LE. Input is not working.
--- sound/usb/quirks-table.h | 42 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+)
sound/usb/quirks-table.h +42 -0
@@ -3592,5 +3592,47 @@ AU0828_DEVICE(0x2040, 0x7270, "Hauppauge", "HVR-950Q"), } } }, +{ +/* +* Pioneer DJ DJM-250MK2 +* PCM is 8 channels out @ 48 fixed (endpoints 0x01). +* The output from computer to the mixer is usable. +* +* The input (phono or line to computer) is not working. +* It should be at endpoint 0x82 and probably also 8 channels, +* but it seems that it works only with Pioneer proprietary software. +* Even on officially supported OS, the Audacity was unable to record +* and Mixxx to recognize the control vinyls. +*/ + USB_DEVICE_VENDOR_SPEC(0x2b73, 0x0017), + .driver_info = (unsigned long ) &(const struct snd_usb_audio_quirk ) { + .ifnum =QUIRK_ANY_INTERFACE , + .type =QUIRK_COMPOSITE , + .data = (const struct snd_usb_audio_quirk []) { + { + .ifnum =0 , + .type =QUIRK_AUDIO_FIXED_ENDPOINT , + .data = &(const struct audioformat ) { + .formats =SNDRV_PCM_FMTBIT_S24_3LE , + .channels =8 ,// outputs + .iface =0 , + .altsetting =1 , + .altset_idx =1 , + .endpoint =0x01 , + .ep_attr =USB_ENDPOINT_XFER_ISOC | +USB_ENDPOINT_SYNC_ASYNC , + .rates =SNDRV_PCM_RATE_48000 , + .rate_min =48000 , + .rate_max =48000 , + .nr_rates =1 , + .rate_table = (unsigned int []) {48000 } + } + }, + { + .ifnum =-1 + } + } + } +}, #undef USB_DEVICE_VENDOR_SPEC
Signature · 1 line
2.20.1
Takashi Iwai
AppliedRe: [PATCH] ALSA: usb-audio: Add Pioneer DJ DJM-250MK2 quirk
Quoted 9 lines · František Kučera
From: František Kučera <[email protected]>
Pioneer DJ DJM-250MK2 is a mixer that acts like a USB sound card. The MIDI controller part is standard but the PCM part is "vendor specific". Output is enabled by this quirk: 8 channels, 48 000 Hz,
S24_3LE. Input is not working.Signed-off-by František Kučera <[email protected]>
Applied, thanks.
Takashi
Hi František,
a few months ago, I was working on patches to support the DJM-900MK2 mixer. I guess they are using a similar format on this mixer, at least your quirk is similar to mine. I did not submit these patches yet because I could not figure out a proper way to support both input and output. I'm not an expert on usb audio, but I'll share my thoughts. At least on the 900MK2, both playback and recording use the same interface:
I: If#= 0 Alt= 1 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=snd-usb-audio E: Ad=01(O) Atr=05(Isoc) MxPS=1024 Ivl=125us
E: Ad=82(I) Atr=05(Isoc) MxPS=1024 Ivl=125us
Thus, I introduced a quirk with .ifnum=0 for both capture and playback. The problem is that the device accepts sample rate change commands for the capture endpoint 0x82 only. Both endpoints are then configured to that sample rate. Contrary to that, snd-usb-audio expects that playback and recording is on two independent interface that both accept sample rate changes and can operate on different sample rates.
My first approach was introducing a quirk in sound/usb/clock.c, set_sample_rate_v1(). The quirk rejected changes to the sample rate of one interface when the other was already in use by returning EBUSY. This did work only if the capture endpoint was started before playback, which was not predictable when using pulseaudio. Can anyone help on that? Is there a supported device which I can look at that only allows the same sample rate on both endpoints?
Cheers
Fabian
Am 26.03.20 um 10:20 schrieb Jaroslav Kysela:
Quoted 93 lines
Dne 04. 03. 20 v 17:03 František Kučera napsal(a):
Quoted 78 lines
Dne 24. 02. 20 v 17:29 František Kučera napsal(a):
Quoted 77 lines
Hello,
I have created a quirk that adds support for the Pioneer DJ DJM-250MK2 mixer (acts like a USB sound card, but Vendor Specific Class).
Output (from computer to card) is working: 8 channels, 48 000 Hz,
S24_3LE.Input is not working. I tried, but I was unable to make it working even under an officially supported OS with Pioneer drivers - Audacity or Mixxx see the channels, but there is no signal. It probably works only with Pioneer proprietary application. But I hope that even mere output support will be useful for someone. (it is usable for playback, just not for DVS)
Franta
Signed-off-by František Kučera <[email protected]>---
sound/usb/quirks-table.h | 42
++++++++++++++++++++++++++++++++++++++++++1 file changed, 42 insertions(+)sound/usb/quirks-table.h +9
-0@@ -3592,5 +3592,47 @@ AU0828_DEVICE(0x2040, 0x7270, "Hauppauge", "HVR-950Q"), } } }, +{ + /* +* Pioneer DJ DJM-250MK2 +* PCM is 8 channels out @ 48 fixed (endpoints 0x01). +* The output from computer to the mixer is usable. +* +* The input (phono or line to computer) is not working. +* It should be at endpoint 0x82 and probably also 8 channels, +* but it seems that it works only with Pioneer proprietary software.
+ * Even on officially supported OS, the Audacity was unable to record
+ * and Mixxx to recognize the control vinyls.
+ */
+USB_DEVICE_VENDOR_SPEC(0x2b73, 0x0017),
+ .driver_info = (unsigned long) &(const structsnd_usb_audio_quirk) {
+ .ifnum =QUIRK_ANY_INTERFACE,
+ .type =QUIRK_COMPOSITE,
+ .data = (const struct snd_usb_audio_quirk[]) { + {
+ .ifnum = 0,
+ .type =QUIRK_AUDIO_FIXED_ENDPOINT, + .data = &(const struct audioformat) { + .formats =SNDRV_PCM_FMTBIT_S24_3LE,
+ .channels = 8, // outputs + .iface = 0,
+ .altsetting = 1,
+ .altset_idx = 1,
+ .endpoint =0x01,
+ .ep_attr = USB_ENDPOINT_XFER_ISOC|
+USB_ENDPOINT_SYNC_ASYNC,
+ .rates =SNDRV_PCM_RATE_48000, + .rate_min = 48000, + .rate_max = 48000, + .nr_rates = 1,
+ .rate_table = (unsigned int[]) { 48000 }
+ }
+ },
+ {Quoted 8 lines
Quoted 7 lines
+ .ifnum = -1
+ }
+ }
+ }
+},
#undefUSB_DEVICE_VENDOR_SPECCan anyone review this patch please?
Takashi, could you put this patch to sound-next ? A partial support is better than no support.
Jaroslav