Hi,
I'm trying to solve scratchy (as like as scratched vinyl records) playback
issue with my Amanero Asyncronous USB to I2S interface (http://amanero.com/)
on a amd64 FreeBSD-10-BETA1 system.
Amanero is a 2 channels high speed usb class2 audio device which capable of
accepting up to 32bit 384khz data format. I haven't similar issues with
other operating systems.
I played with many sysctl setting combinations including:
dev.pcm.0.play.vchanmode=fixed/adaptive
dev.pcm.0.play.vchanformat:s32le:2.0
dev.pcm.0.play.vchans=0
dev.pcm.0.bitperfect:1
etc.
With enabling debug, lots of these error messages appear on dmesg output:
uaudio_chan_play_sync_callback: Value = 0x0005fff8
uaudio_chan_play_sync_callback: Comparing 47998 < 48000
uaudio_chan_play_sync_callback: Value = 0x0005fff6
uaudio_chan_play_sync_callback: Comparing 47998 < 48000
or
uaudio_chan_play_sync_callback: Value = 0x000bfff0
uaudio_chan_play_sync_callback: Comparing 95997 < 96000
uaudio_chan_play_sync_callback: Value = 0x000bfff0
uaudio_chan_play_sync_callback: Comparing 95997 < 96000
---> dmesg output while device attached
uaudio0: at uhub1, port 3, addr 1 (disconnected)
pcm0: detached
uaudio0: on usbus0
uaudio0: Play: 96000 Hz, 2 ch, 32-bit S-LE PCM format, 2x8ms buffer.
uaudio0: Play: 88200 Hz, 2 ch, 32-bit S-LE PCM format, 2x8ms buffer.
uaudio0: Play: 48000 Hz, 2 ch, 32-bit S-LE PCM format, 2x8ms buffer.
uaudio0: Play: 44100 Hz, 2 ch, 32-bit S-LE PCM format, 2x8ms buffer.
uaudio0: Play: 32000 Hz, 2 ch, 32-bit S-LE PCM format, 2x8ms buffer.
uaudio0: No recording.
uaudio0: No MIDI sequencer.
pcm0: on uaudio0
uaudio0: No HID volume keys found.
---> usbconfig -d 0.2 dump_all_config_desc
ugen0.2: at usbus0, cfg=0 md=HOST
spd=HIGH (480Mbps) pwr=ON (128mA)
Configuration index 0
bLength = 0x0009
bDescriptorType = 0x0002
wTotalLength = 0x00b0
bNumInterfaces = 0x0003
bConfigurationValue = 0x0001
iConfiguration = 0x0002
bmAttributes = 0x0080
bMaxPower = 0x0040
Interface 0
bLength = 0x0009
bDescriptorType = 0x0004
bInterfaceNumber = 0x
bAlternateSetting = 0x
bNumEndpoints = 0x0001
bInterfaceClass = 0x00ff
bInterfaceSubClass = 0x00ff
bInterfaceProtocol = 0x
iInterface = 0x
Endpoint 0
bLength = 0x0007
bDescriptorType = 0x0005
bEndpointAddress = 0x0002
bmAttributes = 0x0002
wMaxPacketSize = 0x0200
bInterval = 0x
bRefresh = 0x
bSynchAddress = 0x
Additional Descriptor
bLength = 0x08
bDescriptorType = 0x0b
bDescriptorSubType = 0x01
RAW dump:
0x00 | 0x08, 0x0b, 0x01, 0x02, 0x01, 0x00, 0x20, 0x00
Interface 1
bLength = 0x0009
bDescriptorType = 0x0004
bInterfaceNumber = 0x0001
bAlternateSetting = 0x
bNumEndpoints = 0x
bInterfaceClass = 0x0001
bInterfaceSubClass = 0x0001
bInterfaceProtocol = 0x0020
iInterface = 0x
Additional Descriptor
bLength = 0x09
bDescriptorType = 0x24
bDescriptorSubType = 0x01
RAW dump:
0x00 | 0x09, 0x24, 0x01, 0x00, 0x02, 0x01, 0x48, 0x00,
0x08 | 0x00
Additional Descriptor
bLength = 0x08
bDescriptorType = 0x24
bDescriptorSubType = 0x0a
RAW dump:
0x00 | 0x08, 0x24, 0x0a, 0x29, 0x03, 0x07, 0x00, 0x02
Additional Descriptor
bLength = 0x08
bDescriptorType = 0x24
bDescriptorSubType = 0x0b
RAW dump:
0x00 | 0x08, 0x24, 0x0b, 0x28, 0x01, 0x29, 0x03, 0x02
Additional Descriptor
bLength = 0x11
bDescriptorType = 0x24
bDescriptorSubType = 0x02
RAW dump:
0x00 | 0x11, 0x24, 0x02, 0x2a, 0x01, 0x01, 0x00, 0x28,
0x08 | 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x10 | 0x00
Additional Descriptor
bLength = 0x12
bDescriptorType = 0x24
bDescriptorSubType = 0x06
RAW dump:
0x00 | 0x12, 0x24, 0x06, 0x0a, 0x2a, 0x0f, 0x00, 0x00,
0x08 | 0x00, 0x0f, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00,
0x10 | 0x00, 0x00
Additional Descriptor
bLength = 0x0c
bDescriptorType = 0x24
bDescriptorSubType = 0x03
RAW dump:
0x00 | 0x0c, 0x24, 0x03, 0x2b, 0x01, 0x03, 0x00, 0x0a,
0x08 | 0x28, 0x00, 0x00, 0x00
Interface 2
bLength = 0x0009
bDescriptorType = 0x0004
bInterfaceNumber = 0x0002
bAlternateSetting = 0x
bNumEndpoints = 0x
bInterfaceClass = 0x0001
bInterfaceSubClass = 0x0002
bInterfaceProtocol = 0x0020
iInterface = 0x
Interface 2 Alt 1
bLength = 0x0009
bDescriptorType = 0x0004
bInterfaceNumber = 0x0002
bAlternateSetting = 0x0001
bNumEndpoints = 0x0002
bInterfaceClass = 0x0001
bInterfaceSubClass = 0x0002
bInterfaceProtocol = 0x0020
iInterface = 0x