SAME70 UART+XDMAC

Go To Last Post
2 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hello to all. I am using SAME70.

For the protocol with variable packet length (MODBUS), you need to know how many bytes are read through the DMA channel to start the timeout.
I tried to determine the number of bytes read hrough the XDMAC registers (XDMAC_CDA, DMAC_CUBC).

Until the entire buffer is filled (256 bytes), the value of the registers does not change.

Is this a feature of SAME70?

As long as one option remains: Tx channel through DMA, Rx channel - by interruption UART_SR_RXRDY the register UART_RHR is read with the start of the timeout.

Who managed to use the XDMAC registers to determine the number of bytes read, tell me how to do this.

Last Edited: Thu. Jul 16, 2020 - 02:45 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You've already hijacked another thread with this:

 

https://community.atmel.com/comm...

 

 

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...
Topic locked