# mycobot_ros [](#contributors-) [](https://docs.elephantrobotics.com/docs/gitbook/12-ApplicationBaseROS/) [](https://docs.elephantrobotics.com/docs/gitbook-en/12-ApplicationBaseROS/) [δΈζζζ‘£](https://docs.elephantrobotics.com/docs/gitbook/12-ApplicationBaseROS/) | [English Documentation](https://docs.elephantrobotics.com/docs/gitbook-en/12-ApplicationBaseROS/) Control or simulate myCobot series robots in ROS.  **Notes**: * Make sure that `Atom` is flashed into the top Atom and `Transponder` or `minirobot` is flashed into the base Basic .The tool download address: [https://github.com/elephantrobotics/myCobot/tree/main/Software](https://github.com/elephantrobotics/myCobot/tree/main/Software) * Supported ROS versions: * Ubuntu 16.04 / ROS Kinetic * Ubuntu 18.04 / ROS Melodic * Ubuntu 20.04 / ROS Noetic * The urdf model of a single gripper in this article is applicable to all machines that support this accessory. ## Installation ### Option 1: Docker There are two ways to run this project. The first is by running the project in a container, and this requires [installing docker](https://docs.docker.com/engine/install/ubuntu/) and [installing docker-compose](https://docs.docker.com/compose/install/). The benefit of running in the container is that you can run the project in any version of linux, as long as your kernel is new enough. Once docker is installed, run the following command, and the project should show up. #### Without NVIDIA GPU: **ROS Noetic**: ``` docker-compose build ros-noetic && xhost +local:root && docker-compose up ros-noetic ``` **ROS Melodic**: ``` docker-compose build ros && xhost +local:root && docker-compose up ros ``` #### With NVIDIA GPU **ROS Noetic**: ``` docker-compose build nvidia-ros-noetic && xhost +local:root && docker-compose up nvidia-ros-noetic ``` **ROS Melodic**: ``` docker-compose build nvidia-ros && xhost +local:root && docker-compose up nvidia-ros ``` This command does three things: 1) `docker-compose build ros` This builds the project in a container. That means nothing is installed on your host machine! The first time this runs, this command will take a long while. After running it once, caching will allow this command to run quickly. 2) `xhost +local:root` This command gives X the ability to display GUI's from within the docker container 3) `docker-compose up ros` This runs the image specified in the `docker-compose.yml`, which by default runs the command `roslaunch mycobot_320 mycobot_320_slider.launch` within the container. To run other tutorials, set the LAUNCH_TARGET environment variable. For example, to the run the MoveIt tutorial run: ``` export LAUNCH_TARGET=mycobot_320_moveit mycobot320_moveit.launch docker-compose up ros ``` ### Option 2: Local #### 2.1 Pre-Requriements For using this package, the [Python api](https://github.com/elephantrobotics/pymycobot.git) library should be installed first. ```bash pip install pymycobot --user ``` #### 2.2 Package Download and Install Install ros package in your src folder of your Catkin workspace. ```bash $ cd ~/catkin_ws/src $ git clone --depth 1 https://github.com/elephantrobotics/mycobot_ros.git $ cd ~/catkin_ws $ catkin_make $ source ~/catkin_ws/devel/setup.bash $ sudo echo 'source ~/catkin_ws/devel/setup.bash' >> ~/.bashrc ``` #### 2.3 Test Python API ```bash cd ~/catkin_ws/src/mycobot_ros python test.py ``` ## Where to get help There is documentation in the [ElephantRobotics Docs](https://docs.elephantrobotics.com/docs/gitbook-en/). Please check the ROS chapter. ## Important Links & Docs * [User Guide](https://docs.elephantrobotics.com/docs/gitbook-en/12-ApplicationBaseROS/) ## Contributing Contributions are always welcome! See [CONTRIBUTING.md](CONTRIBUTING.md) for ways to get started. Please adhere to this project's [code of conduct](CODE_OF_CONDUCT.md). ## Screenshots       ## URDF Model Graph [mycobot 280 m5](./mycobot_description/urdf/mycobot_280_m5/mycobot_280_m5.urdf)  [mycobot 280 m5 gripper](./mycobot_description/urdf/mycobot_280_m5/mycobot_280m5_with_gripper_parallel.urdf)  [mycobot 280 m5 pump](./mycobot_description/urdf/mycobot_280_m5/mycobot_280m5_with_pump.urdf)  [mycobot 280 m5 camera flange](./mycobot_description/urdf/mycobot_280_m5/mycobot_280m5_with_camera_flange.urdf)  [mycobot 280 m5 camera flange & pump](./mycobot_description/urdf/mycobot_280_m5/mycobot_280m5_with_camera_flange_pump.urdf)  [mycobot 280 pi](./mycobot_description/urdf/mycobot_280_pi/mycobot_280_pi.urdf)  [mycobot 280 pi pump](./mycobot_description/urdf/mycobot_280_pi/mycobot_280pi_with_pump.urdf)  [mycobot 280 pi camera flange](./mycobot_description/urdf/mycobot_280_pi/mycobot_280pi_with_camera_flange.urdf)  [mycobot 280 pi camera flange & pump](./mycobot_description/urdf/mycobot_280_pi/mycobot_280pi_with_camera_flange_pump.urdf)  [mycobot 280 JetsonNano](./mycobot_description/urdf/mycobot_280_jn/mycobot_280_jn.urdf)  [mycobot 280 JetsonNano Adaptive gripper](./mycobot_description/urdf/mycobot_280_jn/mycobot_280_jn_adaptive_gripper_parallel.urdf)  [mycobot 280 JetsonNano Parallel gripper](./mycobot_description/urdf/mycobot_280_jn/mycobot_280_jn_parallel_gripper.urdf)  [mycobot 280 Arduino](./mycobot_description/urdf/mycobot_280_arduino/mycobot_280_arduino.urdf)  [mechArm 270 m5](./mycobot_description/urdf/mecharm_270_m5/mecharm_270_m5.urdf)  [mechArm 270 pi](./mycobot_description/urdf/mecharm_270_pi/mecharm_270_pi.urdf)  [myPalletizer 260 m5](./mycobot_description/urdf/mypalletizer_260_m5/mypalletizer_260_m5.urdf)  [myPalletizer 260 pi](./mycobot_description/urdf/mypalletizer_260_pi/mypalletizer_260_pi.urdf)  [mycobot 320 m5 2020](./mycobot_description/urdf/mycobot_320_m5_2020/mycobot_pro_320_m5_2020.urdf)  [mycobot 320 m5 2022](./mycobot_description/urdf/mycobot_320_m5_2022/new_mycobot_pro_320_m5_2022.urdf)  [mycobot 320 m5 2022 gripper](./mycobot_description/urdf/mycobot_320_m5_2022/new_mycobot_pro_320_m5_2022_gripper.urdf)  [mycobot 320 m5 2022 force control gripper](./mycobot_description/urdf/mycobot_320_m5_2022/pro_320_m5_2022_force_gripper.urdf)  [mycobot 320 pi 2022](./mycobot_description/urdf/mycobot_320_pi_2022/new_mycobot_pro_320_pi_2022.urdf)  [mycobot 320 pi 2022 gripper](./mycobot_description/urdf/mycobot_320_pi_2022/new_mycobot_pro_320_pi_2022_gripper.urdf)  [mycobot 320 pi 2022 force control gripper](./mycobot_description/urdf/mycobot_320_pi_2022/pro_320_pi_2022_force_gripper.urdf)  [ultraArm P340](./mycobot_description/urdf/ultraArm_p340/ultraArm_p340.urdf)  [mycobot 280 pi aikit](./mycobot_description/urdf/mycobot_280_pi/mycobot_280pi_with_vision_v2.urdf)  [mycobot 320 pi aikit](./mycobot_description/urdf/mycobot_320_pi_2022/new_mycobot_vision_v2_2022.urdf)  [mybuddy](./mycobot_description/urdf/mybuddy/mybuddy.urdf)  [mycobot pro 600](./mycobot_description/urdf/mycobot_pro_600/mycobot_pro_600.urdf)  [myArm 300 Pi](./mycobot_description/urdf/myarm_300_pi/myarm_300_pi.urdf)  [mycobot pro 630](./mycobot_description/urdf/mycobot_pro_630/mycobot_pro_630.urdf)  ## Single Gripper URDF Model Graph >> **This urdf model is applicable to all machines that support this accessory** [mycobot Adaptive gripper](./mycobot_description/urdf/adaptive_gripper/mycobot_adaptive_gripper.urdf)  [mycobot Parallel gripper](./mycobot_description/urdf/parallel_gripper/mycobot_parallel_gripper.urdf)  [mycobot Pro Adaptive gripper](./mycobot_description/urdf/pro_adaptive_gripper/mycobot_pro_adaptive_gripper.urdf)  ## Contributors Thanks goes to these people ([Emoji Key](https://allcontributors.org/docs/en/emoji-key)):