MDK-ARM Keil, MDK-ARM Datasheet - Page 146

KIT REALVIEW MCU DEVELOPMENT

MDK-ARM

Manufacturer Part Number
MDK-ARM
Description
KIT REALVIEW MCU DEVELOPMENT
Manufacturer
Keil
Type
Compiler and IDEr
Datasheets

Specifications of MDK-ARM

For Use With/related Products
ARM MCUs
Lead Free Status / RoHS Status
Lead free / RoHS Compliant
146
Chapter 6. RL-CAN Introduction
CAN arbitrates its messages by a method called “non-destructive bit-wise
arbitration”. In the diagram, three messages are pending transmission. Once the
bus is idle and the messages are synchronized by the start bit, they will start to
write their identifiers on to the bus. For the first two bits, all three messages
write the same logic and, hence, read back the same logic, so each node
continues transmission. However, on the third bit, nodes A and C write dominant
bits, and node B writes recessive. At this point, node B wrote recessive but reads
back dominant. In this case, it will back off the bus and start listening.
Nodes A and C will continue transmission until node C writes recessive and node
A writes dominant. Now, node C stops transmission and starts listening. Node
A has won the bus and will send its message. Once node A has finished, the
nodes B and C will transmit. Node C will win and send its message. Finally,
node B will send its message. If node A is scheduled again, it will win the bus
even though the node B and C messages have been waiting. In practice, the
CAN bus will transmit the message with the lowest value identifier first.
RL-CAN Driver
As mentioned above, CAN has been widely adopted for distributed control
within embedded systems. Today, just about all microcontroller families include
a variant, or variants, with a CAN controller peripheral. However, each
manufacturer’s CAN controller has a different set of special function registers
and features. The RL-ARM library includes a dedicated CAN driver, which
provides a standard programming API for all supported microcontrollers. The
CAN driver uses RTX message queues to buffer data before it is transmitted or
received. The RL-CAN driver provides a quick and easy way to implement a
CAN network. The RL-CAN driver also provides code portability, in case you
need migrating code to another microcontroller.
First Project
Unlike the other middleware components within the RL-ARM library, the RL-
CAN driver must be used with RTX.
The RL-CAN driver consists of
two C modules and associated
header files. The first module,
, is a generic layer
RTX_CAN.c
driver, which provides the high

Related parts for MDK-ARM