Skip to main content
JulienD
Associate III
May 23, 2024 10:09 AM UTC
Solved

Uart : what is the difference between IDLE and RTO interrupts

Hello,

 

Can I say that "IDLE" is equivalent to "RTO with 8-10 bits (depending on framing)"?

Or are there some other subtle differences?

 

My goal is to transfer received data with DMA and start interpretation of the data when nothing is received on the line which, in my application's world, is equivalent to an end of frame.

 

Thanks

Julien

 

Muhammed Güler
Muhammed GülerBest answer
Senior III
May 23, 2024 12:15 PM UTC

5 replies

Muhammed Güler
Muhammed GülerBest answer
Senior III
May 23, 2024 12:15 PM UTC
JulienD
JulienDAuthor
Associate III
May 27, 2024 8:56 AM UTC

Thanks for your answer, it's exactly what my experiments lead me to understand.

Delay is the only difference between RTO and IDLE.

Pavel A.
May 27, 2024 10:21 PM UTC

No, delay is not the only difference between RTO and IDLE.

The IDLE condition occurs when the UART receives the "idle frame". So when the RX line is silent and IDLEIE set, the UART will continuously generate IDLE interrupts. RTO timeout starts counting after at least one data byte is received (after its stop bit TL;DR); it won't occur just when RX line is silent. Easier to manage. This is the behavior you actually want (and the reason why this feature exists at all).

The IDLE detection serves also another purpose, to wait for opportunity to transmit when multiple devices share the comm line or wait until noise disappears.

Pavel A.
May 24, 2024 8:35 PM UTC

Short answer: RTO is what you want to use. IDLE is what you don't want, if RTO is available.