Ethin wrote:Again, I'm *writing* the driver. There is an ADC specification, but its quite brief on how the device is supposed to work.
I know you are writing a driver. I am suggesting you look up a working driver to figure out how this device is supposed to work. Unfortunately, not having a programmer's reference seems to be the norm. If there was a USB class for these kinds of device, there may have been a USB class specification available from the USB-IF. However, I have also seen a lot of devices where the class is just "vendor specific" and the vendor doesn't feel like writing programmer's references.
For example, the other day I was interested in how popular USB-serial converters work. I found out, however, the the Universal
Serial Bus doesn't have a standard for USB-RS232 converters. So basically it comes down to the two main chip vendors: FTDI and Prolific. In both cases, the cable says the class is "vendor-specific", and, as far as I could find at least, Prolific actually doesn't publish programmer's references. They publish data sheets, but those only tell you what you need to develop the hardware around the chip, like the physical dimensions, electrical characteristics, and the functions of each pin, but when it comes to actually driving these chips, there's only deafening silence. So the only viable choice was to download the Linux source code (which admittedly I already had on my disk) and read the driver code. For FTDI the situation was a little better, because for some of their chips there are programmer's guides, but not for all of them, and for the FT4222 there is only an advert for their library.
If there is no programming guide, but at least an open-source driver, that may be bad, but is at least an order of magnitude better than not even having that. If there is no open-source driver, your only choices are to reverse-engineer the closed-source one, or to reverse-engineer the hardware itself by sniffing the USB traffic. But for that you have to have a lot more knowledge about USB. I don't have an explanation for the invalid URB types you are seeing. And anyone else here could only guess, unless they happen to have the exact same hardware and have already reverse-engineered it.
I just noticed, that you want to play audio through an ADC. Don't you need a DAC for that? I admit I am not an electrical engineer, so maybe I misunderstood something here.