Custom board USB-Audio 2.0 device sample rate error

Sub forums for various specialist XMOS applications. e.g. USB audio, motor control and robotics.
willem_vdk
New User
Posts: 2
Joined: Fri Feb 01, 2019 11:11 pm

Custom board USB-Audio 2.0 device sample rate error

Post by willem_vdk »

Hi,

I have been trying to convert the app_usb_aud_xk_216_mc example code to a custom project for a custom board so the code is a bit easier to read, the reason for this is that it has te be maintained by different students after i am done with college and we don't use xmos microcontrollers that often. I have started with implementing the USB framework for the USB-Audiocard running linux (ubuntu bionic beaver) since i am only interested in the audio 2.0 standard and linux has native support. When starting the program the output for "dmesg -Hw" shows the device is being recognized and enumerated correctly, but when the class specific requests start it gives an error for the clock "parse_audio_format_rates_v2(): unable to find clock source (clock -110)" and than twice the error "parse_audio_format_rates_v2(): unable to find clock source (clock -71)" . When i look at the settings of stream0 the rates are blank meaning there are none.

My understanding of the matter is that the host requests the device for the supported sample rates through a class specific request which is in AudioClassRequests_2() in the RANGE case.
Does anyone have expirience with this issue?

Thanks in advance,
Willem van der Kooij


pfitchen
Junior Member
Posts: 4
Joined: Mon Mar 25, 2019 8:42 pm

Post by pfitchen »

Hi Willem,

I'm in exactly the same situation too. Did you end up getting this resolved?

Thanks!
pfitchen
Junior Member
Posts: 4
Joined: Mon Mar 25, 2019 8:42 pm

Post by pfitchen »

Hi Willem,

I managed to find the issue. My custom board doesn't have the same audio peripheral devices as the reference design and there were a few spots in the audiohw.xc file that were dependent on these peripherals. Make sure that the AudioHwConfig() function isn't dependent on something that isn't on your board. In my case, changing line 200 from #if 1 to #if 0 properly disabled all of the features I don't want. If that doesn't work, can you share more about the peripheral devices on your board? I might be able to help track down the issue!

-Peter