mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-25 17:25:20 +03:00
Move board specific to config.c
This commit is contained in:
parent
e68df0415e
commit
d463d75269
2 changed files with 43 additions and 2 deletions
42
src/main/target/KAKUTEF7/config.c
Normal file
42
src/main/target/KAKUTEF7/config.c
Normal file
|
@ -0,0 +1,42 @@
|
||||||
|
/*
|
||||||
|
* This file is part of Cleanflight and Betaflight.
|
||||||
|
*
|
||||||
|
* Cleanflight and Betaflight are free software. You can redistribute
|
||||||
|
* this software and/or modify this software under the terms of the
|
||||||
|
* GNU General Public License as published by the Free Software
|
||||||
|
* Foundation, either version 3 of the License, or (at your option)
|
||||||
|
* any later version.
|
||||||
|
*
|
||||||
|
* Cleanflight and Betaflight are distributed in the hope that they
|
||||||
|
* will be useful, but WITHOUT ANY WARRANTY; without even the implied
|
||||||
|
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
* See the GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with this software.
|
||||||
|
*
|
||||||
|
* If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include <stdbool.h>
|
||||||
|
#include <stdint.h>
|
||||||
|
|
||||||
|
#include "platform.h"
|
||||||
|
|
||||||
|
#ifdef USE_TARGET_CONFIG
|
||||||
|
|
||||||
|
#include "config_helper.h"
|
||||||
|
|
||||||
|
#include "io/serial.h"
|
||||||
|
|
||||||
|
#define ESC_SENSOR_UART SERIAL_PORT_USART7
|
||||||
|
|
||||||
|
static targetSerialPortFunction_t targetSerialPortFunction[] = {
|
||||||
|
{ ESC_SENSOR_UART, FUNCTION_ESC_SENSOR },
|
||||||
|
};
|
||||||
|
|
||||||
|
void targetConfiguration(void)
|
||||||
|
{
|
||||||
|
targetSerialPortFunctionConfig(targetSerialPortFunction, ARRAYLEN(targetSerialPortFunction));
|
||||||
|
}
|
||||||
|
#endif
|
|
@ -20,7 +20,7 @@
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
//#define USE_TARGET_CONFIG
|
#define USE_TARGET_CONFIG
|
||||||
|
|
||||||
#ifdef KAKUTEF7V2
|
#ifdef KAKUTEF7V2
|
||||||
#define TARGET_BOARD_IDENTIFIER "KT76"
|
#define TARGET_BOARD_IDENTIFIER "KT76"
|
||||||
|
@ -168,7 +168,6 @@
|
||||||
#define DEFAULT_RX_FEATURE FEATURE_RX_SERIAL
|
#define DEFAULT_RX_FEATURE FEATURE_RX_SERIAL
|
||||||
#define SERIALRX_UART SERIAL_PORT_USART6
|
#define SERIALRX_UART SERIAL_PORT_USART6
|
||||||
#define SERIALRX_PROVIDER SERIALRX_SBUS
|
#define SERIALRX_PROVIDER SERIALRX_SBUS
|
||||||
#define ESC_SENSOR_UART SERIAL_PORT_USART7
|
|
||||||
|
|
||||||
#define USE_SERIAL_4WAY_BLHELI_INTERFACE
|
#define USE_SERIAL_4WAY_BLHELI_INTERFACE
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue