From e983ebf702beff65e3a271fcaa3cc4d99098f9c7 Mon Sep 17 00:00:00 2001 From: mikeller Date: Sat, 19 Jan 2019 16:09:35 +1300 Subject: [PATCH] Migrate the remaining F3 targets to feature cut levels. --- src/main/target/AIRHEROF3/target.h | 2 -- src/main/target/BETAFLIGHTF3/target.h | 31 -------------------- src/main/target/BETAFLIGHTF3/target.mk | 7 +++-- src/main/target/COLIBRI_RACE/target.h | 2 -- src/main/target/COLIBRI_RACE/target.mk | 3 ++ src/main/target/CRAZYBEEF3FR/target.h | 32 ++++----------------- src/main/target/CRAZYBEEF3FR/target.mk | 2 ++ src/main/target/FRSKYF3/target.h | 24 ---------------- src/main/target/FRSKYF3/target.mk | 3 ++ src/main/target/FURYF3/target.h | 30 -------------------- src/main/target/FURYF3/target.mk | 7 ++++- src/main/target/IMPULSERCF3/target.h | 20 ------------- src/main/target/IMPULSERCF3/target.mk | 3 ++ src/main/target/IRCFUSIONF3/target.h | 2 -- src/main/target/IRCFUSIONF3/target.mk | 4 ++- src/main/target/KROOZX/target.h | 3 +- src/main/target/KROOZX/target.mk | 4 +++ src/main/target/LUX_RACE/target.h | 30 -------------------- src/main/target/LUX_RACE/target.mk | 7 +++++ src/main/target/OMNIBUS/target.h | 31 -------------------- src/main/target/OMNIBUS/target.mk | 3 ++ src/main/target/RACEBASE/target.h | 24 ---------------- src/main/target/RACEBASE/target.mk | 1 + src/main/target/RCEXPLORERF3/target.h | 13 --------- src/main/target/RCEXPLORERF3/target.mk | 3 ++ src/main/target/RG_SSD_F3/target.h | 5 ---- src/main/target/RG_SSD_F3/target.mk | 3 ++ src/main/target/SIRINFPV/target.h | 25 ---------------- src/main/target/SIRINFPV/target.mk | 3 ++ src/main/target/SPRACINGF3/target.h | 33 ---------------------- src/main/target/SPRACINGF3/target.mk | 9 ++++++ src/main/target/SPRACINGF3MINI/target.h | 27 ------------------ src/main/target/SPRACINGF3MINI/target.mk | 3 ++ src/main/target/STM32F3DISCOVERY/target.h | 24 ---------------- src/main/target/STM32F3DISCOVERY/target.mk | 3 ++ 35 files changed, 69 insertions(+), 357 deletions(-) diff --git a/src/main/target/AIRHEROF3/target.h b/src/main/target/AIRHEROF3/target.h index 22eb12390..48ea12af3 100644 --- a/src/main/target/AIRHEROF3/target.h +++ b/src/main/target/AIRHEROF3/target.h @@ -22,8 +22,6 @@ #define TARGET_BOARD_IDENTIFIER "AIR3" -#define CONFIG_PREFER_ACC_ON - #define LED0_PIN PB3 #define LED1_PIN PB4 diff --git a/src/main/target/BETAFLIGHTF3/target.h b/src/main/target/BETAFLIGHTF3/target.h index d871c6e47..c6ed95dfc 100644 --- a/src/main/target/BETAFLIGHTF3/target.h +++ b/src/main/target/BETAFLIGHTF3/target.h @@ -24,37 +24,6 @@ #define TARGET_BOARD_IDENTIFIER "BFF3" -// Removed to make the firmware fit into flash (in descending order of priority): -//#undef USE_GYRO_OVERFLOW_CHECK -#undef USE_GYRO_LPF2 - -//#undef USE_MSP_DISPLAYPORT -//#undef USE_MSP_OVER_TELEMETRY - -//#undef USE_DYN_LPF -//#undef USE_D_CUT - -#undef USE_ITERM_RELAX -#undef USE_RC_SMOOTHING_FILTER - -#undef USE_HUFFMAN -#undef USE_PINIO -#undef USE_PINIOBOX - -#undef USE_TELEMETRY_HOTT -#undef USE_TELEMETRY_MAVLINK -#undef USE_TELEMETRY_LTM -#undef USE_SERIALRX_XBUS -#undef USE_SERIALRX_SUMH -#undef USE_PWM - -#undef USE_BOARD_INFO -#undef USE_EXTENDED_CMS_MENUS -#undef USE_RTC_TIME -#undef USE_RX_MSP -#undef USE_ESC_SENSOR_INFO - - #define USE_BEEPER #define BEEPER_PIN PC15 #define BEEPER_INVERTED diff --git a/src/main/target/BETAFLIGHTF3/target.mk b/src/main/target/BETAFLIGHTF3/target.mk index d470b1b5e..ea762c2e8 100644 --- a/src/main/target/BETAFLIGHTF3/target.mk +++ b/src/main/target/BETAFLIGHTF3/target.mk @@ -1,7 +1,8 @@ - F3_TARGETS += $(TARGET) + FEATURES = VCP SDCARD_SPI -TARGET_FLAGS = -DSPRACINGF3 + +FEATURE_CUT_LEVEL = 7 TARGET_SRC = \ drivers/accgyro/accgyro_mpu.c \ @@ -11,4 +12,4 @@ TARGET_SRC = \ drivers/display_ug2864hsweg01.h \ drivers/flash_m25p16.c \ drivers/max7456.c \ - io/osd.c \ No newline at end of file + io/osd.c diff --git a/src/main/target/COLIBRI_RACE/target.h b/src/main/target/COLIBRI_RACE/target.h index 0fe1c1459..3e7ba5fbb 100644 --- a/src/main/target/COLIBRI_RACE/target.h +++ b/src/main/target/COLIBRI_RACE/target.h @@ -20,9 +20,7 @@ #pragma once -// Removed to make the firmware fit into flash (in descending order of priority): #undef USE_GYRO_OVERFLOW_CHECK // target does not use affected gyros -//#undef USE_RTC_TIME #define TARGET_BOARD_IDENTIFIER "CLBR" diff --git a/src/main/target/COLIBRI_RACE/target.mk b/src/main/target/COLIBRI_RACE/target.mk index d9346ed6a..477cdaa71 100644 --- a/src/main/target/COLIBRI_RACE/target.mk +++ b/src/main/target/COLIBRI_RACE/target.mk @@ -1,6 +1,9 @@ F3_TARGETS += $(TARGET) + FEATURES = VCP +FEATURE_CUT_LEVEL = 0 + TARGET_SRC = \ i2c_bst.c \ bus_bst_stm32f30x.c \ diff --git a/src/main/target/CRAZYBEEF3FR/target.h b/src/main/target/CRAZYBEEF3FR/target.h index bfbb4ba78..bf30f3323 100644 --- a/src/main/target/CRAZYBEEF3FR/target.h +++ b/src/main/target/CRAZYBEEF3FR/target.h @@ -31,23 +31,14 @@ #define USBD_PRODUCT_STRING "CrazyBee F3 FR" #endif -// Removed to make the firmware fit into flash (in descending order of priority): -//#undef USE_GYRO_OVERFLOW_CHECK -//#undef USE_GYRO_LPF2 - -//#undef USE_ITERM_RELAX -//#undef USE_RC_SMOOTHING_FILTER - -//#undef USE_MSP_DISPLAYPORT -//#undef USE_MSP_OVER_TELEMETRY - -//#undef USE_HUFFMAN -//#undef USE_PINIO -//#undef USE_PINIOBOX - #undef USE_SERIALRX_CRSF #undef USE_SERIALRX_SUMD +#undef USE_SERIALRX_SUMH +#undef USE_SERIALRX_XBUS #undef USE_TELEMETRY_CRSF +#undef USE_TELEMETRY_MAVLINK +#undef USE_PWM + #if defined(CRAZYBEEF3FS) #undef USE_SERIALRX_SBUS @@ -68,19 +59,6 @@ #undef USE_TELEMETRY_SRXL #endif -#undef USE_TELEMETRY_HOTT -#undef USE_TELEMETRY_MAVLINK -#undef USE_TELEMETRY_LTM -#undef USE_SERIALRX_XBUS -#undef USE_SERIALRX_SUMH -#undef USE_PWM - -//#undef USE_BOARD_INFO -//#undef USE_EXTENDED_CMS_MENUS -//#undef USE_RTC_TIME -#undef USE_RX_MSP -//#undef USE_ESC_SENSOR_INFO - #define ENABLE_DSHOT_DMAR true #define LED0_PIN PB3 diff --git a/src/main/target/CRAZYBEEF3FR/target.mk b/src/main/target/CRAZYBEEF3FR/target.mk index 087feab25..fba7bc99d 100644 --- a/src/main/target/CRAZYBEEF3FR/target.mk +++ b/src/main/target/CRAZYBEEF3FR/target.mk @@ -2,6 +2,8 @@ F3_TARGETS += $(TARGET) FEATURES = VCP +FEATURE_CUT_LEVEL = 2 + TARGET_SRC = \ drivers/accgyro/accgyro_mpu.c \ drivers/accgyro/accgyro_spi_mpu6000.c \ diff --git a/src/main/target/FRSKYF3/target.h b/src/main/target/FRSKYF3/target.h index 4774852a3..962c809cb 100644 --- a/src/main/target/FRSKYF3/target.h +++ b/src/main/target/FRSKYF3/target.h @@ -23,30 +23,6 @@ #define TARGET_BOARD_IDENTIFIER "FRF3" #define USE_TARGET_CONFIG -// Removed to make the firmware fit into flash (in descending order of priority): -//#undef USE_GYRO_OVERFLOW_CHECK -//#undef USE_GYRO_LPF2 - -//#undef USE_ITERM_RELAX -#undef USE_RC_SMOOTHING_FILTER - -#undef USE_HUFFMAN -#undef USE_PINIO -#undef USE_PINIOBOX - -#undef USE_TELEMETRY_HOTT -#undef USE_TELEMETRY_MAVLINK -#undef USE_TELEMETRY_LTM -#undef USE_SERIALRX_XBUS -#undef USE_SERIALRX_SUMH -#undef USE_PWM - -#undef USE_BOARD_INFO -#undef USE_EXTENDED_CMS_MENUS -#undef USE_RTC_TIME -#undef USE_RX_MSP -#undef USE_ESC_SENSOR_INFO - #define LED0_PIN PB3 #define USE_BEEPER #define BEEPER_PIN PC15 diff --git a/src/main/target/FRSKYF3/target.mk b/src/main/target/FRSKYF3/target.mk index 395c6cf1c..64894d9a1 100644 --- a/src/main/target/FRSKYF3/target.mk +++ b/src/main/target/FRSKYF3/target.mk @@ -1,6 +1,9 @@ F3_TARGETS += $(TARGET) + FEATURES = VCP SDCARD_SPI +FEATURE_CUT_LEVEL = 4 + TARGET_SRC = \ drivers/accgyro/accgyro_mpu.c \ drivers/accgyro/accgyro_spi_mpu6000.c \ diff --git a/src/main/target/FURYF3/target.h b/src/main/target/FURYF3/target.h index 07549aa48..1cc819703 100644 --- a/src/main/target/FURYF3/target.h +++ b/src/main/target/FURYF3/target.h @@ -23,41 +23,11 @@ #ifdef FURYF3OSD #define TARGET_BOARD_IDENTIFIER "FY3O" // #define USBD_PRODUCT_STRING "FuryF3OSD" - #undef USE_THRUST_LINEARIZATION #else #define TARGET_BOARD_IDENTIFIER "FYF3" // #define USBD_PRODUCT_STRING "FuryF3" #endif -// Removed to make the firmware fit into flash (in descending order of priority): -//#undef USE_GYRO_OVERFLOW_CHECK -//#undef USE_GYRO_LPF2 - -//#undef USE_ITERM_RELAX -//#undef USE_RC_SMOOTHING_FILTER - -//#undef USE_MSP_DISPLAYPORT -//#undef USE_MSP_OVER_TELEMETRY - -//#undef USE_HUFFMAN -//#undef USE_PINIO -//#undef USE_PINIOBOX - -//#undef USE_TELEMETRY_HOTT -//#undef USE_TELEMETRY_MAVLINK -#undef USE_TELEMETRY_LTM -#undef USE_SERIALRX_XBUS -#undef USE_SERIALRX_SUMH -#undef USE_PWM - -#undef USE_BOARD_INFO -#undef USE_EXTENDED_CMS_MENUS -#undef USE_RTC_TIME -#undef USE_RX_MSP -#undef USE_ESC_SENSOR_INFO - -#define CONFIG_PREFER_ACC_ON - #define LED0_PIN PC14 #define USE_BEEPER diff --git a/src/main/target/FURYF3/target.mk b/src/main/target/FURYF3/target.mk index be5e24d82..a48dc9544 100644 --- a/src/main/target/FURYF3/target.mk +++ b/src/main/target/FURYF3/target.mk @@ -1,8 +1,13 @@ F3_TARGETS += $(TARGET) + ifeq ($(TARGET), FURYF3OSD) FEATURES += VCP ONBOARDFLASH + +FEATURE_CUT_LEVEL = 4 else FEATURES += VCP SDCARD_SPI + +FEATURE_CUT_LEVEL = 3 endif TARGET_SRC = \ @@ -18,4 +23,4 @@ TARGET_SRC += \ else TARGET_SRC += \ drivers/barometer/barometer_ms5611.c -endif \ No newline at end of file +endif diff --git a/src/main/target/IMPULSERCF3/target.h b/src/main/target/IMPULSERCF3/target.h index 22d74c56b..bf6de5580 100644 --- a/src/main/target/IMPULSERCF3/target.h +++ b/src/main/target/IMPULSERCF3/target.h @@ -22,26 +22,6 @@ #define TARGET_BOARD_IDENTIFIER "IMF3" - -// Removed to make the firmware fit into flash (in descending order of priority): -//#undef USE_GYRO_OVERFLOW_CHECK -//#undef USE_GYRO_LPF2 - -//#undef USE_ITERM_RELAX -//#undef USE_RC_SMOOTHING_FILTER - -//#undef USE_TELEMETRY_HOTT -//#undef USE_TELEMETRY_MAVLINK -#undef USE_TELEMETRY_LTM -#undef USE_SERIALRX_XBUS - -#undef USE_BOARD_INFO -#undef USE_EXTENDED_CMS_MENUS -#undef USE_RTC_TIME -#undef USE_RX_MSP -#undef USE_ESC_SENSOR_INFO - - #define ENABLE_DSHOT_DMAR true #define LED0_PIN PB7 diff --git a/src/main/target/IMPULSERCF3/target.mk b/src/main/target/IMPULSERCF3/target.mk index db716cfd3..ef03014be 100644 --- a/src/main/target/IMPULSERCF3/target.mk +++ b/src/main/target/IMPULSERCF3/target.mk @@ -1,6 +1,9 @@ F3_TARGETS += $(TARGET) + FEATURES = VCP ONBOARDFLASH +FEATURE_CUT_LEVEL = 2 + TARGET_SRC = \ drivers/accgyro/accgyro_mpu.c \ drivers/accgyro/accgyro_spi_mpu6000.c \ diff --git a/src/main/target/IRCFUSIONF3/target.h b/src/main/target/IRCFUSIONF3/target.h index 19b20435f..a557c7b8c 100644 --- a/src/main/target/IRCFUSIONF3/target.h +++ b/src/main/target/IRCFUSIONF3/target.h @@ -82,8 +82,6 @@ #define CURRENT_METER_ADC_PIN PA5 #define RSSI_ADC_PIN PB2 -#undef USE_LED_STRIP - // IO - stm32f303cc in 48pin package #define TARGET_IO_PORTA 0xffff #define TARGET_IO_PORTB 0xffff diff --git a/src/main/target/IRCFUSIONF3/target.mk b/src/main/target/IRCFUSIONF3/target.mk index 94df931d5..e39aa8fca 100644 --- a/src/main/target/IRCFUSIONF3/target.mk +++ b/src/main/target/IRCFUSIONF3/target.mk @@ -1,6 +1,8 @@ F3_TARGETS += $(TARGET) + FEATURES = VCP ONBOARDFLASH -TARGET_FLAGS = -DSPRACINGF3 + +FEATURE_CUT_LEVEL = 1 TARGET_SRC = \ drivers/accgyro/accgyro_mpu.c \ diff --git a/src/main/target/KROOZX/target.h b/src/main/target/KROOZX/target.h index 99e92e38d..07349b43b 100644 --- a/src/main/target/KROOZX/target.h +++ b/src/main/target/KROOZX/target.h @@ -71,9 +71,8 @@ #define SDCARD_SPI_CS_PIN PA15 #define SPI3_TX_DMA_OPT 0 // DMA 1 Stream 5 Channel 0 -#ifdef USE_MSP_DISPLAYPORT #undef USE_MSP_DISPLAYPORT -#endif + #define USE_MAX7456 #define MAX7456_SPI_INSTANCE SPI1 #define MAX7456_SPI_CS_PIN PC4 diff --git a/src/main/target/KROOZX/target.mk b/src/main/target/KROOZX/target.mk index e12a6ce00..21ff1b2cc 100644 --- a/src/main/target/KROOZX/target.mk +++ b/src/main/target/KROOZX/target.mk @@ -1,5 +1,9 @@ F405_TARGETS += $(TARGET) + FEATURES += VCP SDCARD_SPI + +FEATURE_CUT_LEVEL = 0 + HSE_VALUE = 16000000 TARGET_SRC = \ diff --git a/src/main/target/LUX_RACE/target.h b/src/main/target/LUX_RACE/target.h index ae29ca1d5..7a59d6f6c 100644 --- a/src/main/target/LUX_RACE/target.h +++ b/src/main/target/LUX_RACE/target.h @@ -26,36 +26,6 @@ #define TARGET_BOARD_IDENTIFIER "LUX" #endif -// Removed to make the firmware fit into flash (in descending order of priority): -#if defined(LUXV2_RACE) -//#undef USE_GYRO_OVERFLOW_CHECK -//#undef USE_GYRO_LPF2 - -//#undef USE_DYN_LPF - -//#undef USE_ITERM_RELAX -//#undef USE_RC_SMOOTHING_FILTER -//#undef USE_THRUST_LINEARIZATION - -//#undef USE_HUFFMAN -//#undef USE_PINIO -//#undef USE_PINIOBOX - -//#undef USE_TELEMETRY_HOTT -//#undef USE_TELEMETRY_MAVLINK -//#undef USE_TELEMETRY_LTM -//#undef USE_SERIALRX_XBUS -//#undef USE_SERIALRX_SUMH -//#undef USE_PWM - -//#undef USE_BOARD_INFO -#undef USE_EXTENDED_CMS_MENUS -#undef USE_D_CUT -//#undef USE_RTC_TIME -#undef USE_RX_MSP -//#undef USE_ESC_SENSOR_INFO -#endif - #define DEFAULT_VOLTAGE_METER_SOURCE VOLTAGE_METER_ADC diff --git a/src/main/target/LUX_RACE/target.mk b/src/main/target/LUX_RACE/target.mk index f5d310faa..9ccd443d9 100644 --- a/src/main/target/LUX_RACE/target.mk +++ b/src/main/target/LUX_RACE/target.mk @@ -1,6 +1,13 @@ F3_TARGETS += $(TARGET) + FEATURES = VCP SDCARD_SPI +ifeq ($(TARGET), LUXV2_RACE) +FEATURE_CUT_LEVEL = 1 +else +FEATURE_CUT_LEVEL = 0 +endif + TARGET_SRC = \ drivers/accgyro/accgyro_mpu.c \ drivers/accgyro/accgyro_mpu6500.c \ diff --git a/src/main/target/OMNIBUS/target.h b/src/main/target/OMNIBUS/target.h index d45edf3cf..c7b1783c9 100644 --- a/src/main/target/OMNIBUS/target.h +++ b/src/main/target/OMNIBUS/target.h @@ -21,41 +21,10 @@ #pragma once #undef USE_DSHOT_DMAR // OMNIBUS (F3) does not benefit from burst Dshot - -// Removed to make the firmware fit into flash (in descending order of priority): #undef USE_GYRO_OVERFLOW_CHECK -#undef USE_GYRO_LPF2 - -#undef USE_MSP_DISPLAYPORT -#undef USE_MSP_OVER_TELEMETRY - -#undef USE_DYN_LPF -#undef USE_D_CUT - -#undef USE_ITERM_RELAX -#undef USE_RC_SMOOTHING_FILTER -#undef USE_THRUST_LINEARIZATION - -#undef USE_HUFFMAN -#undef USE_PINIO -#undef USE_PINIOBOX - -#undef USE_TELEMETRY_HOTT -#undef USE_TELEMETRY_MAVLINK -#undef USE_TELEMETRY_LTM -#undef USE_SERIALRX_XBUS -#undef USE_SERIALRX_SUMH -#undef USE_PWM - -#undef USE_BOARD_INFO -#undef USE_EXTENDED_CMS_MENUS -#undef USE_RTC_TIME -#undef USE_RX_MSP -#undef USE_ESC_SENSOR_INFO #define TARGET_BOARD_IDENTIFIER "OMNI" // https://en.wikipedia.org/wiki/Omnibus - #define LED0_PIN PB3 #define USE_BEEPER diff --git a/src/main/target/OMNIBUS/target.mk b/src/main/target/OMNIBUS/target.mk index 109f4a4c7..7808948cc 100644 --- a/src/main/target/OMNIBUS/target.mk +++ b/src/main/target/OMNIBUS/target.mk @@ -1,6 +1,9 @@ F3_TARGETS += $(TARGET) + FEATURES = VCP SDCARD_SPI +FEATURE_CUT_LEVEL = 9 + TARGET_SRC = \ drivers/accgyro/accgyro_mpu.c \ drivers/accgyro/accgyro_spi_mpu6000.c \ diff --git a/src/main/target/RACEBASE/target.h b/src/main/target/RACEBASE/target.h index 683871b9f..f79ae20f5 100644 --- a/src/main/target/RACEBASE/target.h +++ b/src/main/target/RACEBASE/target.h @@ -24,30 +24,6 @@ #define USE_HARDWARE_REVISION_DETECTION #define USE_TARGET_CONFIG -// Removed to make the firmware fit into flash (in descending order of priority): -//#undef USE_GYRO_OVERFLOW_CHECK -//#undef USE_GYRO_LPF2 - -//#undef USE_ITERM_RELAX -//#undef USE_RC_SMOOTHING_FILTER - -//#undef USE_HUFFMAN -//#undef USE_PINIO -//#undef USE_PINIOBOX - -//#undef USE_TELEMETRY_HOTT -//#undef USE_TELEMETRY_MAVLINK -//#undef USE_TELEMETRY_LTM -//#undef USE_SERIALRX_XBUS -//#undef USE_SERIALRX_SUMH -//#undef USE_PWM - -//#undef USE_BOARD_INFO -#undef USE_EXTENDED_CMS_MENUS -//#undef USE_RTC_TIME -#undef USE_RX_MSP -#undef USE_ESC_SENSOR_INFO - #define LED0_PIN PB3 #define LED0_INVERTED diff --git a/src/main/target/RACEBASE/target.mk b/src/main/target/RACEBASE/target.mk index 58fd4da6d..7428ca508 100644 --- a/src/main/target/RACEBASE/target.mk +++ b/src/main/target/RACEBASE/target.mk @@ -2,6 +2,7 @@ F3_TARGETS += $(TARGET) FEATURES = ONBOARDFLASH +FEATURE_CUT_LEVEL = 2 TARGET_SRC = \ drivers/accgyro/accgyro_mpu.c \ drivers/accgyro/accgyro_spi_mpu6000.c \ diff --git a/src/main/target/RCEXPLORERF3/target.h b/src/main/target/RCEXPLORERF3/target.h index 0300699a7..52bc4e26a 100644 --- a/src/main/target/RCEXPLORERF3/target.h +++ b/src/main/target/RCEXPLORERF3/target.h @@ -22,20 +22,7 @@ #define TARGET_BOARD_IDENTIFIER "REF3" -// Removed to make the firmware fit into flash (in descending order of priority): #undef USE_GYRO_OVERFLOW_CHECK -#undef USE_GYRO_LPF2 - -//#undef USE_TELEMETRY_MAVLINK -//#undef USE_TELEMETRY_LTM -#undef USE_SERIALRX_XBUS - -#undef USE_EXTENDED_CMS_MENUS -#undef USE_RTC_TIME -#undef USE_RX_MSP -#undef USE_ESC_SENSOR_INFO - - #define LED0_PIN PB4 #define LED1_PIN PB5 diff --git a/src/main/target/RCEXPLORERF3/target.mk b/src/main/target/RCEXPLORERF3/target.mk index 254db6c70..8f6850389 100644 --- a/src/main/target/RCEXPLORERF3/target.mk +++ b/src/main/target/RCEXPLORERF3/target.mk @@ -1,6 +1,9 @@ F3_TARGETS += $(TARGET) + FEATURES = VCP +FEATURE_CUT_LEVEL = 2 + TARGET_SRC = \ drivers/accgyro/accgyro_mpu.c \ drivers/accgyro/accgyro_spi_mpu6000.c \ diff --git a/src/main/target/RG_SSD_F3/target.h b/src/main/target/RG_SSD_F3/target.h index 48d278152..df6393162 100644 --- a/src/main/target/RG_SSD_F3/target.h +++ b/src/main/target/RG_SSD_F3/target.h @@ -22,11 +22,6 @@ #define TARGET_BOARD_IDENTIFIER "RGF3" // rgSSD_F3 -// Removed to make the firmware fit into flash (in descending order of priority): -//#undef USE_RTC_TIME -#undef USE_RX_MSP -//#undef USE_ESC_SENSOR_INFO - #define LED0_PIN PC1 #define LED1_PIN PC0 diff --git a/src/main/target/RG_SSD_F3/target.mk b/src/main/target/RG_SSD_F3/target.mk index 6598b60ee..a6fc69a8a 100644 --- a/src/main/target/RG_SSD_F3/target.mk +++ b/src/main/target/RG_SSD_F3/target.mk @@ -1,6 +1,9 @@ F3_TARGETS += $(TARGET) + FEATURES = VCP SDCARD_SPI +FEATURE_CUT_LEVEL = 1 + TARGET_SRC = \ drivers/accgyro/accgyro_mpu.c \ drivers/accgyro/accgyro_spi_mpu6000.c diff --git a/src/main/target/SIRINFPV/target.h b/src/main/target/SIRINFPV/target.h index 59f886451..1bddaa15e 100644 --- a/src/main/target/SIRINFPV/target.h +++ b/src/main/target/SIRINFPV/target.h @@ -22,31 +22,6 @@ #define TARGET_BOARD_IDENTIFIER "SIRF" -// Removed to make the firmware fit into flash (in descending order of priority): -//#undef USE_GYRO_OVERFLOW_CHECK -//#undef USE_GYRO_LPF2 - -//#undef USE_ITERM_RELAX -//#undef USE_RC_SMOOTHING_FILTER - -#undef USE_HUFFMAN -#undef USE_PINIO -#undef USE_PINIOBOX - -//#undef USE_TELEMETRY_HOTT -//#undef USE_TELEMETRY_MAVLINK -#undef USE_TELEMETRY_LTM -#undef USE_SERIALRX_XBUS -#undef USE_SERIALRX_SUMH -#undef USE_PWM - -#undef USE_BOARD_INFO -#undef USE_EXTENDED_CMS_MENUS -#undef USE_RTC_TIME -#undef USE_RX_MSP -#undef USE_ESC_SENSOR_INFO -#undef USE_THRUST_LINEARIZATION - #define LED0_PIN PB2 #define USE_BEEPER #define BEEPER_PIN PA1 diff --git a/src/main/target/SIRINFPV/target.mk b/src/main/target/SIRINFPV/target.mk index 57abe64cf..bb6789e5d 100644 --- a/src/main/target/SIRINFPV/target.mk +++ b/src/main/target/SIRINFPV/target.mk @@ -1,6 +1,9 @@ F3_TARGETS += $(TARGET) + FEATURES = VCP SDCARD_SPI +FEATURE_CUT_LEVEL = 4 + TARGET_SRC = \ drivers/accgyro/accgyro_mpu.c \ drivers/accgyro/accgyro_mpu6500.c \ diff --git a/src/main/target/SPRACINGF3/target.h b/src/main/target/SPRACINGF3/target.h index c66d9a269..79623030b 100644 --- a/src/main/target/SPRACINGF3/target.h +++ b/src/main/target/SPRACINGF3/target.h @@ -32,39 +32,6 @@ #define TARGET_BOARD_IDENTIFIER "SRF3" #endif -// Removed to make the firmware fit into flash (in descending order of priority): -//#undef USE_GYRO_OVERFLOW_CHECK -//#undef USE_GYRO_LPF2 -#undef USE_EXTENDED_CMS_MENUS - -#if !(defined(ZCOREF3) || defined(FLIP32F3OSD) || defined(IRCSYNERGYF3)) -//#undef USE_ITERM_RELAX -//#undef USE_RC_SMOOTHING_FILTER - -//#undef USE_MSP_DISPLAYPORT -//#undef USE_MSP_OVER_TELEMETRY - -#undef USE_LED_STRIP -//#undef USE_HUFFMAN -//#undef USE_PINIO -//#undef USE_PINIOBOX - -//#undef USE_TELEMETRY_HOTT -//#undef USE_TELEMETRY_MAVLINK -//#undef USE_TELEMETRY_LTM -#undef USE_SERIALRX_XBUS -#undef USE_SERIALRX_SUMH -#undef USE_PWM - -#endif - -#undef USE_THRUST_LINEARIZATION -#undef USE_BOARD_INFO -#undef USE_RTC_TIME - -#undef USE_RX_MSP -#undef USE_ESC_SENSOR_INFO - #if defined(ZCOREF3) #define LED0_PIN PB8 diff --git a/src/main/target/SPRACINGF3/target.mk b/src/main/target/SPRACINGF3/target.mk index 0d96cb170..4698ba9fe 100644 --- a/src/main/target/SPRACINGF3/target.mk +++ b/src/main/target/SPRACINGF3/target.mk @@ -1,4 +1,5 @@ F3_TARGETS += $(TARGET) + FEATURES = ONBOARDFLASH TARGET_SRC = \ @@ -11,18 +12,26 @@ TARGET_SRC = \ drivers/compass/compass_qmc5883l.c ifeq ($(TARGET), FLIP32F3OSD) +FEATURE_CUT_LEVEL = 1 + TARGET_SRC += \ drivers/accgyro/accgyro_mpu6500.c else ifeq ($(TARGET), ZCOREF3) +FEATURE_CUT_LEVEL = 1 + TARGET_SRC += \ drivers/accgyro/accgyro_mpu6500.c \ drivers/accgyro/accgyro_spi_mpu6500.c else ifeq ($(TARGET), IRCSYNERGYF3) +FEATURE_CUT_LEVEL = 1 + TARGET_SRC += \ drivers/accgyro/accgyro_spi_mpu6000.c else +FEATURE_CUT_LEVEL = 3 + TARGET_SRC += \ drivers/accgyro/accgyro_mpu6050.c endif diff --git a/src/main/target/SPRACINGF3MINI/target.h b/src/main/target/SPRACINGF3MINI/target.h index 195fa613b..b7982ed73 100644 --- a/src/main/target/SPRACINGF3MINI/target.h +++ b/src/main/target/SPRACINGF3MINI/target.h @@ -32,33 +32,6 @@ #define SPRACINGF3MINI_REV 2 #endif -// Removed to make the firmware fit into flash (in descending order of priority): -//#undef USE_GYRO_OVERFLOW_CHECK -//#undef USE_GYRO_LPF2 - -//#undef USE_ITERM_RELAX -//#undef USE_RC_SMOOTHING_FILTER - -//#undef USE_MSP_DISPLAYPORT -//#undef USE_MSP_OVER_TELEMETRY - -#undef USE_HUFFMAN -#undef USE_PINIO -#undef USE_PINIOBOX - -#undef USE_TELEMETRY_HOTT -#undef USE_TELEMETRY_MAVLINK -#undef USE_TELEMETRY_LTM -#undef USE_SERIALRX_XBUS -#undef USE_SERIALRX_SUMH -#undef USE_PWM - -#undef USE_BOARD_INFO -#undef USE_EXTENDED_CMS_MENUS -#undef USE_RTC_TIME -#undef USE_RX_MSP -#undef USE_ESC_SENSOR_INFO - #define LED0_PIN PB3 #endif diff --git a/src/main/target/SPRACINGF3MINI/target.mk b/src/main/target/SPRACINGF3MINI/target.mk index e20629f15..57c2e7957 100644 --- a/src/main/target/SPRACINGF3MINI/target.mk +++ b/src/main/target/SPRACINGF3MINI/target.mk @@ -1,6 +1,9 @@ F3_TARGETS += $(TARGET) + FEATURES = VCP SDCARD_SPI +FEATURE_CUT_LEVEL = 6 + TARGET_SRC = \ drivers/accgyro/accgyro_mpu.c \ drivers/accgyro/accgyro_mpu6500.c \ diff --git a/src/main/target/STM32F3DISCOVERY/target.h b/src/main/target/STM32F3DISCOVERY/target.h index f5fa85b08..f3f6fbee6 100644 --- a/src/main/target/STM32F3DISCOVERY/target.h +++ b/src/main/target/STM32F3DISCOVERY/target.h @@ -36,30 +36,6 @@ #define TARGET_BOARD_IDENTIFIER "SDF3" // STM Discovery F3 -// Removed to make the firmware fit into flash (in descending order of priority): -//#undef USE_GYRO_OVERFLOW_CHECK -//#undef USE_GYRO_LPF2 - -//#undef USE_ITERM_RELAX -//#undef USE_RC_SMOOTHING_FILTER - -#undef USE_HUFFMAN -#undef USE_PINIO -#undef USE_PINIOBOX - -#undef USE_TELEMETRY_HOTT -#undef USE_TELEMETRY_MAVLINK -#undef USE_TELEMETRY_LTM -#undef USE_SERIALRX_XBUS -#undef USE_SERIALRX_SUMH -//#undef USE_PWM - -#undef USE_BOARD_INFO -//#undef USE_RX_MSP -//#undef USE_RTC_TIME -#undef USE_EXTENDED_CMS_MENUS -#undef USE_ESC_SENSOR_INFO - #define USE_SENSOR_NAMES #define CURRENT_TARGET_CPU_VOLTAGE 3.0 diff --git a/src/main/target/STM32F3DISCOVERY/target.mk b/src/main/target/STM32F3DISCOVERY/target.mk index 3897e2b86..cdabb4f17 100644 --- a/src/main/target/STM32F3DISCOVERY/target.mk +++ b/src/main/target/STM32F3DISCOVERY/target.mk @@ -1,6 +1,9 @@ F3_TARGETS += $(TARGET) + FEATURES = VCP SDCARD_SPI ONBOARDFLASH +FEATURE_CUT_LEVEL = 4 + TARGET_SRC = \ drivers/accgyro/accgyro_fake.c \ drivers/accgyro/accgyro_mpu.c \