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/>.
19 #define TARGET_BOARD_IDENTIFIER "YPF7"
20 #define USBD_PRODUCT_STRING "YUPIF7"
24 //define camera control
25 #define CAMERA_CONTROL_PIN PB7
28 #define BEEPER_INVERTED
29 #define BEEPER_PWM_FREQUENCY 3150
32 #define USE_IMU_ICM20689
33 #define IMU_ICM20689_ALIGN CW90_DEG
34 #define ICM20689_CS_PIN SPI1_NSS_PIN
35 #define ICM20689_SPI_BUS BUS_SPI1
38 #define MAG_I2C_BUS BUS_I2C1
40 #define TEMPERATURE_I2C_BUS BUS_I2C1
43 #define BARO_I2C_BUS BUS_I2C1
44 #define USE_BARO_MS5611
45 #define USE_BARO_BMP280
50 #define VBUS_SENSING_PIN PA8
51 #define VBUS_SENSING_ENABLED
54 #define UART1_RX_PIN PA10
55 #define UART1_TX_PIN PA9
58 #define UART3_RX_PIN PB11
59 #define UART3_TX_PIN PB10
62 #define UART5_RX_PIN PD2
63 #define UART5_TX_PIN PC12
66 #define UART6_RX_PIN PC7
67 #define UART6_TX_PIN PC6
69 #define USE_SOFTSERIAL1
70 #define SOFTSERIAL_1_RX_PIN PB0
71 #define SOFTSERIAL_1_TX_PIN PB1
73 #define SERIAL_PORT_COUNT 6 //VCP, USART1, USART3, USART5, USART6
76 #define ESCSERIAL_TIMER_TX_HARDWARE 0
78 #define UG2864_I2C_BUS BUS_I2C1
80 #define USE_OLED_UG2864
81 #define DASHBOARD_ARMED_BITMAP
84 #define PITOT_I2C_BUS BUS_I2C1
89 #define USE_SPI_DEVICE_1
90 #define SPI1_NSS_PIN PA4
91 #define SPI1_SCK_PIN PA5
92 #define SPI1_MISO_PIN PA6
93 #define SPI1_MOSI_PIN PA7
95 #define USE_SPI_DEVICE_3
96 #define SPI3_NSS_PIN PA15
97 #define SPI3_SCK_PIN PC10
98 #define SPI3_MISO_PIN PC11
99 #define SPI3_MOSI_PIN PB5
103 #define USE_I2C_DEVICE_1
106 #define I2C_DEVICE (I2CDEV_1)
110 #define MAX7456_SPI_BUS BUS_SPI1
111 #define MAX7456_CS_PIN PA14
114 #define M25P16_CS_PIN SPI3_NSS_PIN
115 #define M25P16_SPI_BUS BUS_SPI3
117 #define USE_FLASH_M25P16
118 #define ENABLE_BLACKBOX_LOGGING_ON_SPIFLASH_BY_DEFAULT
122 #define ADC_CHANNEL_1_PIN PC0
123 #define ADC_CHANNEL_2_PIN PC1
124 #define ADC_CHANNEL_3_PIN PC2
125 #define RSSI_ADC_CHANNEL ADC_CHN_1
126 #define VBAT_ADC_CHANNEL ADC_CHN_2
127 #define CURRENT_METER_ADC_CHANNEL ADC_CHN_3
128 #define CURRENT_METER_SCALE 235
130 // LED Strip can run off Pin 5 (PB1) of the motor outputs
131 #define USE_LED_STRIP
132 #define WS2811_PIN PB1
136 #define USE_ESC_SENSOR
138 // Default configuration
139 #define DEFAULT_RX_TYPE RX_TYPE_SERIAL
140 #define SERIALRX_PROVIDER SERIALRX_SBUS
141 #define SERIALRX_UART SERIAL_PORT_USART6
142 #define TELEMETRY_UART SERIAL_PORT_USART1
143 #define DEFAULT_FEATURES (FEATURE_TELEMETRY | FEATURE_OSD)
145 // Target IO and timers
146 #define USE_SERIAL_4WAY_BLHELI_INTERFACE
148 #define MAX_PWM_OUTPUT_PORTS 9
149 #define TARGET_MOTOR_COUNT 6
151 #define TARGET_IO_PORTA 0xffff
152 #define TARGET_IO_PORTB 0xffff
153 #define TARGET_IO_PORTC 0xffff
154 #define TARGET_IO_PORTD (BIT(2))