Go to the documentation of this file.
23 #ifndef PERIPH_CPU_COMMON_H
24 #define PERIPH_CPU_COMMON_H
36 #define CPUID_LEN (4U)
52 #define GPIO_UNDEF (0xff)
57 #define GPIO_PIN(x, y) ((x << 4) | y)
69 #define HAVE_GPIO_FLANK_T
83 #define PERIPH_SPI_NEEDS_INIT_CS
84 #define PERIPH_SPI_NEEDS_TRANSFER_BYTE
85 #define PERIPH_SPI_NEEDS_TRANSFER_REG
86 #define PERIPH_SPI_NEEDS_TRANSFER_REGS
96 #define SPI_MODE_SEL(pol, pha) ((pol << 3) | (pha << 2))
105 #define HAVE_SPI_MODE_T
120 #define SPI_CLK_SEL(s2x, pr1, pr0) ((s2x << 2) | (pr1 << 1) | pr0)
128 #define HAVE_SPI_CLK_T
163 #define PERIPH_TIMER_PROVIDES_SET
168 #define EEPROM_CLEAR_BYTE (0xff)
174 #define NWDT_TIME_LOWER_LIMIT (1)
175 #define NWDT_TIME_UPPER_LIMIT (8192U)
181 #define WDT_HAS_STOP (1)
187 #if defined(SCCR0) && !defined(RTT_BACKEND_SC)
188 #define RTT_BACKEND_SC (1)
193 #ifndef RTT_MAX_VALUE
194 #define RTT_MAX_VALUE (0xFFFFFFFFUL)
197 #ifndef RTT_FREQUENCY
198 #define RTT_FREQUENCY (62500UL)
203 #ifndef RTT_MAX_VALUE
204 #define RTT_MAX_VALUE (0x00FFFFFF)
207 #ifndef RTT_FREQUENCY
208 #define RTT_FREQUENCY (1024U)
@ SPI_CLK_400KHZ
drive the SPI bus with 400KHz
@ SPI_MODE_3
CPOL=1, CPHA=1.
@ SPI_CLK_100KHZ
drive the SPI bus with 100KHz
@ TIMER_DIV1_8_32_64_128_256_1024
1/{1,8,32,64,128,256,1024}
@ TIMER_DIV1_8_64_128_1024
1/{1,8,64,128,1024}
mini_timer_t * dev
Timer used.
@ SPI_MODE_0
CPOL=0, CPHA=0.
timer_div_t div
Timer divider mask.
spi_mode_t
Available SPI modes, defining the configuration of clock polarity and clock phase.
@ GPIO_FALLING
emit interrupt on falling flank
@ GPIO_RISING
emit interrupt on rising flank
PWM device configuration.
@ SPI_CLK_10MHZ
drive the SPI bus with 10MHz
spi_clk_t
Available SPI clock speeds.
@ SPI_CLK_5MHZ
drive the SPI bus with 5MHz
@ GPIO_BOTH
emit interrupt on both flanks
unsigned int gpio_t
GPIO type identifier.
@ SPI_CLK_1MHZ
drive the SPI bus with 1MHz
@ SPI_MODE_1
CPOL=0, CPHA=1.
@ SPI_MODE_2
CPOL=1, CPHA=0.