3 ./mtdevice.py [commands] [opts]
7 Print this help and quit.
9 Reset device to factory defaults.
10 -a, --change-baudrate=NEW_BAUD
11 Change baudrate from BAUD (see below) to NEW_BAUD.
12 -c, --configure=OUTPUT
13 Configure the device (see OUTPUT description below).
15 Print MTData. It is the default if no other command is supplied.
17 Print current MT device configuration.
19 Change the current XKF scenario.
20 -l, --legacy-configure
21 Configure the device in legacy mode (needs MODE and SETTINGS arguments
25 -y, --synchronization=settings (see below)
26 Configure the synchronization settings of each sync line (see below).
27 -u, --utc-time=time (see below)
28 Set the UTC time buffer of the device.
29 -g, --gnss-platform=platform
30 Change the GNSS navigation filter settings (check the documentation).
31 -o, --option-flags=flags (see below)
33 -j, --icc-command=command (see below)
34 Send command to the In-run Compass Calibration.
38 Serial interface of the device (default: /dev/ttyUSB0). If 'auto', then
39 all serial ports are tested at all baudrates and the first
40 suitable device is used.
42 Baudrate of serial interface (default: 115200). If 0, then all
43 rates are tried until a suitable one is found.
45 Timeout of serial communication in second (default: 0.002).
46 -w, --initial-wait=WAIT
47 Initial wait to allow device to be ready in second (default: 0.1).
51 The format is a sequence of "<group><type><frequency>?<format>?"
53 The frequency and format are optional.
54 The groups and types can be:
55 t temperature (max frequency: 1 Hz):
57 i timestamp (max frequency: 2000 Hz):
60 ii Integer Time of the Week (ITOW)
64 o orientation data (max frequency: 400 Hz):
68 b pressure (max frequency: 50 Hz):
70 a acceleration (max frequency: 2000 Hz (see documentation)):
74 ah acceleration HR (max frequency 1000 Hz)
75 p position (max frequency: 400 Hz):
79 n GNSS (max frequency: 4 Hz):
81 ns GNSS satellites info
82 w angular velocity (max frequency: 2000 Hz (see documentation)):
85 wh rate of turn HR (max frequency 1000 Hz)
86 g GPS (max frequency: 4 Hz):
91 r Sensor Component Readout (max frequency: 2000 Hz):
92 rr ACC, GYR, MAG, temperature
94 m Magnetic (max frequency: 100 Hz):
96 v Velocity (max frequency: 400 Hz):
98 s Status (max frequency: 2000 Hz):
101 Frequency is specified in decimal and is assumed to be the maximum
102 frequency if it is omitted.
103 Format is a combination of the precision for real valued numbers and
106 f single precision floating point number (32-bit) (default)
107 d double precision floating point number (64-bit)
109 e East-North-Up (default)
113 The default configuration for the MTi-1/10/100 IMUs can be
117 "wd2000fe,ad2000fe,mf100fe,ip2000,if2000,sw2000"
118 For getting quaternion orientation in float with sample time:
120 For longitude, latitude, altitude and orientation (on MTi-G-700):
121 "pl400fe,pa400fe,oq400fe"
123 Synchronization settings:
124 The format follows the xsens protocol documentation. All fields are
125 required and separated by commas.
126 Note: The entire synchronization buffer is wiped every time a new one
127 is set, so it is necessary to specify the settings of multiple
129 It also possible to clear the synchronization with the argument "clear"
131 Function (see manual for details):
133 4 Interval Transition Measurement
135 9 ClockBiasEstimation
137 Line (manual for details):
139 1 GPSClockIn (only available for 700/710)
140 2 Input Line (SyncIn)
142 5 ExtTimepulseIn (only available for 700/710)
143 6 Software (only available for SendLatest with ReqData message)
145 1 Positive pulse/ Rising edge
146 2 Negative pulse/ Falling edge
151 Skip First (unsigned_int):
152 Number of initial events to skip before taking actions
153 Skip Factor (unsigned_int):
154 Number of events to skip before taking action again
155 Ignored with ReqData.
156 Pulse Width (unsigned_int):
158 For SyncOut, the width of the generated pulse in 100 microseconds
159 unit. Ignored for Toggle pulses.
161 Delay after receiving a sync pulse to taking action,
162 100 microseconds units, range [0...600000]
164 Reference clock period in milliseconds for ClockBiasEstimation
166 Offset from event to pulse generation.
167 100 microseconds unit, range [-30000...+30000]
170 For changing the sync setting of the SyncIn line to trigger indication
171 with rising edge, one time triggering and no skipping and delay. Enter
175 Note a number is still in the place for pulse width despite it being
178 To set multiple lines at once:
179 ./mtdevice.py -y 3,2,1,0,0,0,0,0 -y 9,0,1,0,0,0,10,0
181 To clear the synchronization settings of MTi
182 ./mtdevice.py -y clear
185 There are two ways to set the UTCtime for the MTi.
186 Option #1: set MTi to the current UTC time based on local system time with
188 Option #2: set MTi to a specified UTC time
189 The time fields are set as follows:
190 year: range [1999,2099]
192 day: day of the month, range [1,31]
193 hour: hour of the day, range [0,23]
194 min: minute of the hour, range [0,59]
195 sec: second of the minute, range [0,59]
196 ns: nanosecond of the second, range [0,1000000000]
198 1: Valid Time of Week
201 Note: the flag is ignored for --utc-time as it is set by the device
202 itself when connected to a GPS
205 Set UTC time for the device:
207 ./mtdevice.py -u 1999,1,1,0,0,0,0,0
209 GNSS platform settings:
210 Only for MTi-G-700/710 with firmware>=1.7.
211 The following two platform settings are listed in the documentation:
214 Check the XSens documentation before changing anything.
217 Several flags can be set or cleared.
218 0x00000001 DisableAutoStore: when set, configuration changes are not saved
219 in non-volatile memory (only MTi-1 series)
220 0x00000002 DisableAutoMeasurement: when set, device will stay in Config
221 Mode upon start up (only MTi-1 series)
222 0x00000004 EnableBeidou: when set, enable Beidou and disable GLONASS (only
224 0x00000010 EnableAHS: enable Active Heading Stabilization (overrides
226 0x00000080 EnableInRunCompassCalibration: doc is unclear
227 The flags provided must be a pair of ored values: the first for flags to be
228 set the second for the flags to be cleared.
230 Only set DisableAutoStore and DisableAutoMeasurement flags:
231 ./mtdevice.py -o 0x03,0x00
232 Disable AHS (clear EnableAHS flag):
233 ./mtdevice.py -o 0x00,0x10
234 Set DisableAutoStore and clear DisableAutoMeasurement:
235 ./mtdevice.py -o 0x02,0x01
237 In-run Compass Calibration commands:
238 The idea of ICC is to record magnetic field data during so-called
239 representative motion in order to better calibrate the magnetometer and
241 Typical usage would be to issue the start command, then move the device
242 for some time then issue the stop command. If parameters are acceptable,
243 these can be stored using the store command.
245 00: Start representative motion
246 01: Stop representative motion; return ddt, dimension, and status.
247 02: Store ICC parameters
248 03: Get representative motion state; return 1 if active
249 Check the documentation for more details.
252 -m, --output-mode=MODE
253 Legacy mode of the device to select the information to output.
254 This is required for 'legacy-configure' command.
255 MODE can be either the mode value in hexadecimal, decimal or
256 binary form, or a string composed of the following characters
258 t temperature, [0x0001]
259 c calibrated data, [0x0002]
260 o orientation data, [0x0004]
261 a auxiliary data, [0x0008]
262 p position data (requires MTi-G), [0x0010]
263 v velocity data (requires MTi-G), [0x0020]
264 s status data, [0x0800]
265 g raw GPS mode (requires MTi-G), [0x1000]
266 r raw (incompatible with others except raw GPS), [0x4000]
267 For example, use "--output-mode=so" to have status and
269 -s, --output-settings=SETTINGS
270 Legacy settings of the device. This is required for 'legacy-configure'
272 SETTINGS can be either the settings value in hexadecimal,
273 decimal or binary form, or a string composed of the following
274 characters (in any order):
275 t sample count (excludes 'n')
276 n no sample count (excludes 't')
278 q orientation in quaternion (excludes 'e' and 'm')
279 e orientation in Euler angles (excludes 'm' and 'q')
280 m orientation in matrix (excludes 'q' and 'e')
281 A acceleration in calibrated data
282 G rate of turn in calibrated data
283 M magnetic field in calibrated data
284 i only analog input 1 (excludes 'j')
285 j only analog input 2 (excludes 'i')
286 N North-East-Down instead of default: X North Z up
287 For example, use "--output-settings=tqMAG" for all calibrated
288 data, sample counter and orientation in quaternion.
290 Sampling period in (1/115200) seconds (default: 1152).
291 Minimum is 225 (1.95 ms, 512 Hz), maximum is 1152
293 Note that for legacy devices it is the period at which sampling occurs,
294 not the period at which messages are sent (see below).
297 -f, --deprecated-skip-factor=SKIPFACTOR
298 Only for mark III devices.
299 Number of samples to skip before sending MTData message
301 The frequency at which MTData message is send is:
302 115200/(PERIOD * (SKIPFACTOR + 1))
303 If the value is 0xffff, no data is send unless a ReqData request