-
Notifications
You must be signed in to change notification settings - Fork 0
/
orientation.h
107 lines (93 loc) · 4.38 KB
/
orientation.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
/*
* Copyright (C) 2015-2018 Swift Navigation Inc.
* Contact: Swift Navigation <[email protected]>
*
* This source is subject to the license found in the file 'LICENSE' which must
* be be distributed together with this source. All other rights reserved.
*
* THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND,
* EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR PURPOSE.
*/
/*****************************************************************************
* Automatically generated from yaml/swiftnav/sbp/orientation.yaml
* with generate.py. Please do not hand edit!
*****************************************************************************/
/** \defgroup orientation Orientation
*
* * Orientation Messages
* \{ */
#ifndef LIBSBP_ORIENTATION_MESSAGES_H
#define LIBSBP_ORIENTATION_MESSAGES_H
#include "common.h"
/** Heading relative to True North
*
* This message reports the baseline heading pointing from the base station
* to the rover relative to True North. The full GPS time is given by the
* preceding MSG_GPS_TIME with the matching time-of-week (tow). It is intended
* that time-matched RTK mode is used when the base station is moving.
*/
#define SBP_MSG_BASELINE_HEADING 0x020F
typedef struct {
u32 tow; /**< GPS Time of Week [ms] */
u32 heading; /**< Heading [mdeg] */
u8 n_sats; /**< Number of satellites used in solution */
u8 flags; /**< Status flags */
} msg_baseline_heading_t;
/** Quaternion 4 component vector
*
* This message reports the quaternion vector describing the vehicle body frame's orientation
* with respect to a local-level NED frame. The components of the vector should sum to a unit
* vector assuming that the LSB of each component as a value of 2^-31.
*/
#define SBP_MSG_ORIENT_QUAT 0x0220
typedef struct {
u32 tow; /**< GPS Time of Week [ms] */
s32 w; /**< Real component [2^-31] */
s32 x; /**< 1st imaginary component [2^-31] */
s32 y; /**< 2nd imaginary component [2^-31] */
s32 z; /**< 3rd imaginary component [2^-31] */
float acc_w; /**< Estimated standard deviation of w [N/A] */
float acc_x; /**< Estimated standard deviation of x [N/A] */
float acc_y; /**< Estimated standard deviation of y [N/A] */
float acc_z; /**< Estimated standard deviation of z [N/A] */
u8 flags; /**< Status flags */
} msg_orient_quat_t;
/** Euler angles
*
* This message reports the yaw, pitch, and roll angles of the vehicle body frame.
* The rotations should applied intrinsically in the order yaw, pitch, and roll
* in order to rotate the from a frame aligned with the local-level NED frame
* to the vehicle body frame.
*/
#define SBP_MSG_ORIENT_EULER 0x0221
typedef struct {
u32 tow; /**< GPS Time of Week [ms] */
s32 roll; /**< rotation about the forward axis of the vehicle [microdegrees] */
s32 pitch; /**< rotation about the rightward axis of the vehicle [microdegrees] */
s32 yaw; /**< rotation about the downward axis of the vehicle [microdegrees] */
float var_roll; /**< Estimated standard deviation of roll [degrees] */
float var_pitch; /**< Estimated standard deviation of pitch [degrees] */
float var_yaw; /**< Estimated standard deviation of yaw [degrees] */
u8 flags; /**< Status flags */
} msg_orient_euler_t;
/** Vehicle Body Frame instantaneous angular rates
*
* This message reports the orientation rates in the vehicle body frame.
* The values represent the measurements a strapped down gyroscope would
* make and are not equivalent to the time derivative of the Euler angles.
* The orientation and origin of the user frame is specified via device settings.
* By convention, the vehicle x-axis is expected to be aligned with the forward
* direction, while the vehicle y-axis is expected to be aligned with the right
* direction, and the vehicle z-axis should be aligned with the down direction.
*/
#define SBP_MSG_ANGULAR_RATE 0x0222
typedef struct {
u32 tow; /**< GPS Time of Week [ms] */
s32 x; /**< angular rate about x axis [microdegrees/s] */
s32 y; /**< angular rate about y axis [microdegrees/s] */
s32 z; /**< angular rate about z axis [microdegrees/s] */
u8 flags; /**< Status flags */
} msg_angular_rate_t;
/** \} */
#endif /* LIBSBP_ORIENTATION_MESSAGES_H */