|
PebbleOS v4.47.0-1312-gf1984a001
|
GPIO tasks and events of the nRF54L SoCs. More...
Data Structures | |
| struct | pbl_gpio_nrf54l_gpiote_channel |
| Owner of a GPIOTE channel. More... | |
| struct | pbl_gpio_nrf54l_gpiote_state |
| GPIOTE state. More... | |
| struct | pbl_gpio_nrf54l_gpiote |
| nRF54L GPIOTE. More... | |
Macros | |
| #define | PBL_GPIO_NRF54L_GPIOTE_CHANNELS 8U |
| Most channels of a GPIOTE. | |
| #define | PBL_GPIO_NRF54L_GPIOTE_DEFINE(sym, _name, _base, _irq, _num_channels) |
| Define an nRF54L GPIOTE. | |
Functions | |
| int | pbl_gpio_nrf54l_gpiote_configure (const struct pbl_gpio_nrf54l_gpiote *gpiote, const struct pbl_intc *intc, uint32_t hwirq, uint32_t port, uint32_t pin, uint32_t type) |
| Bind a channel to a pin, for a line of an interrupt controller. | |
| int | pbl_gpio_nrf54l_gpiote_enable (const struct pbl_gpio_nrf54l_gpiote *gpiote, const struct pbl_intc *intc, uint32_t hwirq) |
| Raise the events of the channel of a line. | |
| int | pbl_gpio_nrf54l_gpiote_disable (const struct pbl_gpio_nrf54l_gpiote *gpiote, const struct pbl_intc *intc, uint32_t hwirq) |
| Stop the events of the channel of a line, leaving its input unsensed. | |
| void | pbl_gpio_nrf54l_gpiote_free (const struct pbl_gpio_nrf54l_gpiote *gpiote, const struct pbl_intc *intc, uint32_t hwirq) |
| Unbind the channel of a line, leaving it to others. | |
GPIO tasks and events of the nRF54L SoCs.
Its channels raise the interrupt lines of the controllers of the GPIO ports that refer to it.
| struct pbl_gpio_nrf54l_gpiote_channel |
Owner of a GPIOTE channel.
| Data Fields | ||
|---|---|---|
| uint8_t | hwirq | Line of the controller. |
| const struct pbl_intc * | intc | Controller of the line, nullptr when free. |
| struct pbl_gpio_nrf54l_gpiote_state |
GPIOTE state.
| Data Fields | ||
|---|---|---|
| struct pbl_gpio_nrf54l_gpiote_channel | channels[PBL_GPIO_NRF54L_GPIOTE_CHANNELS] | Owner of each channel. |
| struct pbl_gpio_nrf54l_gpiote |
nRF54L GPIOTE.
| Data Fields | ||
|---|---|---|
| uintptr_t | base | Registers. |
| struct pbl_device | dev | Device. |
| pbl_irq_t | irq | Interrupt. |
| uint8_t | num_channels | Number of channels. |
| struct pbl_gpio_nrf54l_gpiote_state * | state | State. |
| #define PBL_GPIO_NRF54L_GPIOTE_CHANNELS 8U |
Most channels of a GPIOTE.
| #define PBL_GPIO_NRF54L_GPIOTE_DEFINE | ( | sym, | |
| _name, | |||
| _base, | |||
| _irq, | |||
| _num_channels | |||
| ) |
Define an nRF54L GPIOTE.
| sym | Symbol. |
| _name | Name. |
| _base | Registers. |
| _irq | Interrupt. |
| _num_channels | Number of channels. |
| int pbl_gpio_nrf54l_gpiote_configure | ( | const struct pbl_gpio_nrf54l_gpiote * | gpiote, |
| const struct pbl_intc * | intc, | ||
| uint32_t | hwirq, | ||
| uint32_t | port, | ||
| uint32_t | pin, | ||
| uint32_t | type | ||
| ) |
Bind a channel to a pin, for a line of an interrupt controller.
The channel stays allocated to the line until it is freed.
| gpiote | GPIOTE. |
| intc | Controller of the line. |
| hwirq | Line. |
| port | Port number of the pin. |
| pin | Pin. |
| type | Edge, PBL_IRQ_TYPE_EDGE_*. |
-ENOTSUP for a level or -ENOMEM if all channels are in use. | int pbl_gpio_nrf54l_gpiote_disable | ( | const struct pbl_gpio_nrf54l_gpiote * | gpiote, |
| const struct pbl_intc * | intc, | ||
| uint32_t | hwirq | ||
| ) |
Stop the events of the channel of a line, leaving its input unsensed.
| gpiote | GPIOTE. |
| intc | Controller of the line. |
| hwirq | Line. |
-EINVAL if the line has no channel. | int pbl_gpio_nrf54l_gpiote_enable | ( | const struct pbl_gpio_nrf54l_gpiote * | gpiote, |
| const struct pbl_intc * | intc, | ||
| uint32_t | hwirq | ||
| ) |
Raise the events of the channel of a line.
| gpiote | GPIOTE. |
| intc | Controller of the line. |
| hwirq | Line. |
-EINVAL if the line has no channel. | void pbl_gpio_nrf54l_gpiote_free | ( | const struct pbl_gpio_nrf54l_gpiote * | gpiote, |
| const struct pbl_intc * | intc, | ||
| uint32_t | hwirq | ||
| ) |
Unbind the channel of a line, leaving it to others.
| gpiote | GPIOTE. |
| intc | Controller of the line. |
| hwirq | Line. |