board.h
Go to the documentation of this file.
1 /*
2  * SPDX-FileCopyrightText: 2018 OTA keys S.A.
3  * SPDX-License-Identifier: LGPL-2.1-only
4  */
5 
6 #pragma once
7 
20 #include <stdint.h>
21 
22 #include "cpu.h"
23 
24 #ifdef __cplusplus
25 extern "C" {
26 #endif
27 
32 #define LED0_PIN_NUM 3
33 #define LED0_PORT GPIO_PORT_E
34 #define LED0_PORT_NUM PORT_E
35 
36 #define LED1_PIN_NUM 4
37 #define LED1_PORT GPIO_PORT_E
38 #define LED1_PORT_NUM PORT_E
39 
40 #define LED2_PIN_NUM 1
41 #define LED2_PORT GPIO_PORT_E
42 #define LED2_PORT_NUM PORT_E
49 #define BTN0_PIN GPIO_PIN(PORT_C, 13)
50 #define BTN0_MODE GPIO_IN
58 #define SI70XX_PARAM_I2C_DEV I2C_DEV(1)
59 #define SI70XX_PARAM_ADDR (0x70)
60 #define SI70XX_SAUL_INFO { .name = "si7034" }
67 #define SDCARD_SPI_PARAM_SPI SPI_DEV(0)
68 #define SDCARD_SPI_PARAM_CS GPIO_PIN(PORT_E, 11)
69 #define SDCARD_SPI_PARAM_CLK GPIO_PIN(PORT_E, 2)
70 #define SDCARD_SPI_PARAM_MOSI GPIO_PIN(PORT_E, 6)
71 #define SDCARD_SPI_PARAM_MISO GPIO_PIN(PORT_E, 5)
78 #define UB_PWRON_PIN GPIO_PIN(PORT_E, 14)
79 #define UB_M_RST_PIN GPIO_PIN(PORT_B, 5)
80 #define M_GPIO2_PIN GPIO_PIN(PORT_D, 1)
81 #define M_GPIO3_PIN GPIO_PIN(PORT_B, 4)
82 #define GPS_RST_PIN GPIO_PIN(PORT_C, 10) /* Not connected */
85 #ifdef __cplusplus
86 }
87 #endif
88 
89 #include "stm32_leds.h"
90 
Common LED macros.