This project employs sensor fusion using the EKF ROS package to localize the robot inside a Gazebo environment.
- ROS Distro : Noetic
- OS : Ubuntu 20.04 LTS
$ apt-get update
$ apt-get upgrade -y
Now, Clone this repository in /src
of your ROS workspace
$ git clone https://github.com/Apatil10/SensorFusion-EKF.git
Under /main/launch/
, edit the main.launch file:
<node pkg="rviz" type="rviz" name="rviz" args="-d {update your absolute path for the EKF.rviz config file}"/>
Example:
<node pkg="rviz" type="rviz" name="rviz" args="-d /home/aditya(user_name))/EKF_project(worksapce)/src/EKF.rviz"/>
$ cd {your Catkin_workspace}
$ source devel/setup.bash
$ rosdep install --from-paths src --ignore-src --rosdistro noetic -y
$ catkin_make
$ source devel/setup.bash
$ roslaunch main main.launch
Now, you should see Gazebo and rviz launching. Please note that Gazebo might take up to 5 min to launch!
In the terminal, use the keyboard commands(w-a-s-d-x-space.) and drive the robot around. The red
trajectory represents the Odom path
whereas the green
trajectory represents the EKF path
.