Go to the source code of this file.
◆ ALTERNATE
| #define ALTERNATE 0x0 /* Alternate function output */ |
◆ ANALOG
| #define ANALOG 0x2 /* Analog */ |
◆ GPIO_IN
| #define GPIO_IN 0x1 /* Input */ |
◆ GPIO_OUT
| #define GPIO_OUT 0x3 /* Output */ |
◆ STM32_LINE_MASK
| #define STM32_LINE_MASK 0xFU |
◆ STM32_LINE_SHIFT
| #define STM32_LINE_SHIFT 2U |
◆ STM32_MODE_MASK
| #define STM32_MODE_MASK 0x3U |
◆ STM32_MODE_SHIFT
| #define STM32_MODE_SHIFT 0U |
Originally derived from Linux: include/dt-bindings/pinctrl/stm32-pinfunc.h.
For compatibility with Linux, the STM32_PINMUX macro and pinmux property have been retained. However, the resulting value is not saved as-is inside the image: during compilation, information is extracted from pinmux and saved in a custom format (c.f. soc/st/stm32/common/pinctrl_soc.h)
Macro to generate pinmux int using port, pin number and mode arguments This is adapted from Linux equivalent st,stm32f429-pinctrl binding
◆ STM32_PORT_MASK
| #define STM32_PORT_MASK 0xFU |
◆ STM32_PORT_SHIFT
| #define STM32_PORT_SHIFT 6U |
◆ STM32_REMAP_MASK
| #define STM32_REMAP_MASK 0x3FFU |
◆ STM32_REMAP_SHIFT
| #define STM32_REMAP_SHIFT 10U |
◆ STM32F1_PINMUX
| #define STM32F1_PINMUX |
( |
| port, |
|
|
| line, |
|
|
| mode, |
|
|
| remap ) |
Value:
#define STM32_PORT_SHIFT
Definition stm32-pinctrl.h:53
#define STM32_MODE_MASK
Definition stm32-pinctrl.h:50
#define STM32_MODE_SHIFT
Macro to generate pinmux int using port, pin number and mode arguments This is inspired from Linux eq...
Definition stm32-pinctrl.h:49
#define STM32_LINE_MASK
Definition stm32-pinctrl.h:52
#define STM32_LINE_SHIFT
Definition stm32-pinctrl.h:51
#define STM32_PORT_MASK
Definition stm32-pinctrl.h:54
#define STM32_REMAP_MASK
Definition stm32f1-pinctrl.h:34
#define STM32_REMAP_SHIFT
Definition stm32f1-pinctrl.h:33
Pin configuration configuration bit field.
Fields:
- mode [ 0 : 1 ]
- line [ 2 : 5 ]
- port [ 6 : 9 ]
- remap [ 10 : 19 ]
- Parameters
-
| port | Port ('A'..'K') |
| line | Pin (0..15) |
| mode | Pin mode (ANALOG, GPIO_IN, GPIO_OUT, ALTERNATE). |
| remap | Pin remapping configuration (NO_REMAP, REMAP_1, ...) |