M5Unit-IMU 0.0.2 git rev:e5b00aa
Loading...
Searching...
No Matches
m5::unit::UnitDoF9 Class Reference

Unit DoF9: BMI270 + BMM350, both directly on the GROVE main bus (no AUX bypass). The BMI270 address is SW1-selectable (0x68 default / 0x69); pass it to the constructor (e.g. from bmi270::detectAddress). BMM350 is fixed at 0x14. Add imu() and mag() to an AhrsController. More...

#include <unit_dof9.hpp>

Inheritance diagram for m5::unit::UnitDoF9:

Public Member Functions

 UnitDoF9 (const uint8_t bmi_addr=0x68)
 Construct with the BMI270's I2C address (the composite children derive from this)
 
virtual ~UnitDoF9 ()
 Destructor.
 
UnitBMI270 & imu ()
 Accel/gyro sub-unit (add to an AhrsController)
 
UnitBMM350 & mag ()
 Magnetometer sub-unit (add to an AhrsController)
 
virtual bool begin () override
 Begin: children are begun by the framework (all on the shared bus, any order)
 

Protected Member Functions

virtual std::shared_ptr< Adapter > ensure_adapter (const uint8_t ch) override
 

Detailed Description

Unit DoF9: BMI270 + BMM350, both directly on the GROVE main bus (no AUX bypass). The BMI270 address is SW1-selectable (0x68 default / 0x69); pass it to the constructor (e.g. from bmi270::detectAddress). BMM350 is fixed at 0x14. Add imu() and mag() to an AhrsController.

Constructor & Destructor Documentation

◆ UnitDoF9()

m5::unit::UnitDoF9::UnitDoF9 ( const uint8_t bmi_addr = 0x68)
explicit

Construct with the BMI270's I2C address (the composite children derive from this)

Parameters
[in]bmi_addrBMI270 I2C address (defaults to 0x68)