remove unused vector.[ch]
[protos/imu.git] / MadgwickAHRS.h
1 /*\r
2  * Copyright (c) 2014, Olivier MATZ <zer0@droids-corp.org>\r
3  * Copyright (c) 2011, SOH Madgwick\r
4  *\r
5  *  This program is free software: you can redistribute it and/or modify\r
6  *  it under the terms of the GNU General Public License as published by\r
7  *  the Free Software Foundation, either version 3 of the License, or\r
8  *  (at your option) any later version.\r
9  *\r
10  *  This program is distributed in the hope that it will be useful,\r
11  *  but WITHOUT ANY WARRANTY; without even the implied warranty of\r
12  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\r
13  *  GNU General Public License for more details.\r
14  *\r
15  *  You should have received a copy of the GNU General Public License\r
16  *  along with this program.  If not, see <http://www.gnu.org/licenses/>.\r
17  *\r
18  */\r
19 \r
20 //=============================================================================\r
21 // MadgwickAHRS.h\r
22 //=============================================================================\r
23 //\r
24 // Implementation of Madgwick's IMU and AHRS algorithms.\r
25 // See: http://www.x-io.co.uk/node/8#open_source_ahrs_and_imu_algorithms\r
26 //\r
27 // Date                 Author          Notes\r
28 // 29/09/2011   SOH Madgwick    Initial release\r
29 // 02/10/2011   SOH Madgwick    Optimised for reduced CPU load\r
30 //\r
31 //=============================================================================\r
32 \r
33 #ifndef MadgwickAHRS_h\r
34 #define MadgwickAHRS_h\r
35 \r
36 #include "imu.h"\r
37 \r
38 extern volatile float beta;  // algorithm gain\r
39 \r
40 /* update quaternion structure using the new IMU infos */\r
41 void MadgwickAHRSupdate(const struct imu_info *imu, struct quaternion *quat);\r
42 \r
43 /* update quaternion structure using the new IMU infos, without using magneto */\r
44 void MadgwickAHRSupdateIMU(const struct imu_info *imu, struct quaternion *quat);\r
45 \r
46 #endif\r