Open search
Advertisement

CAN Newsletter magazine

Migration from Classical CAN to CAN FD

The evolution of Classical CAN to CAN FD and its standardization within ISO 11898-1:2015 has opened the way for CAN FD applications. Especially, raising the performance of entire machine units with as little effort as possible makes CAN FD an interesting option.

CAN FD boards of 402 series in various form factors (Source: ESD Electronics)

The complete article is published in the March issue of the CAN Newsletter magazine 2021. This is just an excerpt.

Due to its high data security the CAN network has been successfully established in automotive applications and in the industrial automation sector as well as safety-related areas. The longstanding CAN network has not only become a standard in the automotive industry, but has also proven effective in the field of industrial automation, elevator engineering, or medical engineering as well as for vehicle bodies or marine electronics. As a result of growing demands within the automotive sector, in 2011 Bosch initiated the further development of the CAN protocol. In close collaboration with other CAN experts the protocol underwent further development and was equipped with a flexible data-rate (FD) enhancement. The low data-rate of 1 Mbit/s with cable lengths of around 40 m as well as limited user data of 8 bit did not comply anymore with the desired performance characteristics of modern CAN applications. The data through- put can be increased by a factor of eight without changing cabling and infrastructure.

Especially, complex electronic controllers require a wider range when it comes to software downloads or servo- motor controls. CAN FD allows data-rates up to 10 Mbit/s and transmission up to 64-bit user data. This increased data-range of 64 bit also corresponds to the smallest possible message within the Ethernet protocol. In this way, gateways between CAN FD and Ethernet can be realized more easily. Moreover, related data items can be transferred in a single data package and do not have to be synchronized by software. This makes handling of application programs and system design much easier and more convenient.

The structure of the backwards compatible CAN FD frame hardly differs from the Classical CAN frame (Source: ESD Electronics)

The continued simple data link protocol, the cost-effective controller, and transceiver chips with a low power consumption make CAN FD a particularly attractive solution: thanks to its robustness and reliability CAN FD was adopted quite fast in the automotive industry. In this sector CAN FD products are successfully used for test builds and testing systems. Outside of automotive applications CAN FD is applied for example in CAN-based machines and plant equipment. Due to the same CAN frame design the existing cabling can be used. Even for ongoing developments of applications a migration to CAN FD can be accomplished quite easily.

How CAN FD functions

The idea behind the CAN FD protocol is to increase the cycle-rate between network arbitration and the acknowledgment field of a CAN frame. Since at this stage only one node is able to send on the network the maximum data- rate only depends on the internal delay time of the CAN transceiver and the data signal (about 5 ns/m). In this way, it is possible to realize data-rates up to 15 Mbit/s with net- work lengths up to 40 m.

The CAN FD frame is backwards compatible and quite similar to the Classical CAN frame. A new feature is the bit BRS (bit-rate-switch) in the arbitration field, which is used to recognize the higher data- rate. There is also the ESI (error state indicator) which is related to the control panel and displays the error-mode. In order to verify the data-field length the bit FDF (FD format) was defined as well as a three-bit wide stuff bit counter. The sender counts the number of stuff bit and transmits the result as gray-coded 3-bit-value. The recipient also counts the incoming stuff bit and compares their values. The transmission reliability is increased by a parity bit attached to the sequence and by a fixed stuff bit in the CRC field.

The RTR bit, however, is being ignored, since the CAN FD protocol does not support any remote frames. With correction of the error detection mechanism of the CAN FD standard (ISO 11989-1/2015) such as adding the stuff bit counter the protocol reaches a Hamming distance of six. It is possible to distinguish up to five arbitrarily distributed bit errors leading to an automatic-repeated message. This makes the protocol an interesting option for safety-related areas.

The Advanced CAN Controller (esdACC) offers an up to 32-bit wide interface, supports 64-bit time stamp and is able to generate a 100 % network load (Source: ESD Electronics)

CAN FD controller for FPGA (esdACC)

In developing CAN components, it is possible to refer to regular CAN FD controllers or to CAN FD controllers in FPGAs. FPGAs are more flexible in terms of performance and functional density. In the past, common CAN controllers were connected to the host-system via 8-bit or 16-bit wide networks. The write access and especially the read access towards these controllers are quite slow compared to cycle times of modern CPUs (central processing unit). That is why ESD Electronics developed its own FPGA-based CAN controller called Advanced CAN Controller (esdACC). It offers an up to 32-bit wide interface, supports 64-bit time stamp and is able to generate a 100 % network load.

Another variant is the CAN FD controller for FPGA which supports the CAN FD protocol according to ISO 11898-1:2015. This controller is able to send and receive an ISO-compliant CAN FD protocol and to transmit the 11-bit-identifier base frame format and 29-bit-idientifier extended frame format frames. The CAN FD transmission rate is between 10 kbit/s and 5 Mbit/s. Thanks to the FPGA technology it is no problem to implement custom-specific performance characteristics.

PC board with CAN FD

The esdACC is the core component of the CAN interface CAN-PCIe/402-FD. The board provides a CAN FD transceiver and a connection to the PCI Express network as well as a 16 CAN frame deep TX FIFO. Hence, it is possible to generate a 100 % network load with a true back- to-back-transmission even when using non-real-time operating systems. Due to the 32-bit register interface CAN frames can be sent and received with a minimum number of register accesses. Further features include bit-precise CAN transmission and frame-precise cancellation of transmission with a minimum delay due to timeouts.

Broken CAN FD frames in the FIFO are not blocked by low-priority TX signal. Also, host CPU loads are reduced by network mastering towards RX and by the optional integration of a 32-bit micro-controller. The large FIFO for read and write operations as well as a precise time stamping enable further applications, e.g. for higher-layer CAN protocols. The esdACC IP core has been validated for Xilinx Spartan and Altera Cyclone FPGAs. The CAN interface CAN-PCIe/402-FD can be applied universally and has been developed for the PCIe (peripheral component interconnect express) network.

It provides one or two CAN FD interfaces according to ISO11898-2. For data transmission to the host memory the board uses network mastering. In this way, the latency periods can be reduced during I/O-transactions due to higher data-rates and a reduction of CPU loads. With the help of MSI (message signaled interrupts) the PC board can operate in hypervisor environments. Moreover, it supports high-resolution hardware time stamping. Handling of the CAN FD is significantly simplified by the monitoring and diagnosis tool “CAN real”.

CiA test passed

The user organization CiA (CAN in Automation) regularly organizes so called plugfests in order to test interoperability of CAN FD implementations. Furthermore, it is the goal to find out about the physical limits of transmission with respect to topology and data-rates. During these tests, data-rates up to 10 Mbit/s were approved error-free even at 100 % network load over a longer period of time. ESD Electronics took part at the plugfest with its PCI Express CAN interface CAN-PCIe/402 with CAN FD transceivers. Hauke Webermann, developing engineer at ESD Electronics, summarizes the results as follows: “The board interoperated perfectly with other CAN nodes. Communication with the CAN FD network even worked with bit-rates of more than 6 Mbit/s and the pure data reception was flawless up to a bit-rate of 10 Mbit/s.”

If you would like to read the full article from Renate Klebe-Klingemann and Hauke Webemann (both ESD Electronics) you can download it free of charge or you download the entire magazine.

cw

Publish date
2021-03-10
Company

CAN Newsletter March issue
ESD Electronics

Breadcrumb