Files
paparazzi/conf/modules/imu_mpu6000.xml
T
Felix Ruess 17d32772c0 [imu] convert imu subsystems to modules (#1788)
* [imu] convert imu subsystems to modules

Also
- get rid of explicit imu init|event|periodic calls in main
- each imu implementation has their own imu_x_init/event/periodic

* [imu] fix some imu modules

* [imu] fix bad paths

* [imu] add imu_common module that every implementation autoloads

and put body_to_imu settings in imu_common module

* [imu] fix imu_ardrone2

* [conf] add imu_common settings module in conf_example and conf_tests
2016-08-12 12:02:38 +02:00

42 lines
1.8 KiB
XML

<!DOCTYPE module SYSTEM "module.dtd">
<module name="imu_mpu6000" dir="imu">
<doc>
<description>
IMU with MPU6000 via SPI.
</description>
<configure name="IMU_MPU_SPI_DEV" value="spi1" description="SPI device to use for MPU6000"/>
<configure name="IMU_MPU_SPI_SLAVE_IDX" value="SPI_SLAVE0" description="slave index of the MPU CS pin"/>
<define name="IMU_MPU_LOWPASS_FILTER" value="MPU60X0_DLPF_256HZ" description="DigitalLowPassFilter setting of the MPU"/>
<define name="IMU_MPU_SMPLRT_DIV" value="3" description="sample rate divider setting of the MPU"/>
<define name="IMU_MPU_GYRO_RANGE" value="MPU60X0_GYRO_RANGE_2000" description="gyroscope range setting of the MPU"/>
<define name="IMU_MPU_ACCEL_RANGE" value="MPU60X0_ACCEL_RANGE_16G" description="accelerometer range setting of the MPU"/>
</doc>
<autoload name="imu_common"/>
<autoload name="imu_nps"/>
<header>
<file name="imu_mpu6000.h" dir="subsystems/imu"/>
</header>
<init fun="imu_mpu_spi_init()"/>
<periodic fun="imu_mpu_spi_periodic()"/>
<event fun="imu_mpu_spi_event()"/>
<makefile target="!sim|nps|fbw">
<configure name="IMU_MPU_SPI_DEV" default="spi1" case="lower|upper"/>
<configure name="IMU_MPU_SPI_SLAVE_IDX" default="SPI_SLAVE0"/>
<define name="IMU_MPU_SPI_DEV" value="$(IMU_MPU_SPI_DEV_LOWER)"/>
<define name="USE_$(IMU_MPU_SPI_DEV_UPPER)"/>
<define name="IMU_MPU_SPI_SLAVE_IDX" value="$(IMU_MPU_SPI_SLAVE_IDX)"/>
<define name="USE_$(IMU_MPU_SPI_SLAVE_IDX)"/>
<define name="IMU_TYPE_H" value="subsystems/imu/imu_mpu6000.h" type="string"/>
<file name="mpu60x0.c" dir="peripherals"/>
<file name="mpu60x0_spi.c" dir="peripherals"/>
<file name="imu_mpu6000.c" dir="subsystems/imu"/>
<raw>
include $(CFG_SHARED)/spi_master.makefile
</raw>
</makefile>
</module>