Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Target] MATEKF411RX / CRAZYBEEF4 (FR,FS,DX,DXS) add BMI270 ICM42688P #916

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 19 additions & 2 deletions src/main/target/MATEKF411RX/target.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,34 +49,51 @@
#define SPI1_MOSI_PIN PA7

#define MPU6000_CS_PIN PA4
#define ICM20689_CS_PIN MPU6000_CS_PIN
#define ICM20689_CS_PIN PA4
#define BMI270_CS_PIN PA4
#define ICM42688P_CS_PIN PA4
#define MPU6000_SPI_INSTANCE SPI1
#define ICM20689_SPI_INSTANCE MPU6000_SPI_INSTANCE
#define ICM20689_SPI_INSTANCE SPI1
#define BMI270_SPI_INSTANCE SPI1
#define ICM42688P_SPI_INSTANCE SPI1

#define USE_EXTI
#define MPU_INT_EXTI PA1
#define USE_MPU_DATA_READY_SIGNAL

#define USE_GYRO
#define USE_SPI_GYRO
#define USE_GYRO_SPI_MPU6000
#define USE_GYRO_SPI_ICM20689
#define USE_ACCGYRO_BMI270
#define USE_GYRO_SPI_ICM42688P


#if defined(CRAZYBEEF4FS) || defined(CRAZYBEEF4FR) || defined(CRAZYBEEF4DX)
#define GYRO_MPU6000_ALIGN CW90_DEG
#define GYRO_ICM20689_ALIGN CW90_DEG
#define GYRO_BMI270_ALIGN CW90_DEG
#define GYRO_ICM42688P_ALIGN CW90_DEG
#else
#define GYRO_MPU6000_ALIGN CW180_DEG
#define GYRO_ICM20689_ALIGN CW180_DEG
#define GYRO_BMI270_ALIGN CW180_DEG
#define GYRO_ICM42688P_ALIGN CW180_DEG
#endif
#define USE_ACC
#define USE_ACC_SPI_MPU6000
#define USE_ACC_SPI_ICM20689
#define USE_ACC_SPI_ICM42688P
#if defined(CRAZYBEEF4FS) || defined(CRAZYBEEF4FR) || defined(CRAZYBEEF4DX)
#define ACC_MPU6000_ALIGN CW90_DEG
#define ACC_ICM20689_ALIGN CW90_DEG
#define ACC_BMI270_ALIGN CW90_DEG
#define ACC_ICM42688P_ALIGN CW90_DEG
#else
#define ACC_MPU6000_ALIGN CW180_DEG
#define ACC_ICM20689_ALIGN CW180_DEG
#define ACC_BMI270_ALIGN CW180_DEG
#define ACC_ICM42688P_ALIGN CW180_DEG
#endif
// *************** SPI2 OSD *****************************
#define USE_SPI_DEVICE_2
Expand Down
11 changes: 7 additions & 4 deletions src/main/target/MATEKF411RX/target.mk
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,17 @@ FEATURES += VCP SDCARD

TARGET_SRC = \
drivers/accgyro/accgyro_spi_mpu6000.c \
drivers/accgyro/accgyro_spi_icm20689.c \
drivers/accgyro/accgyro_spi_icm20689.c \
drivers/accgyro/accgyro_bmi270.c \
drivers/accgyro/accgyro_spi_bmi270.c \
drivers/accgyro/accgyro_spi_icm426xx.c \
drivers/max7456.c \
drivers/rx/rx_cc2500.c \
rx/cc2500_common.c \
rx/cc2500_common.c \
rx/cc2500_frsky_shared.c \
rx/cc2500_frsky_d.c \
rx/cc2500_frsky_x.c \
rx/cc2500_redpine.c \
rx/cc2500_frsky_x.c \
rx/cc2500_redpine.c \
rx/cc2500_sfhss.c
ifeq ($(TARGET), CRAZYBEEF4FS)
TARGET_SRC += \
Expand Down
Loading