Login

CAN Driver

CAN driver

MDK-Professional includes a generic CAN interface layer which provides a standard programming API for all supported microcontrollers. It provides a quick and easy way to implement a CAN network, and provides code portability, should you need to migrate your code to another microcontroller.

RTX Functions

The CAN interface runs interrupt service routines using RTX Kernel functions for Mailbox Management and Memory Allocation. It uses one Memory Pool for all CAN messages and two mailbox arrays.

Generic Software Layer

The generic software layer allows users to apply the same interface across different targets and to easily switch from one target to another without changing the main application code. The CAN interface API supports:

  • Initialize/Start CAN Communication
  • Define CAN message objects for RX/TX
  • Send, request, and receive CAN messages

Hardware Dependent Layer

The CAN hardware layer enables the generic software interface to function on many different targets, with each target having its own hardware layer implementation. The Hardware Layer supports the following devices:

  • Atmel SAM7 & SAM9
  • NXP LPC17xx, LPC21xx, LPC23xx, LPC24xx, & LPC29xx
  • STMicroelectronics STR7, STR9, & STM32
  • Texas Instruments Stellaris family

CAN Primer

CAN is extensively used in automobiles and trucks but has found applications everywhere. There are many application layers available for CAN, however, it is very easy to develop your own protocol that will fit and simplify your needs. This detailed primer removes the mystery of developing applications using CAN and will guide you in making the right choices when implementing a system.

Download the CAN Primer

Note:

  • The USB Device Interface is provided in binary form as part of MDK-Professional. It is not included with other MDK-ARM Editions.
 
 


Features
11-bit message IDs yes
29-bit message ID yes
Data Frames yes
Remote Frames yes
Multiple Message Queues yes
Basic CAN (single tx & rx buffer) yes
Full CAN (multiple tx & rx buffers) yes

Memory Requirements
CAN Component Code Size (Bytes) RAM Size (Bytes)
CAN Core 456 173
LPC17xx HW Driver 1,172 4
STM32F10x HW driver 1,584 12

Note

  • All example figures are based on Cortex-M3
  • All values are minimum requirements with minimum data buffers and no application code

Maximise


Cookies

We use cookies to give you the best experience on our website. By continuing to use our site you consent to our cookies.

Change Settings

Find out more about the cookies we set