El 19/12/11 23:19, Clemens Ladisch wrote:
> Casi wrote:
>> I intend to use the snd-usb-audio module with a Yamaha MOX6/8 built-in
>> USB audio card.
>>
>> I would be glad if only get it works as 2 audio channels (full-duplex)
>> and 1 midi port.
>> Is it possible?
>
> No, streaming works only with the correct number of channels. :)
:) 4 better than 2 ... :? but it's odd cause the MOX USB audio card has two
modes:
- 2 audio channels
- 4 audio channels
The change of mode needs reboot the hardware. In fact, 2 channels is the only
mode that works for me with the "native" Windows driver cause it sucks less.
Look at this:
$ diff lsusb-v_2channels.txt lsusb-v_4channels.txt
50c50
< ** UNRECOGNIZED: 0c 24 02 03 03 06 00 02 03 00 00 00
---
> ** UNRECOGNIZED: 0c 24 02 03 03 06 00 04 33 00 00 00
105c105
< ** UNRECOGNIZED: 0b 24 02 01 02 03 18 01 44 ac 00
---
> ** UNRECOGNIZED: 0b 24 02 01 04 03 18 01 44 ac 00
114c114
< wMaxPacketSize 0x0120 1x 288 bytes
---
> wMaxPacketSize 0x0240 1x 576 bytes
>
>> $ lsusb -v
>> [...]
>> bInterfaceClass 255 Vendor Specific Class
>
> This device claims not to be compatible with a standard driver.
> To force the driver to attach to it anyway, we need to add a quirk entry.
> Please try to apply the patch below and to recompile the driver.
Thanks for the patch. This is my checking (2 audio channels mode):
Kernel:
$ uname -a
Linux casi 3.0.9-mox-v1 #1 SMP Wed Dec 21 09:37:15 CET 2011 x86_64 x86_64
x86_64 GNU/Linux
$ dmesg
[ 488.027151] usb 2-1.2: new full speed USB device number 3 using ehci_hcd
[ 488.670131] input: Yamaha Corporation Yamaha MOX6/MOX8 as
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.2/2-1.2:1.4/input/input12
[ 488.670243] generic-usb 0003:0499:1503.0001: input,hidraw0: USB HID v1.00
Keyboard [Yamaha Corporation Yamaha MOX6/MOX8] on usb-0000:00:1d.0-1.2/input4
[ 488.670280] usbcore: registered new interface driver usbhid
[ 488.670282] usbhid: USB HID core driver
[ 488.690184] usbcore: registered new interface driver snd-usb-audio
[ 488.896074] cannot submit datapipe for urb 0, error -28: not enough bandwidth
Usb:
$ lsusb
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
Bus 001 Device 003: ID 064e:a219 Suyin Corp. 1.3M WebCam (notebook emachines
E730, Acer sub-brand)
Bus 002 Device 003: ID 0499:1503 Yamaha Corp.
$ lsusb -t
/: Bus 02.Port 1: Dev 1, Class=root_hub, Driver=ehci_hcd/2p, 480M
|__ Port 1: Dev 2, If 0, Class=hub, Driver=hub/8p, 480M
|__ Port 2: Dev 3, If 0, Class=vend., Driver=snd-usb-audio, 12M
|__ Port 2: Dev 3, If 1, Class=vend., Driver=snd-usb-audio, 12M
|__ Port 2: Dev 3, If 2, Class=vend., Driver=snd-usb-audio, 12M
|__ Port 2: Dev 3, If 3, Class=vend., Driver=snd-usb-audio, 12M
|__ Port 2: Dev 3, If 4, Class=HID, Driver=usbhid, 12M
/: Bus 01.Port 1: Dev 1, Class=root_hub, Driver=ehci_hcd/2p, 480M
|__ Port 1: Dev 2, If 0, Class=hub, Driver=hub/6p, 480M
|__ Port 1: Dev 3, If 0, Class='bInterfaceClass 0x0e not yet handled',
Driver=uvcvideo, 480M
|__ Port 1: Dev 3, If 1, Class='bInterfaceClass 0x0e not yet handled',
Driver=uvcvideo, 480M
$ sudo lsusb -v -s 2:3
Bus 002 Device 003: ID 0499:1503 Yamaha Corp.
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 239 Miscellaneous Device
bDeviceSubClass 2 ?
bDeviceProtocol 1 Interface Association
bMaxPacketSize0 8
idVendor 0x0499 Yamaha Corp.
idProduct 0x1503
bcdDevice 1.00
iManufacturer 1 Yamaha Corporation
iProduct 2 Yamaha MOX6/MOX8
iSerial 0
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 308
bNumInterfaces 5
bConfigurationValue 1
iConfiguration 0
bmAttributes 0xc0
Self Powered
MaxPower 2mA
Interface Association:
bLength 8
bDescriptorType 11
bFirstInterface 0
bInterfaceCount 4
bFunctionClass 255 Vendor Specific Class
bFunctionSubClass 0
bFunctionProtocol 0
iFunction 0
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 0
bInterfaceClass 255 Vendor Specific Class
bInterfaceSubClass 1
bInterfaceProtocol 0
iInterface 0
** UNRECOGNIZED: 0a 24 01 00 01 34 00 02 01 02
** UNRECOGNIZED: 0c 24 02 01 01 01 00 02 03 00 00 00
** UNRECOGNIZED: 09 24 03 02 01 03 00 01 00
** UNRECOGNIZED: 0c 24 02 03 03 06 00 02 03 00 00 00
** UNRECOGNIZED: 09 24 03 04 01 01 00 03 00
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 1
bAlternateSetting 0
bNumEndpoints 0
bInterfaceClass 255 Vendor Specific Class
bInterfaceSubClass 2
bInterfaceProtocol 0
iInterface 0
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 1
bAlternateSetting 1
bNumEndpoints 1
bInterfaceClass 255 Vendor Specific Class
bInterfaceSubClass 2
bInterfaceProtocol 0
iInterface 0
** UNRECOGNIZED: 07 24 01 01 01 01 00
** UNRECOGNIZED: 0b 24 02 01 02 03 18 01 44 ac 00
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x01 EP 1 OUT
bmAttributes 5
Transfer Type Isochronous
Synch Type Asynchronous
Usage Type Data
wMaxPacketSize 0x0120 1x 288 bytes
bInterval 1
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 2
bAlternateSetting 0
bNumEndpoints 0
bInterfaceClass 255 Vendor Specific Class
bInterfaceSubClass 2
bInterfaceProtocol 0
iInterface 0
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 2
bAlternateSetting 1
bNumEndpoints 1
bInterfaceClass 255 Vendor Specific Class
bInterfaceSubClass 2
bInterfaceProtocol 0
iInterface 0
** UNRECOGNIZED: 07 24 01 04 01 01 00
** UNRECOGNIZED: 0b 24 02 01 02 03 18 01 44 ac 00
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x82 EP 2 IN
bmAttributes 5
Transfer Type Isochronous
Synch Type Asynchronous
Usage Type Data
wMaxPacketSize 0x0120 1x 288 bytes
bInterval 1
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 3
bAlternateSetting 0
bNumEndpoints 2
bInterfaceClass 255 Vendor Specific Class
bInterfaceSubClass 3
bInterfaceProtocol 0
iInterface 0
** UNRECOGNIZED: 07 24 01 00 01 60 00
** UNRECOGNIZED: 06 24 02 01 01 00
** UNRECOGNIZED: 06 24 02 01 02 00
** UNRECOGNIZED: 06 24 02 01 03 00
** UNRECOGNIZED: 06 24 02 01 04 00
** UNRECOGNIZED: 06 24 02 01 05 00
** UNRECOGNIZED: 09 24 03 01 06 01 01 01 00
** UNRECOGNIZED: 09 24 03 01 07 01 01 01 00
** UNRECOGNIZED: 09 24 03 01 08 01 01 01 00
** UNRECOGNIZED: 09 24 03 01 09 01 01 01 00
** UNRECOGNIZED: 09 24 03 01 0a 01 01 01 00
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x03 EP 3 OUT
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0020 1x 32 bytes
bInterval 1
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x84 EP 4 IN
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0020 1x 32 bytes
bInterval 1
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 4
bAlternateSetting 0
bNumEndpoints 1
bInterfaceClass 3 Human Interface Device
bInterfaceSubClass 0 No Subclass
bInterfaceProtocol 1 Keyboard
iInterface 0
HID Device Descriptor:
bLength 9
bDescriptorType 33
bcdHID 1.00
bCountryCode 0 Not supported
bNumDescriptors 1
bDescriptorType 34 Report
wDescriptorLength 45
Report Descriptors:
** UNAVAILABLE **
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x85 EP 5 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0008 1x 8 bytes
bInterval 16
Device Status: 0x0000
(Bus Powered)
Audio cards:
$ cat /proc/asound/cards
0 [Intel ]: HDA-Intel - HDA Intel
HDA Intel at 0xb4400000 irq 43
1 [MOX6MOX8 ]: USB-Audio - Yamaha MOX6/MOX8
Yamaha Corporation Yamaha MOX6/MOX8 at
usb-0000:00:1d.0-1.2, full speed
Play:
$ aplay -l
**** Lista de PLAYBACK dispositivos hardware ****
tarjeta 0: Intel [HDA Intel], dispositivo 0: ALC272X Analog [ALC272X Analog]
Subdispositivos: 1/1
Subdispositivo #0: subdevice #0
tarjeta 0: Intel [HDA Intel], dispositivo 3: HDMI 0 [HDMI 0]
Subdispositivos: 1/1
Subdispositivo #0: subdevice #0
tarjeta 1: MOX6MOX8 [Yamaha MOX6/MOX8], dispositivo 0: USB Audio [USB Audio]
Subdispositivos: 1/1
Subdispositivo #0: subdevice #0
$ aplay -Ddefault:1 /usr/share/sounds/alsa/Front_Center.wav
ALSA lib conf.c:4630:(snd_config_expand) Unknown parameters 1
ALSA lib pcm.c:2212:(snd_pcm_open_noupdate) Unknown PCM default:1
aplay: main:660: error al abrir audio: Argumento inválido
$ alsamixer -c1
Card: Yamaha MOX6/MOX8 "This sound device doesn't have controls."
Midi:
$ aconnect -iol
cliente 0: 'System' [tipo=kernel]
0 'Timer '
1 'Announce '
cliente 14: 'Midi Through' [tipo=kernel]
0 'Midi Through Port-0'
cliente 20: 'Yamaha MOX6/MOX8' [tipo=kernel]
0 'Yamaha MOX6/MOX8 MIDI 1'
1 'Yamaha MOX6/MOX8 MIDI 2'
2 'Yamaha MOX6/MOX8 MIDI 3'
3 'Yamaha MOX6/MOX8 MIDI 4'
4 'Yamaha MOX6/MOX8 MIDI 5'
$ aplaymidi -p 20:0 LVB_Sonate_02no1_1.mid
... No sound in the MOX internal tone generator
Relative to 4 channels mode:
$ dmesg
...
[ 94.013048] usb 2-1.2: new full speed USB device number 3 using ehci_hcd
[ 94.641051] input: Yamaha Corporation Yamaha MOX6/MOX8 as
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.2/2-1.2:1.4/input/input12
[ 94.641166] generic-usb 0003:0499:1503.0001: input,hidraw0: USB HID v1.00
Keyboard [Yamaha Corporation Yamaha MOX6/MOX8] on usb-0000:00:1d.0-1.2/input4
[ 94.641182] usbcore: registered new interface driver usbhid
[ 94.641184] usbhid: USB HID core driver
[ 94.715965] usbcore: registered new interface driver snd-usb-audio
So it looks theonly difference are the wMaxPacketSize value and this dmesg
error:
[ .....] cannot submit datapipe for urb 0, error -28: not enough bandwidth
Summary: at the moment the patch doesn't work for me :( ... but I'm all ears ;)
Thanks again.
------------------------------------------------------------------------------
Write once. Port to many.
Get the SDK and tools to simplify cross-platform app development. Create
new or port existing apps to sell to consumers worldwide. Explore the
Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join
http://p.sf.net/sfu/intel-appdev
_______________________________________________
Alsa-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/alsa-user