X-IO x-IMU3 User manual

x-IMU3 User Manual v0.5
July 7, 2020
x-IMU3 User Manual
v0.5
July 7, 2020
x-io Technologies
1

x-IMU3 User Manual v0.5
July 7, 2020
Contents
1 Overview 5
2 Hardware 6
3 Technical specification 7
3.1 Sensors ............................................... 7
3.1.1 Gyroscope.......................................... 7
3.1.2 Accelerometer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
3.1.3 Magnetometer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
3.1.4 High-g accelerometer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
3.1.5 Temperature sensor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
4 LED 9
5 Bluetooth 9
6 Message rates 9
7 Communication protocol 9
7.1 Command messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
7.1.1 Read setting command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
7.1.2 Write setting command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
7.1.3 Default command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
7.1.4 Apply command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
7.1.5 Save command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
7.1.6 Read time command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
7.1.7 Write time command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
7.1.8 Ping command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
7.1.9 Ping response . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
7.1.10 Reset command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
7.1.11 Shutdown command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
7.1.12 Strobe command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
7.1.13 Serial accessory command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
7.1.14 Note command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
7.1.15 Self-test command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
7.1.16 Result command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
7.1.17 Result response . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
7.1.18 Bootloader command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
7.2 Data messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
7.2.1 Byte stuffing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
7.2.2 Inertial message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
7.2.3 Magnetometer message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
7.2.4 Quaternion message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
7.2.5 Rotation matrix message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
7.2.6 Euler angles message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
7.2.7 Linear acceleration message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
7.2.8 Earth acceleration message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
7.2.9 High-g message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
7.2.10 Temperature message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
7.2.11 Battery message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
7.2.12 RSSI message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
7.2.13 Serial accessory message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
7.2.14 Notification message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
7.2.15 Error message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
8 Network announcement message 22
2

x-IMU3 User Manual v0.5
July 7, 2020
9 Device settings 23
9.1 Individual settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
9.1.1 Calibration date (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
9.1.2 System clock calibration (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
9.1.3 RTC calibration (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
9.1.4 Battery measurement sensitivity (read-only) . . . . . . . . . . . . . . . . . . . . . . . . 23
9.1.5 Gyroscope misalignment (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
9.1.6 Gyroscope sensitivity (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
9.1.7 Gyroscope offset (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
9.1.8 Accelerometer misalignment (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . 24
9.1.9 Accelerometer sensitivity (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
9.1.10 Accelerometer offset (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
9.1.11 Soft iron matrix (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
9.1.12 Hard iron offset (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
9.1.13 High-g misalignment (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
9.1.14 High-g sensitivity (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
9.1.15 High-g offset (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
9.1.16 Device name . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
9.1.17 Serial number (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
9.1.18 Firmware version (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
9.1.19 Bootloader version (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
9.1.20 Hardware version (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
9.1.21 Serial mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
9.1.22 Serial baud rate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
9.1.23 Serial RTS/CTS enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
9.1.24 Serial accessory number of bytes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
9.1.25 Serial accessory termination byte . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
9.1.26 Serial accessory timeout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
9.1.27 Serial accessory transmit enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
9.1.28 Wireless mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
9.1.29 Wireless firmware version (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
9.1.30 External antennae enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
9.1.31 Wi-Fi region . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
9.1.32 Wi-Fi MAC address (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
9.1.33 Wi-Fi IP address (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
9.1.34 Wi-Fi client SSID . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
9.1.35 Wi-Fi client key . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
9.1.36 Wi-Fi client channel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
9.1.37 Wi-Fi client DHCP enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
9.1.38 Wi-Fi client IP address . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
9.1.39 Wi-Fi client netmask . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
9.1.40 Wi-Fi client gateway . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
9.1.41 Wi-Fi AP SSID . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
9.1.42 Wi-Fi AP key . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
9.1.43 Wi-Fi AP channel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
9.1.44 TCP port . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
9.1.45 UDP IP address . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
9.1.46 UDP send port . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
9.1.47 UDP receive port . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
9.1.48 Synchronisation enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
9.1.49 Synchronisation network latency . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
9.1.50 Bluetooth address (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
9.1.51 Bluetooth name . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
9.1.52 Bluetooth pin code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
9.1.53 Bluetooth discovery mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
9.1.54 Bluetooth paired address (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
3

x-IMU3 User Manual v0.5
July 7, 2020
9.1.55 Bluetooth paired link key (read-only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
9.1.56 Data logger enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
9.1.57 Data logger file name prefix . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
9.1.58 Data logger file name number . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
9.1.59 Data logger file name is time . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
9.1.60 Data logger maximum file size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
9.1.61 Data logger maximum file period . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
9.1.62 Axes alignment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36
9.1.63 Gyroscope offset correction enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
9.1.64 AHRS gain . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
9.1.65 AHRS ignore magnetometer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
9.1.66 Binary mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
9.1.67 USB data messages enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
9.1.68 Serial data messages enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38
9.1.69 TCP data messages enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38
9.1.70 UDP data messages enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38
9.1.71 Bluetooth data messages enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38
9.1.72 Data logger data messages enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38
9.1.73 AHRS message type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
9.1.74 Inertial message rate divisor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
9.1.75 Magnetometer message rate divisor . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
9.1.76 AHRS message rate divisor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
9.1.77 High-g message rate divisor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
9.1.78 Temperature message rate divisor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
9.1.79 Battery message rate divisor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42
9.1.80 Serial accessory rate divisor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42
10 Updating device firmware 42
Glossary 43
Document version history 45
Disclaimer 46
4

x-IMU3 User Manual v0.5
July 7, 2020
1 Overview
The x-IMU3 is x-io technologies’ third generation
Inertial Measurement Unit (IMU). It is a
high-performance and versatile measurement
device designed to accommodate a wide range of
data logging and real-time applications including
biomechanics, motion-capture, virtual reality, drones,
robotics, and industrial.
USB, Wi-Fi and Bluetooth provide connectivity
for mobile and desktop devices while serial
communication supports embedded and industrial
systems. An on-board micro SD card allows the
x-IMU3 to function as a stand-alone data logger
with the ability to download files by USB and Wi-Fi.
Multiple x-IMU3s operating together on the same
wireless network will automatically synchronise to
stream or log synchronised measurements.
Sensors
·Gyroscope, ±2000°/s, 400 Hz
·Accelerometer, ±16 g, 400 Hz
·Magnetometer, ±2.5 uT, 20 Hz
·High-g accelerometer, ±200 g, 1600 Hz
·Temperature sensor1
Calibration
·12-parameter calibration for: axis sensitivity,
axis bias, inter-axis misalignment, and package
misalignment.
·Hard-iron and soft-iron calibration
·On-board gyroscope bias correction algorithm
AHRS
·Algorithm outputs:
- Quaternion
- Rotation matrix
- Euler angles
- Linear acceleration
- Earth acceleration
·Linear acceleration rejection
·Magnetic distortion rejection
·400 Hz update rate
·Static accuracy:
- 1° RMS inclination
- 2° RMS heading
Communication
·USB
·Serial, 3.3V UART
·TCP (Wi-Fi)
·UDP (Wi-Fi)
·Bluetooth (SPP)
Wi-Fi
·Client and AP mode
·Dual band (2.4 GHz, 5 GHz)
·WPA/WPA2-Personal
·WPA/WPA2-Enterprise2(TBC)
Data logging
·Supports SD cards up to 32 GB3
·Start/stop logging remotely
·USB download
·Wi-Fi download
·CSV output
Serial accessories
·Receive data from external sensors and user
electronics, e.g. GPS, analogue/digital inputs,
application-specific sensors.
·3.3 V output to power external electronics
Battery
·Internal battery charged by USB
·15 hours data logging
·11 hours Bluetooth
·9 hours Wi-Fi client 2.4 GHz
·6 hours Wi-Fi client 5 GHz
Housing
·IP67 (TBC)
·Wearable strap or chassis mount
Software GUI
·Real-time data plots and 3D view
·Log real-time data to CSV
·Forward real-time data to other applications
·Windows and OSX
Software API
·Rust, C, C++, Python
·Code examples for other languages available
1The temperature sensor is used for calibration and is not intended to provide an accurate measurement of ambient temperature.
2WPA/WPA2-Enterprise security is only supported in client mode.
3The product is supplied with an 8 GB SD card that can be upgraded by the user.
5

x-IMU3 User Manual v0.5
July 7, 2020
2 Hardware
Board components are annotated in Figure 1. A detailed mechanical drawing describing the board dimensions
and locations of key components is available on the product web page.
1
2
3
4
5
67
8
9
10
11
Figure 1: Board
1. Power button
2. USB-C connector
3. LED
4. Serial header
5. High-g accelerometer
6. Inertial sensor (gyroscope and accelerometer)
7. Magnetometer
8. Wireless antennae
9. U.FL connector for external wireless antennae
10. Micro SD card socket
11. Battery connector
6

x-IMU3 User Manual v0.5
July 7, 2020
3 Technical specification
3.1 Sensors
3.1.1 Gyroscope
Characteristic Value Notes
Range ±2000°/s
Resolution 16-bit, 0.061°/s -
Sample rate 400 Hz ±TBC 1
Bandwidth TBC 2
Noise TBC -
Table 1: Gyroscope specification
Notes
1. Each sample includes a timestamp for a reliable measurement of time independent of the sample rate
tolerance. See Section 6 on page 9 for more information.
2. The maximum bandwidth is achieved when the message rate is equal to the sample rate. If the message
rate is less than the sample rate then samples are averaged. See Section 6 on page 9 for more
information.
3.1.2 Accelerometer
Characteristic Value Notes
Range ±16 g -
Resolution 16-bit, 488 µg -
Sample rate 400 Hz ±TBC 1
Bandwidth TBC 2
Noise TBC -
Accuracy at 1 g TBC 3
Table 2: Accelerometer specification
Notes
1. Each sample includes a timestamp for a reliable measurement of time independent of the sample rate
tolerance. See Section 6 on page 9 for more information.
2. The maximum bandwidth is achieved when the message rate is equal to the sample rate. If the message
rate is less than the sample rate then samples are averaged. See Section 6 on page 9 for more
information.
3. The accuracy at 1 g is evaluated as the deviation of the measured magnitude of gravity for a 360°
rotation around the X, Y, and Z axis aligned to the horizontal axis.
7

x-IMU3 User Manual v0.5
July 7, 2020
3.1.3 Magnetometer
Characteristic Value Notes
Range ±1300 µT (X, Y), ±2500 µT (Z) -
Sample rate 20 Hz ±TBC 1
Noise 0.3 µT -
Accuracy at 1 a.u. TBC 2, 3
Table 3: Magnetometer specification
Notes
1. Each sample includes a timestamp for a reliable measurement of time independent of the sample rate
tolerance. See Section 6 on the next page for more information.
2. The calibrated magnetometer units are arbitrary units (a.u.). 1 a.u. is equal to the magnitude of the
ambient magnetic during calibration, approximately 500 µT.
3. The accuracy at 1 a.u. is evaluated as the deviation of the measured magnitude of the ambient magnetic
field for a 360° rotation around the X, Y, and Z axis aligned to the vertical axis.
3.1.4 High-g accelerometer
Characteristic Value Notes
Range ±200 g -
Resolution 16-bit, 6.1 mg -
Sample rate 1600 Hz ±TBC -
Bandwidth 800 Hz 1, 2
Noise 5 mg/√Hz -
Accuracy at 1 g TBC 3
Table 4: High-g Accelerometer specification
Notes
1. Each sample includes a timestamp for a reliable measurement of time independent of the sample rate
tolerance. See Section 6 on the following page for more information.
2. The maximum bandwidth is achieved when the message rate is equal to the sample rate. If the message
rate is less than the sample rate then samples are averaged. See Section 6 on the next page for more
information.
3. The accuracy at 1 g is evaluated as the deviation of the measured magnitude of gravity for a 360°
rotation around the X, Y, and Z axis aligned to the horizontal axis.
8

x-IMU3 User Manual v0.5
July 7, 2020
3.1.5 Temperature sensor
Characteristic Value Notes
Range TBC -
Sample rate 5 Hz ±TBC 1, 2
Accuracy TBC -
Table 5: Temperature sensor specification
Notes
1. Each sample includes a timestamp for a reliable measurement of time independent of the sample rate
tolerance. See Section 6 for more information.
2. The temperature sensor is oversampled and the result decimated to the specified sample rate.
4 LED
Section unavailable. Please contact x-io Technologies for more information.
5 Bluetooth
Section unavailable. Please contact x-io Technologies for more information.
6 Message rates
Section unavailable. Please contact x-io Technologies for more information.
7 Communication protocol
All communication interfaces use the same communication protocol. The byte stream is therefore identical for
Universal Serial Bus (USB), serial, Transmission Control Protocol (TCP), User Datagram Protocol (UDP),
Bluetooth, and the files created by on-board data logging. The communication protocol consists of two
message types:
·Command messages
·Data messages
All messages are terminated by a Line Feed (LF) control character. This termination byte will not appear
anywhere else in a message and so can be used to divide a byte stream into individual messages. Some
messages are terminated with an additional Carriage Return (CR) control character. Table 6 on the next
page describes the different ways that the control characters LF and CR may be referred to throughout this
document.
9

x-IMU3 User Manual v0.5
July 7, 2020
Control character Abbreviation String Hex Decimal
Line Feed LF “\n” 0x0A 10
Carriage Return CR “\r” 0x0D 13
Table 6: Control characters LF and CR representations
The first byte of a message indicates the message type. Command messages start with the character “{”
(0x7B in hex, 123 in decimal). Data messages start with either an uppercase character or a byte value
greater than 0x80 (128 in decimal) depending on the message.
7.1 Command messages
Command messages are sent to the device to read and write settings and execute commands. All command
messages are a JavaScript Object Notation (JSON) object containing a single key/value pair, terminated by
the control character sequence: CR, LF. The control character LF must not appear anywhere else in a
command message. The device will acknowledge each received command message by sending a command
message with the same key to the host.
The key used by command messages sent to the device is not case sensitive and can use non-alphanumeric
characters arbitrarily. For example, “serialNumber”, “Serial Number”, and “serial number” are all valid keys
for a command message to read the device serial number. The key used by the acknowledgement command
message sent from the device to the host will always be in camel case. For example, “serialNumber”.
7.1.1 Read setting command
The read setting command is sent to the device to read a setting value. The key is the setting key and the
value is null. See Section 9.1 on page 23 for a complete list of settings. The device will acknowledge a read
setting command by sending a write setting command to the host.
Example: {"serialNumber":null}\r\n
7.1.2 Write setting command
The write setting command is sent to the device to write a setting value, or sent from the device to the host
in response to a read setting command. The key is the setting key and the value is the setting value. See
Section 9.1 on page 23 for a complete list of settings. The device will acknowledge a write setting command
by sending a setting write command back to the host, indicating the new settings value. The device will not
apply new settings until two seconds after the most recent write setting command or default command was
received.
Example: {"deviceName":"x-IMU3"}\r\n
7.1.3 Default command
The default command is sent to the device to set all settings to default values. The key is “default” and the
value is null. The device will not apply new settings until two seconds after the most recent write setting
command or default command was received.
Example: {"default":null}\r\n
10

x-IMU3 User Manual v0.5
July 7, 2020
7.1.4 Apply command
The apply command is sent to the device to apply all settings. The key is “apply” and the value is null. This
command can be sent after a write setting or default command to apply settings immediately instead of after
a two second delay.
Example: {"apply":null}\r\n
7.1.5 Save command
The save command is sent to the device to save all settings to Non-Volatile Memory (NVM). The key is “save”
and the value is null. This command is unnecessary in most applications because the device will automatically
save all settings on shutdown.
Example: {"save":null}\r\n
7.1.6 Read time command
The read time command is sent to the device to read the date and time of the Real-Time Clock (RTC). The
key is “time” and the value is null. The device will acknowledge a read time command by sending a write time
command to the host.
Example: {"time":null}\r\n
7.1.7 Write time command
The write time command is sent to the device to write the date and time of the RTC, or sent from the device
to the host in response to a read time command. The key is “time” and the value is a string expressing
the date and time in the format “YYYY-MM-DD hh:mm:ss” where each delimiter can be any non-numerical
character. The device will acknowledge a write time command by sending a write time command back to the
host, indicating the new date and time.
Example: {"time":"2020-01-01 00:00:00"}\r\n
7.1.8 Ping command
The ping command is sent to the device to trigger a ping response. The key is “ping” and the value is null.
The device will acknowledge a ping command by sending a ping response to the host.
Example: {"ping":null}\r\n
7.1.9 Ping response
The ping response is sent from the device to the host in response to the ping command. The key is “ping” and
the value is a JSON object containing three key/value pairs indicating the communication interface, device
name, and device serial number. The keys are “interface”, “deviceName”, and “serialNumber”, respectively
and all values are string types.
11

x-IMU3 User Manual v0.5
July 7, 2020
Example*:{"ping": {
"interface": "USB",
"deviceName": "x-IMU3",
"serialNumber": "0123-4567-89AB-CDEF"
}
}\r\n
* The actual JSON will not include any whitespace.
7.1.10 Reset command
The reset command is sent to the device to reset the device. The key is “reset” and the value is null. A reset
is equivalent to switching the device off and then on again. The device will reset two seconds after receiving
this command.
Example: {"reset":null}\r\n
7.1.11 Shutdown command
The shutdown command is sent to the device to switch the device off. The key is “shutdown” and the value is
null. The device will shutdown two seconds after receiving this command.
Example: {"shutdown":null}\r\n
7.1.12 Strobe command
The strobe command is sent to the device to strobe the Light-Emitting Diode (LED) bright white for 5 seconds.
The key is “strobe” and the value is null.
Example: {"strobe":null}\r\n
7.1.13 Serial accessory command
The serial accessory command is sent to the device to transmit data to a serial accessory when the serial
interface is in serial accessory mode. The key is “serial” and the value is the data expressed as a string of up
to 256 characters. Longer strings will be truncated to the maximum size. The string escape sequence “\u”
can be used to express any byte value as per the JSON specification.
Example: {"serial":"hello \u0077\u006F\u0072\u006C\u0064"}\r\n
7.1.14 Note command
The note command is sent to the device to generate a timestamped notification message containing a
user-defined string. The key is “note” and the value is the string of up to 127 characters. Longer strings
will be truncated to the maximum size. This command can be used to create timestamped notes of events
during data logging.
Example: {"note":"Something happened."}\r\n
12

x-IMU3 User Manual v0.5
July 7, 2020
7.1.15 Self-test command
The self-test command is sent to the device to perform a self-test. The key is “test” and the value is null. The
result of the self-test is obtained using the result command. The device must be stationary during the self-test.
Example: {"test":null}\r\n
7.1.16 Result command
The result command is sent to the device to obtain the result of the most recent self-test. The key is “result”
and the value is null. The device will acknowledge a result command by sending a result response to the host.
Example: {"result":null}\r\n
7.1.17 Result response
The result response is sent from the device to the host in response to the result command. The key is “result”
and the value is a JSON object containing multiple key/value pairs. Each key/value pair indicates the result
of a test. Each key is the test name and the value is the string ”Passed” if the test was passed. The JSON
object will be empty if the self-test is in progress or if a self-test has not been performed.
Example*:{"result": {
"Test A": "Passed",
"Test B": "Passed",
"Test C": "Passed"
}
}\r\n
* The actual JSON will not include any whitespace.
7.1.18 Bootloader command
The bootloader command is sent to the device to put the device in bootloader mode. The key is “bootloader”
and the value is null. The device will enter bootloader mode two seconds after receiving this command. See
Section 10 on page 42 for more information about updating the device firmware.
Example: {"bootloader":null}\r\n
7.2 Data messages
Data messages are sent from the device to the host to provide timestamped measurements, serial accessory
data, notifications, and error messages. Data messages will be either American Standard Code for
Information Interchange (ASCII) or binary, depending on the device settings.
ASCII data messages consist of multiple comma-separated values terminated by the control character
sequence: CR, LF. The first value is a single uppercase character indicating the message type. The second
value is the timestamp in microseconds. The remaining values are arguments specific to the message type.
Binary data messages are a sequence of bytes terminated by the control character LF. The first byte of the
sequence indicates the message type. The value of this byte is equal to 0x80 plus the first character of the
equivalent ASCII message. The next eight bytes are the timestamp in microseconds expressed as a 64-bit
unsigned integer. The remaining bytes are arguments specific to the message type. Numerical types use
little-endian ordering. Byte stuffing is used to remove all occurrences of the control character LF prior to the
termination byte.
13

x-IMU3 User Manual v0.5
July 7, 2020
7.2.1 Byte stuffing
Byte stuffing ensures that the termination byte value, 0x0A, only occurs at the end of a binary data message.
This is achieved by replacing all occurrences of the termination byte prior to termination with an escape
sequence. This process is identical to Serial Line Internet Protocol (SLIP) except that the “END” byte value is
defined as 0x0A. Table 7 lists the values used by the byte stuffing process.
Hex Decimal Name Description
0x0A 10 END Message termination
0xDB 219 ESC Message escape
0xDC 220 ESC END Transposed message termination
0xDD 221 ESC ESC Transposed message escape
Table 7: Values used by the byte stuffing process
Byte stuffing is achieved by the following:
·Replace each occurrence of END in the original message with the two byte sequence: ESC, ESC END.
·Replace each occurrence of ESC in the original message with the two byte sequence: ESC, ESC ESC.
The byte stuffing process will not modify the END that terminates the message. Table 8 demonstrates byte
stuffing for example byte sequences terminated as binary data messages.
Example Before byte stuffing After byte stuffing
145 58 41 4D 50 4C 45 0A 45 58 41 4D 50 4C 45 0A
245 0A 41 4D 50 4C 45 0A 45 DB DC 41 4D 50 4C 45 0A
345 58 DB 4D 50 4C 45 0A 45 58 DB DD 4D 50 4C 45 0A
445 58 41 4D 50 DB 0A 0A 45 58 41 4D 50 DB DD DB DC 0A
Table 8: Byte stuffing examples
7.2.2 Inertial message
The inertial message provides timestamped gyroscope and accelerometer measurements. Inertial messages
are sent continuously at the message rate configured in the device settings. The first value of an ASCII
message is the character “I” and the arguments are six numerical values expressed to four decimal places.
The first byte of a binary message is 0xC9 (equal to 0x80 + “I”) and the arguments are six contiguous 32-bit
floats. The message arguments are described in Table 9.
Argument Description
1 Gyroscope X axis in degrees per second
2 Gyroscope Y axis in degrees per second
3 Gyroscope Z axis in degrees per second
4 Accelerometer X axis in g
5 Accelerometer Y axis in g
6 Accelerometer Z axis in g
Table 9: Inertial message arguments
14

x-IMU3 User Manual v0.5
July 7, 2020
The following message examples are for a timestamp of 1 second (1,000,000 microseconds) and argument
values of:
1. Gyroscope X axis = 0
2. Gyroscope Y axis = 0
3. Gyroscope Z axis = 0
4. Accelerometer X axis = 0
5. Accelerometer Y axis = 0
6. Accelerometer Z axis = 1
ASCII example: I,1000000,0.0000,0.0000,0.0000,0.0000,0.0000,1.0000\r\n
Binary example: C9 40 42 0F 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 80 3F 0A
7.2.3 Magnetometer message
The magnetometer message provides timestamped magnetometer measurements. Magnetometer messages
are sent continuously at the message rate configured in the device settings. The first value of an ASCII
message is the character “M” and the arguments are three numerical values expressed to four decimal places.
The first byte of a binary message is 0xCD (equal to 0x80 + “M”) and the arguments are three contiguous
32-bit floats. The message arguments are described in Table 10.
Argument Description
1 Magnetometer X axis in a.u.
2 Magnetometer Y axis in a.u.
3 Magnetometer Z axis in a.u.
Table 10: Magnetometer message arguments
The following message examples are for a timestamp of 1 second (1,000,000 microseconds) and argument
values of:
1. Magnetometer X axis = 1.0
2. Magnetometer Y axis = 0.0
3. Magnetometer Z axis = 0.0
ASCII example: M,1000000,1.0000,0.0000,0.0000\r\n
Binary example: CD 40 42 0F 00 00 00 00 00 00 00 80 3F 00 00 00 00 00 00 00 00 0A
7.2.4 Quaternion message
The quaternion message provides timestamped measurements of the orientation of the device relative to the
Earth. Quaternion messages are sent continuously at the message rate configured in the device settings. The
first value of an ASCII message is the character “Q” and the arguments are four numerical values expressed
to four decimal places. The first byte of a binary message is 0xD1 (equal to 0x80 + “Q”) and the arguments
are four contiguous 32-bit floats. The message arguments are described in Table 11 on the next page.
15

x-IMU3 User Manual v0.5
July 7, 2020
Argument Description
1 Quaternion W element
2 Quaternion X element
3 Quaternion Y element
4 Quaternion Z element
Table 11: Quaternion message arguments
The following message examples are for a timestamp of 1 second (1,000,000 microseconds) and argument
values of:
1. Quaternion W element = 1
2. Quaternion X element = 0
3. Quaternion Y element = 0
4. Quaternion Z element = 0
ASCII example: Q,1000000,1.0000,0.0000,0.0000,0.0000\r\n
Binary example: D1 40 42 0F 00 00 00 00 00 00 00 80 3F 00 00 00 00 00 00 00 00 00 00
00 00 0A
7.2.5 Rotation matrix message
The rotation matrix message provides timestamped measurements of the orientation of the device relative
to the Earth. Rotation matrix messages are sent continuously at the message rate configured in the device
settings. The first value of an ASCII message is the character “R” and the arguments are nine numerical
values expressed to four decimal places. The first byte of a binary message is 0xD2 (equal to 0x80 + “R”) and
the arguments are nine contiguous 32-bit floats. The message arguments are described in Table 12.
Argument Description
1 Rotation matrix XX element
2 Rotation matrix XY element
3 Rotation matrix XZ element
4 Rotation matrix YX element
5 Rotation matrix YY element
6 Rotation matrix YZ element
7 Rotation matrix ZX element
8 Rotation matrix ZY element
9 Rotation matrix ZZ element
Table 12: Rotation matrix message arguments
The following message examples are for a timestamp of 1 second (1,000,000 microseconds) and argument
values of:
1. Rotation matrix XX element = 1
2. Rotation matrix XY element = 0
3. Rotation matrix XZ element = 0
16

x-IMU3 User Manual v0.5
July 7, 2020
4. Rotation matrix YX element = 0
5. Rotation matrix YY element = 1
6. Rotation matrix YZ element = 0
7. Rotation matrix ZX element = 0
8. Rotation matrix ZY element = 0
9. Rotation matrix ZZ element = 1
ASCII example: R,1000000,1.0000,0.0000,0.0000,0.0000,1.0000,0.0000,0.0000,0.0000,1.
0000\r\n
Binary example: D2 40 42 0F 00 00 00 00 00 00 00 80 3F 00 00 00 00 00 00 00 00 00 00
00 00 00 00 80 3F 00 00 00 00 00 00 00 00 00 00 00 00 00 00 80 3F 0A
7.2.6 Euler angles message
The Euler angles message provides timestamped measurements of the orientation of the device relative
to the Earth. Euler angles messages are sent continuously at the message rate configured in the device
settings. The first value of an ASCII message is the character “E” and the arguments are three numerical
values expressed to four decimal places. The first byte of a binary message is 0xC5 (equal to 0x80 + “E”) and
the arguments are three contiguous 32-bit floats. The message arguments are described in Table 13.
Argument Description
1 Roll angle in degrees
2 Pitch angle in degrees
3 Yaw angle in degrees
Table 13: Euler angles message arguments
The following message examples are for a timestamp of 1 second (1,000,000 microseconds) and argument
values of:
1. Roll angle = 0.0
2. Pitch angle = 0.0
3. Yaw angle = 0.0
ASCII example: E,1000000,0.0000,0.0000,0.0000\r\n
Binary example: C5 40 42 0F 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0A
7.2.7 Linear acceleration message
The linear acceleration message provides timestamped measurements of linear acceleration and the
orientation of the device relative to the Earth. Linear acceleration messages are sent continuously at the
message rate configured in the device settings. The first value of an ASCII message is the character “L”
and the arguments are seven numerical values expressed to four decimal places. The first byte of a binary
message is 0xCC (equal to 0x80 + “L”) and the arguments are seven contiguous 32-bit floats. The message
arguments are described in Table 14 on the following page.
17

x-IMU3 User Manual v0.5
July 7, 2020
Argument Description
1 Quaternion W element
2 Quaternion X element
3 Quaternion Y element
4 Quaternion Z element
5 Linear acceleration X axis in g
6 Linear acceleration Y axis in g
7 Linear acceleration Z axis in g
Table 14: Linear acceleration message arguments
The following message examples are for a timestamp of 1 second (1,000,000 microseconds) and argument
values of:
1. Quaternion W element = 1
2. Quaternion X element = 0
3. Quaternion Y element = 0
4. Quaternion Z element = 0
5. Linear acceleration X axis = 0
6. Linear acceleration Y axis = 0
7. Linear acceleration Z axis = 0
ASCII example: L,1000000,1.0000,0.0000,0.0000,0.0000,0.0000,0.0000,0.0000\r\n
Binary example: CC 40 42 0F 00 00 00 00 00 00 00 80 3F 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 0A
7.2.8 Earth acceleration message
The Earth acceleration message provides timestamped measurements of Earth acceleration and the
orientation of the device relative to the Earth. Earth acceleration messages are sent continuously at the
message rate configured in the device settings. The first value of an ASCII message is the character “E”
and the arguments are seven numerical values expressed to four decimal places. The first byte of a binary
message is 0xC5 (equal to 0x80 + “E”) and the arguments are seven contiguous 32-bit floats. The message
arguments are described in Table 15.
Argument Description
1 Quaternion W element
2 Quaternion X element
3 Quaternion Y element
4 Quaternion Z element
5 Earth acceleration X axis in g
6 Earth acceleration Y axis in g
7 Earth acceleration Z axis in g
Table 15: Earth acceleration message arguments
The following message examples are for a timestamp of 1 second (1,000,000 microseconds) and argument
18

x-IMU3 User Manual v0.5
July 7, 2020
values of:
1. Quaternion W element = 1
2. Quaternion X element = 0
3. Quaternion Y element = 0
4. Quaternion Z element = 0
5. Earth acceleration X axis = 0
6. Earth acceleration Y axis = 0
7. Earth acceleration Z axis = 0
ASCII example: E,1000000,1.0000,0.0000,0.0000,0.0000,0.0000,0.0000,0.0000\r\n
Binary example: C5 40 42 0F 00 00 00 00 00 00 00 80 3F 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 0A
7.2.9 High-g message
The High-g message provides timestamped high-g accelerometer measurements. High-g messages are sent
continuously at the message rate configured in the device settings. The first value of an ASCII message is
the character “H” and the arguments are three numerical values expressed to four decimal places. The first
byte of a binary message is 0xC8 (equal to 0x80 + “H”) and the arguments are three contiguous 32-bit floats.
The message arguments are described in Table 16.
Argument Description
1 High-g accelerometer X axis in g
2 High-g accelerometer Y axis in g
3 High-g accelerometer Z axis in g
Table 16: High-g message arguments
The following message examples are for a timestamp of 1 second (1,000,000 microseconds) and argument
values of:
1. High-g accelerometer X axis = 0.0
2. High-g accelerometer Y axis = 0.0
3. High-g accelerometer Z axis = 1.0
ASCII example: H,1000000,0.0000,0.0000,1.0000\r\n
Binary example: C8 40 42 0F 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 80 3F 0A
7.2.10 Temperature message
The temperature message provides timestamped temperature measurements. Temperature messages are
sent continuously at the message rate configured in the device settings. The first value of an ASCII message
is the character “T” and the argument is a numerical value expressed to four decimal places. The first byte of
a binary message is 0xD4 (equal to 0x80 + “T”) and the argument is a 32-bit float. The message arguments
are described in Table 17.
Argument Description
1 Temperature in degrees Celsius
Table 17: Temperature message arguments
19

x-IMU3 User Manual v0.5
July 7, 2020
The following message examples are for a timestamp of 1 second (1,000,000 microseconds) and argument
values of:
1. Temperature = 25
ASCII example: T,1000000,25.0000\r\n
Binary example: D4 40 42 0F 00 00 00 00 00 00 00 41 C8 0A
7.2.11 Battery message
The battery message message provides timestamped measurements of the battery level, voltage, and charger
status. Battery message messages are sent continuously at the message rate configured in the device
settings. The first value of an ASCII message is the character “B” and the arguments are four numerical
values expressed to four decimal places. The first byte of a binary message is 0xC2 (equal to 0x80 + “B”) and
the arguments are four contiguous 32-bit floats. The message arguments are described in Table 18.
Argument Description
1 Battery percentage
2 Battery voltage in volts
3 Charger connected (0 = not connected, 1 = connected)
4 Charger status (0 = not charging, 1 = charging)
Table 18: Battery message arguments
The following message examples are for a timestamp of 1 second (1,000,000 microseconds) and argument
values of:
1. Percentage = 100
2. Voltage = 4.2
3. Charger connected = 1
4. Charger status = 0
ASCII example: B,1000000,100.0000,4.2000,1.0000,0.0000\r\n
Binary example: C2 40 42 0F 00 00 00 00 00 00 00 C8 42 66 66 86 40 00 00 80 3F 00 00
00 00 0A
7.2.12 RSSI message
The Received Signal Strength Indicator (RSSI) message provides timestamped Wi-Fi RSSI measurements.
RSSI messages are sent continuously at the message rate configured in the device settings. RSSI messages
will only be sent if the device is configured as a Wi-Fi client. The first value of an ASCII message is the
character “W” and the arguments are two numerical values expressed to four decimal places. The first byte
of a binary message is 0xD7 (equal to 0x80 + “W”) and the arguments are two contiguous 32-bit floats. The
message arguments are described in Table 19.
Argument Description
1 RSSI percentage
2 RSSI power in dBm
Table 19: RSSI message arguments
20
Other manuals for x-IMU3
2
Table of contents
Other X-IO Measuring Instrument manuals