cancel
Showing results for 
Search instead for 
Did you mean: 

How to properly temporarily disable UART reception ?

bully
Senior

Hello,

we have UART based communication that cause crosstalk between RX and TX lines.

It can't be fixed, so I'd like to solve it in SW.

I'd like to temporarily disable/enable UART reception before/after sending on UART.

I'm already putting DMA into Pause/Resume, but I still get those crosstalk bytes (probably UART is still receiving into own buffer).

How to properly disable UART reception for some short time ?

I could do deinit_/init procedure, but maybe there is a shorter way...

thanks in advance.

5 REPLIES 5

0693W00000D0KcCQAV.pngJW

Helger Brenner
Associate

Just some wild suggestion:

Since you are prepared to compromise some transmission speed. So, why not adding some redundancy instead? Send every byte three times and apply "majority". Hardware error correction (parity check?) will have to be disable, I think.

Regards

It is a wild idea, but I think that sending more chars will just cause more crosstalk and echos... I think the easiest solution is not receive, while transmitting...

Regards.

Hello,

thanks for the tip. I'll check and implement it...

Regards.

0693W00000D1HJ9QAN.jpgIn case you want to restart reception with a clean (empty) Rx content (and discard a data that might have been received prior you disable/enable RE), you could also flush the RX path by writing 1 in RXFRQ bit in USART_RQR register.

Regards