embassy-mcxa

Crates

git

Versions

mcx-a256

Flavors

InterruptExt

Trait InterruptExt 

Source
pub trait InterruptExt {
    // Required methods
    fn unpend(&self);
    fn set_priority(&self, priority: Priority);
    unsafe fn enable(&self);
    unsafe fn disable(&self);
    fn is_pending(&self) -> bool;
}
Expand description

Trait for configuring and controlling interrupts.

This trait provides a consistent interface for interrupt management across different interrupt sources, similar to embassy-imxrt’s InterruptExt.

Required Methods§

Source

fn unpend(&self)

Clear any pending interrupt in NVIC.

Source

fn set_priority(&self, priority: Priority)

Set NVIC priority for this interrupt.

Source

unsafe fn enable(&self)

Enable this interrupt in NVIC.

§Safety

This function is unsafe because it can enable interrupts that may not be properly configured, potentially leading to undefined behavior.

Source

unsafe fn disable(&self)

Disable this interrupt in NVIC.

§Safety

This function is unsafe because disabling interrupts may leave the system in an inconsistent state if the interrupt was expected to fire.

Source

fn is_pending(&self) -> bool

Check if the interrupt is pending in NVIC.

Implementors§