Recenty i've submitted a patch that slightly improves the uaudio(4) driver
and fixes a bug; but i haven't got any feedback since then. Anybody can look
attached a copy of the message/patch
the usb audio spec allows devices to use signed numbers for mixer values,
but the current uaudio(4) driver doesn't handle properly negative values.
The attached patch fixes this.
It also improves the way the driver converts bsd mixer values (in the range
0..255) to uaudio values (in the range mc->minval..mc->maxval). It ensures
that we have the following properties:
- when writing to the mixer:
0 (on the bsd side) is mapped to mc->minval (on the uaudio side)
and 255 is mapped to mc->maxval
- when reading the mixer:
mc->maxval is mapped to 255 and
mc->minval is mapped to 0
- mc->delta (used on the bsd side) is such that if an application
1. reads the mixer,
2. adds mc->delta to the returned value
3. writes the obtained value to the mixer and
4. reads again the mixer
then the returned value will be different from the initial one.
Imo, it is important for an user application to be able to reach the maximum
and minimum values of a mixer control because on some devices these seems to
be "special values". Example: on the m-audio mobilepre the "direct monitor"
feature is turned off by setting the corresponding mixer control to