From dafdd97565391374acf3225573b687ed69524358 Mon Sep 17 00:00:00 2001 From: nerdCopter <56646290+nerdCopter@users.noreply.github.com> Date: Mon, 15 Apr 2024 14:47:28 -0500 Subject: [PATCH] [target] BETAFPVF411RX remove softserial, fix flashpin, update id --- src/main/target/BETAFPVF411RX/target.h | 51 ++++++++------------------ 1 file changed, 15 insertions(+), 36 deletions(-) diff --git a/src/main/target/BETAFPVF411RX/target.h b/src/main/target/BETAFPVF411RX/target.h index 2a68447eda..1f6d46c96b 100644 --- a/src/main/target/BETAFPVF411RX/target.h +++ b/src/main/target/BETAFPVF411RX/target.h @@ -20,15 +20,16 @@ #pragma once - -#define TARGET_BOARD_IDENTIFIER "BEFH" -#define USBD_PRODUCT_STRING "BETAFPVF411RX" +#define BOARD_NAME BETAFPVF411RX +#define MANUFACTURER_ID BEFH +#define TARGET_BOARD_IDENTIFIER "S411" // generic ID +#define FC_TARGET_MCU STM32F411 // not used in EmuF #define LED0_PIN PC14 -//#define USE_BEEPER -//#define BEEPER_PIN P -//#define BEEPER_INVERTED +#define USE_BEEPER +#define BEEPER_PIN PA14 +#define BEEPER_INVERTED // *************** Gyro & ACC ********************** #define USE_SPI @@ -68,24 +69,6 @@ #define BMI270_CS_PIN PA4 #define BMI270_SPI_INSTANCE SPI1 -// *************** Baro ************************** -//#define USE_I2C - -//#define USE_I2C_DEVICE_1 -//#define I2C_DEVICE (I2CDEV_1) -//#define I2C1_SCL PB8 // SCL pad -//#define I2C1_SDA PB9 // SDA pad -//#define BARO_I2C_INSTANCE (I2CDEV_1) - -//#define USE_BARO //External, connect to I2C1 -//#define USE_BARO_BMP280 -//#define USE_BARO_MS5611 -//#define USE_BARO_BMP085 - -//#define USE_MAG -//#define USE_MAG_HMC5883 //External, connect to I2C1 -//#define USE_MAG_QMC5883 - // *************** UART ***************************** #define USE_VCP #define USE_USB_DETECT @@ -98,15 +81,10 @@ #define UART2_RX_PIN PA3 #define UART2_TX_PIN PA2 -#define USE_SOFTSERIAL1 -#define SOFTSERIAL1_RX_PIN PA8 -#define SOFTSERIAL1_TX_PIN PA8 - -#define SERIAL_PORT_COUNT 4 +#define SERIAL_PORT_COUNT 3 // *************** SPI3 CC2500 *************************** - #define USE_SPI_DEVICE_3 #define SPI3_SCK_PIN PB3 #define SPI3_MISO_PIN PB4 @@ -151,16 +129,20 @@ #define ENABLE_BLACKBOX_LOGGING_ON_SPIFLASH_BY_DEFAULT #define USE_FLASHFS #define USE_FLASH_M25P16 -#define FLASH_CS_PIN PB2 +#define FLASH_CS_PIN PA8 #define FLASH_SPI_INSTANCE SPI2 // *************** ADC ***************************** #define USE_ADC #define ADC_INSTANCE ADC1 -//#define ADC1_DMA_OPT 0 // DMA 2 Stream 0 Channel 0 +#define ADC1_DMA_OPT 1 #define ADC1_DMA_STREAM DMA2_Stream4 //# ADC 1: DMA2 Stream 4 Channel 0 #define VBAT_ADC_PIN PA1 #define CURRENT_METER_ADC_PIN PB0 +#define DEFAULT_VOLTAGE_METER_SOURCE VOLTAGE_METER_ADC +#define DEFAULT_CURRENT_METER_SOURCE CURRENT_METER_ADC +#define DEFAULT_CURRENT_METER_SCALE 179 + //#define RSSI_ADC_PIN PB1 //#define EXTERNAL1_ADC_PIN PA4 @@ -174,10 +156,7 @@ //#define PINIO2_PIN PA15 // Camera switcher //#define USE_PINIOBOX -#define DEFAULT_FEATURES (FEATURE_OSD | FEATURE_TELEMETRY | FEATURE_AIRMODE | FEATURE_SOFTSERIAL) -#define CURRENT_METER_SCALE_DEFAULT 179 -#define DEFAULT_VOLTAGE_METER_SOURCE VOLTAGE_METER_ADC -#define DEFAULT_CURRENT_METER_SOURCE CURRENT_METER_ADC +#define DEFAULT_FEATURES (FEATURE_OSD | FEATURE_TELEMETRY | FEATURE_AIRMODE) #define TARGET_IO_PORTA 0xffff #define TARGET_IO_PORTB 0xffff