![]() |
MAX32665 SDK Documentation
0.2
Software Development Kit Overview and API Documentation
|
Modules | |
Port and Pin Definitions | |
GPIO_Registers | |
Registers, Bit Masks and Bit Positions for the GPIO Peripheral Module. | |
Data Structures | |
struct | gpio_cfg_t |
Structure type for configuring a GPIO port. More... | |
Typedefs | |
typedef void(* | gpio_callback_fn) (void *cbdata) |
Type alias for a GPIO callback function with prototype: More... | |
Enumerations | |
enum | gpio_func_t { GPIO_FUNC_IN, GPIO_FUNC_OUT, GPIO_FUNC_ALT1, GPIO_FUNC_ALT2, GPIO_FUNC_ALT3, GPIO_FUNC_ALT4 } |
Enumeration type for the GPIO Function Type. More... | |
enum | gpio_pad_t { GPIO_PAD_NONE, GPIO_PAD_PULL_UP, GPIO_PAD_PULL_DOWN } |
Enumeration type for the type of GPIO pad on a given pin. More... | |
enum | gpio_int_mode_t { GPIO_INT_LEVEL = 0, GPIO_INT_EDGE = 1 } |
Enumeration type for the interrupt modes. More... | |
enum | gpio_int_pol_t { GPIO_INT_FALLING = 0, GPIO_INT_HIGH = GPIO_INT_FALLING, GPIO_INT_RISING, GPIO_INT_LOW = GPIO_INT_RISING, GPIO_INT_BOTH } |
Enumeration type for the interrupt polarity. More... | |
Functions | |
int | GPIO_Init (void) |
Initialize GPIO. More... | |
int | GPIO_Config (const gpio_cfg_t *cfg) |
Configure GPIO pin(s). More... | |
uint32_t | GPIO_InGet (const gpio_cfg_t *cfg) |
Gets the pin(s) input state. More... | |
void | GPIO_OutSet (const gpio_cfg_t *cfg) |
Sets the pin(s) to a high level output. More... | |
void | GPIO_OutClr (const gpio_cfg_t *cfg) |
Clears the pin(s) to a low level output. More... | |
uint32_t | GPIO_OutGet (const gpio_cfg_t *cfg) |
Gets the pin(s) output state. More... | |
void | GPIO_OutPut (const gpio_cfg_t *cfg, uint32_t val) |
Write the pin(s) to a desired output level. More... | |
void | GPIO_OutToggle (const gpio_cfg_t *cfg) |
Toggles the the pin(s) output level. More... | |
int | GPIO_IntConfig (const gpio_cfg_t *cfg, gpio_int_mode_t mode, gpio_int_pol_t pol) |
Configure GPIO interrupt(s) More... | |
void | GPIO_IntEnable (const gpio_cfg_t *cfg) |
Enables the specified GPIO interrupt. More... | |
void | GPIO_IntDisable (const gpio_cfg_t *cfg) |
Disables the specified GPIO interrupt. More... | |
uint32_t | GPIO_IntStatus (const gpio_cfg_t *cfg) |
Gets the interrupt(s) status on a GPIO pin. More... | |
void | GPIO_IntClr (const gpio_cfg_t *cfg) |
Clears the interrupt(s) status on a GPIO pin. More... | |
void | GPIO_RegisterCallback (const gpio_cfg_t *cfg, gpio_callback_fn callback, void *cbdata) |
Registers a callback for the interrupt on a given port and pin. More... | |
void | GPIO_Handler (unsigned int port) |
GPIO IRQ Handler. More... | |
typedef void(* gpio_callback_fn) (void *cbdata) |
cbdata | A void pointer to the data type as registered when GPIO_RegisterCallback() was called. |
enum gpio_func_t |
enum gpio_pad_t |
enum gpio_int_mode_t |
enum gpio_int_pol_t |
int GPIO_Init | ( | void | ) |
int GPIO_Config | ( | const gpio_cfg_t * | cfg | ) |
cfg | Pointer to configuration structure describing the pin. |
uint32_t GPIO_InGet | ( | const gpio_cfg_t * | cfg | ) |
cfg | Pointer to configuration structure describing the pin. |
void GPIO_OutSet | ( | const gpio_cfg_t * | cfg | ) |
cfg | Pointer to configuration structure describing the pin |
void GPIO_OutClr | ( | const gpio_cfg_t * | cfg | ) |
cfg | Pointer to configuration structure describing the pin |
uint32_t GPIO_OutGet | ( | const gpio_cfg_t * | cfg | ) |
cfg | Pointer to configuration structure describing the pin |
void GPIO_OutPut | ( | const gpio_cfg_t * | cfg, |
uint32_t | val | ||
) |
cfg | Pointer to configuration structure describing the pin. |
val | Desired output level of the pin(s). This will be masked with the configuration mask |
void GPIO_OutToggle | ( | const gpio_cfg_t * | cfg | ) |
cfg | Pointer to configuration structure describing the pin |
int GPIO_IntConfig | ( | const gpio_cfg_t * | cfg, |
gpio_int_mode_t | mode, | ||
gpio_int_pol_t | pol | ||
) |
cfg | Pointer to configuration structure describing the pin |
mode | Requested interrupt mode |
pol | Requested interrupt polarity |
void GPIO_IntEnable | ( | const gpio_cfg_t * | cfg | ) |
cfg | Pointer to configuration structure describing the pin |
void GPIO_IntDisable | ( | const gpio_cfg_t * | cfg | ) |
cfg | Pointer to configuration structure describing the pin |
uint32_t GPIO_IntStatus | ( | const gpio_cfg_t * | cfg | ) |
cfg | Pointer to configuration structure describing the pin for which the status is being requested |
void GPIO_IntClr | ( | const gpio_cfg_t * | cfg | ) |
cfg | Pointer to configuration structure describing the pin to clear the interrupt state of |
void GPIO_RegisterCallback | ( | const gpio_cfg_t * | cfg, |
gpio_callback_fn | callback, | ||
void * | cbdata | ||
) |
cfg | Pointer to configuration structure describing the pin |
callback | A pointer to a function of type gpio_callback_fn |
cbdata | The parameter to be passed to the callback function, gpio_callback_fn, when an interrupt occurs. |
void GPIO_Handler | ( | unsigned int | port | ) |
port | number of the port that generated the interrupt service routine |