// php echo do_shortcode (‘[responsivevoice_button voice=”US English Male” buttontext=”Listen to Post”]’)?>
Due to higher bandwidth requirements in the automotive field, the CAN (controller area networking) specification was extended for flexible data – rates with a new iteration known as CAN FD.
CAN offers advantages such as cost, flexibility, and robustness, all of which are very beneficial to non-automotive applications in many fields. The market opportunities are even wider with the CAN FD extension. This article covers the fundamentals of CAN and CAN FD and the different application implementations using varying physical layers or higher layer protocols with CAN as the data link layer.
First, let’s touch on the advantages of CAN over standard serial communication such as RS232 or RS485. Due to CAN’s higher communication speed with error detection, it offers excellent robustness and lower cost.
Cost and flexibility
The most important driver for the car industry was to reduce the amount of wiring in the car. Due to twisted pair wiring, it is relatively easy to lay the wire, and it is less heavy and expensive. The termination resistors are necessary to run CAN and CAN FD at higher speeds. The flexibility is a great plus, as it is very easy to extend the system with more nodes.
Error detection and robustness
CAN and CAN FD incorporate very reliable error check mechanisms. Bit stuffing and monitoring work on layer one, while frame check, acknowledgment, and cyclic redundancy check function on layer two of the OSI model.
Bit stuffing adds an alternating bit after five consecutive high or low bits. Six consecutive bits with the same level indicate an error. Bit monitoring reads back every message that is sent. If there is a difference (except in the arbitration or acknowledgment field), an error is detected. A big advantage is that errors are detected in a very timely manner.
Cyclic redundancy checks are implemented differently on CAN versus CAN FD because of the different data lengths. Frame errors (sometimes also called format or form errors) use predefined values which must be the same on the receiver side. Each message needs to be acknowledged. This three error check mechanism works well on the message level.
In summary, CAN and CAN FD are very robust and reliable with several different error checks. No data is lost during the transmission of a message and message collisions are prevented. Each node waits for a period of inactivity before sending. In case two, messages are sent at the same time, the transmitter detects which message has a higher priority, and disables the message with lower priority. Compared to Ethernet where both messages are stopped and sent later, on CAN the message with the highest priority comes through.
High – speed and low latency
CAN supports data rates up to 1Mbps. With CAN FD the data rate can be increased for the control and data area depending on the maximum clock of the CAN FD controller. The rate for the arbitration phase stays at maximum 1Mbps.
The latency for CAN is less than 145us while for CAN FD with 8Msps and 8Byte data, it is less than 58us.
Short data frames have an advantage in terms of latency. The complete package is transferred and decoded faster and therefore the reaction time is also faster. With higher transmission rates on CAN FD, this effect is even greater. Compared with TCP / IP communication, which is designed for large amount of data, the packages are relatively large and therefore latency increases. That means CAN FD, depending on the amount of data, potentially has shorter reaction times compared to TCP / IP communication with 10 or 100Mbit, and shows better total real – time performance.
Regarding the number of nodes, there is theoretically no limit as each message can be sent to a different node. In practice, each node causes signal reflections on the bus and transmission quality is dependent on the CAN transceiver and the implementation on the physical layer.
This is also the reason for limitation in terms of speed when it comes to long distance. Usual values are at maximum 25 nodes on CAN and at maximum 8 nodes on CAN FD.
Application examples outside of automotive
Why use CAN FD outside of automotive applications? Because of the great advantages described above. CAN and CAN FD are widely used across industries including:
- Building Automation
- Elevator and lift
- Access control, light control, and secure door opener
- Air conditioning
- Automotive aftermarket
- Fleet tracking, vehicle tracking
- Logging for predictive maintenance, telematics, insurance, and blackbox
- Medical and healthcare equipment
- Industrial drives
- Between host and chained actuators
A great use case of MCUs with two CAN FD controller units in combination with TrustZone and Security is a control unit in building automation separating secure parts from non-secure parts. One CAN FD controller can be used for the secure side to control critical components such as door openers, sliding doors, and ID card readers. The second CAN FD can be used for non-critical control parts in building automation, such as light switch buttons, bulbs, and doors inside of the building.
Another use case for dual CAN FD units is gateway functionality such as in large building automation systems, large cabinets, and communication extension modules. There are many different use cases for MCUs with integrated CAN FD controllers such as actuators, sensors, and control.
CAN FD is very suitable in applications where high safety and reliability are required, such as in robots, lifts, and transportation systems, as well as in medical and healthcare systems. The reliability requirements necessary in automotive applications are also very beneficial in these use cases.