Go to the documentation of this file.
41 #define GPIO_UNDEF (0xffffffff)
46 #define GPIO_PIN(x, y) (((uint32_t)PIOA + (x << 9)) | y)
52 #define PERIPH_SPI_NEEDS_INIT_CS
53 #define PERIPH_SPI_NEEDS_TRANSFER_BYTE
54 #define PERIPH_SPI_NEEDS_TRANSFER_REG
55 #define PERIPH_SPI_NEEDS_TRANSFER_REGS
61 #define CPUID_LEN (16U)
66 #define TIMER_MAX_VAL (0xffffffff)
76 #define TIMER_CHANNEL_NUMOF (1)
81 #define RTT_MAX_VALUE (0xffffffff)
91 #define GPIO_MODE(io, pu, od) (io | (pu << 1) | (od << 2))
100 #define ADC_NUMOF (16U)
113 #define DAC_NUMOF (2U)
120 #define HAVE_GPIO_MODE_T
135 #define HAVE_GPIO_FLANK_T
167 #define HAVE_SPI_MODE_T
180 #define HAVE_SPI_CLK_T
196 #define HAVE_ADC_RES_T
uint8_t id
corresponding ID of that module
@ SPI_CLK_400KHZ
drive the SPI bus with 400KHz
#define GPIO_MODE(io, pu, od)
Generate GPIO mode bitfields.
@ SPI_MODE_3
CPOL=1, CPHA=1.
gpio_mux_t mux
pin MUX setting
PWM channel configuration.
@ SPI_CLK_100KHZ
drive the SPI bus with 100KHz
@ ADC_RES_6BIT
ADC resolution: 6 bit.
@ GPIO_IN_PD
configure as input with pull-down resistor
@ GPIO_MUX_A
alternate function A
@ SPI_MODE_0
CPOL=0, CPHA=0.
@ GPIO_OD
configure as output in open-drain mode without pull resistor
@ ADC_RES_14BIT
ADC resolution: 14 bit.
adc_res_t
Possible ADC resolution settings.
gpio_mux_t
GPIO mux configuration.
@ GPIO_OUT
configure as output in push-pull mode
@ ADC_RES_16BIT
ADC resolution: 16 bit.
spi_mode_t
Available SPI modes, defining the configuration of clock polarity and clock phase.
@ ADC_RES_8BIT
ADC resolution: 8 bit.
@ GPIO_FALLING
emit interrupt on falling flank
@ GPIO_IN_PU
configure as input with pull-up resistor
@ GPIO_RISING
emit interrupt on rising flank
@ SPI_CLK_10MHZ
drive the SPI bus with 10MHz
uint32_t spi_clk_t
SPI clock type.
@ GPIO_IN
configure as input without pull resistor
Spi * dev
SPI module to use.
void gpio_init_mux(gpio_t pin, uint8_t over, uint8_t sel, uint8_t func)
Configure an alternate function for the given pin.
UART device configuration.
gpio_mux_t
Available MUX values for configuring a pin's alternate function.
@ SPI_CLK_5MHZ
drive the SPI bus with 5MHz
@ GPIO_OD_PU
configure as output in open-drain mode with pull resistor enabled
@ GPIO_BOTH
emit interrupt on both flanks
gpio_t clk
pin mapped to the CLK line
uint8_t id_ch0
ID of the timer's first channel.
@ GPIO_MUX_B
alternate function B
gpio_mode_t
Available pin modes.
@ ADC_RES_10BIT
ADC resolution: 10 bit.
@ ADC_RES_12BIT
ADC resolution: 12 bit.
uint8_t pmc_id
bit in the PMC register of the device
unsigned int gpio_t
GPIO type identifier.
uint8_t hwchan
the HW channel used for a logical channel
@ SPI_CLK_1MHZ
drive the SPI bus with 1MHz
Uart * dev
U(S)ART device used.
SPI configuration structure type.
@ SPI_MODE_1
CPOL=0, CPHA=1.
@ SPI_MODE_2
CPOL=1, CPHA=0.