We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hi to all I'm attempting to modify the USBAudio example on an LPC2378 in order to appear as a microphone using isochronous endpoint 3. I modified the example and it works fine. The next step is to enable a double buffered endpoint. Did someone have an example ? I understood the working principle but from the LPC2378 user manual is not clear how to enable it. best regards
> The next step is to enable a double buffered endpoint.
For USB device engine on LPC family, isoc and bulk endpoints are double buffered as the default. Rather, Single buffer is not available for isoc endpoint. (For bulk, assigning bulk transfer to an interrupt endpoint, single buffer is available.)
Therefore, if you've done isoc in DMA, it's already double buffered.
Tsuneo
Ok, thanks for the answer. So the double buffering is yet enabled, but what about managing ? That is, I imagine that I should check the B_1_FULL and B_2_FULL bits in order to know which one should be filled. Did you have some sample code ? best regards
Your firmware doesn't need to be aware of the double buffer on the device engine. On every FRAME (SOF) interrupt, write a packet to the IN endpoint buffer. The packet is sent at the next USB frame, when host puts IN transaction. Because of this one frame delay, double buffer is assigned on the USB engine.
The USB device engine of LPC family is not so good for advanced audio application. It doesn't have hardware SOF recovery and hardware PLL driven by SOF. These features are required to support packet drop detection and synchronization. You have to implement these feature on the firmware.
Compare the device functions with audio-specific chip
TI TAS1020B USB Steaming Controller focus.ti.com/.../tas1020b.pdf