This project involved performing data processing and analysis on Inertial Measurement Unit (IMU) and GPS data collected during driving. The script includes three main parts:
- The raw magnetometer data is calibrated for hard and soft iron effects.
- The calibrated magnetometer data is plotted before and after calibration.
- Yaw is computed from IMU quaternion data and magnetometer data.
- Comparison of yaw from gyroscope and magnetometer is performed.
- Sensor fusion using a complementary filter is applied to combine gyroscope and magnetometer estimates.
- Velocity is estimated from GPS data.
- Outliers in GPS velocity are corrected.
- Velocity is estimated from accelerometer data.
- Outlier detection and correction are applied to improve IMU velocity estimation.
- Displacement is calculated from both GPS and IMU velocity.
- UTM coordinates are used to plot the route on a graph.
- Comparison of observed acceleration and Coriolis acceleration.
- The script is designed to be run in MATLAB.
- Ensure required CSV files ("imu.csv", "driving_imu.csv", "driving_gps.csv") are present in the same directory.
-
To integrate with ROS, use the following command to run the launch file:
$ roslaunch LAB4 driver.launch port1:="(name of IMU port)" port2:="(name of the GPS port)"
-
Make sure to replace "(name of IMU port)" and "(name of GPS port)" with the actual port names.
-
The name of the ROS package is LAB4.
- MATLAB (R2022a or later)
- ROS