Merge pull request #3175 from bnn1044/clracingf7
Add ICM20689 support for CLRACINGF7
This commit is contained in:
commit
323d0ae734
|
@ -9,6 +9,5 @@ Blackbox: SD Card
|
||||||
PPM/UART NOT Shared: YES
|
PPM/UART NOT Shared: YES
|
||||||
Battery Voltage Sensor: 10:1
|
Battery Voltage Sensor: 10:1
|
||||||
Current sensor: 0.5 mOhm, 250 Current scale in the setting
|
Current sensor: 0.5 mOhm, 250 Current scale in the setting
|
||||||
Integrated Voltage Regulator: 1.2A 5v
|
Integrated Voltage Regulator: 3 A 5v
|
||||||
Integrated Volrage Regulator: 1.2A 7.8V for clean vtx and camera power
|
|
||||||
120A Current sensing PDB and 150A burst current for 10S on the current sensing Resistor
|
120A Current sensing PDB and 150A burst current for 10S on the current sensing Resistor
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
|
|
||||||
const timerHardware_t timerHardware[USABLE_TIMER_CHANNEL_COUNT] = {
|
const timerHardware_t timerHardware[USABLE_TIMER_CHANNEL_COUNT] = {
|
||||||
|
|
||||||
DEF_TIM(TIM4, CH3, PB8, TIM_USE_PPM | TIM_USE_LED, TIMER_INPUT_ENABLED, 0), // PPM -DMA1_ST7
|
DEF_TIM(TIM4, CH3, PB8, TIM_USE_PPM, TIMER_INPUT_ENABLED, 0), // PPM -DMA1_ST7
|
||||||
|
|
||||||
DEF_TIM(TIM2, CH4, PA3, TIM_USE_MOTOR, TIMER_OUTPUT_ENABLED, 1), // PWM1 - DMA1_ST6
|
DEF_TIM(TIM2, CH4, PA3, TIM_USE_MOTOR, TIMER_OUTPUT_ENABLED, 1), // PWM1 - DMA1_ST6
|
||||||
DEF_TIM(TIM8, CH3, PC8, TIM_USE_MOTOR, TIMER_OUTPUT_ENABLED, 1), // PWM2 - DMA2_ST2
|
DEF_TIM(TIM8, CH3, PC8, TIM_USE_MOTOR, TIMER_OUTPUT_ENABLED, 1), // PWM2 - DMA2_ST2
|
||||||
|
@ -39,4 +39,5 @@ const timerHardware_t timerHardware[USABLE_TIMER_CHANNEL_COUNT] = {
|
||||||
|
|
||||||
DEF_TIM(TIM1, CH3N, PB1, TIM_USE_MOTOR | TIM_USE_LED, TIMER_OUTPUT_ENABLED | TIMER_OUTPUT_INVERTED, 0), // S5_OUT - DMA2_ST6
|
DEF_TIM(TIM1, CH3N, PB1, TIM_USE_MOTOR | TIM_USE_LED, TIMER_OUTPUT_ENABLED | TIMER_OUTPUT_INVERTED, 0), // S5_OUT - DMA2_ST6
|
||||||
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
|
@ -18,25 +18,34 @@
|
||||||
#pragma once
|
#pragma once
|
||||||
#define TARGET_BOARD_IDENTIFIER "CLR7"
|
#define TARGET_BOARD_IDENTIFIER "CLR7"
|
||||||
|
|
||||||
#define USBD_PRODUCT_STRING "CL_RACING F7"
|
#define USBD_PRODUCT_STRING "CLRACINGF7"
|
||||||
|
|
||||||
#define LED0 PB0
|
#define LED0 PB0
|
||||||
#define BEEPER PB4
|
#define BEEPER PB4
|
||||||
#define BEEPER_INVERTED
|
#define BEEPER_INVERTED
|
||||||
|
|
||||||
#define MPU6000_CS_PIN PA4
|
#define USE_EXTI
|
||||||
#define MPU6000_SPI_INSTANCE SPI1
|
#define MPU_INT_EXTI PC4
|
||||||
|
#define USE_MPU_DATA_READY_SIGNAL
|
||||||
|
//ICM20689
|
||||||
|
#define ICM20689_CS_PIN PA4
|
||||||
|
#define ICM20689_SPI_INSTANCE SPI1
|
||||||
|
#define GYRO
|
||||||
|
#define USE_GYRO_SPI_ICM20689
|
||||||
|
#define GYRO_ICM20689_ALIGN CW0_DEG
|
||||||
|
#define ACC
|
||||||
|
#define USE_ACC_SPI_ICM20689
|
||||||
|
#define ACC_ICM20689_ALIGN CW0_DEG
|
||||||
|
|
||||||
|
//MPU-6000
|
||||||
#define ACC
|
#define ACC
|
||||||
#define USE_ACC_SPI_MPU6000
|
#define USE_ACC_SPI_MPU6000
|
||||||
#define GYRO
|
#define GYRO
|
||||||
#define USE_GYRO_SPI_MPU6000
|
#define USE_GYRO_SPI_MPU6000
|
||||||
|
|
||||||
// MPU6000 interrupts
|
|
||||||
#define USE_EXTI
|
|
||||||
#define MPU_INT_EXTI PC4
|
|
||||||
#define USE_MPU_DATA_READY_SIGNAL
|
|
||||||
#define GYRO_MPU6000_ALIGN CW0_DEG
|
#define GYRO_MPU6000_ALIGN CW0_DEG
|
||||||
#define ACC_MPU6000_ALIGN CW0_DEG
|
#define ACC_MPU6000_ALIGN CW0_DEG
|
||||||
|
#define MPU6000_CS_PIN PA4
|
||||||
|
#define MPU6000_SPI_INSTANCE SPI1
|
||||||
|
|
||||||
#define OSD
|
#define OSD
|
||||||
#define USE_MAX7456
|
#define USE_MAX7456
|
||||||
|
@ -59,7 +68,6 @@
|
||||||
#define SDCARD_DMA_CLK RCC_AHB1Periph_DMA2
|
#define SDCARD_DMA_CLK RCC_AHB1Periph_DMA2
|
||||||
#define SDCARD_DMA_CHANNEL DMA_CHANNEL_0
|
#define SDCARD_DMA_CHANNEL DMA_CHANNEL_0
|
||||||
|
|
||||||
|
|
||||||
#define USE_VCP
|
#define USE_VCP
|
||||||
#define USE_UART1
|
#define USE_UART1
|
||||||
#define UART1_RX_PIN PA10
|
#define UART1_RX_PIN PA10
|
||||||
|
@ -101,28 +109,22 @@
|
||||||
#define SPI3_MISO_PIN PC11
|
#define SPI3_MISO_PIN PC11
|
||||||
#define SPI3_MOSI_PIN PC12
|
#define SPI3_MOSI_PIN PC12
|
||||||
|
|
||||||
|
|
||||||
#define USE_ADC
|
#define USE_ADC
|
||||||
#define DEFAULT_VOLTAGE_METER_SOURCE VOLTAGE_METER_ADC
|
#define DEFAULT_VOLTAGE_METER_SOURCE VOLTAGE_METER_ADC
|
||||||
#define DEFAULT_CURRENT_METER_SOURCE CURRENT_METER_ADC
|
#define DEFAULT_CURRENT_METER_SOURCE CURRENT_METER_ADC
|
||||||
#define CURRENT_METER_ADC_PIN PC1
|
#define CURRENT_METER_ADC_PIN PC1
|
||||||
#define VBAT_ADC_PIN PC2
|
#define VBAT_ADC_PIN PC2
|
||||||
#define RSSI_ADC_PIN PC3
|
#define RSSI_ADC_PIN PC3
|
||||||
|
|
||||||
#define CURRENT_METER_SCALE_DEFAULT 250 // 3/120A = 25mv/A
|
#define CURRENT_METER_SCALE_DEFAULT 250 // 3/120A = 25mv/A
|
||||||
|
|
||||||
// LED strip configuration.
|
// LED strip configuration.
|
||||||
#define LED_STRIP
|
#define LED_STRIP
|
||||||
#define SPEKTRUM_BIND_PIN UART6_RX_PIN
|
#define SPEKTRUM_BIND_PIN UART6_RX_PIN
|
||||||
#define BINDPLUG_PIN PB2
|
#define BINDPLUG_PIN PB2
|
||||||
|
|
||||||
#define ENABLE_BLACKBOX_LOGGING_ON_SDCARD_BY_DEFAULT
|
#define ENABLE_BLACKBOX_LOGGING_ON_SDCARD_BY_DEFAULT
|
||||||
|
|
||||||
#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 TELEMETRY_UART SERIAL_PORT_USART1
|
#define TELEMETRY_UART SERIAL_PORT_USART1
|
||||||
|
|
||||||
#define USE_SERIAL_4WAY_BLHELI_INTERFACE
|
#define USE_SERIAL_4WAY_BLHELI_INTERFACE
|
||||||
|
|
||||||
#define TARGET_IO_PORTA 0xffff
|
#define TARGET_IO_PORTA 0xffff
|
||||||
|
|
|
@ -1,6 +1,8 @@
|
||||||
F7X2RE_TARGETS += $(TARGET)
|
F7X2RE_TARGETS += $(TARGET)
|
||||||
FEATURES += SDCARD VCP
|
FEATURES += SDCARD VCP
|
||||||
|
|
||||||
TARGET_SRC = \
|
TARGET_SRC = \
|
||||||
drivers/accgyro/accgyro_spi_mpu6000.c\
|
drivers/accgyro/accgyro_spi_icm20689.c\
|
||||||
|
drivers/accgyro/accgyro_spi_mpu6000.c \
|
||||||
|
drivers/light_ws2811strip.c \
|
||||||
|
drivers/light_ws2811strip_hal.c \
|
||||||
drivers/max7456.c
|
drivers/max7456.c
|
||||||
|
|
Loading…
Reference in New Issue