DriveWorks SDK Reference
4.0.0 Release
For Test and Development only

tools/calibration-imu/README-calibration-imu.md
Go to the documentation of this file.
1 # Copyright (c) 2019-2020, NVIDIA CORPORATION. All rights reserved.
2 
3 @page dwx_imu_calibration_tool IMU Calibration Tool
4 @tableofcontents
5 
6 @section dwx_imu_calibration_tool_description Description
7 
8 The NVIDIA<sup>&reg;</sup> DriveWorks IMU Calibration tool calibrates the orientation of IMU with respect to the
9 car ("Rig") coordinate system, and displays it on screen.
10 
11 If the orientation is successfully calibrated, a new rig file containing this orientation is created in the same folder as the input rig file. \n This new rig file is labelled `<input_rig_filename>_calibrated.json`.
12 
13 @section dwx_imu_calibration_prereqs Prerequisites
14 
15 This tool is available on the x86 Host System and NVIDIA DRIVE<sup>&trade;</sup> OS Linux.
16 
17 This tool creates output files that are placed into the current working directory by default. Please ensure the following for your convenience:
18 - Write permissions are enabled for the current working directory.
19 - Include the tools folder in the binary search path of the system.
20 - Execute from your home directory.
21 
22 To use this tool, you first must capture IMU and CAN data, with the vehicle performing
23 a special calibration sequence. For more information, see how @ref dwx_imu_calibration_IMUsequence.
24 
25 For an example of a suitable input rig file, please navigate to `path/to/data/tools/calibration_imu/rig.json`.
26 
27 @section dwx_imu_calibration_usage Running the Tool
28 
29 When you have obtained the IMU and CAN data, run the tool by executing:
30 
31  ./calibration_imu --rig=rig.json
32  --imu-sensor=[IMU sensor or name]
33  --can-sensor=[CAN sensor or name]
34  [--trigger=[float number]]
35  [--angleStdDev=[float number]]
36 
37 @subsection dwx_imu_calibration_parameters Parameters
38 
39  --rig=[path to vehicle rig file]
40  Description: The rig file must specify file paths to the IMU, CAN, and DBC files.
41  Example: --rig=rig.json
42 
43  --imu-sensor=[IMU name or number]
44  Description: The IMU sensor name or number specified in the input rig file.
45  Example: --imu-sensor=imu:xsens
46 
47  --can-sensor=[IMU name or number]
48  Description: The CAN sensor name or number specified in the input rig file.
49  Example: --can-sensor=can:vehicle
50 
51  --trigger=[float number]
52  Description: Specifies a forward acceleration trigger to record in (m/s^2).
53  Heavy vehicles such as trucks may require a smaller acceleration trigger.
54  This parameter is optional.
55  Default value: 2.0
56  Example: --trigger=6.1
57 
58  --angleStdDev=[float number]
59  Description: The angular standard deviation threshold in degrees.
60  This parameter is optional.
61  Default value: 10.0
62  Example: --angleStdDev=7.6
63 
64 @section dwx_imu_calibration_example Example
65 
66 @subsection dwx_imu_calibration_displaying Displaying the IMU Sensor's Orientation on Screen
67 
68  ./calibration_imu --rig=rig.json
69  --imu-sensor=imu:xsens
70  --can-sensor=can:vehicle
71 
72 @section dwx_imu_calibration_additional Additional Information
73 
74 @subsection dwx_imu_calibration_IMUsequence To Capture IMU and CAN Data
75 
76 1. Find a level surface. It is important for the surface to have as little incline as possible.
77 
78 2. Start recording the IMU data with the car stopped. (To obtain the IMU data,
79  use the @ref dwx_tools_recording that NVIDIA<sup>&reg;</sup> DriveWorks provides.)
80 
81 3. With a Recording Tool turned on, **wait at least 5 seconds before driving**. This is for the tool to find the gravity vector.
82 
83 4. Rapidly accelerate the vehicle, and rapidly stop multiple times. Try to avoid skidding.
84  This is needed for the calibration utility to find forward acceleration.
85 
86 5. Stop the Recording Tool.