Brian Silverman | 5f17a97 | 2016-02-28 01:49:32 -0500 | [diff] [blame] | 1 | package frc971; |
| 2 | |
| 3 | // Values returned from an IMU. |
| 4 | message IMUValues { |
| 5 | // Gyro readings in radians/second. |
| 6 | // Positive is clockwise looking at the connector. |
| 7 | float gyro_x; |
| 8 | // Positive is clockwise looking at the right side (from the connector). |
| 9 | float gyro_y; |
| 10 | // Positive is counterclockwise looking at the top. |
| 11 | float gyro_z; |
| 12 | |
| 13 | // Accelerometer readings in Gs. |
| 14 | // Positive is up. |
| 15 | float accelerometer_x; |
| 16 | // Positive is away from the right side (from the connector). |
| 17 | float accelerometer_y; |
| 18 | // Positive is away from the connector. |
| 19 | float accelerometer_z; |
| 20 | |
| 21 | // Magnetometer readings in gauss. |
| 22 | // Positive is up. |
| 23 | float magnetometer_x; |
| 24 | // Positive is away from the right side (from the connector). |
| 25 | float magnetometer_y; |
| 26 | // Positive is away from the connector. |
| 27 | float magnetometer_z; |
| 28 | |
| 29 | // Barometer readings in pascals. |
| 30 | float barometer; |
| 31 | |
| 32 | // Temperature readings in degrees Celsius. |
| 33 | float temperature; |
| 34 | |
| 35 | // FPGA timestamp when the values were captured. |
| 36 | double fpga_timestamp; |
| 37 | // CLOCK_MONOTONIC time in nanoseconds when the values were captured. |
| 38 | int64_t monotonic_timestamp_ns; |
| 39 | }; |
| 40 | |
| 41 | queue IMUValues imu_values; |