AN2341 STMicroelectronics ST10F27x/F25x CAN Interrupt Drivers Programming Application Note

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.


AN2341 STMicroelectronics ST10F27x/F25x CAN Interrupt Drivers Programming Application Note - cover page
Brand
STMicroelectronics
Category
microcontrollers
Document type
Application Note
Language
English
Pages
26
File format
PDF
File size
163 KB
Published
06 August, 2012
Updated
30 September, 2023
Models
ST10F27x, ST10
MD5 checksum
4AF5D3E6E831346FD9FD8B44599310BA

About this manual

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.

What's inside

  • Interrupt sources and identification
  • Global interrupt sources
  • Individual interrupt sources
  • Status interrupts
  • Error interrupts
  • Message-specific interrupts
  • Handling interrupts
  • Programming through CAN hardware features
  • Programming through polling
  • Bus-off recovery sequence

Specifications

Number of C-CAN modulesTwo
Total message objects per module32
Error warning limit96
Bus-off threshold255

Frequently asked questions

Which method is preferred for handling CAN interrupts?

Programming through CAN hardware features using RXIE and TXIE bits is the preferred method as it requires minimum CPU overhead.

When should polling be used for interrupt handling?

Polling is recommended only for small networks because it generates high CPU overhead by interrupting the CPU every time a message is acknowledged.

What causes a bus-off state?

A bus-off state occurs when the transmit error counter exceeds the value of 255.

Download PDF (163 KB)

More STMicroelectronics Manuals


View all STMicroelectronics manuals →