MotionAC Software Library: algorithms/Middlewares/ST/STM32_MotionAC_Library/Inc/motion_ac.h Source File

Motion AC

MotionAC Software Library
MotionAC Software Library Documentation
motion_ac.h
Go to the documentation of this file.
1 
38 /* Define to prevent recursive inclusion -------------------------------------*/
39 #ifndef _MOTION_AC_H_
40 #define _MOTION_AC_H_
41 
42 #ifdef __cplusplus
43 extern "C"
44 {
45 #endif
46 
47 /* Includes ------------------------------------------------------------------*/
48 #include <stdint.h>
49 
58 /* Exported types ------------------------------------------------------------*/
59 
64 typedef enum
65 {
71 
72 typedef struct
73 {
74  float Acc[3]; /* Acceleration in X, Y, Z axis in [g] */
75  int TimeStamp; /* Time stamp for accelerometer sensor output in [ms] */
76 } MAC_input_t;
77 
78 typedef struct
79 {
80  float AccBias[3]; /* Accelerometer offset value in [g] */
81  float SF_Matrix[3][3]; /* Scale factor correction matrix (diagonal matrix) */
82  MAC_CalQuality_t CalQuality; /* Quality factor */
83 } MAC_output_t;
84 
89 /* Exported constants --------------------------------------------------------*/
90 /* Exported variables --------------------------------------------------------*/
91 /* Exported macro ------------------------------------------------------------*/
92 
97 /* Exported functions ------------------------------------------------------- */
98 
105 void MotionAC_Initialize(int sampletime, unsigned short int enable);
106 
112 void MotionAC_Update(MAC_input_t *data_in);
113 
119 void MotionAC_GetCalParams(MAC_output_t *data_out);
120 
126 uint8_t MotionAC_GetLibVersion(char *version);
127 
140 #ifdef __cplusplus
141 }
142 #endif
143 
144 #endif /* _MOTION_AC_H_ */
145 
146 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
void MotionAC_Initialize(int sampletime, unsigned short int enable)
Initialize the MotionAC engine.
void MotionAC_Update(MAC_input_t *data_in)
Run accelerometer calibration algorithm.
MAC_CalQuality_t
Definition: motion_ac.h:64
void MotionAC_GetCalParams(MAC_output_t *data_out)
Get the accelerometer compensation parameters.
uint8_t MotionAC_GetLibVersion(char *version)
Get the library version.
MAC_CalQuality_t CalQuality
Definition: motion_ac.h:82
int TimeStamp
Definition: motion_ac.h:75
Generated on Fri Mar 31 2017 10:53:54 for MotionAC Software Library by   doxygen 1.8.9.1