GetIntFlag

From chipKIT
Jump to: navigation, search

Synopsis

uint32_t getIntFlag(int irq)

Description

Return the state of the interrupt request flag for the specified interrupt. The return value will be 0 if the flag is not set, and non-zero if the flag is set.

Return Value

The current interrupt flag state - 0 for not set, 1 for set.

Conforming To

getIntFlag() does not conform to any external API, it is unique to the chipKIT system.

Examples

Test an interrupt flag:

if (getIntFlag(_TIMER_3_IRQ)) {
    // Do something
    clearIntFlag(_TIMER_3_IRQ);
}

See Also

attachInterrupt(), detachInterrupt(), clearIntEnable(), clearIntFlag(), clearIntVector(), disableInterrupts(), enableInterrupts(), getIntPriority(), getIntVector(), restoreIntEnable(), restoreInterrupts(), setIntEnable(), setIntPriority(), setIntVector()