Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
AnWa_3863696
Level 2
Level 2
First like given

Hi

Is it possible to send pattern frame in UVC application from CX3 module FW in every DMA callback?

I try to modify dmaBuffer.buffer content, but the result seems only around 60 bytes data were modified that captured by USB wireshark.

What's wrong with my code or any limitation for change frame buffer?

          status = CyU3PDmaMultiChannelGetBuffer(chHandle, &dmaBuffer, CYU3P_WAIT_FOREVER);

       while (status == CY_U3P_SUCCESS)

        {

            /* Add Headers*/

            if(dmaBuffer.count < CX3_UVC_DATA_BUF_SIZE)

            {

#ifdef UVC_APPLICATION

                CyCx3UvcAppAddHeader ((dmaBuffer.buffer - CX3_UVC_PROD_HEADER), CX3_UVC_HEADER_EOF);

           CyU3PMemCopy(dmaBuffer.buffer+CX3_UVC_PROD_HEADER, ptrEEPROM, 0x4000);

#endif

Thanks

Angus

0 Likes
1 Solution
Hemanth
Moderator
Moderator
Moderator
First like given First question asked 750 replies posted

Hi Angus,

Angus Wang wrote:

I want to replace the entire video frame with local buffer data. Is this possible?

>> Please refer to following example in the FX3 SDK:

C:\Program Files (x86)\Cypress\EZ-USB FX3 SDK\1.3\firmware\uvc_examples\cyfxuvcinmem_bulk

(Please check readme file of the project)

You have to use CY_U3P_DMA_TYPE_MANUAL_OUT channel instead of CY_U3P_DMA_TYPE_MANUAL_MANY_TO_ONE

Note: I assume that you don't want to use MIPI interface at all.

Regards,

Hemanth

Hemanth

View solution in original post

0 Likes
4 Replies