# ekf-localization-odometry-and-imu **Repository Path**: maxibooksiyi/ekf-localization-odometry-and-imu ## Basic Information - **Project Name**: ekf-localization-odometry-and-imu - **Description**: No description available - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2024-09-10 - **Last Updated**: 2024-09-10 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # EKF Localization: Odometry and IMU First, perform system update/Upgrade: ```sh apt-get update apt-get upgrade -y ``` Steps ```sh 1- Create Catkin Workspace: mkdir -p /home/workspace/catkin_ws/src cd /home/workspace/catkin_ws/src catkin_init_workspace cd .. catkin_make ``` ```sh 2- Import TurtleBot Gazebo Package: Clone Package: cd /home/workspace/catkin_ws/src git clone https://github.com/turtlebot/turtlebot_simulator Install Dependencies: cd /home/workspace/catkin_ws source devel/setup.bash rosdep -i install turtlebot_gazebo Build Package: catkin_make source devel/setup.bash Launch Nodes: roslaunch turtlebot_gazebo turtlebot_world.launch ``` ```sh 3- Install EKF package: Documentation available on http://wiki.ros.org/robot_pose_ekf cd /home/workspace/catkin_ws/src/ git clone https://github.com/udacity/robot_pose_ekf Edit robot_pose_ekf.launch Now, build the package: cd /home/workspace/catkin_ws catkin_make source devel/setup.bash Launch the node: roslaunch robot_pose_ekf robot_pose_ekf.launch ``` ```sh 4-Install odom_to_trajectory: This package calculates the trajectory from odometer data. cd /home/workspace/catkin_ws/src git clone https://github.com/udacity/odom_to_trajectory Build the package: cd /home/workspace/catkin_ws catkin_make source devel/setup.bash Launch the nodes: roslaunch odom_to_trajectory create_trajectory.launch ``` ```sh 5- Install Teleop package: This package helps controlling the TurtleBot cd /home/workspace/catkin_ws/src git clone https://github.com/turtlebot/turtlebot Install the Dependencies: cd /home/workspace/catkin_ws source devel/setup.bash rosdep -i install turtlebot_teleop Build the package: catkin_make source devel/setup.bash Launch the node: roslaunch turtlebot_teleop keyboard_teleop.launch ``` ```sh 6- Launch rviz: rosrun rviz rviz Edit the rviz configuration: - Change the Fixed Frame to base_footprint - Change the Reference Frame to odom - Add a RobotModel - Add a camera and select the /camera/rgb/image_raw topic - Add a /ekfpath topic and change the display name to EKFPath - Add a /odompath topic and change the display name to OdomPath - Change the OdomPath color to red:255;0;0 - Save the rviz configuration: - Save the rviz configuration in /home/workspace/catkin_ws/src as EKFLab.rviz Create a RvizLaunch.launch file in the src folder Add the following to the RvizLaunch.launch file: Close the rviz terminal and Relaunch rviz: rosrun rviz rviz -d /home/workspace/catkin_ws/src/EKFLab.rviz ``` ```sh 7- Create a main file to open everything at the same time: cd /home/workspace/catkin_ws/src catkin_create_pkg main Build the package: cd /home/workspace/catkin_ws catkin_make Create and edit the main.launch file: cd /home/workspace/catkin_ws/src/main mkdir launch cd launch Download https://github.com/udacity/RoboND-EKFLab/blob/master/main/launch/main.launch Launch the main.launch file: cd /home/workspace/catkin_ws/ source devel/setup.bash roslaunch main main.launch ```