Boboter
Loading...
Searching...
No Matches
Device::Imu Class Reference

#include <imu.h>

Public Member Functions

 Imu (Robot &robot)
 ~Imu ()
void initialize ()
 Sets up the necessary I2C channel.
void read_fifo_buffer ()
 Reads the current FIFO buffer from the IMUs DMP (digital motion processor).
quaternion get_quaternion () const
 Retrieves the quaternion from the last measurement.
vector3 get_gyro_values () const
 Retrieves the gyro values from the last measurement.

Constructor & Destructor Documentation

◆ Imu()

Device::Imu::Imu ( Robot & robot)
explicit

◆ ~Imu()

Device::Imu::~Imu ( )

Member Function Documentation

◆ get_gyro_values()

vector3 Device::Imu::get_gyro_values ( ) const
inlinenodiscard

Retrieves the gyro values from the last measurement.

Returns
A 3D vector struct of the x, y and z components of the gyroscope

◆ get_quaternion()

quaternion Device::Imu::get_quaternion ( ) const
inlinenodiscard

Retrieves the quaternion from the last measurement.

Returns
The last read quaternion

◆ initialize()

void Device::Imu::initialize ( )

Sets up the necessary I2C channel.

◆ read_fifo_buffer()

void Device::Imu::read_fifo_buffer ( )

Reads the current FIFO buffer from the IMUs DMP (digital motion processor).


The documentation for this class was generated from the following files: