Open-source USB interface: Audio Widget

Hi,

I've been working on a new build lately. There was an issue with the polling rate in Windows UAC2 which should be fixed now. See if these files do a good job for you.

I'm genuinely surprised if these files sound different! The only thing I can think of is that the feedback poll rate may be different. I have experimented with 32ms polling intervals instead of 1ms. There is simply no need to poll that frequently.

Unfortunately, Windows or the Windows ASIO driver don't handle !=1ms very well, so for UAC2 the attached build has USB descriptors set back to what works on Windows. OS X, on the other hand, seems to use an 8ms poll rate regardless of what the descriptors say... There are just too many interpretations and assumptions out there. The attached builds should work with all OSes.

So if there really is a difference in sound quality due to poll rate, the DAC will perhaps sound different on OSes which choose to ignore the poll rate set in the USB descriptors.


Børge
 

Attachments

  • awx_201300712.zip
    267.7 KB · Views: 77
I'm genuinely surprised if these files sound different! The only thing I can think of is that the feedback poll rate may be different.
indeed. Among the other things, I guess that it may somewhat change the characteristics of the noise present on the PC-(USB)-AW interface and thus indirectly affect the sound... :scratch:

So if there really is a difference in sound quality due to poll rate, the DAC will perhaps sound different on OSes which choose to ignore the poll rate set in the USB descriptors.
differences in SQ between different OSs (and other related details) have been often reported by many (not only for AW). This may be yet another of the many possible reasons for that...
 
Hi folks,

I've been following this thread with interest for a few weeks now. I'm doing a project on PIC32 that includes USB audio, and have been of course trying to get async working with much challenge. I've been using the sdr-widget descriptors, as well as a lot of other examples as a starting point, since I can't find any document such as: "what the descriptor for a class compliant sound card looks like"

Anyway, I hope that maybe some of you with more experience in USB audio could lend me some pointers. I'm hoping to release this module for others to use once I get it working

My needs are not very demanding: (or so I thought...)

- USB full-speed
- 24 bit stereo in/out at 44.1 or 48kHz
- class compliant use with no drivers on Windows 7, OS X and Linux

After a lot of evenings crafting what I thought would be a working set of descriptors, the device now enumerates with Windows. It shows up as both a USB audio device, and another unknown device. The audio device has a "device cannot start" error, and I can't see it in the list of sound interfaces in the sound settings panel. I don't see any errors in USBlyzer, but it seems to not really understand all aspects of audio devices.

Anyway, could anyone suggest what to try now? BTW to start with I'm just transferring empty buffers in/out of the endpoints, and sending "48 << 14" to the 3 byte feedback endpoint for now, but the TX and RX don't seem to transfer any data, except a burst of activity right when the device is connected.

Any clues on how I should continue debugging this would be greatly appreciated. I feel as though I'm staring blindly into the problem now.


Andrew
 
DIY DAC fulfills CE & FCC requirements

Hi guys,

The AB-1.2 DAC has become more popular than I ever expected. People even buy it who will never crack it open. Because of this I have subjected it to CE and FCC testing. The reports came in today. All tests passed on the 1st go with good margins. :D

Does this mean the AB-1.2 DAC is now no longer DIY and instead 100% commercial? Nope, it's still the same open source firmware, hardware and ASIO driver as ever. Nothing has changed to how tweakable it is.

But what it does mean is that the code base is stable enough for me to dare sell one to your aunt!

I will shortly release new firmware with UAC1 improvements. It's going through the last stages of testing. Let me know if you wish to test it on your setup.

Cheers,
Børge
 
Hi folks,

I've been following this thread with interest for a few weeks now. I'm doing a project on PIC32 that includes USB audio, and have been of course trying to get async working with much challenge. I've been using the sdr-widget descriptors, as well as a lot of other examples as a starting point, since I can't find any document such as: "what the descriptor for a class compliant sound card looks like"

Anyway, I hope that maybe some of you with more experience in USB audio could lend me some pointers. I'm hoping to release this module for others to use once I get it working

My needs are not very demanding: (or so I thought...)

- USB full-speed
- 24 bit stereo in/out at 44.1 or 48kHz
- class compliant use with no drivers on Windows 7, OS X and Linux

After a lot of evenings crafting what I thought would be a working set of descriptors, the device now enumerates with Windows. It shows up as both a USB audio device, and another unknown device. The audio device has a "device cannot start" error, and I can't see it in the list of sound interfaces in the sound settings panel. I don't see any errors in USBlyzer, but it seems to not really understand all aspects of audio devices.

Anyway, could anyone suggest what to try now? BTW to start with I'm just transferring empty buffers in/out of the endpoints, and sending "48 << 14" to the 3 byte feedback endpoint for now, but the TX and RX don't seem to transfer any data, except a burst of activity right when the device is connected.

Any clues on how I should continue debugging this would be greatly appreciated. I feel as though I'm staring blindly into the problem now.


Andrew

Hi Andrew,

I'm quite interested in what your doing.
Can you start up a dedicated thread for this?

Cheers,
 
I'm mainly looking for an offline SRC which gives out .wav.

Børge
(Note: I am WAY behind in my reading)

Now that you have a Mac, look for afconvert
You may need to install the development environment and compile the program, or it may be there already, I forget.
Mac OS X includes very powerful SRC as part of CoreAudio. However, you need some sort of application to access the feature. afconvert is a sample source code that opens many audio file formats and converts to others. It will also perform SRC.
If you use the right command-line options, the SRC will use the highest quality settings for a nearly perfect conversion. If you're interested, I can look up the exact parameters.

Brian Willoughby
Sound Consulting
 
Last edited:
Well, I'm a total beginner here. Which player (preferably free of charge) should I download and use on the Mac?

Børge
iTunes has already been suggested, but I want to add a warning (I'm behind in this topic, and scanned quickly, but didn't notice anyone mentioning this - I may have missed it).

Audio MIDI Setup allows you to set the hardware sample rate. When iTunes launches, it will make a note of this sample rate. If you play audio files at a different rate, iTunes will use quick and dirty SRC.

Unfortunately, if you change the hardware sample rate after iTunes has launched, and then play an audio file at the new rate, iTunes will still blindly SRC to the original rate and then CoreAudio will SRC back to the new rate. The workaround here is to quit and relaunch iTunes any time you change the hardware sample rate, at least if you want to eliminate real time SRC from the audio stream.

p.s. I also use AULab.app, part of the development environment, along with some audio interface hardware that loops back the output of iTunes to an input. This, plus an AudioUnit plugin that I wrote to show the bit depth of a CoreAudio stream, allows me to see when iTunes is using SRC and when it is bit perfect. Any time I forget what rate iTunes is using internally, my AULab diagnostics will let me confirm whether everything is working as I want.

Brian Willoughby
Sound Consulting
 
Last edited:
The AB-1.2 DAC has become more popular than I ever expected. People even buy it who will never crack it open. Because of this I have subjected it to CE and FCC testing. The reports came in today. All tests passed on the 1st go with good margins. :D

Does this mean the AB-1.2 DAC is now no longer DIY and instead 100% commercial? Nope, it's still the same open source firmware, hardware and ASIO driver as ever. Nothing has changed to how tweakable it is.

But what it does mean is that the code base is stable enough for me to dare sell one to your aunt!
Congratulations!
In a market where some small hardware manufacturers skip this step, I'm very impressed that you accomplished it! Do you mind telling us how much it cost to test both CE and FCC standards? Maybe you can encourage other small audio interface makers to test as well.

Brian Willoughby
Sound Consulting
 
Thanks Brian,

I actually ended up saving .wav files in JRiver. It's just for sample rate testing. Rather than test with sine waves I test with an Enya album resampled to the 6 most typical sampling frequencies. It has little to do with audiophile listening, I just had to test sample rate transitioning in various setups.

Cheers,
Børge


(Note: I am WAY behind in my reading)

Now that you have a Mac, look for afconvert
You may need to install the development environment and compile the program, or it may be there already, I forget.
Mac OS X includes very powerful SRC as part of CoreAudio.
.....
 
Thanks again Brian!

The testing is something I wanted to do. As you may know, I design circuit boards for a living, and it's good to be able to tell that my stuff works.

I tested with SIQ:SIQ

I don't think I may publish their quotes. But if you are interested, let me know and I'll forward their contact details to you.

Børge



Congratulations!
In a market where some small hardware manufacturers skip this step, I'm very impressed that you accomplished it! Do you mind telling us how much it cost to test both CE and FCC standards? Maybe you can encourage other small audio interface makers to test as well.

Brian Willoughby
Sound Consulting
 
Hi Andrew,

I'm quite interested in what your doing.
Can you start up a dedicated thread for this?

Cheers,

I would start up a new thread, but kind of disappointed that nobody responded to my questions in a few months. I get the impression that maybe this project is not really encouraged to be used as open source after all? I've found almost no authoritative docs on what Windows / OS X / Linux are expecting in terms of a class-compliant stereo audio device. I set this project aside until I could hopefully get some tips from the folks here, but haven't had any response. :worried:

Basically I'm working on a little open hardware design with a friend to make a digital audio distribution system over CAT5 cable. I designed a little audio node that has line in/out, and expansion for, say, building a little add-on digital amplifier board. My friend is doing a router unit with some CPLDs. Since my little board is powered off USB I thought it would be useful to also make it into a nice stereo class-compliant sound card. (all but the USB part is now working quite well)

My goal is to make the device do async stereo audio record/playback. I thought it would be a good learning project in USB, and also might be a useful starting point for others looking to do USB-enabled audio projects in the future. My platform is PIC32 which I've done a few digital audio projects with since they now have I2S ports on the smaller devices.