/simulationNew

all simulation

Primary LanguagePythonApache License 2.0Apache-2.0

Simulation Workspace

This repository includes the simulation code for UMARV.

Contents

Prerequisites

  • ROS (sudo apt-get install ros-noetic-desktop-full)
  • Xacro (sudo apt-get install ros-noetic-xacro)
  • Gazebo (sudo apt-get install ros-noetic-gazebo-ros)

Clone the Workspace

git clone --recursive https://github.com/umigv/simulationNew.git simulation_ws
cd simulation_ws

Set up Cartographer

Comment out line 46 (<!-- <depend>libabsl-dev</depend> -->) in Cartographer package.xml as per cartographer-project/cartographer_ros#1726

# Install prerequisites
sudo apt-get update
sudo apt-get install -y python3-wstool python3-rosdep ninja-build
sudo apt-get install -y liblua5.3-dev python3-sphinx libeigen3-dev
sudo apt-get install -y stow

# Install Cartographer dependencies
src/cartographer/scripts/install_debs_cmake.sh
src/cartographer/scripts/install_abseil.sh
scripts/install_proto3_fixed.sh

# Install ROS dependencies
sudo rosdep init
rosdep update
rosdep install --from-paths src --ignore-src --rosdistro=${ROS_DISTRO} -y

Build the Workspace

catkin build
source devel/setup.bash

Launch the Robot

# Launch with sensors in RVIZ
roslaunch marvin world.launch 2> >(grep -v -E 'TF_REPEATED_DATA|buffer_core|lookupTransform')

# Launch with no RVIZ (for Cartgrapher)
roslaunch marvin world_no_rviz.launch 2> >(grep -v -E 'TF_REPEATED_DATA|buffer_core|lookupTransform')

Launch Cartographer

roslaunch marvin cartographer.launch 2> >(grep -v -E 'TF_REPEATED_DATA|buffer_core|lookupTransform|at line|^$')

Control the Robot

Use teleop_twist_keyboard

rosrun marvin teleop_twist_keyboard.py