Page 1 of 1

What can cause TWAI TWAI_ALERT_TX_FAILED

Posted: Wed Aug 24, 2022 1:48 pm
by ci4rail
Using ESP32S2 and esp-idf v4.4.1.

Under heavily loaded CAN bus, sometimes it happens that the TWAI driver reports TWAI_ALERT_TX_FAILED and in this case, the transmit message is lost. What can cause this error? I noticed from ESP32-S2 TRM (V1.0) that this alert is fired when TWAI_STATUS_REG.TWAI_TX_COMPLETE is not set when the transmit interrupt occurs. However, the technical manual does not explain why TWAI_TX_COMPLETE may not be set.

How can I avoid that transmit messages can get lost?

Re: What can cause TWAI TWAI_ALERT_TX_FAILED

Posted: Thu Sep 01, 2022 9:11 am
by ci4rail
Hello, can somebody help please?