summaryrefslogtreecommitdiff
path: root/RocketViewImuNode.mdwn
blob: 7a2dd291806a447b7d7da288f6dfa79f000a70e5 (plain)
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
# <a name="Inertial Measurement Unit Displa"></a> Inertial Measurement Unit Display in rocketview

Note: Message IDs are described in the form `DEFINED_MESSAGE_NAME = [16bit ID] = [11bit ID] [RTR] [length] [byte0] ... [byte7]`, where the 16bit ID is the 16 bit "packed value" of the ID (11 bits CAN ID + 1 bit RTR + 4 bits length).

If the data is unkown - e.g., because a message has not been received which sets this data - then display a dash(-).

**_Note:_** Ian came up with a good idea, which is to integrate this display with the 6 strip charts. There's no reason the IMU needs its own box, so if the IMU mode can be integrated with the stripcharts as a header (or bounding box) and the text can be added to each strip charts, that would be great. The temperature could be added between the bouning box and the first strip chart, maybe.

<table border=1>
  <tr>
    <td><pre>
IMU Node ([-|Safe|Armed])

Temp:  [-|xx.x deg. C]

X acc: [-|xxx.x g]
Y acc: [-|xxx.x g]
Z acc: [-|xxx.x g]

R vel: [-| xxx.x deg/s]
P vel: [-| xxx.x deg/s]
Y vel: [-| xxx.x deg/s]
</pre></td>
  </tr>
</table>

Here's how to map CAN messages to the display:

The IMU node's mode is set by `IMU_REPORT_MODE = 1B61 = DB 0 1 [mode]` where `mode` is:

- 0x20= `'Safe'`
- 0x2F= `'Armed'`

`temp` (the temperature of the IMU) is set by `TEMP_REPORT_DATA = 6B22 = 359 0 2 [MSB] [LSB]` where:

                                           3487.972309658033
    Internal Temp.[K] = ------------------------------------------------------
                         Log[ (3.116381893600779E8 / counts) - 252811.23882451496 ]

Accelerometers and gyros TBD: strip charts? Or display here?