Giter Site home page Giter Site logo

robotnikautomation / summit_xl_sim Goto Github PK

View Code? Open in Web Editor NEW
65.0 16.0 39.0 11.85 MB

Packages for the simulation of the Summit XL, Summit XL HL and Summit-X (including X-WAM) robots

License: BSD 2-Clause "Simplified" License

CMake 18.69% Dockerfile 78.23% Shell 3.08%
robots summit-xl ros gazebo gazebo-ros gazebo-simulator melodic kinetic docker ros-melodic

summit_xl_sim's Introduction

summit_xl_sim

Packages for the simulation of the Summit XL

This packages contains:

summit_xl_gazebo

Launch files and world files to start the models in gazebo

summit_xl_sim_bringup

Launch files that launch the complete simulation of the robot/s

Simulating Summit XL

This simulation has been tested using Gazebo 9 version.

Installation and run instruccions

1. Install the following dependencies:

To facilitate the installation you can use the vcstool:

sudo apt-get install -y python3-vcstool

2. Create a workspace and clone the repository:

mkdir catkin_ws
cd catkin_ws

Install the latest version of the simulation:

vcs import --input https://raw.githubusercontent.com/RobotnikAutomation/summit_xl_sim/melodic-devel/repos/summit_xl_sim_devel.repos

Install the ROS dependencies

rosdep install --from-paths src --ignore-src --skip-keys="summit_xl_robot_control marker_mapping robotnik_locator robotnik_pose_filter robotnik_gazebo_elevator" -y -r

3. Compile:

catkin build
source devel/setup.bash

ONLY: if catkin build doesn't work: The package catkin-tools is need to compile with catkin build:

sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu `lsb_release -sc` main" > /etc/apt/sources.list.d/ros-latest.list'
wget http://packages.ros.org/ros.key -O - | sudo apt-key add -
sudo apt-get update
sudo apt-get install python-catkin-tools

4. Launch Summit XL simulation (1 robot by default, up to 3 robots):

Summit XL:

roslaunch summit_xl_sim_bringup summit_xl_complete.launch

Summit XL with Trossen Arm

roslaunch summit_xl_sim_bringup summit_xl_complete.launch default_xacro:=summit_xl_tix_std.urdf.xacro launch_arm_a:=true arm_manufacturer_a:=trossen arm_model_a:=vx300s

Launch moveit to plan trajectories:

ROS_NAMESPACE=robot roslaunch summit_xl_vx300s_moveit_config demo.launch

Summit XL with Kinova Arm

roslaunch summit_xl_sim_bringup summit_xl_complete.launch default_xacro:=summit_xl_gen_std.urdf.xacro launch_arm_a:=true arm_manufacturer_a:=kinova arm_model_a:=j2s7s300 amcl_and_mapserver_a:=false move_base_robot_a:=false

Note: in this configuration the robot has not laser, therefore the amcl is turned off. When Rviz is opened, change robot_map to robot_odom in fixed_frame in order to visualize the robot.

or Summit XL Steel:

roslaunch summit_xl_sim_bringup summit_xls_complete.launch

Optional general arguments:

<arg name="launch_rviz" default="true"/>
<arg name="gazebo_world" default="$(find summit_xl_gazebo)/worlds/summit_xl_office.world"/>
<arg name="omni_drive" default="false"/> (only for Summit XL)
<arg name="use_gpu_for_simulation" default="false"/>

By default the Gazebo plugin Planar Move to ignore the physics of the wheels + the skid steering kinematics. In case you want to disable this plugin, set the following arguments:

roslaunch summit_xl_sim_bringup summit_xl_complete.launch \
  ros_planar_move_plugin:=false \
  omni_drive:=false

Optional robot arguments:

<!--arguments for each robot (example for robot A)-->
<arg name="id_robot_a" default="robot"/>
<arg name="launch_robot_a" default="true"/>
<arg name="map_file_a" default="willow_garage/willow_garage.yaml"/>
<arg name="localization_robot_a" default="false"/>
<arg name="gmapping_robot_a" default="false"/>
<arg name="amcl_and_mapserver_a" default="true"/>
<arg name="x_init_pose_robot_a" default="0" />
<arg name="y_init_pose_robot_a" default="0" />
<arg name="z_init_pose_robot_a" default="0" />
<arg name="xacro_robot_a" default="summit_xl_std.urdf.xacro"/>
  • Example to launch simulation with 3 Summit XL robots:
roslaunch summit_xl_sim_bringup summit_xl_complete.launch \
  launch_robot_b:=true \
  launch_robot_c:=true
  • Example to launch simulation with 1 Summit XL robot with navigation:
roslaunch summit_xl_sim_bringup summit_xl_complete.launch \
  move_base_robot_a:=true \
  amcl_and_mapserver_a:=true

Enjoy! You can use the topic ${id_robot}/robotnik_base_control/cmd_vel to control the Summit XL robot or send simple goals using /${id_robot}/move_base_simple/goal

Docker usage

Installation of required files

Intel GPU

Nvidia GPU

Usage

git clone https://github.com/RobotnikAutomation/summit_xl_sim.git
cd summit_xl_sim
git checkout melodic-devel
export ROS_BU_PKG="summit_xl_sim_bringup"
export ROS_BU_LAUNCH="summit_xl_complete.launch"
nvidia-smi &>/dev/null \
&& ln -sf docker-compose-nvidia.yml docker-compose.yml \
|| ln -sf docker-compose-intel.yml docker-compose.yml
docker compose up

Selecting the robot model

You can select the robot, the launch file of package using the optional arguments on launch By default the selected robot is summit_xl

Summit XL GEN

export ROS_BU_PKG="summit_xl_sim_bringup"
export ROS_BU_LAUNCH="summit_xl_gen_complete.launch"
docker compose up

Summit XLS

export ROS_BU_PKG="summit_xl_sim_bringup"
export ROS_BU_LAUNCH="summit_xls_complete.launch"
docker compose up

Manual Build

If you wish to build the image without launching the simulation use the following commands:

cd docker
docker compose build

Notes

This is docker requires a graphical interface

  • In order to exit you have to 2 options

  • The ROS_MASTER_URI is accessible outside the container, so in the host any ros command should work

  • You could also run a roscore previous to launch the simulation in order to have some processes on the host running

  • if you want to enter on the container use the following command in another terminal

  1. Close gazebo and rviz and wait a bit

  2. execute in another terminal:

    docker container rm --force summit_xl_sim_instance

Notes

  • This is docker requires a graphical interface

  • The ROS_MASTER_URI is accessible outside the container, so in the host any ros command should work

  • You could also run a roscore previous to launch the simulation in order to have some processes on the host running

  • if you want to enter on the container use the following command in another terminal

    docker container exec -it docker-base-1 bash
  • In order to exit you have to 2 options

  1. Close gazebo and rviz and wait a bit

  2. execute in another terminal in the same folder than the docker-compose.yml:

    docker compose down

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.