New documentation has been created as .media/Trajectory-Linear-Circular.pdf. Please refer ther for a more in depth introduction to the code and project.
You can find some useful commands here ./how-to-run.md. Also, ./commands.md has some useful utilities for working with real robot.
git clone git@gitlab.lrz.de:00000000014B74D8/assignment-2-group-1.git
git checkout mainModify the .env file replacing
<username>with your username (i.e., the output ofwhoamiin your terminal) inUSERNAME=<username><username>with your username inROS_WS=/home/<username>/ros_ws(ROS_WSwill be the path of your ROS2 workspace in the container)
Reason: these variables are used to setup the container user with same credential of the host (by default the container would run as superuser). Among several benefits, this implies that all the files generated by the container have the same ownership of the one generated by the host. For further info, refer to this [guide][dockerROS2guide].
At the first usage, build the docker image using the following command in the project folder:
./setup_docker.bashOpen a terminal in the project folder and run:
docker compose upIn some systems instead of using docker compose you have to use docker-compose command. Change it in the setup_docker.bash as well.
Now a docker container is running on your machine. To access the container, open another terminal and run:
docker compose exec -it gazebo_franka_ros1-ros1_node-1 bashthis is the equivalent of opening a terminal on your Ubuntu installation but on the Ubuntu installation running in the container.
where gazebo_franka_ros1-ros1_node-1 is the name of the container you want to access. To see the names of all the container running on your machine, you can use docker ps.
Access a running container and use the following command to initialize your catkin_ws:
catkin_makeStart simulation with robot arm:
roslaunch franka_gazebo panda.launch x:=-0.5 \
controller:=cartesian_impedance_example_controller \
use_gripper:=false\
rviz:=trueStart simulation with robot arm with pick-and-place setup:
roslaunch franka_gazebo panda.launch x:=-0.5 \
world:=$(rospack find demo_pkg)/world/pick_place.sdf \
controller:=cartesian_impedance_example_controller \
rviz:=trueStart simulation using impedance controller:
roslaunch franka_gazebo panda.launch \
world:=$(rospack find demo_pkg)/world/polish.sdf \
controller:=cartesian_impedance_example_controller \
use_gripper:=false \
rviz:=false \
interactive_marker:=false
In src folder, run:
catkin_make