Skip to content

Commit

Permalink
Remove redundant directives
Browse files Browse the repository at this point in the history
  • Loading branch information
haslinghuis committed Dec 22, 2023
1 parent 8197ed9 commit 06d3f96
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 104 deletions.
55 changes: 1 addition & 54 deletions src/main/sensors/acceleration_init.c
Expand Up @@ -37,79 +37,26 @@
#include "config/feature.h"

#include "drivers/accgyro/accgyro.h"
#include "drivers/accgyro/accgyro_mpu.h"

#ifdef USE_VIRTUAL_ACC
#include "drivers/accgyro/accgyro_virtual.h"
#endif

#ifdef USE_ACC_MPU3050
#include "drivers/accgyro/accgyro_mpu.h"
#include "drivers/accgyro/accgyro_mpu3050.h"
#endif

#ifdef USE_ACC_MPU6050
#include "drivers/accgyro/accgyro_mpu6050.h"
#endif

#ifdef USE_ACC_MPU6500
#include "drivers/accgyro/accgyro_mpu6500.h"
#endif

#ifdef USE_ACCGYRO_BMI160
#include "drivers/accgyro/accgyro_spi_bmi160.h"
#endif

#ifdef USE_ACCGYRO_BMI270
#include "drivers/accgyro/accgyro_spi_bmi270.h"
#endif

#ifdef USE_ACC_SPI_ICM20649
#include "drivers/accgyro/accgyro_spi_icm20649.h"
#endif

#ifdef USE_ACC_SPI_ICM20689
#include "drivers/accgyro/accgyro_spi_icm20689.h"
#endif

#if defined(USE_ACC_SPI_ICM42605) || defined(USE_ACC_SPI_ICM42688P)
#include "drivers/accgyro/accgyro_spi_icm426xx.h"
#endif

#ifdef USE_ACCGYRO_LSM6DSO
#include "drivers/accgyro/accgyro_spi_lsm6dso.h"
#endif

#ifdef USE_ACC_SPI_MPU6000
#include "drivers/accgyro/accgyro_spi_mpu6000.h"
#endif

#if defined(USE_ACC_SPI_MPU6500) || defined(USE_ACC_SPI_MPU9250) || defined(USE_ACC_SPI_ICM20601) || defined(USE_ACC_SPI_ICM20602) || defined(USE_ACC_SPI_ICM20608G)
#include "drivers/accgyro/accgyro_spi_mpu6500.h"
#endif

#ifdef USE_ACC_SPI_MPU9250
#include "drivers/accgyro/accgyro_spi_mpu9250.h"
#endif

#ifdef USE_ACCGYRO_LSM6DSV16X
#include "drivers/accgyro/accgyro_spi_lsm6dsv16x.h"
#endif

#ifdef USE_ACC_ADXL345
#include "drivers/accgyro_legacy/accgyro_adxl345.h"
#endif

#ifdef USE_ACC_BMA280
#include "drivers/accgyro_legacy/accgyro_bma280.h"
#endif

#ifdef USE_ACC_LSM303DLHC
#include "drivers/accgyro_legacy/accgyro_lsm303dlhc.h"
#endif

#ifdef USE_ACC_MMA8452
#include "drivers/accgyro_legacy/accgyro_mma845x.h"
#endif

#include "drivers/bus_spi.h"

Expand Down
51 changes: 1 addition & 50 deletions src/main/sensors/gyro_init.c
Expand Up @@ -35,79 +35,30 @@
#include "config/config.h"

#include "drivers/accgyro/accgyro.h"
#include "drivers/accgyro/accgyro_mpu.h"

#ifdef USE_VIRTUAL_GYRO
#include "drivers/accgyro/accgyro_virtual.h"
#endif

#ifdef USE_GYRO_MPU3050
#include "drivers/accgyro/accgyro_mpu.h"
#include "drivers/accgyro/accgyro_mpu3050.h"
#endif

#ifdef USE_GYRO_MPU6050
#include "drivers/accgyro/accgyro_mpu6050.h"
#endif

#if defined(USE_GYRO_MPU6500)
#include "drivers/accgyro/accgyro_mpu6500.h"
#endif

#ifdef USE_ACCGYRO_BMI160
#include "drivers/accgyro/accgyro_spi_bmi160.h"
#endif

#ifdef USE_ACCGYRO_BMI270
#include "drivers/accgyro/accgyro_spi_bmi270.h"
#endif

#ifdef USE_GYRO_SPI_ICM20649
#include "drivers/accgyro/accgyro_spi_icm20649.h"
#endif

#ifdef USE_GYRO_SPI_ICM20689
#include "drivers/accgyro/accgyro_spi_icm20689.h"
#endif

#if defined(USE_GYRO_SPI_ICM42605) || defined(USE_GYRO_SPI_ICM42688P)
#include "drivers/accgyro/accgyro_spi_icm426xx.h"
#endif

#ifdef USE_ACCGYRO_LSM6DSO
#include "drivers/accgyro/accgyro_spi_lsm6dso.h"
#endif

#ifdef USE_GYRO_SPI_MPU6000
#include "drivers/accgyro/accgyro_spi_mpu6000.h"
#endif

#if defined(USE_GYRO_SPI_MPU6500) || defined(USE_GYRO_SPI_MPU9250) || defined(USE_GYRO_SPI_ICM20601) || defined(USE_GYRO_SPI_ICM20602) || defined(USE_GYRO_SPI_ICM20608G)
#include "drivers/accgyro/accgyro_spi_mpu6500.h"
#endif

#ifdef USE_GYRO_SPI_MPU9250
#include "drivers/accgyro/accgyro_spi_mpu9250.h"
#endif

#ifdef USE_ACCGYRO_LSM6DSV16X
#include "drivers/accgyro/accgyro_spi_lsm6dsv16x.h"
#endif

#ifdef USE_GYRO_L3GD20
#include "drivers/accgyro/accgyro_spi_l3gd20.h"
#endif

#ifdef USE_GYRO_L3G4200D
#include "drivers/accgyro_legacy/accgyro_l3g4200d.h"
#endif

#include "drivers/accgyro/gyro_sync.h"

#include "fc/runtime_config.h"

#ifdef USE_DYN_NOTCH_FILTER
#include "flight/dyn_notch_filter.h"
#endif

#include "pg/gyrodev.h"

Expand Down

0 comments on commit 06d3f96

Please sign in to comment.