periph_conf.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2019 Gunar Schorcht
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 
30 #ifndef PERIPH_CONF_H
31 #define PERIPH_CONF_H
32 
33 #include <stdint.h>
34 
35 #ifdef __cplusplus
36  extern "C" {
37 #endif
38 
51 #ifndef ADC_GPIOS
52 #define ADC_GPIOS { GPIO36, GPIO39, GPIO37, GPIO38, \
53  GPIO0, GPIO2, GPIO12, GPIO13, GPIO4, GPIO15 }
54 #endif
55 
66 #ifndef DAC_GPIOS
67 #define DAC_GPIOS { }
68 #endif
69 
83 #ifndef I2C0_SPEED
84 #define I2C0_SPEED I2C_SPEED_FAST
85 #endif
86 #ifndef I2C0_SCL
87 #define I2C0_SCL GPIO15
88 #endif
89 #ifndef I2C0_SDA
90 #define I2C0_SDA GPIO4
91 #endif
92 
105 #ifndef PWM0_GPIOS
106 #define PWM0_GPIOS { GPIO25, GPIO0, GPIO2, GPIO17 }
107 #endif
108 
110 #ifndef PWM1_GPIOS
111 #define PWM1_GPIOS { GPIO22, GPIO23 }
112 #endif
113 
126 #ifndef SPI0_CTRL
127 #define SPI0_CTRL VSPI
128 #endif
129 #ifndef SPI0_SCK
130 #define SPI0_SCK GPIO5
131 #endif
132 #ifndef SPI0_MISO
133 #define SPI0_MISO GPIO19
134 #endif
135 #ifndef SPI0_MOSI
136 #define SPI0_MOSI GPIO27
137 #endif
138 #ifndef SPI0_CS0
139 #define SPI0_CS0 GPIO18
140 #endif
141 
154 #define UART0_TXD GPIO1
155 #define UART0_RXD GPIO3
157 #if FLASH_MODE_DOUT || FLASH_MODE_DIO || DOXYGEN
158 #ifndef UART1_TXD
159 #define UART1_TXD GPIO10
160 #endif
161 #ifndef UART1_RXD
162 #define UART1_RXD GPIO9
163 #endif
164 #else
165 #warning Configuration problem: Flash mode is qio or qout, \
166  GPIO9 and GPIO10 are not available for UART1 as configured
167 #endif
168 
171 #ifdef __cplusplus
172 } /* end extern "C" */
173 #endif
174 
175 /* include common board definitions as last step */
176 #include "periph_conf_common.h"
177 
178 #endif /* PERIPH_CONF_H */
179