Go to the documentation of this file.
12 #ifndef FSL_COMPONENT_ID
13 #define FSL_COMPONENT_ID "platform.drivers.igpio"
23 #if !(defined(FSL_SDK_DISABLE_DRIVER_CLOCK_CONTROL) && FSL_SDK_DISABLE_DRIVER_CLOCK_CONTROL)
73 #if !(defined(FSL_SDK_DISABLE_DRIVER_CLOCK_CONTROL) && FSL_SDK_DISABLE_DRIVER_CLOCK_CONTROL)
85 base->
IMR &= ~(1UL << pin);
90 base->
GDIR &= ~(1UL << pin);
95 base->
GDIR |= (1UL << pin);
116 base->
DR &= ~(1UL << pin);
120 base->
DR |= (1UL << pin);
134 volatile uint32_t *icr;
151 switch (pinInterruptMode)
154 *icr &= ~(3UL << (2UL * icrShift));
157 *icr = (*icr & (~(3UL << (2UL * icrShift)))) | (1UL << (2UL * icrShift));
160 *icr = (*icr & (~(3UL << (2UL * icrShift)))) | (2UL << (2UL * icrShift));
163 *icr |= (3UL << (2UL * icrShift));
GPIO Init structure definition.
static const clock_ip_name_t s_gpioClock[]
gpio_pin_direction_t direction
void GPIO_PinWrite(GPIO_Type *base, uint32_t pin, uint8_t output)
Sets the output level of the individual GPIO pin to logic 1 or 0.
void GPIO_PinSetInterruptConfig(GPIO_Type *base, uint32_t pin, gpio_interrupt_mode_t pinInterruptMode)
Sets the current pin interrupt mode.
gpio_interrupt_mode_t interruptMode
static uint32_t GPIO_GetInstance(GPIO_Type *base)
Gets the GPIO instance according to the GPIO base.
enum _gpio_interrupt_mode gpio_interrupt_mode_t
GPIO interrupt mode definition.
#define GPIO_CLOCKS
Clock ip name array for GPIO.
@ kGPIO_IntRisingOrFallingEdge
#define ARRAY_SIZE(x)
Computes the number of elements in an array.
void GPIO_PinInit(GPIO_Type *base, uint32_t pin, const gpio_pin_config_t *Config)
Initializes the GPIO peripheral according to the specified parameters in the initConfig.
static void CLOCK_EnableClock(clock_ip_name_t name)
Enable the clock for specific IP.
static void GPIO_SetPinInterruptConfig(GPIO_Type *base, uint32_t pin, gpio_interrupt_mode_t pinInterruptMode)
Sets the current pin interrupt mode.
static GPIO_Type *const s_gpioBases[]
enum _clock_ip_name clock_ip_name_t
CCM CCGR gate control for each module independently.