pub struct Int { /* private fields */ }Expand description
Access to interrupt controller.
Implementations§
Source§impl Int
impl Int
Sourcepub fn new(int: INT) -> Int
pub fn new(int: INT) -> Int
Create a new instance. Configures the interrupt controller to work in the Multi-vectored mode. The Cause register of the MIPS core must be already configured for use with External Interrupt Controller (EIC); done by startup code.
Sourcepub fn ei(&self, s: InterruptSource)
pub fn ei(&self, s: InterruptSource)
Enable interrupts for a specific source
Sourcepub fn di(&self, s: InterruptSource)
pub fn di(&self, s: InterruptSource)
Disable interrupts for a specific source
Sourcepub fn is_ie(&self, s: InterruptSource) -> bool
pub fn is_ie(&self, s: InterruptSource) -> bool
Check if interrupts for a specific source are enabled
Sourcepub fn get_if(&self, s: InterruptSource) -> bool
pub fn get_if(&self, s: InterruptSource) -> bool
Read the interrupt flag of a specific interrupt source
Sourcepub fn clear_if(&self, s: InterruptSource)
pub fn clear_if(&self, s: InterruptSource)
Clear the interrupt flag of a specific interrupt source To be called before terminating an ISR.
Sourcepub fn set_if(&self, s: InterruptSource)
pub fn set_if(&self, s: InterruptSource)
Set the interrupt flag of a specific interrupt source
Sourcepub fn set_ipl(&self, iv: Interrupt, ipl: Ipl)
pub fn set_ipl(&self, iv: Interrupt, ipl: Ipl)
Set the interrupt priority level of a specific interrupt vector
Sourcepub fn ipl(&self, iv: Interrupt) -> Ipl
pub fn ipl(&self, iv: Interrupt) -> Ipl
Get the interrupt priority level of a specific interrupt vector
Auto Trait Implementations§
impl !Sync for Int
impl Freeze for Int
impl RefUnwindSafe for Int
impl Send for Int
impl Unpin for Int
impl UnsafeUnpin for Int
impl UnwindSafe for Int
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more