Skip to content

UART-to-Ethernet Loopback

Pre-release
Pre-release
Compare
Choose a tag to compare
@javakys javakys released this 15 May 05:53

A Peer system sends data via Ethernet, WIZ145SR receives data and stores data to DMATxBuf, then sends data from UART Tx to an external device. UART Tx is connected to its UART Rx so that data from UART Tx is echoed back to UART Rx.
All received data on UART Rx DR register are stored to DMARxBuf automatically due to the system configuration.
DMA HT, TC and UART IDLE interrupt occur whenever a corresponding event happens.
So in the corresponding callback functions, all corresponding Flags are set to inform that data copy is needed.
The application function checks whether the flag for data copy is set and if so, copy data from DMARxBuf to RxBuf.
Then send data in RxBuf to the peer system via Ethernet.