Witmotion IMU Library  1.3.1~dev_4684448
Open source UART communication library for sensor devices manufactured by WitMotion Shenzhen Co.,Ltd
types.h File Reference

Abstract types collection for Witmotion sensor library. More...

#include <cmath>
#include <set>
#include <inttypes.h>
#include <QtCore>
#include <QSerialPort>
#include "witmotion/version.h"
Include dependency graph for types.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  witmotion::witmotion_datapacket
 Generic structure respresenting the standard 11-byte datapacket defined in Witmotion protocol. More...
 
struct  witmotion::witmotion_config_packet
 Generic structure respresenting the standard 5-byte configuration command defined in Witmotion protocol. More...
 
class  witmotion::QAbstractWitmotionSensorReader
 Abstract base class to program convenience classes for the sensors. More...
 

Namespaces

 witmotion
 Main namespace of Witmotion UART connection library.
 

Enumerations

enum  witmotion::witmotion_packet_id {
  witmotion::pidRTC = 0x50 ,
  witmotion::pidAcceleration = 0x51 ,
  witmotion::pidAngularVelocity = 0x52 ,
  witmotion::pidAngles = 0x53 ,
  witmotion::pidMagnetometer = 0x54 ,
  witmotion::pidDataPortStatus = 0x55 ,
  witmotion::pidAltimeter = 0x56 ,
  witmotion::pidGPSCoordinates = 0x57 ,
  witmotion::pidGPSGroundSpeed = 0x58 ,
  witmotion::pidOrientation = 0x59 ,
  witmotion::pidGPSAccuracy = 0x5A
}
 Packet type IDs from the vendor-defined protocol. More...
 
enum  witmotion::witmotion_config_register_id {
  witmotion::ridSaveSettings = 0x00 ,
  witmotion::ridCalibrate = 0x01 ,
  witmotion::ridOutputValueSet = 0x02 ,
  witmotion::ridOutputFrequency = 0x03 ,
  witmotion::ridPortBaudRate = 0x04 ,
  witmotion::ridAccelerationBiasX = 0x05 ,
  witmotion::ridAccelerationBiasY = 0x06 ,
  witmotion::ridAccelerationBiasZ = 0x07 ,
  witmotion::ridAngularVelocityBiasX = 0x08 ,
  witmotion::ridAngularVelocityBiasY = 0x09 ,
  witmotion::ridAngularVelocityBiasZ = 0x0A ,
  witmotion::ridMagnetometerBiasX = 0x0B ,
  witmotion::ridMagnetometerBiasY = 0x0C ,
  witmotion::ridMagnetometerBiasZ = 0x0D ,
  witmotion::ridPortModeD0 = 0x0E ,
  witmotion::ridPortModeD1 = 0x0F ,
  witmotion::ridPortModeD2 = 0x10 ,
  witmotion::ridPortModeD3 = 0x11 ,
  witmotion::ridPortPWMLevelD0 = 0x12 ,
  witmotion::ridPortPWMLevelD1 = 0x13 ,
  witmotion::ridPortPWMLevelD2 = 0x14 ,
  witmotion::ridPortPWMLevelD3 = 0x15 ,
  witmotion::ridPortPWMPeriodD0 = 0x16 ,
  witmotion::ridPortPWMPeriodD1 = 0x17 ,
  witmotion::ridPortPWMPeriodD2 = 0x18 ,
  witmotion::ridPortPWMPeriodD3 = 0x19 ,
  witmotion::ridIICAddress = 0x1A ,
  witmotion::ridLED = 0x1B ,
  witmotion::ridGPSBaudRate = 0x1C ,
  witmotion::ridFilterBandwidth = 0x1F ,
  witmotion::ridGyroscopeRange = 0x20 ,
  witmotion::ridAccelerometerRange = 0x21 ,
  witmotion::ridStandbyMode = 0x22 ,
  witmotion::ridInstallationDirection = 0x23 ,
  witmotion::ridTransitionAlgorithm = 0x24 ,
  witmotion::ridInstructionStart = 0x2D ,
  witmotion::ridTimeYearMonth = 0x30 ,
  witmotion::ridTimeDayHour = 0x31 ,
  witmotion::ridTimeMinuteSecond = 0x32 ,
  witmotion::ridTimeMilliseconds = 0x33 ,
  witmotion::ridSetAccelerationX = 0x34 ,
  witmotion::ridSetAccelerationY = 0x35 ,
  witmotion::ridSetAccelerationZ = 0x36 ,
  witmotion::ridSetAngularVelocityX = 0x37 ,
  witmotion::ridSetAngularVelocityY = 0x38 ,
  witmotion::ridSetAngularVelocityZ = 0x39 ,
  witmotion::ridSetMagnetometerX = 0x3A ,
  witmotion::ridSetMagnetometerY = 0x3B ,
  witmotion::ridSetMagnetometerZ = 0x3C ,
  witmotion::ridSetAngleRoll = 0x3D ,
  witmotion::ridSetAnglePitch = 0x3E ,
  witmotion::ridSetAngleYaw = 0x3F ,
  witmotion::ridSetTemperature = 0x40 ,
  witmotion::ridSetPortStatusD0 = 0x41 ,
  witmotion::ridSetPortStatusD1 = 0x42 ,
  witmotion::ridSetPortStatusD2 = 0x43 ,
  witmotion::ridSetPortStatusD3 = 0x44 ,
  witmotion::ridSetPressureLow = 0x45 ,
  witmotion::ridSetPressureHigh = 0x46 ,
  witmotion::ridSetAltitudeLow = 0x47 ,
  witmotion::ridSetAltitudeHigh = 0x48 ,
  witmotion::ridSetLongitudeLow = 0x49 ,
  witmotion::ridSetLongitudeHigh = 0x4A ,
  witmotion::ridSetLatitudeLow = 0x4B ,
  witmotion::ridSetLatitudeHigh = 0x4C ,
  witmotion::ridSetGPSAltitude = 0x4D ,
  witmotion::ridSetGPSYaw = 0x4E ,
  witmotion::ridSetGPSGroundSpeedLow = 0x4F ,
  witmotion::ridSetGPSGroundSpeedHigh = 0x50 ,
  witmotion::ridSetOrientationX = 0x51 ,
  witmotion::ridSetOrientationY = 0x52 ,
  witmotion::ridSetOrientationZ = 0x53 ,
  witmotion::ridSetOrientationW = 0x54 ,
  witmotion::ridGyroscopeAutoCalibrate = 0x63 ,
  witmotion::ridUnlockConfiguration = 0x69
}
 List of configuration slots (registers) available for the library. More...
 

Variables

static const uint8_t witmotion::WITMOTION_HEADER_BYTE = 0x55
 Packet header byte value (vendor protocol-specific)
 
static const uint8_t witmotion::WITMOTION_CONFIG_HEADER = 0xFF
 Configuration header byte value (vendor protocol-specific)
 
static const uint8_t witmotion::WITMOTION_CONFIG_KEY = 0xAA
 Configuration marker key byte value (vendor protocol-specific)
 
static const std::set< size_t > witmotion::witmotion_registered_ids
 Packet ID set to retrieve descriptions via witmotion_packet_descriptions. More...
 
static const std::map< uint8_t, std::string > witmotion::witmotion_packet_descriptions
 Packet ID string set to store built-in descriptions for message-enumerator. More...
 

Detailed Description

Author
Andrey Vukolov andre.nosp@m.y.vu.nosp@m.kolov.nosp@m.@ele.nosp@m.ttra..nosp@m.eu

This header file contains all abstract types and hardware-defined constants to operate Witmotion sensor device.