vtx: fix VTX_SETTINGS_POWER_COUNT and add dummy entries to saPowerNames
[inav.git] / src / main / target / BLUEJAYF4 / target.h
blobe62120bdc86f8b8ff2574460b29bbf7ee297930f
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 "BJF4"
21 #define USBD_PRODUCT_STRING "BlueJayF4"
23 #define USE_HARDWARE_REVISION_DETECTION
24 #define HW_PIN PB2
26 #define BOARD_HAS_VOLTAGE_DIVIDER
28 #define LED0 PB6
29 #define LED1 PB5
30 #define LED2 PB4
32 #define BEEPER PC1
33 #define BEEPER_OPT PB7
34 #define BEEPER_INVERTED
36 // MPU6500
37 #define MPU6500_CS_PIN PC4
38 #define MPU6500_SPI_BUS BUS_SPI1
39 #define USE_IMU_MPU6500
40 #define IMU_MPU6500_ALIGN CW0_DEG
42 #define USE_MAG
43 #define MAG_I2C_BUS BUS_I2C1
44 #define USE_MAG_ALL
46 #define TEMPERATURE_I2C_BUS BUS_I2C1
48 #define USE_BARO
49 #define BARO_I2C_BUS BUS_I2C1
50 #define USE_BARO_BMP085
51 #define USE_BARO_BMP280
52 #define USE_BARO_MS5611
54 #define USE_SDCARD
55 #define USE_SDCARD_SPI
56 #define SDCARD_DETECT_INVERTED
57 #define SDCARD_DETECT_PIN PD2
58 #define SDCARD_SPI_BUS BUS_SPI3
59 #define SDCARD_CS_PIN PA15
61 #define M25P16_CS_PIN PB7
62 #define M25P16_SPI_BUS BUS_SPI3
64 #define USE_FLASHFS
65 #define USE_FLASH_M25P16
67 #define USE_VCP
68 //#define VBUS_SENSING_PIN PA8
69 //#define VBUS_SENSING_ENABLED
71 #define USE_UART_INVERTER
73 #define USE_UART1
74 #define UART1_RX_PIN PA10
75 #define UART1_TX_PIN PA9
76 //#define INVERTER_PIN_UART1_TX PC9
78 #define USE_UART3
79 #define UART3_RX_PIN PB11
80 #define UART3_TX_PIN PB10
82 #define USE_UART6
83 #define UART6_RX_PIN PC7
84 #define UART6_TX_PIN PC6
85 #define INVERTER_PIN_UART6_RX PB15
87 #define USE_SOFTSERIAL1
88 #define SERIAL_PORT_COUNT 5
90 #define SOFTSERIAL_1_RX_PIN PB1
91 #define SOFTSERIAL_1_TX_PIN PB0
94 #define USE_ESCSERIAL
95 #define ESCSERIAL_TIMER_TX_HARDWARE 0
97 #define USE_SPI
99 #define USE_SPI_DEVICE_1
100 #define SPI1_NSS_PIN PC4
101 #define SPI1_SCK_PIN PA5
102 #define SPI1_MISO_PIN PA6
103 #define SPI1_MOSI_PIN PA7
105 #define USE_SPI_DEVICE_3
106 #define SPI3_NSS_PIN PB3
107 #define SPI3_SCK_PIN PC10
108 #define SPI3_MISO_PIN PC11
109 #define SPI3_MOSI_PIN PC12
111 #define USE_I2C
112 #define USE_I2C_DEVICE_1
113 #define USE_I2C_PULLUP
115 #define USE_ADC
116 #define ADC_CHANNEL_1_PIN PC3
117 #define VBAT_ADC_CHANNEL ADC_CHN_1
119 #define USE_LED_STRIP
120 #define WS2811_PIN PB1
122 #define ENABLE_BLACKBOX_LOGGING_ON_SDCARD_BY_DEFAULT
124 #define DEFAULT_RX_TYPE RX_TYPE_SERIAL
125 #define DEFAULT_FEATURES (FEATURE_TX_PROF_SEL | FEATURE_BLACKBOX)
127 #define USE_SERIAL_4WAY_BLHELI_INTERFACE
129 #define USE_SPEKTRUM_BIND
130 #define BIND_PIN PB11
132 // Number of available PWM outputs
133 #define MAX_PWM_OUTPUT_PORTS 6
135 #define TARGET_IO_PORTA 0xffff
136 #define TARGET_IO_PORTB 0xffff
137 #define TARGET_IO_PORTC 0xffff
138 #define TARGET_IO_PORTD (BIT(2))