Download Print this page

Espressif ESP32 Technical Reference Manual page 548

Hide thumbs Also See for ESP32:

Advertisement

21 Two-wire Automotive Interface (TWAI)
• A frame with the smallest ID value will always win arbitration.
• Given the same ID and format, Data Frames will always prevail over RTR Frames.
• Given the same first 11 bits of ID, a Standard Format Data Frame will prevail over an Extended Format Data
Frame due to the SRR being recessive.
Control Field
The control field primarily consists of the DLC (Data Length Code) which indicates the number of payload data
bytes for a Data Frame, or the number of requested data bytes for a Remote Frame. The DLC is transmitted most
significant bit first.
Data Field
The Data Field contains the actual payload data bytes of a Data Frame. Remote Frames do not contain a Data
Field.
CRC Field
The CRC Field primarily consists of a a CRC Sequence. The CRC Sequence is a 15-bit cyclic redundancy code
calculated form the de-stuffed contents (everything from the SOF to the end of the Data Field) of a Data or
Remote Frame.
ACK Field
The ACK Field primarily consists of an ACK Slot and an ACK Delim. The ACK Field is mainly intended for the
receiver to send a message to a transmitter, indicating it has received an effective message.
Data/Remote Frames
SOF
Base ID
RTR
SRR
IDE
Extd ID
r1
r0
Espressif Systems
Table 21-1. Data Frames and Remote Frames in SFF and EFF
Description
The SOF (Start of Frame) is a single Dominant bit used to synchronize nodes
on the bus.
The Base ID (ID.28 to ID.18) is the 11-bit Identifier for SFF, or the first 11-bits of
the 29-bit Identifier for EFF.
The RTR (Remote Transmission Request) bit indicates whether the message is
a Data Frame (Dominant) or a Remote Frame (Recessive). This means that a
Remote Frame will always lose arbitration to a Data Frame given they have the
same ID.
The SRR (Substitute Remote Request) bit is transmitted in EFF to substitute for
the RTR bit at the same position in SFF.
The IDE (Identifier Extension) bit indicates whether the message is SFF (Domi-
nant) or EFF (Recessive). This means that a SFF frame will always win arbitration
over an EFF frame given they have the same Base ID.
The Extended ID (ID.17 to ID.0) is the remaining 18-bits of the 29-bit identifier
for EFF.
The r1 (reserved bit 1) is always Dominant.
The r0 (reserved bit 0) is always Dominant.
Submit Documentation Feedback
548
ESP32 TRM (Version 5.2)

Advertisement

loading
Need help?

Need help?

Do you have a question about the ESP32 and is the answer not in the manual?

Subscribe to Our Youtube Channel