The USB Audio 2.0 Group

User avatar
GeorgeIoak
Active Member
Posts: 56
Joined: Wed May 19, 2010 9:42 pm

Post by GeorgeIoak »

Looking at the reference design I see that the CS4270 is put into hardware mode which should mean that it is in slave mode. However while trying to understand the firmware I see in audio.xc starting on line 203 I see the following comment:

/* CODEC is master */
/* Wait for LRCLK edge */

I ask because I'm bringing up a new board and am having some trouble. I initially see a LRCLK when I first power the board but then it goes away. On the eval board the LRCLK stays at 48kHz while I'm connected to the computer.

Since there's not I2C communication between the L1 and the CODEC it should only be able to be in 1 mode but I'm a bit confused now and would really appreciate some clarification for me!

Thanks,
George
User avatar
lilltroll
XCore Expert
Posts: 956
Joined: Fri Dec 11, 2009 3:53 am
Location: Sweden, Eskilstuna

Post by lilltroll »

Lately, several people in this group has contacted me regarding the Windows drivers.
The most common wish is to be able to enable I2C on a L1 chip for CODEC register programming. For an example you can skip the button on the ref. card and use the 2 1-bit ports for I2C.
For other very low-bandwith data I/O you can instead use the 32-bit port.

The I2C framework is already included in the 2.00 ver. of the code, so it's mostly about some reconfiguration of the code-package.

The next thing is to be able to send commands to the XMOS-chip which translates to I2C messages via the Windows driver.
People that have been in contact with the 2 companies that delivers the drivers seems to have received answers that such a driver customization can be done, but will cost around 1000-12000 $ - which many believes is ridiculous.
The alternative is to use some of the already implemented driver features to send non-Audio data over the USB link - and I can report that several here is working on that.
Probably not the most confused programmer anymore on the XCORE forum.
User avatar
GeorgeIoak
Active Member
Posts: 56
Joined: Wed May 19, 2010 9:42 pm

Post by GeorgeIoak »

Anyone tried to run the eval board under a Linux OS? In theory this should work as it should come up as a USB 2.0 Audio device but I've tried several OS's and they all claim that the USB descriptors are invalid. This is odd since the board works fine on a MAC. I've gone in and commented out some options, like Audio IN, MIDI but the device still doesn't want to enumerate properly. It does show up but you can't use it.
bearcat
Respected Member
Posts: 283
Joined: Fri Mar 19, 2010 4:49 am

Post by bearcat »

Trying to figure out what the vendor audio requests are???

No new driver out (yet), so not sure if there is going to be vendor audio request support there also???
User avatar
lilltroll
XCore Expert
Posts: 956
Joined: Fri Dec 11, 2009 3:53 am
Location: Sweden, Eskilstuna

Post by lilltroll »

Most of you seems to want to do one thing in common.
Add SPI and or I2C to the L1, and be able to send commands from the host to the SPI/I2C ports via USB.

The thing is the lack of free 1 port pins.

It seems stupid that you all have to invent it in parallel.

Right now I think that using the existing SPI that are connected to the flash must be the best way. By using pull-ups and pull downs on the SPI Chip Select in such a way that only the Flash chip is active during SPI-boot.
Thereafter the p32 can be used to control the CS of the other chips. This should also be possible to combine with the flash-lib with some mod.
The simple way to apply I2C is to skip the 2 buttons and use them for I2C, but that will kill the MIDI option on L1. Another port that might not be used in your application is the S/PDIF out.

Another option is to have some type of bootloader in the OTP maybe including the AES encryption. In that case the XMOS becomes active running before the read from the flash. That should give you an option to take full control over the port. Maybe possible to use the falsh pins for both SPI and I2C if you do not need both at the same time?

Please tell me your findings. (I'm mostly working with the XAI for the moment)
Probably not the most confused programmer anymore on the XCORE forum.
User avatar
GeorgeIoak
Active Member
Posts: 56
Joined: Wed May 19, 2010 9:42 pm

Post by GeorgeIoak »

In the readme document it's mentioned that 176.4kHz is not supported but it can be supported by changing the clock and MCLK defines. I think the note should read "2 x 11.2896MHz", correct?

- The L1 Reference Design board has a 12.288MHz master clock source (oscillator) for 44.1kHz family of sample frequencies. S/PDIF Tx operation at 172.4kHz is therefore not supported due to the 2 x MCLK requirement. 176.4kHz operation can be enabled by using a (2 x 12.288)MHz clock source and modifying the relevant MCLK frequency defines.

I'm a little confused as to why the eval board doesn't just use a 22.579MHz clock so all frequencies can be supported? Is there some other problem?
User avatar
GeorgeIoak
Active Member
Posts: 56
Joined: Wed May 19, 2010 9:42 pm

Post by GeorgeIoak »

I'm doing some distortion measurements on Win7 with the Thesycon driver loaded and using Windows Media Player to play some music. It seems that Windows is still resampling so do I need to also load the ASIO4ALL driver and/or switch to using FooBar or WinAmp?
User avatar
GeorgeIoak
Active Member
Posts: 56
Joined: Wed May 19, 2010 9:42 pm

Post by GeorgeIoak »

Anyone tried to use the DFU utility (not the console but the one through the Thesycon Control Panel) to update firmware? I don't find much information on it other than DFU .

In that document the only information I see to create the bin file is:

To generate the firmware upgrade image run the following command

xflash --upgrade 1 usb_audio.xe 0x20000 -o new_firmware.bin

You should now have the file usb_audio_class1.bin which contains the firmware for the audio class 1 implementation.

I ran that command with the xe file but the actual firmware update failed.
User avatar
lilltroll
XCore Expert
Posts: 956
Joined: Fri Dec 11, 2009 3:53 am
Location: Sweden, Eskilstuna

Post by lilltroll »

I tried to communicate with the xxxxAPI.dll in the latest driver relsease. The DLL answers but it doesn't enumerate the USB device.
The manual refers to theSycon SDK that has to be licensed.

Have anyone used the SDK?
Is it impossible to use the DSP API without a special licence from theSycon ? (There seems to be a missing code for the DSP in the .sys file)
Probably not the most confused programmer anymore on the XCORE forum.
maxwang71
Newbie
Posts: 1
Joined: Fri Sep 02, 2011 8:41 am

Post by maxwang71 »

Hi,

who can send me a copy of source code for this USB Audio 2.0 reference design

my email: maxwang71@hotmail.com

thanks