2 * This file is part of INAV Project.
4 * This Source Code Form is subject to the terms of the Mozilla Public
5 * License, v. 2.0. If a copy of the MPL was not distributed with this file,
6 * You can obtain one at http://mozilla.org/MPL/2.0/.
8 * Alternatively, the contents of this file may be used under the terms
9 * of the GNU General Public License Version 3, as described below:
11 * This file is free software: you may copy, redistribute and/or modify
12 * it under the terms of the GNU General Public License as published by the
13 * Free Software Foundation, either version 3 of the License, or (at your
14 * option) any later version.
16 * This file is distributed in the hope that it will be useful, but
17 * WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
19 * Public License for more details.
21 * You should have received a copy of the GNU General Public License
22 * along with this program. If not, see http://www.gnu.org/licenses/.
27 // Deprecated USE_GYRO/ACC defines
28 #if defined (USE_GYRO) || defined (USE_ACC)
29 #error "Unnecessary USE_ACC and/or USE_GYRO"
32 #if defined (USE_GYRO_MPU6000) || defined (USE_ACC_MPU6000) || defined (USE_GYRO_MPU6050) || defined (USE_ACC_MPU6050)
33 #error "Replace USE_GYRO_xxx and USE_ACC_xxx with USE_IMU_xxx"
36 #if defined (USE_GYRO_MPU6500) || defined (USE_ACC_MPU6500) || defined (USE_GYRO_MPU9250) || defined (USE_ACC_MPU9250)
37 #error "Replace USE_GYRO_xxx and USE_ACC_xxx with USE_IMU_xxx"
40 #if defined (USE_GYRO_ICM20689) || defined (USE_ACC_ICM20689)
41 #error "Replace USE_GYRO_xxx and USE_ACC_xxx with USE_IMU_xxx"
44 #if defined (USE_FAKE_GYRO) || defined (USE_FAKE_ACC)
45 #error "Replace USE_GYRO_xxx and USE_ACC_xxx with USE_IMU_xxx"
48 #if defined (USE_ACC_LSM303DLHC) || defined (USE_ACC_BMI160)
49 #error "Replace USE_GYRO_xxx and USE_ACC_xxx with USE_IMU_xxx"
52 // Make sure IMU alignments are migrated to IMU_xxx_ALIGN
53 #if defined (GYRO_MPU6050_ALIGN) || defined (ACC_MPU6050_ALIGN)
54 #error "Replace GYRO_MPU6050_ALIGN and ACC_MPU6050_ALIGN with IMU_MPU6050_ALIGN"
57 #if defined (GYRO_MPU6000_ALIGN) || defined (ACC_MPU6000_ALIGN)
58 #error "Replace GYRO_MPU6000_ALIGN and ACC_MPU6000_ALIGN with IMU_MPU6000_ALIGN"
61 #if defined (GYRO_MPU6500_ALIGN) || defined (ACC_MPU6500_ALIGN)
62 #error "Replace GYRO_MPU6500_ALIGN and ACC_MPU6500_ALIGN with IMU_MPU6500_ALIGN"
65 #if defined (GYRO_MPU9250_ALIGN) || defined (ACC_MPU9250_ALIGN)
66 #error "Replace GYRO_MPU9250_ALIGN and ACC_MPU9250_ALIGN with IMU_MPU9250_ALIGN"
69 #if defined (GYRO_BMI160_ALIGN) || defined (ACC_BMI160_ALIGN)
70 #error "Replace GYRO_BMI160_ALIGN and ACC_BMI160_ALIGN with IMU_BMI160_ALIGN"
73 #if defined (GYRO_ICM20689_ALIGN) || defined (ACC_ICM20689_ALIGN)
74 #error "Replace GYRO_ICM20689_ALIGN and ACC_ICM20689_ALIGN with IMU_ICM20689_ALIGN"
77 #if defined (GYRO_MPU3050_ALIGN)
78 #error "Replace GYRO_MPU3050_ALIGN with IMU_MPU3050_ALIGN"
81 #if defined (GYRO_L3GD20_ALIGN)
82 #error "Replace GYRO_L3GD20_ALIGN with IMU_L3GD20_ALIGN"
85 #if defined (ACC_LSM303DLHC_ALIGN)
86 #error "Replace ACC_LSM303DLHC_ALIGN with IMU_LSM303DLHC_ALIGN"