This commit is contained in:
2024-09-26 22:32:20 +08:00
commit 097089ef4e
323 changed files with 135661 additions and 0 deletions
+52
View File
@@ -0,0 +1,52 @@
#ifndef __INERTIALSENSOR_ADIS1647x_H__
#define __INERTIALSENSOR_ADIS1647x_H__
#include "SPIDevice.h"
#include "GPIO_EXTI.h"
#include <stdint.h>
#include <stdbool.h>
typedef struct
{
const char *name;
bool success;
int crc_err;
int seq_err;
int comm_err;
int good_cnt;
int crc_pps;
int seq_pps;
int comm_pps;
int good_pps;
SPI_DEV_t *dev;
GPIO_EXIT_t *drdy;
uint16_t last_counter;
bool done_first_read;
float temp_sum;
uint8_t temp_count;
float accel_scale;
float gyro_scale;
float _clip_limit;
float accel[3];
float gyro[3];
float temp;
uint8_t seq;
} InertialSensor_ADIS1647x_t;
bool InertialSensor_ADIS1647x_init(InertialSensor_ADIS1647x_t *imu,
const char *name,
SPI_DEV_t *dev,
GPIO_EXIT_t *drdy);
void InertialSensor_ADIS1647x_loop(InertialSensor_ADIS1647x_t *imu);
void InertialSensor_ADIS1647x_update(InertialSensor_ADIS1647x_t *imu);
void InertialSensor_ADIS1647x_monitor(InertialSensor_ADIS1647x_t *imu);
#endif /* __INERTIALSENSOR_ADIS1647x_H__ */