Zephyr API Documentation 3.7.99
A Scalable Open Source RTOS
|
Macros | |
#define | PINCTRL_DT_STATE_PINS_DEFINE(node_id, prop) |
Helper macro to define the pins of a pin control state from Devicetree. | |
#define | PINCTRL_DT_STATE_INIT(prop, state) |
Utility macro to initialize a pin control state. | |
Functions | |
int | pinctrl_update_states (struct pinctrl_dev_config *config, const struct pinctrl_state *states, uint8_t state_cnt) |
Update states with a new set. | |
#define PINCTRL_DT_STATE_INIT | ( | prop, | |
state ) |
#include <zephyr/drivers/pinctrl.h>
Utility macro to initialize a pin control state.
This macro should be used in conjunction with PINCTRL_DT_STATE_PINS_DEFINE when using dynamic pin control to define an alternative state configuration stored in Devicetree.
Example:
prop | Property name in Devicetree containing state configuration. |
state | State represented by prop (see PINCTRL_STATES). |
#define PINCTRL_DT_STATE_PINS_DEFINE | ( | node_id, | |
prop ) |
#include <zephyr/drivers/pinctrl.h>
Helper macro to define the pins of a pin control state from Devicetree.
The name of the defined state pins variable is the same used by prop
. This macro is expected to be used in conjunction with PINCTRL_DT_STATE_INIT.
node_id | Node identifier containing prop . |
prop | Property within node_id containing state configuration. |
int pinctrl_update_states | ( | struct pinctrl_dev_config * | config, |
const struct pinctrl_state * | states, | ||
uint8_t | state_cnt ) |
#include <zephyr/drivers/pinctrl.h>
Update states with a new set.
default
and sleep
are in the current list of states, it is expected that the new array of states also contains both.config | Pin control configuration. |
states | New states to be set. |
state_cnt | Number of new states to be set. |
-EINVAL | If the new configuration does not contain the same states as the current active configuration. |
-ENOSYS | If the functionality is not available. |
0 | On success. |