Skip to content

Commit

Permalink
AP_ExternalAHRS: added InertialLabs backend
Browse files Browse the repository at this point in the history
  • Loading branch information
tridge committed Dec 4, 2023
1 parent abd1ef8 commit d1afc6c
Show file tree
Hide file tree
Showing 5 changed files with 903 additions and 1 deletion.
6 changes: 6 additions & 0 deletions libraries/AP_ExternalAHRS/AP_ExternalAHRS.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
#include "AP_ExternalAHRS_backend.h"
#include "AP_ExternalAHRS_VectorNav.h"
#include "AP_ExternalAHRS_MicroStrain5.h"
#include "AP_ExternalAHRS_InertialLabs.h"

#include <GCS_MAVLink/GCS.h>
#include <AP_AHRS/AP_AHRS.h>
Expand Down Expand Up @@ -103,6 +104,11 @@ void AP_ExternalAHRS::init(void)
case DevType::MicroStrain5:
backend = new AP_ExternalAHRS_MicroStrain5(this, state);
return;
#endif
#if AP_EXTERNAL_AHRS_INERTIAL_LABS_ENABLED
case DevType::InertialLabs:
backend = new AP_ExternalAHRS_InertialLabs(this, state);
return;
#endif
}

Expand Down
9 changes: 8 additions & 1 deletion libraries/AP_ExternalAHRS/AP_ExternalAHRS.h
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,12 @@ class AP_ExternalAHRS {
#endif
#if AP_EXTERNAL_AHRS_MICROSTRAIN5_ENABLED
MicroStrain5 = 2,
#endif
#if AP_EXTERNAL_AHRS_INERTIAL_LABS_ENABLED
InertialLabs = 5,
#endif
// 3 reserved for AdNav
// 4 reserved for CINS
// 5 reserved for InertialLabs
// 6 reserved for Trimble
// 7 reserved for MicroStrain7
// 8 reserved for SBG
Expand Down Expand Up @@ -154,6 +156,11 @@ class AP_ExternalAHRS {
float temperature;
} ins_data_message_t;

typedef struct {
float differential_pressure; // Pa
float temperature; // degC
} airspeed_data_message_t;

protected:

enum class OPTIONS {
Expand Down
Loading

0 comments on commit d1afc6c

Please sign in to comment.