Main Content

Event Scheduling and Interrupt Handling

R2026b
Schedule events and handle hardware interrupts to address real-time tasks with Arduino

Improve system responsiveness to real-time tasks and events using external and hardware interrupts for Arduino® boards across various architectures.

Blocks

External Interrupt blockExternal InterruptTrigger the downstream function-call subsystem from an Interrupt Service Routine
Arduino Hardware Interrupt IconHardware Interrupt SAMDTrigger downstream function-call subsystems from interrupt service routine for Arduino SAMD21 core (Since R2023b)
Arduino AVR Library Hardware Interrupt Block IconHardware Interrupt AVRTrigger downstream function-call subsystems from interrupt service routine for Arduino AVR core (Since R2024a)
Arduino SAM Library Hardware Interrupt Block IconHardware Interrupt SAMTrigger downstream function-call subsystems from interrupt service routine for Arduino SAM core (Since R2024b)
Arduino Teensy4 Library Hardware Interrupt Block IconHardware Interrupt Teensy4Trigger downstream function-call subsystems from interrupt service routine for Teensy 4.0 and 4.1 boards (Since R2024b)

Topics

Troubleshooting

Workaround for Interrupt Workflow with Sensors

Follow the steps to use interrupts with sensors and the I2C protocol.

External Interrupts Workflow for Arduino

Follow the steps to use external interrupts in Simulink models.

Featured Examples