Re: [linux-audio-dev] Sending USB msgs to sound card through snd_usb_audio driver - how ?

From: Clemens Ladisch <clemens@email-addr-hidden>
Date: Thu Jun 09 2005 - 11:33:53 EEST

Jan Holst Jensen wrote:
> --- Clemens Ladisch <clemens@email-addr-hidden> wrote:
> > > Are there any standard ioctl() calls in the
> >
> > No, but this would be a very good idea for testing
> > purposes. I'll add a hwdep device for this.
>
> Great. Looking forward to that. But until then, my
> best shot is hacking the driver I guess... ?

This _is_ hacking the driver. :-)

> Any idea what happens in Windows ? Doesn't seem like
> the device is locked by the driver in that OS (?).

It is, but usually the driver provides ioctls to allow applications to
change some settings.

The patch adds an hwdep device that provides a USBDEVFS_CONTROL ioctl
that should work identical to that from <linux/usbdevice_fs.h>, except
that you need root privileges to use it.

The patch is against the CVS version of ALSA. Both the driver and
alsa-lib need to be recompiled.

To access the device, use snd_hwdep_open() and snd_hwdep_ioctl(). The
device name is "hw:X,1" where X is the card number.

HTH
Clemens

Received on Thu Jun 9 12:15:08 2005

This archive was generated by hypermail 2.1.8 : Thu Jun 09 2005 - 12:15:09 EEST