|
Zephyr API 3.6.99
|
Loading...
Searching...
No Matches
Go to the documentation of this file.
6#ifndef ZEPHYR_INCLUDE_DT_BINDINGS_PINCTRL_GECKO_PINCTRL_H_
7#define ZEPHYR_INCLUDE_DT_BINDINGS_PINCTRL_GECKO_PINCTRL_H_
27#define GECKO_FUN_POS 24U
29#define GECKO_FUN_MSK 0xFFU
32#define GECKO_PIN_POS 0U
34#define GECKO_PIN_MSK 0xFFU
37#define GECKO_PORT_POS 8U
39#define GECKO_PORT_MSK 0xFFU
42#define GECKO_LOC_POS 0U
44#define GECKO_LOC_MSK 0xFFU
54#define GECKO_FUN_UART_TX 0U
56#define GECKO_FUN_UART_RX 1U
58#define GECKO_FUN_UART_RTS 2U
60#define GECKO_FUN_UART_CTS 3U
62#define GECKO_FUN_UART_RX_LOC 4U
64#define GECKO_FUN_UART_TX_LOC 5U
66#define GECKO_FUN_UART_RTS_LOC 6U
68#define GECKO_FUN_UART_CTS_LOC 7U
70#define GECKO_FUN_SPIM_MISO 8U
71#define GECKO_FUN_SPIM_MOSI 9U
72#define GECKO_FUN_SPIM_CS 10U
73#define GECKO_FUN_SPIM_SCK 11U
75#define GECKO_FUN_LEUART_RX_LOC 12U
76#define GECKO_FUN_LEUART_TX_LOC 13U
78#define GECKO_FUN_SPIS_MISO 14U
79#define GECKO_FUN_SPIS_MOSI 15U
80#define GECKO_FUN_SPIS_CS 16U
81#define GECKO_FUN_SPIS_SCK 17U
83#define GECKO_FUN_SPI_MISO_LOC 18U
84#define GECKO_FUN_SPI_MOSI_LOC 19U
85#define GECKO_FUN_SPI_CS_LOC 20U
86#define GECKO_FUN_SPI_SCK_LOC 21U
88#define GECKO_FUN_I2C_SDA 22U
89#define GECKO_FUN_I2C_SCL 23U
90#define GECKO_FUN_I2C_SDA_LOC 24U
91#define GECKO_FUN_I2C_SCL_LOC 25U
103#define GECKO_PSEL(fun, port, pin) \
104 (((GECKO_PORT_##port & GECKO_PORT_MSK) << GECKO_PORT_POS) | \
105 ((GECKO_PIN(##pin##) & GECKO_PIN_MSK) << GECKO_PIN_POS) | \
106 ((GECKO_FUN_##fun & GECKO_FUN_MSK) << GECKO_FUN_POS))
114#define GECKO_LOC(fun, loc) \
115 (((GECKO_LOCATION(##loc##) & GECKO_LOC_MSK) << GECKO_LOC_POS) | \
116 ((GECKO_FUN_##fun##_LOC & GECKO_FUN_MSK) << GECKO_FUN_POS))