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

PSoC™ 6 Forum Discussions

SaGa_4641021
Level 4
100 sign-ins 50 sign-ins 25 replies posted
Level 4

Hi

I am using the DMA Tx and Rx with a UART following code example CE219656.

I am trying to understand the rules for data size and I did tested several size combinations for data_size, src_size and dst_size.

I think the UART buffer is 1-byte, but the UART functions are defined as 4-bytes.

In the code example, the DMA_buffers ("RxDmaUartBufferA and RxDmaUartBufferB") are also 1-byte.

Not all the data/src/dst-size combinations work, very few are sucessful in echoing data to/from the UART, others do not lead to any serial transfer, there is no activity on the serial port. I tabulated the size combinations. I am trying to decipher the size rules that can lead to the expected operation. Any hints ?

thanks

SaGa_4641021_0-1637804490762.png

 

0 Likes
1 Solution
SaGa_4641021
Level 4
100 sign-ins 50 sign-ins 25 replies posted
Level 4

I captured the errors and used logic analyzer and signals to monitor the flow and found that:

-For proper operation: RxDMA-SRC and TxDMA-SRC must be 4-bytes.

-If RxDMA-SRC is not 4-bytes, I get "Source bus error"

-If TxDMA-SRC must be 4-bytes, the Tx-DMA does not execute

I think it aligns with your comment.

thanks a lot

View solution in original post

0 Likes
2 Replies
RodolfoGL
Employee
250 sign-ins 5 comments on KBA First comment on KBA
Employee

Every access to a peripheral FIFO has to be 32-bit, even if the FIFO is 8-bit width.

So in your case, the RxDMA source address and TxDMA destination address need to be all WORD. 

SaGa_4641021
Level 4
100 sign-ins 50 sign-ins 25 replies posted
Level 4

I captured the errors and used logic analyzer and signals to monitor the flow and found that:

-For proper operation: RxDMA-SRC and TxDMA-SRC must be 4-bytes.

-If RxDMA-SRC is not 4-bytes, I get "Source bus error"

-If TxDMA-SRC must be 4-bytes, the Tx-DMA does not execute

I think it aligns with your comment.

thanks a lot

0 Likes