Laelaps  2.3.5
RoadNarrows Robotics Small Outdoor Mobile Robot Project
laeImu.h File Reference

Laelaps built-in Inertial Measurement Unit class interface. More...

#include <pthread.h>
#include <string>
#include "rnr/rnrconfig.h"
#include "Laelaps/laelaps.h"
#include "Laelaps/laeDesc.h"
#include "Laelaps/laeTune.h"

Go to the source code of this file.

Classes

class  sensor::imu::Quaternion
 Quaternion class. More...
 
class  sensor::imu::LaeImu
 
struct  sensor::imu::msp::MspIdent
 Board identity structure. More...
 
class  sensor::imu::LaeImuCleanFlight
 

Namespaces

 sensor
 The sensor namespace.
 
 sensor::imu::msp
 Multiwii Serial Protocal Interface.
 

Macros

#define STATIC_STR   static const char* const
 

Enumerations

enum  sensor::imu::Axis {
  sensor::imu::X = 0,
  sensor::imu::Y = 1,
  sensor::imu::Z = 2
}
 Axes indices. More...
 
enum  sensor::imu::RPY {
  sensor::imu::ROLL = 0,
  sensor::imu::PITCH = 1,
  sensor::imu::YAW = 2
}
 Roll, pitch, and yaw indices. More...
 

Variables

const int sensor::imu::NumOfAxes = 3
 maximum number of axes per sensor component.
 
static const char *const sensor::imu::msp::MspPreamble = "$M"
 message preamble
 
static const char *const sensor::imu::msp::MspDirTo = "<"
 to imu
 
static const char *const sensor::imu::msp::MspDirFrom = ">"
 from imu
 
static const char *const sensor::imu::msp::MspCmdPreamble = "$M<"
 command preamble
 
static const char *const sensor::imu::msp::MspRspPreamble = "$M>"
 response preamble
 
static const int sensor::imu::msp::MspFieldPosDir = 3
 dir field position
 
static const int sensor::imu::msp::MspFieldPosSize = 3
 data size field position
 
static const int sensor::imu::msp::MspFieldPosCmdId = 4
 command id field position
 
static const int sensor::imu::msp::MspFieldPosDataStart = 5
 data start field position
 
static const int sensor::imu::msp::MspCmdHdrLen = 5
 command header len
 
static const int sensor::imu::msp::MspCmdMinLen = 6
 MspCmdHdrLen+1 command min len.
 
static const int sensor::imu::msp::MspCmdMaxLen = 32
 response max len
 
static const int sensor::imu::msp::MspRspHdrLen = 5
 response header len
 
static const int sensor::imu::msp::MspRspMinLen = 6
 MspRspHdrLen+1 response min len.
 
static const int sensor::imu::msp::MspRspMaxLen = 32
 response max len
 
static const uint_t sensor::imu::msp::MspCmdIdIdent = 100
 read board/sensor idents
 
static const uint_t sensor::imu::msp::MspCmdIdRawImu = 102
 read raw imu data
 
static const uint_t sensor::imu::msp::MspCmdIdAttitude = 108
 read raw attitude data
 
static const double sensor::imu::msp::MspGToMPerSec2 = 9.80665
 standard g in m/s^2
 
static const double sensor::imu::msp::MspMpu6050RawToG = 1.0 / 512.0
 MPU-6050 acceleration raw value to g's.
 
static const double sensor::imu::msp::MspMpu6050RawToDegPerSec = 1.0 / 4.096
 MPU-6050 rotation raw value to degrees/second.
 
static const double sensor::imu::msp::MspAttitudeRawToDeg = 0.1
 board computed attitude raw value to degreess
 

Detailed Description

Laelaps built-in Inertial Measurement Unit class interface.

The current Laelaps uses the open-source CleanFlight firmware loaded on a Naze32 controller. The interface is serial USB.

See also
https://github.com/cleanflight
Author
Robin Knight (robin.nosp@m..kni.nosp@m.ght@r.nosp@m.oadn.nosp@m.arrow.nosp@m.s.co.nosp@m.m)
Copyright
© 2015-2017. RoadNarrows LLC.
http://www.roadnarrows.com
All Rights Reserved

Definition in file laeImu.h.

Enumeration Type Documentation

Axes indices.

Enumerator

x axis index

y axis index

z axis index

Definition at line 91 of file laeImu.h.

92  {
93  X = 0, ///< x axis index
94  Y = 1, ///< y axis index
95  Z = 2 ///< z axis index
96  };
z axis index
Definition: laeImu.h:95
x axis index
Definition: laeImu.h:93
y axis index
Definition: laeImu.h:94

Roll, pitch, and yaw indices.

Enumerator
ROLL 

roll index

PITCH 

pitch index

YAW 

yaw index

Definition at line 103 of file laeImu.h.

104  {
105  ROLL = 0, ///< roll index
106  PITCH = 1, ///< pitch index
107  YAW = 2 ///< yaw index
108  };
yaw index
Definition: laeImu.h:107
roll index
Definition: laeImu.h:105
pitch index
Definition: laeImu.h:106