{"id":21103123,"url":"https://github.com/robotnikautomation/rb1_base_sim","last_synced_at":"2025-05-16T18:35:00.398Z","repository":{"id":55351375,"uuid":"52738398","full_name":"RobotnikAutomation/rb1_base_sim","owner":"RobotnikAutomation","description":"Packages for the simulation of the RB-1 Base robots","archived":false,"fork":false,"pushed_at":"2024-01-04T14:23:01.000Z","size":1603,"stargazers_count":10,"open_issues_count":6,"forks_count":12,"subscribers_count":9,"default_branch":"melodic-devel","last_synced_at":"2024-01-04T15:34:01.636Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-2-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/RobotnikAutomation.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2016-02-28T19:13:24.000Z","updated_at":"2023-08-07T16:55:42.000Z","dependencies_parsed_at":"2024-01-04T15:43:35.308Z","dependency_job_id":null,"html_url":"https://github.com/RobotnikAutomation/rb1_base_sim","commit_stats":null,"previous_names":[],"tags_count":7,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RobotnikAutomation%2Frb1_base_sim","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RobotnikAutomation%2Frb1_base_sim/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RobotnikAutomation%2Frb1_base_sim/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RobotnikAutomation%2Frb1_base_sim/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/RobotnikAutomation","download_url":"https://codeload.github.com/RobotnikAutomation/rb1_base_sim/tar.gz/refs/heads/melodic-devel","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225444578,"owners_count":17475354,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-19T23:57:46.321Z","updated_at":"2024-11-19T23:57:47.002Z","avatar_url":"https://github.com/RobotnikAutomation.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# rb1_base_sim\n\n\nPackages for the simulation of the RB-1 Base\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"doc/rb1_base.jpeg\" height=\"275\" /\u003e\n\u003c/p\u003e\n\n\n## Packages\n\n### rb1_base_gazebo\n\nThis package contains the configuration files and worlds to launch the Gazebo environment along with the simulated robot.\n\n### rb1_base_sim_bringup\n\nLaunch files that launch the complete simulation of the robot/s.\n\n\n## Simulating RB-1 Base\n\n### 1) Install the following dependencies:\n\nThis simulation has been tested using Gazebo 9 version. To facilitate the installation you can use the vcstool:\n\n```bash\nsudo apt-get install -y python3-vcstool\n```\n\n### 2) Create a workspace and clone the repository:\n\n```bash\nmkdir catkin_ws\ncd catkin_ws\nvcs import --input \\\n  https://raw.githubusercontent.com/RobotnikAutomation/rb1_base_sim/melodic-devel/repos/rb1_base_sim.repos\nrosdep install --from-paths src --ignore-src -y\n```\n\n### 3) Compile:\n\n```bash\ncatkin build\nsource devel/setup.bash\n```\n\n\n### 4) Launch RB-1 Base simulation (1 robot by default, up to 3 robots):\n- RB-1 Base:\n\n```bash\nroslaunch rb1_base_sim_bringup rb1_base_complete.launch\n```\n\nOptional general arguments:\n```xml\n\u003carg name=\"launch_rviz\" default=\"true\"/\u003e\n\u003carg\n  name=\"gazebo_world\"\n  default=\"$(find rb1_base_gazebo)/worlds/demo.world\"\n/\u003e\n```\n  Optional robot arguments:\n```xml\n\u003c!--arguments for each robot (example for robot A)--\u003e\n\u003carg name=\"id_robot_a\" default=\"robot\"/\u003e\n\u003carg name=\"launch_robot_a\" default=\"true\"/\u003e\n\u003carg name=\"has_elevator_robot_a\" default=\"true\"/\u003e\n\u003carg name=\"x_init_pose_robot_a\" default=\"0.0\" /\u003e\n\u003carg name=\"y_init_pose_robot_a\" default=\"0.0\" /\u003e\n\u003carg name=\"z_init_pose_robot_a\" default=\"0.0\" /\u003e\n\u003carg name=\"init_yaw_robot_a\" default=\"0.0\" /\u003e\n\u003carg name=\"gmapping_robot_a\" default=\"false\"/\u003e\n\u003carg name=\"amcl_and_mapserver_robot_a\" default=\"true\"/\u003e\n\u003carg name=\"map_frame_robot_a\" default=\"$(arg id_robot_a)_map\"/\u003e\n\u003carg\n  name=\"map_file_robot_a\"\n  default=\"$(find rb1_base_localization)/maps/demo/demo.yaml\"\n/\u003e\n\u003carg name=\"move_base_robot_a\" default=\"true\"/\u003e\n\u003carg name=\"pad_robot_a\" default=\"true\"/\u003e\n```\n- Example to launch simulation with 3 RB-1 Base robots:\n```bash\nroslaunch rb1_base_sim_bringup rb1_base_complete.launch \\\n  launch_robot_a:=true \\\n  launch_robot_b:=true \\\n  launch_robot_c:=true\n```\n- Example to launch simulation with 1 RB-1 Base robot with navigation and localization:\n```bash\nroslaunch rb1_base_sim_bringup rb1_base_complete.launch \\\n  launch_robot_a:=true \\\n  move_base_robot_a:=true \\\n  amcl_and_mapserver_robot_a:=true\n```\n- Example to launch simulation with 2 RB-1 Base robot with navigation and localization sharing the same global frame:\n```bash\nroslaunch rb1_base_sim_bringup rb1_base_complete.launch \\\n  launch_robot_a:=true \\\n  amcl_and_mapserver_robot_a:=true \\\n  move_base_robot_a:=true \\\n  map_frame_a:=/map \\\n  launch_robot_b:=true \\\n  amcl_and_mapserver_robot_b:=true \\\n  move_base_robot_b:=true \\\n  map_frame_b:=/map\n```\n- Example to launch simulation with 3 RB-1 Base robot with navigation and localization sharing the same global frame:\n```bash\nroslaunch rb1_base_sim_bringup rb1_base_complete.launch \\\n  launch_robot_a:=true \\\n  amcl_and_mapserver_robot_a:=true \\\n  move_base_robot_a:=true \\\n  map_frame_a:=/map \\\n  launch_robot_b:=true \\\n  amcl_and_mapserver_robot_b:=true \\\n  move_base_robot_b:=true \\\n  map_frame_b:=/map \\\n  launch_robot_c:=true \\\n  amcl_and_mapserver_robot_c:=true \\\n  move_base_robot_c:=true \\\n  map_frame_c:=/map\n```\n\n### Comands and data retreving\n**Enjoy! You can use the topic `${id_robot}/robotnik_base_control/cmd_vel` to control the RB-1 Base robot:**\n\n```bash\nrostopic pub /robot/robotnik_base_control/cmd_vel geometry_msgs/Twist \"linear:\n  x: 0.1\n  y: 0.0\n  z: 0.0\nangular:\n  x: 0.0\n  y: 0.0\n  z: 0.0\" -r 10\n```\n\nor if you have launched move_base, you can send simple goals using `/${id_robot}/move_base_simple/goal`:\n```bash\nrostopic pub /robot/move_base_simple/goal geometry_msgs/PoseStamped \"header:\n  seq: 0\n  stamp:\n    secs: 0\n    nsecs: 0\n  frame_id: 'robot_map'\npose:\n  position:\n    x: 3.0\n    y: 0.0\n    z: 0.0\n  orientation:\n    x: 0.0\n    y: 0.0\n    z: 0.0\n    w: 1.0\" \n```\n\n## Docker usage\n\nIn order to run this simulation you will need nvidia graphical accelation\n\n### Installation of required files\n- [docker](https://docs.docker.com/engine/install/ubuntu/)\n- [nvidia-docker](https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/install-guide.html#docker)\n- nvidia-drivers\n\n### Usage\n\n```bash\ngit clone https://github.com/RobotnikAutomation/rb1_base_sim.git\ncd rb1_base_sim\ngit checkout melodic-devel\ncd docker\nexport ROS_BU_PKG=\"rb1_base_sim_bringup\"\nexport ROS_BU_LAUNCH=\"rb1_base_complete.launch\"\ndocker compose up\n\n```\n#### Docker permission fix\n\nIn order to run this simulation it's mandatory to the current linux user to have full docker permission. If the script fails due to that, please execute the following command:\n```bash\nsudo usermod -aG docker $USER\nnewgrp docker\n```\n#### Selecting the robot model\n\nYou can select the robot, the launch file of package using the optional arguments on launch\nBy default the selected robot is `rb1_base`\n\n```bash\ndocker/simulation-in-container-run.sh --help\n```\n\n```\nROBOTNIK AUTOMATION S.L.L. 2021\n\nSimulation of RB1 BASE using docker\n\nUsage:\ndocker/simulation-in-container-run.sh [OPTIONS]\n\nOptional arguments:\n --robot -r ROBOT       Select robot to simulate\n                        Valid robots:\n                            multirobot_2 multirobot_3 rb1_base\n                        default: rb1_base\n\n --launch -l            Select launch file\n                        default: rb1_base_complete.launch \\\n                                 launch_robot_a:=true \\\n                                 move_base_robot_a:=true \\\n                                 amcl_and_mapserver_robot_a:=true\n\n --package -p           Select ros package\n                        default: rb1_base_sim_bringup\n\n --ros-port -u PORT     Host ros port\n                        default: 11345\n\n --gazebo-port -g PORT  Host ros port\n                        default: 11345\n\n -h, --help             Shows this help\n\n```\n\n**2 robots simulation**\n```bash\ndocker/simulation-in-container-run.sh --robot multirobot_2\n```\n\n**3 robots simulation**\n```bash\ndocker/simulation-in-container-run.sh --robot multirobot_3\n```\n\n#### Manual Build\n\nIf you wish to build manually the image without the use of the script use one the following commands:\n\n**Optiona A**\n```bash\ncd docker\ndocker build -f Dockerfile ..\n```\n**Option B**\n```bash\ndocker build -f docker/Dockerfile .\n```\n\n#### Notes\n\n- This is docker requires a graphical interface\n- The ros master uri is accesible outside the container, so in the host any ros command should work\n- You could also run a roscore previous to launch the simulation in order to have some processes on the host running\n- if you want to enter on the container use the following command in another terminal\n```bash\ndocker container exec -it docker-base-1 bash\n```\n- In order to exit you have to 2 options\n1. Close `gazebo` and `rviz` and wait a bit\n2. execute in another terminal:\n```bash\ndocker container rm --force rb1_base_sim_instance\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frobotnikautomation%2Frb1_base_sim","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frobotnikautomation%2Frb1_base_sim","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frobotnikautomation%2Frb1_base_sim/lists"}