FlexCAN — CAN Driver


This driver supports the FlexCAN CAN devices available in some NXP i.MXRT microprocessors.


The device provides filtering support that is compatible with the filter model defined by the CAN subsystem, and therefore hardware filtering is employed.

Baud Rates

The following baud rates are supported: 1Mb/s, 500kb/s, 250kb/s, 125kb/s, 100kb/s, 50kb/s, and 20kb/s.


This driver requires an external package to configure it for the particular microcontroller, normally the platform (PLF) or variant (VAR) HAL. Each CAN channel is then implemented by a controller instance as specified.

For each channel # supported the CDL script in this package will provide the following configuration options:


This defines whether the channel is included. It depends on the associated FLEXCAN controller being implemented for the platform.


The CAN channels are numbered logically from 0, whereas the physical FLEXCAN controllers are numbered from 1. So if the platform supports the FLEXCAN2 controller the correspoding CAN channel device name will be “can1” by default.

This defines the name of the channel. This is the name that an eCos application should use to access the device via the I/O API.
This option defines the interrupt priority for the FLEXCAN controller interrupts.

This option defines the number of MailBox (MB) slots available for use as RX buffers. The minimum acceptable setting allowed being 2 dedicated RX buffers. However, for normal application configurations it is expected that more RX buffers will be required than TX buffers, so the default reflects such “normal” ratio.

The number of available TX mailboxes (CYGPKG_DEVS_CAN_CHANNEL#_MB_TX) is calculated as the number of remaining mailboxes after the RX allocation.

This option defines the start-of-day (default) bitrate for the CAN channel.