/ur_fabrication_control

ur_fabrication_control with ROS industrial

Primary LanguagePythonMIT LicenseMIT

UR Robot Simulation and Control Environment

Quick links: compas docs | compas_fab docs | urdf and moveit tutorials | simulation playground | troubleshooting

Requirements

(1): Windows 10 Home does not support running Docker.

Visualizing Robot Model

  • Open the files rhino/ur_robot_model.3dm and rhino/ur_robot_model.ghx.
  • First, you need to load a specified robot model by pressing the load button (you can choose the model from a list of urdf files).
  • Once, the model is loaded, you can add and remove a tool in the Tool cluster and manipulate the joints with the sliders in the Configuration cluster.

Simulation Playground

  • Start the Docker ROS moveit simulation environment, by going to VS code and start the docker containers by:
    • Only once: If you do this the first time, you have to build the local Dockerfile via
      • right-click and Build or
      • in the Terminal (cd to folder) via
        docker build --rm -f Dockerfile -t augmentedfabricationlab/ros-ur-planner .
      • (Building without cache:
        docker build --no-cache --rm -f Dockerfile -t augmentedfabricationlab/ros-ur-planner .)
      • Tag your Docker Image as: augmentedfabricationlab/ros-ur-planner:latest
    • Always: Run the docker image that matches your robot model, e.g. ros-ur10e-rot-demo/docker-compose.yml via
      • right-click on the file Compose-up or
      • type docker-compose up -d in the Terminal (cd to folder) to start it.
      • when ending, don't forget to stop the image via docker-compose down -d
  • For access to the web UI of the docker image, start your browser and go to:
    http://localhost:8080/vnc.html?resize=scale&autoconnect=true
  • Open the files rhino/ur_robot_setup.3dm and rhino/ur_robot_setup.ghx and connect to the ROS client via the rosbridge and load the robot model directly from ROS. You can now query all moveit related services (compute_ik, trajectory planning, etc.)

Control

  • tbd

General Notes

Docker Setup Information

  • Docker user name: augmentedfabricationlab
  • The robotic_setups_description repository contains the robot descriptions files for the Dockerfile building.
  • The robotic_setups repository contains the catkin workspace for the urdf models and moveit packages for various robotic setups of our lab, for setting up the systems in Linux as described in this tutorial.
  • The ros-base and novnc images are remote images and drawn from the gramaziokohler docker hub organization.

Moveit on Linux

when ROS should be connected between 2 machines via Ethernet (and not via localhost), the ROS MASTER and IPP should be changed via

nano ~/.bashrc

and set accordingly:

export ROS_MASTER_URI=http://10.10.0.1:11311
export ROS_IP=10.10.0.1

after pulling a new urdf description into robotic_setups repository run

catkin_make
source devel/setup.bash

then you can configure a new moveit package via

roslaunch moveit_setup_assistant setup_assistant.launch 

Then run again catkin_make and source devel/setup.bash and run your moveit demo pacakge:

roslaunch your_package_name_moveit_config  demo.launch rviz_tutorial:=true

And push the files to the remote repository.

Docker Troubleshooting

Sometimes things don't go as expected. Here are some of answers to the most common issues you might bump into:

Q: Docker does not start. It complains virtualization not enabled in BIOS.

This is vendor specific, depending on the manufacturer of your computer, there are different ways to fix this, but usually, pressing a key (usually F2 for Lenovo) before Windows even start will take you to the BIOS of your machine. In there, you will find a Virtualization tab where this feature can be enabled.

Q: Cannot start containers, nor do anything with Docker. Error message indicates docker daemon not accessible or no response.

Make sure docker is running. Especially after a fresh install, docker does not start immediately. Go to the start menu, and start Docker for Windows.