User Manual Part 1

IS-900 User Guide Page 66 of 159
Data Items 5, 6, 7 Direction Cosines.
X-axis, Y-axis and Z-axis direction cosines can be used to
construct a 3x3 rotation matrix.
X direction cosines.
Y direction cosines.
Z direction cosines.
This matrix can also be constructed from Euler angles:
Data Item 11 Orientation Quaternion.
Quaternion is returned as q = [w, x, y, z]. Quaternion to
rotation matrix conversion can be accomplished using the
following formula:
Data Items 18, 19, 20 16 bit binary format.
16 bit binary format can be used in applications requiring
fastest possible serial I/O. Each floating point number is
stored in 2 bytes with only 14 bits containing actual data.
This results in lower accuracy than the standard IEEE
floating point format.
Data is 2’s-complement. The first byte of the data set has
its high-order bit set to 1; all others have them set to zero.
This can be used for data synchronization. Data is
returned low-order byte, then high-order byte. Use
following code sample as an example on how to decode
this format:
x1 x2 x3
y1 y2 y3
z1 z2 z3
1–2y
2
2z
2
2xy 2wz 2xz + 2wy
2xy + 2wz 1 2x
2
2z
2
2yz 2wx
2xz 2wy 2yz + 2wx 1 2x
2
2y
2
cos(P)*cos(Y) sin(R)*sin(P)*cos(Y) - cos(R)*sin(Y) cos(R)*sin(P)*cos(Y) + sin(R)*sin(Y)
cos(P)*sin(Y) sin(R)*sin(P)*sin(Y) + cos(R)*cos(Y) cos(R)*sin(P)*sin(Y) - sin(R)*cos(Y)
-sin(P) cos(P)*sin(R) cos(P)*cos(R)