add SPL06 in Matek targets
[inav/snaewe.git] / src / main / target / KISSFC / target.h
blob230be7f66ddc1ef918089d8e0dca8ef7561a57ba
1 /*
2 * This file is part of Cleanflight and Betaflight.
4 * Cleanflight and Betaflight are free software. You can redistribute
5 * this software and/or modify this software under the terms of the
6 * GNU General Public License as published by the Free Software
7 * Foundation, either version 3 of the License, or (at your option)
8 * any later version.
10 * Cleanflight and Betaflight are distributed in the hope that they
11 * will be useful, but WITHOUT ANY WARRANTY; without even the implied
12 * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
13 * See the GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this software.
18 * If not, see <http://www.gnu.org/licenses/>.
21 #pragma once
23 #define SBUS_PORT_OPTIONS (SERIAL_STOPBITS_2 | SERIAL_PARITY_EVEN | SERIAL_INVERTED | SERIAL_BIDIR)
25 #define TARGET_BOARD_IDENTIFIER "KISSFC"
27 #define LED0 PB1
29 #define BEEPER PB13
30 #define BEEPER_INVERTED
32 #define USE_IMU_MPU6050
33 #define IMU_MPU6050_ALIGN CW180_DEG
34 #define MPU6050_I2C_BUS BUS_I2C1
36 #define USE_EXTI
37 #define MPU_INT_EXTI PB2
38 #define USE_MPU_DATA_READY_SIGNAL
39 #define ENSURE_MPU_DATA_READY_IS_LOW
41 #define USE_VCP
42 #define USE_UART1
43 #define USE_UART2
44 #define USE_UART3
45 //#define USE_SOFTSERIAL1
46 //#define USE_SOFTSERIAL2
48 #define SERIAL_PORT_COUNT 4
50 #define UART1_TX_PIN PA9
51 #define UART1_RX_PIN PA10
53 #define UART2_TX_PIN PB3
54 #define UART2_RX_PIN PB4
56 #define UART3_TX_PIN PB10 // PB10 (AF7)
57 #define UART3_RX_PIN PB11 // PB11 (AF7)
59 //#define SOFTSERIAL1_TX_PIN PA13 // AUX1
60 //#define SOFTSERIAL2_TX_PIN PA15 // ROLL
62 #define USE_I2C
63 #define USE_I2C_DEVICE_1
64 #define I2C1_SCL PB6
65 #define I2C1_SDA PB7
67 #define USE_ADC
68 #define VBAT_SCALE_DEFAULT 160
69 #define ADC_INSTANCE ADC1
70 #define VBAT_ADC_PIN PA0
71 #define CURRENT_METER_ADC_PIN PA2
73 #define DEFAULT_RX_FEATURE FEATURE_RX_SERIAL
74 #define SERIALRX_PROVIDER SERIALRX_SBUS
75 #define SERIALRX_UART SERIAL_PORT_USART2
77 #define MAX_PWM_OUTPUT_PORTS 12
79 #define TARGET_IO_PORTA 0xffff
80 #define TARGET_IO_PORTB 0xffff
81 #define TARGET_IO_PORTC 0xffff
82 #define TARGET_IO_PORTD 0xffff
83 #define TARGET_IO_PORTF (BIT(4))