Civil Engineering Reference
In-Depth Information
Table 1.1  Maximum frame length for data frames
Short identifier
Elements of a CAN frame
Long identifier
1
Start of frame
1
11
(Base) Identifier
11
Substitute remote request (SRS)
1
Identifier extension flag (IDE)
1
Identifier extension
18
1
Remote transmission request (RTR)
1
6
Control field (IDE, r0, DLC or r1, r0, DLC)
6
64
Data field (8 × 8 bit)
64
16
CRC field (CRC sequence and CRC
delimiter)
16
24
(Maximum number of) stuff-bits
29
2
Acknowledge field (ACK slot and ACK
delimiter)
2
7
End of frame
7
3
Interframe space
3
Total
135
Maximum frame length
Total
160
the effective data rate for different lengths of the Data Field at a bit rate of 1 Mbit/s.
At these values, the number of stuff bits is not considered.
Of course, no data rate can be calculated for a Data Field with a length of zero.
However, such messages still have information content. The mere fact that a mes-
sage with a certain identifier appears on the bus can be used for a so-called “Life
Guarding” mechanism, i.e. key CAN nodes must—in a certain time schedule—send
such a frame on the network, allowing other nodes to keep track of their operation
state. Furthermore, such frames can be used, e.g. for synchronization purposes in a
distributed application.
Considering the previous results for the calculation of the host controller's time
budget needed to handle the CAN messages, the following values have to be taken
into consideration:
The worst-case conditions regarding the processing time of the interrupt service
routine for received frames occur at the maximum transfer rate of 1 Mbit/s, 100 %
bus load and a message length of zero data bytes.
This means that with these parameters a message can be received every 47 µs. If
the interrupt service routine in this example needed exactly 47 µs, the central pro-
cessing unit (CPU) would be loaded to 100 % with this task alone and would have
no capacity left for other tasks. For networks using only frames with 29-bit identi-
fiers, this time would be—under the same conditions—67 µs.
The tasks of the received interrupt service routine depend on the type of CAN
module; they are different for modules of the type “Full CAN” or the type “Basic
CAN”, see Sect. 1.2.7.
 
Search WWH ::




Custom Search