Home
last modified time | relevance | path

Searched refs:pin_cfg (Results 1 – 8 of 8) sorted by relevance

/Zephyr-Core-3.4.0/drivers/pinctrl/
Dpinctrl_xmc4xxx.c20 XMC_GPIO_CONFIG_t pin_cfg = {0}; in pinctrl_configure_pin() local
31 pin_cfg.mode = XMC_GPIO_MODE_INPUT_PULL_DOWN; in pinctrl_configure_pin()
35 pin_cfg.mode = XMC_GPIO_MODE_INPUT_PULL_UP; in pinctrl_configure_pin()
39 pin_cfg.mode |= 0x4; in pinctrl_configure_pin()
43 pin_cfg.mode = XMC_GPIO_MODE_OUTPUT_OPEN_DRAIN; in pinctrl_configure_pin()
47 pin_cfg.mode = XMC_GPIO_MODE_OUTPUT_PUSH_PULL; in pinctrl_configure_pin()
51 pin_cfg.mode |= alt_fun << PORT0_IOCR0_PC0_Pos; in pinctrl_configure_pin()
55 pin_cfg.output_level = XMC_GPIO_OUTPUT_LEVEL_HIGH; in pinctrl_configure_pin()
60 pin_cfg.output_level = XMC_GPIO_OUTPUT_LEVEL_LOW; in pinctrl_configure_pin()
64 pin_cfg.output_strength = XMC4XXX_PINMUX_GET_DRIVE(pinmux); in pinctrl_configure_pin()
[all …]
Dpinctrl_esp32.c163 static int esp32_pin_configure(const uint32_t pin_mux, const uint32_t pin_cfg) in esp32_pin_configure() argument
181 switch (ESP32_PIN_BIAS(pin_cfg)) { in esp32_pin_configure()
192 switch (ESP32_PIN_DRV(pin_cfg)) { in esp32_pin_configure()
215 switch (ESP32_PIN_MODE_OUT(pin_cfg)) { in esp32_pin_configure()
270 uint32_t pin_mux, pin_cfg; in pinctrl_configure_pins() local
277 pin_cfg = pins[i].pincfg; in pinctrl_configure_pins()
279 ret = esp32_pin_configure(pin_mux, pin_cfg); in pinctrl_configure_pins()
/Zephyr-Core-3.4.0/drivers/input/
Dinput_gpio_keys.c33 const struct gpio_keys_pin_config *pin_cfg; member
57 const struct gpio_keys_pin_config *pin_cfg = &cfg->pin_cfg[key_index]; in gpio_keys_change_deferred() local
59 const int new_pressed = gpio_pin_get(pin_cfg->spec.port, pin_cfg->spec.pin); in gpio_keys_change_deferred()
68 pin_cfg->zephyr_code); in gpio_keys_change_deferred()
69 input_report_key(dev, pin_cfg->zephyr_code, new_pressed, true, K_FOREVER); in gpio_keys_change_deferred()
91 if (pins & BIT(cfg->pin_cfg[i].spec.pin)) { in gpio_keys_interrupt()
129 const struct gpio_dt_spec *gpio = &cfg->pin_cfg[i].spec; in gpio_keys_init()
145 ret = gpio_keys_interrupt_configure(&cfg->pin_cfg[i].spec, in gpio_keys_init()
147 cfg->pin_cfg[i].zephyr_code); in gpio_keys_init()
169 .pin_cfg = gpio_keys_pin_config_##i, \
/Zephyr-Core-3.4.0/tests/drivers/input/gpio_keys/src/
Dmain.c27 const struct gpio_keys_pin_config *pin_cfg; member
55 const struct gpio_keys_pin_config *pin_cfg = &config->pin_cfg[BUTTON_0_IDX]; in ZTEST() local
56 const struct gpio_dt_spec *spec = &pin_cfg->spec; in ZTEST()
70 zassert_equal(last_code, pin_cfg->zephyr_code); in ZTEST()
82 zassert_equal(last_code, pin_cfg->zephyr_code); in ZTEST()
/Zephyr-Core-3.4.0/drivers/gpio/
Dgpio_imx.c47 struct pinctrl_soc_pin pin_cfg; in imx_gpio_configure() local
85 memcpy(&pin_cfg.pinmux, &config->pin_muxes[pin], sizeof(pin_cfg)); in imx_gpio_configure()
87 pin_cfg.pin_ctrl_flags = reg; in imx_gpio_configure()
88 pinctrl_configure_pins(&pin_cfg, 1, PINCTRL_REG_NONE); in imx_gpio_configure()
Dgpio_mcux_igpio.c49 struct pinctrl_soc_pin pin_cfg; in mcux_igpio_configure() local
189 memcpy(&pin_cfg.pinmux, &config->pin_muxes[cfg_idx], sizeof(pin_cfg)); in mcux_igpio_configure()
191 pin_cfg.pin_ctrl_flags = reg; in mcux_igpio_configure()
192 pinctrl_configure_pins(&pin_cfg, 1, PINCTRL_REG_NONE); in mcux_igpio_configure()
Dgpio_stm32.c96 static int gpio_stm32_pincfg_to_flags(struct gpio_stm32_pin pin_cfg, in gpio_stm32_pincfg_to_flags() argument
101 if (pin_cfg.mode == LL_GPIO_MODE_OUTPUT) { in gpio_stm32_pincfg_to_flags()
103 if (pin_cfg.type == LL_GPIO_OUTPUT_OPENDRAIN) { in gpio_stm32_pincfg_to_flags()
106 } else if (pin_cfg.mode == LL_GPIO_MODE_INPUT) { in gpio_stm32_pincfg_to_flags()
109 } else if (pin_cfg.mode == LL_GPIO_MODE_FLOATING) { in gpio_stm32_pincfg_to_flags()
116 if (pin_cfg.pupd == LL_GPIO_PULL_UP) { in gpio_stm32_pincfg_to_flags()
118 } else if (pin_cfg.pupd == LL_GPIO_PULL_DOWN) { in gpio_stm32_pincfg_to_flags()
122 if (pin_cfg.out_state != 0) { in gpio_stm32_pincfg_to_flags()
/Zephyr-Core-3.4.0/drivers/can/
Dcan_nxp_s32_canxl.c86 const struct pinctrl_dev_config *pin_cfg; member
836 err = pinctrl_apply_state(config->pin_cfg, PINCTRL_STATE_DEFAULT);
1074 .pin_cfg = PINCTRL_DT_DEV_CONFIG_GET(CAN_NXP_S32_NODE(n)), \