- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
I'm trying to develop a custom module.
The module has embedded data but I cannot receive the data that I expected.
In order to check EMB data, I modified a BulkLoop example to print some logs as below.
I expected "Phase Idx" 0, 1, 2, and 3 should be repeated but they didn't.
At first, I thought I'm able to use "CyU3PDebugPrint()" function.
However when I added that function to DMA callback function which names CyCx3UvcAppDmaCallback(), the firmware didn't work.
I want to check the DMA buffer to make sure that the firmware is no problem.
In this case, how can I access the DMA buffer to check values?
or Is there any way to check the EMB data?
Thank you.
Solved! Go to Solution.
- Labels:
-
USB Superspeed Peripherals
- Tags:
- cx3 dma
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
It is not recommended to use blocking calls like debug prints inside DMA callback functions.
I have modified the SDK example project cyfxbulklpmanual for meeting your requirement. The modifications done are mentioned below:
1. Used the API CyU3PDmaBufferAlloc() for allocating the required amount of buffer memory.
2. Copied the DMA buffer contents inside the DMA callback to the buffer allocated in step 1.
3. Printed the contents of the buffer allocated in step 1 in the infinite for loop.
The modified project is attached along with this response. I have tested this modified project at my end and it works as expected. Please try this at your end and let me know if it helps.
Jayakrishna
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
It is not recommended to use blocking calls like debug prints inside DMA callback functions.
I have modified the SDK example project cyfxbulklpmanual for meeting your requirement. The modifications done are mentioned below:
1. Used the API CyU3PDmaBufferAlloc() for allocating the required amount of buffer memory.
2. Copied the DMA buffer contents inside the DMA callback to the buffer allocated in step 1.
3. Printed the contents of the buffer allocated in step 1 in the infinite for loop.
The modified project is attached along with this response. I have tested this modified project at my end and it works as expected. Please try this at your end and let me know if it helps.
Jayakrishna