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/>.
21 #define TARGET_BOARD_IDENTIFIER "RBF7"
22 #define USBD_PRODUCT_STRING "RUSH_BLADE_F7"
25 #ifdef RUSH_BLADE_F7_HD
26 #define TARGET_BOARD_IDENTIFIER "RBF7HD"
27 #define USBD_PRODUCT_STRING "RUSH_BLADE_F7_HD"
32 #define BEEPER_INVERTED
34 // *************** SPI **********************
37 #define USE_SPI_DEVICE_1
38 #define SPI1_NSS_PIN PC4
39 #define SPI1_SCK_PIN PA5
40 #define SPI1_MISO_PIN PA6
41 #define SPI1_MOSI_PIN PA7
43 #define USE_SPI_DEVICE_2
44 #define SPI2_NSS_FLASH_PIN PB12
45 #define SPI2_NSS_OSD_PIN PB11
46 #define SPI2_SCK_PIN PB13
47 #define SPI2_MISO_PIN PB14
48 #define SPI2_MOSI_PIN PB15
51 // *************** Gyro & ACC **********************
52 #define USE_IMU_MPU6000
53 #define IMU_MPU6000_ALIGN CW270_DEG
54 #define MPU6000_SPI_BUS BUS_SPI1
55 #define MPU6000_CS_PIN SPI1_NSS_PIN
56 #define MPU6000_EXTI_PIN GYRO_INT_EXTI
58 #define USE_IMU_ICM42605
59 #define IMU_ICM42605_ALIGN CW270_DEG
60 #define ICM42605_SPI_BUS BUS_SPI1
61 #define ICM42605_CS_PIN SPI1_NSS_PIN
62 #define ICM42605_EXTI_PIN GYRO_INT_EXTI
64 // *************** I2C/Baro/Mag *********************
67 #define USE_I2C_DEVICE_1
72 #define BARO_I2C_BUS BUS_I2C1
73 #define USE_BARO_BMP280
74 #define USE_BARO_MS5611
75 #define USE_BARO_SPL06
76 #define USE_BARO_DPS310
79 #define MAG_I2C_BUS BUS_I2C1
80 #define USE_MAG_AK8975
81 #define USE_MAG_HMC5883
82 #define USE_MAG_QMC5883
83 #define USE_MAG_IST8310
84 #define USE_MAG_IST8308
85 #define USE_MAG_MAG3110
86 #define USE_MAG_LIS3MDL
89 // *************** Flash ****************************
91 #define USE_FLASH_M25P16
92 #define M25P16_SPI_BUS BUS_SPI2
93 #define M25P16_CS_PIN SPI2_NSS_FLASH_PIN
94 #define ENABLE_BLACKBOX_LOGGING_ON_SPIFLASH_BY_DEFAULT
97 // *************** Analog OSD ************************
100 #define MAX7456_SPI_BUS BUS_SPI2
101 #define MAX7456_CS_PIN SPI2_NSS_OSD_PIN
104 // *************** UART *****************************
108 #define UART1_TX_PIN PA9
109 #define UART1_RX_PIN PA10
112 #define UART2_TX_PIN PA2
113 #define UART2_RX_PIN PA3
116 #define UART3_TX_PIN PC10
117 #define UART3_RX_PIN PC11
120 #define UART4_TX_PIN PA0
121 #define UART4_RX_PIN PA1
124 #define UART5_TX_PIN PC12
125 #define UART5_RX_PIN PD2
127 #define SERIAL_PORT_COUNT 6
129 #define DEFAULT_RX_TYPE RX_TYPE_SERIAL
130 #define SERIALRX_PROVIDER SERIALRX_SBUS
132 // *************** ADC *****************************
134 #define ADC_INSTANCE ADC1
135 #define ADC1_DMA_STREAM DMA2_Stream4
137 #define ADC_CHANNEL_1_PIN PC0
138 #define ADC_CHANNEL_2_PIN PC1
140 #define VBAT_ADC_CHANNEL ADC_CHN_1
141 #define CURRENT_METER_ADC_CHANNEL ADC_CHN_2
143 #define DEFAULT_FEATURES (FEATURE_TX_PROF_SEL | FEATURE_CURRENT_METER | FEATURE_TELEMETRY | FEATURE_VBAT | FEATURE_OSD | FEATURE_LED_STRIP)
145 #define CURRENT_METER_SCALE 179
148 // ********** Optiical Flow and Lidar **************
149 #define USE_RANGEFINDER
150 #define USE_RANGEFINDER_MSP
152 #define USE_OPFLOW_MSP
154 // *************** LED *****************************
155 #define USE_LED_STRIP
156 #define WS2811_PIN PA15
158 #define USE_SERIAL_4WAY_BLHELI_INTERFACE
160 #define TARGET_IO_PORTA 0xffff
161 #define TARGET_IO_PORTB 0xffff
162 #define TARGET_IO_PORTC 0xffff
163 #define TARGET_IO_PORTD (BIT(2))
165 #define MAX_PWM_OUTPUT_PORTS 8
167 #define USE_ESC_SENSOR