cycx3 UVC ov5640 modify the dma buffersize

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

cross mob
haxu_299926
Level 3
Level 3
10 replies posted 5 replies posted 5 questions asked

Hi,

I  used the example of cycx3  UVC ov5640 of the cx3 for test ,I want to modify the dma buffer size ,but I found when I modify the other value except the 0x5FF0 and the 0x2FF0,the captured packet will become 36864, not the value 23552 I modified. I don't know why it happens .

When I modify the buffer to the value of 32768, the DMACreate function will return the error code of 0x10

0 Likes
1 Solution

Edited: Fix to 0x10 error is added.

If you are not using header and footer, you can set DMA size as 32768.

As per your description, the channel creation API returning CY_U3P_ERROR_MEMORY_ERROR.

Please ensure that you have enough dma buffer space. You may reduce the number of buffers per DMA Channel. This will solve the 0x10 error.

View solution in original post

0 Likes
4 Replies
KandlaguntaR_36
Moderator
Moderator
Moderator
25 solutions authored 10 solutions authored 5 solutions authored

Hello,

The DMA buffer size should be multiple of 16 bytes.

In the case of OV5640 (UVC examples), we need a 16 bytes equalent header and footer.

Please set CX3_APP_DATA_BUF_SIZE Macro to 0x7FF0 (Decimal equivalent to 32752) and try.

Regards,

Sridhar

0 Likes

Hello,

         I have modified the dma header and leader size to zero,and the image data don't add the header and trailer.Do I still have to keep the 16 bytes.the 32768 is the multiple of 16 bytes.

Regards,

0 Likes

Edited: Fix to 0x10 error is added.

If you are not using header and footer, you can set DMA size as 32768.

As per your description, the channel creation API returning CY_U3P_ERROR_MEMORY_ERROR.

Please ensure that you have enough dma buffer space. You may reduce the number of buffers per DMA Channel. This will solve the 0x10 error.

0 Likes

Hello,

Please reduce the number of buffers per DMA Channel. This solves the 0x10 error.

Regards,

Sridhar

0 Likes