Paparazzi UAS  v5.10_stable-5-g83a0da5-dirty
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
imu_hbmini.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2011 Paparazzi Team
3  * Derived from Aspirin, NavGo and ppzuavimu drivers
4  *
5  * This file is part of paparazzi.
6  *
7  * paparazzi is free software; you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation; either version 2, or (at your option)
10  * any later version.
11  *
12  * paparazzi is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with paparazzi; see the file COPYING. If not, write to
19  * the Free Software Foundation, 59 Temple Place - Suite 330,
20  * Boston, MA 02111-1307, USA.
21  */
22 
33 #ifndef IMU_HBMINI_H
34 #define IMU_HBMINI_H
35 
36 #include "std.h"
37 #include "generated/airframe.h"
38 #include "subsystems/imu.h"
39 
40 #include "peripherals/max1168.h"
41 #include "peripherals/hmc58xx.h"
42 
43 // Default configuration
44 #if !defined IMU_GYRO_P_SIGN & !defined IMU_GYRO_Q_SIGN & !defined IMU_GYRO_R_SIGN
45 #define IMU_GYRO_P_SIGN -1
46 #define IMU_GYRO_Q_SIGN 1
47 #define IMU_GYRO_R_SIGN -1
48 #endif
49 #if !defined IMU_ACCEL_X_SIGN & !defined IMU_ACCEL_Y_SIGN & !defined IMU_ACCEL_Z_SIGN
50 #define IMU_ACCEL_X_SIGN 1
51 #define IMU_ACCEL_Y_SIGN -1
52 #define IMU_ACCEL_Z_SIGN -1
53 #endif
54 #if !defined IMU_MAG_X_SIGN & !defined IMU_MAG_Y_SIGN & !defined IMU_MAG_Z_SIGN
55 #define IMU_MAG_X_SIGN -1
56 #define IMU_MAG_Y_SIGN -1
57 #define IMU_MAG_Z_SIGN -1
58 #endif
59 
60 
61 struct ImuHbmini {
62  struct Hmc58xx hmc;
63 };
64 
65 extern struct ImuHbmini imu_hbmini;
66 
67 extern void imu_hbmini_init(void);
68 extern void imu_hbmini_periodic(void);
69 extern void imu_hbmini_event(void);
70 extern void imu_hbmini_downlink_raw(void);
71 
72 #endif
struct Hmc58xx hmc
Definition: imu_hbmini.h:62
void imu_hbmini_downlink_raw(void)
Definition: imu_hbmini.c:84
Inertial Measurement Unit interface.
struct ImuHbmini imu_hbmini
Definition: imu_hbmini.c:61
void imu_hbmini_event(void)
Definition: imu_hbmini.c:93
void imu_hbmini_init(void)
Definition: imu_hbmini.c:63
void imu_hbmini_periodic(void)
Definition: imu_hbmini.c:72