Skip to content

Latest commit

 

History

History
69 lines (56 loc) · 2.43 KB

README.md

File metadata and controls

69 lines (56 loc) · 2.43 KB

Curiosity Rover - Demo

This is a simple demo of controlling the canadarm using spaceROS.

Installation

To start the demo, there are few dependencies that need to be installed. The following steps will guide you through the installation process.

  1. You will need ROS Humble on your host system. If it is not already installed, you can follow the instructions here.
  2. You will need Gazebo Sim installed on your system. If not, you can follow the instructions here.
  3. You will need docker installed on your system. If not, you can follow the instructions here.
  4. Install xterm for running the demo. You can install it using the following command.
    sudo apt-get install xterm

How to run the demo

  1. Clone the demo repository
    git clone http://github.com/space-ros/demo.git
  2. cd into the canadarm2 directory
    cd canadarm2
  3. To build and run the demo, we use ./build.sh. There are different subcommands to build and run the demo. You can see the list of available commands using the following command.
    # To see the list of available commands
    ./build.sh help
  4. To list the avaiable demos for the canadarm2, you can use the following command.
    # To list the available demos
    ./build.sh list
    
    # Available demos:
    # -  control-demo
    # Available subcommands:
    # -  build, clean, run
  5. To build the demo, you can use the following command.
    # To build all the demos for the canadarm2
    ./build.sh build
    
    # To build a selected demo, for example control-demo
    ./build.sh build control-demo
  6. To run the demo, you can use the following command.
    # To run the demo
    ./build.sh run control-demo

This will start the demo in one terminal and gazebo in another terminal. To control the canadarm2, we provide ros2 services for the demo. You can control the rover using the following services.

  1. Control arm of the canadarm

    # To open an arm in outstretched position
    ros2 service call /open_arm std_srvs/srv/Empty
    
    # To move the arm to its default close pose of all zeros
    ros2 service call /close_arm std_srvs/srv/Empty
    
    # To move the arm to a random pose
    ros2 service call /random_arm std_srvs/srv/Empty