This application note describes the CAN interrupt drivers of the ST10F27x/ST10F25x and provides programming examples that can be used to define interrupt schemes and write interrupt drivers.
This document provides an overview of the CAN interrupt drivers implemented on the ST10F27x/ST10F25x microcontrollers. It details two primary methods for handling interrupts: one utilizing the hardware features of the CAN modules (preferred for most applications) and another using polling internal sources (recommended only for small networks). The text explains how to identify interrupt sources, manage priorities, and configure the necessary registers.
The guide covers specific interrupt types including status interrupts (for transmission/reception success or errors), error interrupts (warning and bus-off states), and message-specific interrupts. It includes sample programs demonstrating software decoding of these interrupts and describes the bus-off recovery sequence.
| Number of C-CAN modules | Two |
|---|---|
| Total message objects per module | 32 |
| Error warning limit | 96 |
| Bus-off threshold | 255 |
Programming through CAN hardware features using RXIE and TXIE bits is the preferred method as it requires minimum CPU overhead.
Polling is recommended only for small networks because it generates high CPU overhead by interrupting the CPU every time a message is acknowledged.
A bus-off state occurs when the transmit error counter exceeds the value of 255.