Skip to content

Commit d68a833

Browse files
authored
Merge pull request #10310 from sensei-hacker/GEPRC_F722_AIO_uart3_target
GEPRC_F722_AIO add target with UART3 instead of i2c
2 parents 6a20ed4 + 8e32c18 commit d68a833

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
target_stm32f722xe(GEPRC_F722_AIO)
2+
target_stm32f722xe(GEPRC_F722_AIO_UART3)

src/main/target/GEPRC_F722_AIO/target.h

+12
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,11 @@
1717

1818
#pragma once
1919

20+
#ifdef GEPRC_F722_AIO_UART3
21+
#define TARGET_BOARD_IDENTIFIER "GEP3"
22+
#else
2023
#define TARGET_BOARD_IDENTIFIER "GEPR"
24+
#endif
2125

2226
#define USBD_PRODUCT_STRING "GEPRC_F722_AIO"
2327

@@ -52,6 +56,7 @@
5256
#define ICM42605_SPI_BUS BUS_SPI1
5357

5458
// *************** I2C/Baro/Mag *********************
59+
#ifndef GEPRC_F722_AIO_UART3
5560
#define USE_I2C
5661
#define USE_I2C_DEVICE_2
5762
#define I2C2_SCL PB10
@@ -74,6 +79,7 @@
7479
#define USE_RANGEFINDER
7580
#define RANGEFINDER_I2C_BUS BUS_I2C2
7681
#define BNO055_I2C_BUS BUS_I2C2
82+
#endif
7783

7884
// *************** FLASH **************************
7985
#define M25P16_CS_PIN PB9
@@ -108,9 +114,11 @@
108114
#define UART2_RX_PIN PA3
109115
#define UART2_TX_PIN PA2
110116

117+
#ifdef GEPRC_F722_AIO_UART3
111118
#define USE_UART3
112119
#define UART3_RX_PIN PB11
113120
#define UART3_TX_PIN PB10
121+
#endif
114122

115123
#define USE_UART4
116124
#define UART4_RX_PIN PC11
@@ -120,7 +128,11 @@
120128
#define UART5_RX_PIN PD2
121129
#define UART5_TX_PIN PC12
122130

131+
#ifdef GEPRC_F722_AIO_UART3
123132
#define SERIAL_PORT_COUNT 6
133+
#else
134+
#define SERIAL_PORT_COUNT 5
135+
#endif
124136

125137
#define DEFAULT_RX_TYPE RX_TYPE_SERIAL
126138
#define SERIALRX_PROVIDER SERIALRX_SBUS

0 commit comments

Comments
 (0)