UDB UART Rx does not work with DMA in PSoC4

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

cross mob
lock attach
Attachments are accessible only for community members.
IoVo_297831
Level 4
Level 4
First like received

Hi,

   

I need a little help here.
I use a UART component in a PSoC4 project and I would like to save incoming bytes to RAM without CPU intervention.

   

I do not know what I am missing but it does not work to me.
I attach a simple example of using DMA and UART RX facing my issue. It can run directly in the Pioneer kit.

   

The examples for DMA and UART RX use the SCB blocks, which is not an option for my application since the SCBs are reserved for other serial communication blocks. My only option is the UDB UART mode but IU cannot make it work.

   

Any ideas?

   

Thank you very much in advance.
Best Regards,
Yiannis

0 Likes
1 Solution
lock attach
Attachments are accessible only for community members.
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

Your macro callback is not as required, so the cb1() is never called.

   

I changed DMA to Byte -> Byte and Trigger Mode to "Level 4 cycles"

   

When setting a breakpoint at end of for-loop you see that all data was transferred into the buffer.

   

 

   

Bob

View solution in original post

0 Likes
2 Replies
lock attach
Attachments are accessible only for community members.
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

Your macro callback is not as required, so the cb1() is never called.

   

I changed DMA to Byte -> Byte and Trigger Mode to "Level 4 cycles"

   

When setting a breakpoint at end of for-loop you see that all data was transferred into the buffer.

   

 

   

Bob

0 Likes
IoVo_297831
Level 4
Level 4
First like received

Thanks Bob.

   

I tried the modification you suggested and it worked.
I also found why the callback was not called and then I applied the corrections to the rest of the project.

   

Thanks again.

   

Best Regards
Yiannis

0 Likes