The MCUXpresso SDK provides a peripheral driver for the Interrupt Multiplexer (INTMUX) module of MCUXpresso SDK devices.
Typical use case
Channel Configure
Refer to the driver examples codes located at <SDK_ROOT>/boards/<BOARD>/driver_examples/intmux
#define FSL_INTMUX_DRIVER_VERSION (MAKE_VERSION(2, 0, 1)) |
Enumerator |
---|
kINTMUX_ChannelLogicOR |
Logic OR all enabled interrupt inputs.
|
kINTMUX_ChannelLogicAND |
Logic AND all enabled interrupt inputs.
|
void INTMUX_Init |
( |
INTMUX_Type * |
base | ) |
|
This function enables the clock gate for the specified INTMUX. It then resets all channels, so that no interrupt sources are routed and the logic mode is set to default of kINTMUX_ChannelLogicOR. Finally, the NVIC vectors for all the INTMUX output channels are enabled.
- Parameters
-
base | INTMUX peripheral base address. |
void INTMUX_Deinit |
( |
INTMUX_Type * |
base | ) |
|
The clock gate for the specified INTMUX is disabled and the NVIC vectors for all channels are disabled.
- Parameters
-
base | INTMUX peripheral base address. |
static void INTMUX_ResetChannel |
( |
INTMUX_Type * |
base, |
|
|
uint32_t |
channel |
|
) |
| |
|
inlinestatic |
Sets all register values in the specified channel to their reset value. This function disables all interrupt sources for the channel.
- Parameters
-
base | INTMUX peripheral base address. |
channel | The INTMUX channel number. |
INTMUX channels can be configured to use one of the two logic modes that control how pending interrupt sources on the channel trigger the output interrupt.
- Parameters
-
base | INTMUX peripheral base address. |
channel | The INTMUX channel number. |
logic | The INTMUX channel logic mode. |
static void INTMUX_EnableInterrupt |
( |
INTMUX_Type * |
base, |
|
|
uint32_t |
channel, |
|
|
IRQn_Type |
irq |
|
) |
| |
|
inlinestatic |
- Parameters
-
base | INTMUX peripheral base address. |
channel | Index of the INTMUX channel on which the specified interrupt is enabled. |
irq | Interrupt to route to the specified INTMUX channel. The interrupt must be an INTMUX source. |
static void INTMUX_DisableInterrupt |
( |
INTMUX_Type * |
base, |
|
|
uint32_t |
channel, |
|
|
IRQn_Type |
irq |
|
) |
| |
|
inlinestatic |
- Parameters
-
base | INTMUX peripheral base address. |
channel | Index of the INTMUX channel on which the specified interrupt is disabled. |
irq | Interrupt number. The interrupt must be an INTMUX source. |
static uint32_t INTMUX_GetChannelPendingSources |
( |
INTMUX_Type * |
base, |
|
|
uint32_t |
channel |
|
) |
| |
|
inlinestatic |
- Parameters
-
base | INTMUX peripheral base address. |
channel | The INTMUX channel number. |
- Returns
- The mask of pending interrupt bits. Bit[n] set means INTMUX source n is pending.