Solaris Software
Toggle main menu visibility
Loading...
Searching...
No Matches
macrosEsp32.h
Go to the documentation of this file.
1
/**
2
* @file macrosEsp32.h
3
* @brief ESP32 hardware pin definitions and SPI constants.
4
*
5
* Naming conventions used in this file:
6
* - Constants/macros: K_ESP32_*
7
*/
8
9
#ifndef SPP_MACROS_ESP32_H
10
#define SPP_MACROS_ESP32_H
11
12
#include "driver/spi_common.h"
13
14
/* ----------------------------------------------------------------
15
* SPI bus pin assignments
16
* ---------------------------------------------------------------- */
17
18
/** @brief MISO (CIPO) GPIO pin. */
19
#define K_ESP32_PIN_MISO (47)
20
21
/** @brief MOSI (COPI) GPIO pin. */
22
#define K_ESP32_PIN_MOSI (38)
23
24
/** @brief SPI clock GPIO pin. */
25
#define K_ESP32_PIN_CLK (48)
26
27
/** @brief SPI peripheral to use. */
28
#define K_ESP32_SPI_HOST SPI2_HOST
29
30
/* ----------------------------------------------------------------
31
* Chip-select pin assignments
32
* ---------------------------------------------------------------- */
33
34
/** @brief BMP390 barometer chip-select GPIO. */
35
#define K_ESP32_PIN_CS_BMP (18)
36
37
/** @brief ICM20948 IMU chip-select GPIO. */
38
#define K_ESP32_PIN_CS_ICM (21)
39
40
/** @brief SD card chip-select GPIO. */
41
#define K_ESP32_PIN_CS_SDC (9)
42
43
/* ----------------------------------------------------------------
44
* Device table constants
45
* ---------------------------------------------------------------- */
46
47
/** @brief Maximum number of SPI device slots. */
48
#define K_ESP32_MAX_SPI_DEVICES (4U)
49
50
/* ----------------------------------------------------------------
51
* Device index assignments
52
* ---------------------------------------------------------------- */
53
54
/** @brief SPI device index for the BMP390. */
55
#define K_ESP32_SPI_IDX_BMP (0U)
56
57
/** @brief SPI device index for the ICM20948. */
58
#define K_ESP32_SPI_IDX_ICM (1U)
59
60
/** @brief SPI device index for the SD card. */
61
#define K_ESP32_SPI_IDX_SDC (2U)
62
63
/* ----------------------------------------------------------------
64
* UART port assignments
65
* ---------------------------------------------------------------- */
66
#define K_ESP32_UART_PORT_ID UART_NUM_2
67
#define K_ESP32_UART_BAUD_RATE 9600
68
69
#define K_ESP32_UART_TX_PIN 5
70
#define K_ESP32_UART_RX_PIN 6
71
#define K_ESP32_UART_RTS_PIN -1
// Not used
72
#define K_ESP32_UART_CTS_PIN -1
// Not used
73
74
#define K_ESP32_UART_RX_BUFFER_SIZE 1024
75
#define K_ESP32_UART_TX_BUFFER_SIZE 1024
76
77
#define K_ESP32_UART_MAX_DELAY 0
78
79
#endif
/* SPP_MACROS_ESP32_H */
solaris-v2
spp
ports
hal
esp32
macrosEsp32.h
Generated by
1.18.0