- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The ISO example "cyfxuac" (as MIC, send SPI WAV content via USB) does not work (on Windows 10):
it enumerates quite properly (with errors in descriptors) - the audio recording device is there, but
there is NOT any ISO transmission of audio packets.
There are some issues in descriptor - but even fixing it - no ISO packet transmissions:
a) "Maxpacket size for EP0:" should be 64 (0x40 for high-speed device) instead of 0x09
(it is not a power of 2, as 2 power 9, it should be the number in bytes, the comment is misleading,
bMaxPacketSize for EP0 can be only: 8, 16, 32 64 - not 9)
b) OK, 96 bytes a bInterval = 0x03 = 500 micro-sec. (makes sense, even I would assume 192 bytes every 1 ms)
but with USB 2.0 the alternative descriptor sets 192 bytes with 125 micro-second interval. Why? (cannot be right)
(should it be 192 bytes every 1 ms interval, and bInterval for USB 2 should be always set to 1?)
If I understand the comment: 4 frames with 96 bytes, every 4 microframes - for 48 KHz, 2x16bit it would be just 2 frames,
but the bInterval is set for 4 micro-frames (does not seem to match).
How to make this example working?
BTW: instead of reading from SPI flash - how to flash a WAV file into it? (as a WAVFile.img and control center?)
I fill the spiBuffer with samples of a sine period. But Windows 10 does not get any ISO packet, there is no audio in.
Using USBlyzer shows me also that no ISO packets are sent.
Best regards
Torsten
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Torsten,
Could you please tell which version of FX3 SDK are you referring to? Is it version 1.3.3?
I am attaching the cyfxuacdscr.c file for your reference.
In the High-Speed device descriptor CyFxUsb20DeviceDscr[ ], Maxpacket size for EP0 is 0x40.
In the Super-Speed device descriptor CyFxUsb30DeviceDscr[ ], Maxpacket size for EP0 field is set to 0x09. This is according to the UVC 3.1 Spec ( Table 9-11. Standard Device Descriptor). Maxpacket size for EP0 in 3.0 is 2^9=512 bytes
In the Endpoint descriptor for ISO streaming Audio data of CyFxUsbHSConfigDscr[ ], Transaction size is 96 bytes per frame and bInterval is 0x03.
You can write a WAV file into SPI flash by choosing SPI Flash in the Program option of Control Center.