board.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2015-2020 Freie Universität Berlin
3  *
4  * This file is subject to the terms and conditions of the GNU Lesser
5  * General Public License v2.1. See the file LICENSE in the top level
6  * directory for more details.
7  */
8 
20 #ifndef BOARD_H
21 #define BOARD_H
22 
23 #include "cpu.h"
24 #include "periph_conf.h"
25 #include "periph/adc.h"
26 #include "periph/gpio.h"
27 #include "periph/spi.h"
28 
29 #ifdef __cplusplus
30 extern "C" {
31 #endif
32 
39 #define XTIMER_DEV (TIMER_DEV(0))
40 #define XTIMER_HZ (250000UL)
41 #define XTIMER_WIDTH (16)
42 #define XTIMER_CHAN (0)
43 
52 #define BC_PIN GPIO_PIN(PA, 9)
53 
59 #define PB0_PIN GPIO_PIN(PC, 8)
60 #define PB1_PIN GPIO_PIN(PC, 9)
61 
67 #define LED0_PIN GPIO_PIN(PC, 10)
68 #define LED1_PIN GPIO_PIN(PC, 11)
69 
75 #define LED0_ON gpio_set(LED0_PIN)
76 #define LED0_OFF gpio_clear(LED0_PIN)
77 #define LED0_TOGGLE gpio_toggle(LED0_PIN)
78 #define LED1_ON gpio_set(LED1_PIN)
79 #define LED1_OFF gpio_clear(LED1_PIN)
80 #define LED1_TOGGLE gpio_toggle(LED1_PIN)
81 
89 #define CORETEMP_ADC ADC_LINE(0)
90 
98 #define DISP_SPI SPI_DEV(0)
99 #define DISP_COM_PIN GPIO_PIN(PE, 10)
100 #define DISP_CS_PIN GPIO_PIN(PE, 11)
101 #define DISP_SELECT_PIN GPIO_PIN(PA, 8)
102 #define DISP_POWER_PIN GPIO_PIN(PA, 10)
103 
108 void board_init(void);
109 
110 #ifdef __cplusplus
111 }
112 #endif
113 
114 #endif /* BOARD_H */
115 
spi.h
Low-level SPI peripheral driver interface definition.
adc.h
Low-level ADC peripheral driver interface definitions.
periph_conf.h
Configuration of CPU peripherals for the STK3200 starter kit.
gpio.h
Low-level GPIO peripheral driver interface definitions.
board_init
void board_init(void)
Board level initialization.