vtx: fix VTX_SETTINGS_POWER_COUNT and add dummy entries to saPowerNames
[inav.git] / src / main / target / FF_F35_LIGHTNING / target.h
blobb67dcd1d50e9156305d8a9c7086c96f4b0f0a952
1 /*
2 * This file is part of Cleanflight.
4 * Cleanflight 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 * Cleanflight 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 Cleanflight. If not, see <http://www.gnu.org/licenses/>.
18 #pragma once
19 #define TARGET_BOARD_IDENTIFIER "FF35"
21 #define USBD_PRODUCT_STRING "FURIOUS F35-LIGHTNING"
23 #define LED0 PC10 // Blue LED
24 // #define LED1 PC10 // Red LED
25 // #define LED2 PC10 // Green LED
27 #define BEEPER PA1
28 #define BEEPER_INVERTED
30 #define USE_DSHOT
32 #define MPU9250_CS_PIN PC0
33 #define MPU9250_SPI_BUS BUS_SPI3
35 #define USE_IMU_MPU9250
36 #define IMU_MPU9250_ALIGN CW180_DEG
38 #define USE_MAG
39 #define USE_MAG_MPU9250
40 #define MAG_I2C_BUS BUS_I2C1
42 #define USE_BARO
43 #define USE_BARO_BMP280
44 #define BMP280_CS_PIN PC5
45 #define BMP280_SPI_BUS BUS_SPI3
47 #define USE_MAX7456
48 #define MAX7456_CS_PIN PA4
49 #define MAX7456_SPI_BUS BUS_SPI1
51 #define USE_VCP
52 // #define VBUS_SENSING_PIN PA9
54 #define USE_UART_INVERTER
56 #define USE_UART1
57 #define UART1_RX_PIN PA10
58 #define UART1_TX_PIN PA9
60 #define USE_UART2
61 #define UART2_RX_PIN PA3
62 #define UART2_TX_PIN PA2
64 #define USE_UART3
65 #define UART3_RX_PIN PB11
66 #define UART3_TX_PIN PB10
67 #define INVERTER_PIN_UART3_RX PA8
69 #define USE_UART4
70 #define UART4_RX_PIN PC11
71 #define UART4_TX_PIN PA0
73 #define USE_UART5
74 #define UART5_RX_PIN PD2
75 #define UART5_TX_PIN PC12
77 #define USE_UART6
78 #define UART6_RX_PIN PC7
79 #define UART6_TX_PIN PC6
81 #define USE_SOFTSERIAL1
82 #define SOFTSERIAL_1_RX_PIN PA3 // shared with UART2 RX
83 #define SOFTSERIAL_1_TX_PIN PA2 // shared with UART2 TX
85 #define SERIAL_PORT_COUNT 8 //VCP, UART1, UART2, UART3, UART4, UART5, UART6
87 #define USE_SPI
88 #define USE_SPI_DEVICE_1
89 #define SPI1_NSS_PIN NONE
90 #define SPI1_SCK_PIN PA5
91 #define SPI1_MISO_PIN PA6
92 #define SPI1_MOSI_PIN PA7
94 #define USE_SPI_DEVICE_2
95 #define SPI2_NSS_PIN NONE
96 #define SPI2_SCK_PIN PB13
97 #define SPI2_MISO_PIN PB14
98 #define SPI2_MOSI_PIN PB15
100 #define USE_SPI_DEVICE_3
101 #define SPI3_NSS_PIN PA15
102 #define SPI3_SCK_PIN PB3
103 #define SPI3_MISO_PIN PB4
104 #define SPI3_MOSI_PIN PB5
106 #define USE_I2C
107 #define USE_I2C_DEVICE_1
108 #define I2C1_SCL PB6
109 #define I2C1_SDA PB7
111 #define BOARD_HAS_VOLTAGE_DIVIDER
112 #define USE_ADC
113 #define ADC_CHANNEL_1_PIN PC3
114 #define ADC_CHANNEL_2_PIN PC2
115 #define ADC_CHANNEL_3_PIN PC1
116 #define AIRSPEED_ADC_CHANNEL ADC_CHN_1
117 #define CURRENT_METER_ADC_CHANNEL ADC_CHN_2
118 #define VBAT_ADC_CHANNEL ADC_CHN_3
120 #define USE_PITOT_MS4525
121 #define PITOT_I2C_BUS BUS_I2C1
123 #define TEMPERATURE_I2C_BUS BUS_I2C1
125 #define DEFAULT_FEATURES (FEATURE_TX_PROF_SEL | FEATURE_VBAT | FEATURE_CURRENT_METER | FEATURE_OSD | FEATURE_GPS | FEATURE_TELEMETRY)
127 #define CURRENT_METER_SCALE 250
129 // Number of available PWM outputs
130 #define MAX_PWM_OUTPUT_PORTS 6
132 #define USE_SERIAL_4WAY_BLHELI_INTERFACE
134 #define TARGET_IO_PORTA 0xffff
135 #define TARGET_IO_PORTB 0xffff
136 #define TARGET_IO_PORTC 0xffff
137 #define TARGET_IO_PORTD (BIT(2))