Merge pull request #10558 from iNavFlight/MrD_Correct-comments-on-OSD-symbols
[inav.git] / src / main / target / GEPRCF405_BT_HD / target.h
blob185a3970a1139b14c0fbea3d034103c87fba9a3a
1 /*
2 * This file is part of INAV.
4 * INAV is free software: you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation, either version 3 of the License, or
7 * (at your option) any later version.
9 * INAV is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License
15 * along with INAV. If not, see <http://www.gnu.org/licenses/>.
18 #pragma once
20 #define TARGET_BOARD_IDENTIFIER "GEPR"
22 #define USBD_PRODUCT_STRING "GEPRCF405_BT_HD"
24 #define LED0 PC14
25 #define LED1 PC15
29 #define BEEPER PC13
30 #define BEEPER_INVERTED
32 // *************** Gyro & ACC **********************
34 #define USE_SPI
35 #define USE_SPI_DEVICE_3
37 #define SPI3_SCK_PIN PB3
38 #define SPI3_MISO_PIN PB4
39 #define SPI3_MOSI_PIN PB5
42 #define USE_IMU_MPU6000
43 #define IMU_MPU6000_ALIGN CW180_DEG
44 #define MPU6000_CS_PIN PA15
45 #define MPU6000_SPI_BUS BUS_SPI3
47 #define USE_IMU_BMI270
48 #define IMU_BMI270_ALIGN CW180_DEG
49 #define BMI270_CS_PIN PA15
50 #define BMI270_SPI_BUS BUS_SPI3
52 #define USE_IMU_ICM42605
53 #define IMU_ICM42605_ALIGN CW180_DEG
54 #define ICM42605_CS_PIN PA15
55 #define ICM42605_SPI_BUS BUS_SPI3
57 // *************** I2C/Baro/Mag *********************
58 #define USE_I2C
59 #define USE_I2C_DEVICE_1
60 #define I2C1_SCL PB8
61 #define I2C1_SDA PB9
63 #define USE_BARO
64 #define BARO_I2C_BUS BUS_I2C1
65 #define USE_BARO_BMP280
66 #define USE_BARO_DPS310
67 #define USE_BARO_MS5611
69 #define USE_MAG
70 #define MAG_I2C_BUS BUS_I2C1
71 #define USE_MAG_ALL
73 #define TEMPERATURE_I2C_BUS BUS_I2C1
75 #define PITOT_I2C_BUS BUS_I2C1
77 #define USE_RANGEFINDER
78 #define RANGEFINDER_I2C_BUS BUS_I2C1
79 #define BNO055_I2C_BUS BUS_I2C1
81 // *************** FLASH **************************
82 #define M25P16_CS_PIN PB12
83 #define M25P16_SPI_BUS BUS_SPI2
84 #define USE_FLASHFS
85 #define USE_FLASH_M25P16
86 #define ENABLE_BLACKBOX_LOGGING_ON_SPIFLASH_BY_DEFAULT
88 #define USE_SPI_DEVICE_2
89 #define SPI2_SCK_PIN PB13
90 #define SPI2_MISO_PIN PB14
91 #define SPI2_MOSI_PIN PB15
93 // *************** OSD *****************************
94 #define USE_SPI_DEVICE_1
95 #define SPI1_SCK_PIN PA5
96 #define SPI1_MISO_PIN PA6
97 #define SPI1_MOSI_PIN PA7
99 #define USE_MAX7456
100 #define MAX7456_SPI_BUS BUS_SPI1
101 #define MAX7456_CS_PIN PA4
103 // *************** UART *****************************
104 #define USE_VCP
106 #define USE_UART1
107 #define UART1_RX_PIN PB7
108 #define UART1_TX_PIN PB6
110 #define USE_UART2
111 #define UART2_RX_PIN PA3
112 #define UART2_TX_PIN PA2
114 #define USE_UART3
115 #define UART3_RX_PIN PC11
116 #define UART3_TX_PIN PC10
118 #define USE_UART4
119 #define UART4_RX_PIN PA1
120 #define UART4_TX_PIN PA0
122 #define USE_UART5
123 #define UART5_RX_PIN PD2
124 #define UART5_TX_PIN PC12
126 #define USE_UART6
127 #define UART6_RX_PIN PC7
128 #define UART6_TX_PIN PC6
130 #define SERIAL_PORT_COUNT 7
132 #define DEFAULT_RX_TYPE RX_TYPE_SERIAL
133 #define SERIALRX_PROVIDER SERIALRX_SBUS
134 #define SERIALRX_UART SERIAL_PORT_USART2
136 // ************PINIO to other
137 #define PINIO1_PIN PA13
139 // ************PINIO to disable BT*****************
140 #define USE_PINIO
141 #define USE_PINIOBOX
142 #define PINIO2_PIN PA14
143 #define PINIO2_FLAGS PINIO_FLAGS_INVERTED
145 // *************** ADC *****************************
146 #define USE_ADC
147 #define ADC_INSTANCE ADC1
148 #define ADC1_DMA_STREAM DMA2_Stream0
149 #define ADC_CHANNEL_1_PIN PC1
150 #define ADC_CHANNEL_2_PIN PC2
151 #define ADC_CHANNEL_3_PIN PC0
153 #define VBAT_ADC_CHANNEL ADC_CHN_1
154 #define RSSI_ADC_CHANNEL ADC_CHN_2
155 #define CURRENT_METER_ADC_CHANNEL ADC_CHN_3
158 #define DEFAULT_FEATURES (FEATURE_TX_PROF_SEL | FEATURE_CURRENT_METER | FEATURE_TELEMETRY | FEATURE_VBAT | FEATURE_OSD | FEATURE_BLACKBOX)
162 // *************** LEDSTRIP ************************
163 #define USE_LED_STRIP
164 #define WS2811_PIN PB1
168 #define USE_SERIAL_4WAY_BLHELI_INTERFACE
170 #define TARGET_IO_PORTA 0xffff
171 #define TARGET_IO_PORTB 0xffff
172 #define TARGET_IO_PORTC 0xffff
173 #define TARGET_IO_PORTD (BIT(2))
176 #define MAX_PWM_OUTPUT_PORTS 8
178 #define USE_DSHOT
179 #define USE_ESC_SENSOR