11-10-2012, 03:35 PM
CAN with Flexible Data-Rate
CAN with Flexible.pdf (Size: 189.11 KB / Downloads: 303)
INTRODUCTION
The Controller Area Network (CAN) is a serial communications protocol which efficiently
supports distributed realtime control with a very high level of security.
Its domain of application ranges from high speed networks to low cost multiplex wiring.
In automotive electronics, engine control units, sensors, anti-skid-systems, etc. are
connected using CAN with bitrates up to 1 Mbit/s. At the same time it is cost effective to
build into vehicle body electronics, e.g. lamp clusters, electric windows etc. to replace
the wiring harness otherwise required.
CAN FD (CAN with Flexible Data-Rate) complements CAN in applications that require a
higher data-rate. CAN FD protocol controllers are also able to take part in standard CAN
communication, making it possible to use CAN FD only in specific operation modes, e.g.
software-download at end-of-line programming or at maintenance, while other
controllers that do not support CAN FD are kept in standby.
CAN FD makes use of the (first) reserved bit of a CAN frame. In a CAN frame, this
reserved bit is transmitted ’dominant’. In a CAN FD frame, this bit is transmitted
’recessive’ and indicates that this frame is transmitted in the CAN FD format. A CAN FD
controller is able to decode both formats.
There are two main differences between the CAN FD frame format and the CAN frame
format, first the option to use frames with more than 8 data bytes and second the option
to switch to a different bit rate after the arbitration is decided.
CAN FD requires two sets of bit timing configuration registers, the first bit time for the
arbitration phase and the second bit time for the data phase. The bit time for the
arbitration phase has the same limitations as in standard CAN networks, the bit time for
the data phase is chosen with regard to the performance of the chosen transceiver and
the characteristics of the CAN FD network. Both bit times may be identical.
Standard CAN transceivers can be used for CAN FD, dedicated transceivers are
optional. CAN FD protocol controllers may provide additional interface signals to switch
- in the phase with higher bit-rate - a dedicated CAN FD transceiver into an alternate
operating mode.
BASIC CONCEPTS
A CAN FD frame consists of the same elements as a CAN frame, the difference is that
in a CAN FD frame, the Data Field and the CRC Field may be longer. Message
validation requires, as in CAN, a dominant Acknowledge bit from at least one receiver.
The CAN FD fault confinement with Error Frames, Error Counters, Error Passive level
and Bus-Off level is the same as in CAN, it is based on the same five error types: Bit
Error, Stuff Error, CRC Error, Form Error, and Acknowledgement Error.
FRAME FORMAT
CAN FD supports both Identifier lengths of the CAN protocol, the 11 bit long "Standard
Format" and the 29 bit long "Extended Format". In both cases, the bit-rate is switched to
the shorter bit time at the BRS bit (before the ESI bit and the DLC).
DATA LENGTH CODE
The number of bytes in the DATA FIELD is indicated by the DATA LENGTH CODE.
This DATA LENGTH CODE is 4 bits wide and is transmitted within the CONTROL
FIELD.
The coding of the DATA LENGTH CODE is different in CAN FD. The first nine codes
are the same, but the following codes, that in CAN specify a DATA FIELD of eight
bytes, specify longer DATA FIELDS in CAN FD. All Remote Frames shall use a DATA
LENGTH CODE of zero, regardless of the DATA LENGTH CODE of the corresponding
Data Frame.
Note
In this document, the maximum length of the DATA FIELD is specified to be 64 bytes.
This value, and the other values > 8 of DATA LENGTH CODE may change in the final
specification of CAN FD.
BIT TIMING REQUIREMENTS
The CAN FD protocol defines two bit-rates, the first for the arbitration phase with a
longer bit time and the second for the data phase with a shorter bit time. The definition
for the first bit-rate is the same as for the NOMINAL BIT RATE and the NOMINAL BIT
TIME in the CAN protocol specification. The definition for the second bit-rate requires a
separate configuration register set. Both bit times consist of separate non-overlapping
time segments, these segments form the bit time as shown in this figure.
TRANSCEIVER DELAY COMPENSATION
Without a transceiver delay compensation, the bit rate in the fast phase of a CAN FD
frame is limited by the fact that the transmitter detects a bit error if it cannot receive its
own transmitted bit latest at the SAMPLE POINT of that bit.
CAN FD nodes shall support an optional transceiver delay compensation mechanism, to
be used in applications where the length of the CAN bit time in the fast phase is shorter
than the limit required by the transceiver’s internal delay time.
The transceiver delay compensation mechanism defines a secondary sample point
where the transmitted bit is compared with the received bit in order to check for bit
errors. This mechanism shall only be used by transmitters in the fast phase of a
CAN FD frame, when it is used, the transmitter shall ignore the bit value received at the
SAMPLE POINT. The delay to be compensated, Trv_Delay, shall be measured in each
transmitted frame at the edge from the EDL bit to the following reserved bit r0, between
the edge of the transmitted bit and the edge of the received bit.
The position of the secondary sample point shall be Trv_Delay plus an offset (e.g. half
of the bit time in the fast phase), rounded down to the next integer number of time
quanta. The resulting secondary sample point may be placed after the end of the
transmitted bit. If a bit error is detected at the secondary sample point, the transmitter
will react to this bit error at the next following SAMPLE POINT.