Interface for CAN peripherals.
Defines multiple traits for different purposes.
Configure trait is used to configure the communication
mode and bit timing parameters of the CAN peripheral. The
ConfigureFd trait is an advanced feature that can be implemented
for peripherals that support flexible data messages. These
2 traits represent synchronous actions and do not need a client
in order to confirm to the capsule that the action is finished.
Controller trait is used to enable and disable the device.
In order to be able to enable the device, the bit timing parameters
and the communication mode must be previously set, and in order
to disable the device, it must be enabled. This trait defines
asynchronous behaviours and because of that, the
trait is used to confirm to the capsule that the action is finished.
Filter trait is used to configure filter banks for receiving
messages. The action is synchronous.
Transmit trait is used to asynchronously send a message on
the CAN bus. The device must be previously enabled. The
TransmitClient trait is used to notify the capsule when the
transmission is done or when there was en error captured during
Receive trait is used to asynchronously receive messages on
the CAN bus. The
ReceiveClient trait is used to notify the capsule
when a message was received, when the receiving process was aborted
and anytime an error occurs.
Configuretrait is used to configure the CAN peripheral and to prepare it for transmission and reception of data. The peripheral cannot transmit or receive frames if it is not previously configured and enabled.
ConfigureFdtrait is used to configure the CAN peripheral for CanFD and to prepare it for transmission and reception of data. The peripheral cannot transmit or receive frames if it is not previously configured and enabled.
Controllertrait is used to enable and disable the CAN peripheral. The enable process applies the settings that were previously provided to the driver using the
Filtertrait is used to enable and disable a filter bank.
Receivetrait is used to interact with the CAN driver through receive requests only.
StandardBitTimingtrait is used to calculate the optimum timing parameters for a given bitrate and the clock’s frequency.
Transmittrait is used to interact with the CAN driver through transmission requests only.