初始版本

This commit is contained in:
2026-04-23 14:02:03 +08:00
parent d68cb4273f
commit bbd563b069
121 changed files with 94711 additions and 0 deletions
+24
View File
@@ -0,0 +1,24 @@
#ifndef _IMU_H_
#define _IMU_H_
#include <math.h>
#define PI 3.14159265358979323846f
#define RAD_TO_DEG 57.2957795 // 弧度到度的转换系数
#define DEG_TO_RAD 0.0174533 // 度到弧度的转换系数
// 定义欧拉角结构体
typedef struct {
volatile float roll, pitch, yaw;//弧度
}Rad_T, *RadDp;
typedef struct {
volatile float roll, pitch, yaw;//角度
}Deg_T, *DegDp;
#define Imu_AccFilterSize 10
#define Imu_MagFilterSize 20
#define Imu_GyroFilterSize 10
void IMU_Update(float *gy,float *acc, float *mag, RadDp Rad, DegDp Deg);
#endif