================ Setup KUKA Robot ================ Requirements ============ - Robot controller: KRC2, KRC4 or KRC5 - Option RSI3, RSI4 or RSI5. Install driver and setup =========================== Until the relative command patch is merged, use the fork `rsi4_with_velocity_interface `_ instead of the `main repository `_. 1. Optional/Recommended: Follow the `Realtime Kernel setup guide `_ 2. Depending on your KRC version, follow one of the guides per the READMEs below to install the driver - `KRC2 `_ - `KRC4 `_ - `KRC5 `_ Notes ----- - Make sure that your ROS PC is connected to the right physical interface (ethernet port) on the KUKA controller. There are usually two interfaces of interest: one for transferring e.g. WorkVisual projects and the other for control with e.g. RSI. - There is usually a detailed documentation of RSI (and the other installed options) on your controller; refer to that for more information (i.e. ways to debug). (E.g. Log in at least as an Expert on the Teach Pad, then navigate to :code:`KUKA_DATA D(:\\)\\KUKA_OPT\\RobotSensorInterface\\DOC`). Optional -------- Make a backup of current KRC configuration before driver installation. (See also: https://www.youtube.com/watch?v=PtVohrofnLY) 1. Insert USB stick to robot controller cabinet 2. Change user group level to "Expert" 3. In File navigator select :code:`Archiv:\\` 4. Select Archiv everything on USB(cabinet) ROS launch file =============== To start the communication with the KUKA controller a ROS launch file is required. The following ROS launch file loads the driver for a KUKA KR270 robot. We recommend putting the robot into a namespace, for this example we use the robot model: e.g. ``/KUKA-KR270``. The lines of code which have to be changed for your robot are marked by in-line comments. .. code-block:: xml <-- Change to your IP --> <-- Change to your port --> <-- Change to your choosen namespace --> <-- Adapt for your robot type --> <-- Adapt for your robot type --> joint_state_controller: type: joint_state_controller/JointStateController publish_rate: 250 # RSI update rate pitasc environment ================== To let pitasc take joint states and urdf description from the robot namespace, it needs to be configured. Set the urdf prefix if you have one (``tf_prefix`` in the launch file). The only change required in the following code example is the namespace you choose in the ROS launch file. .. code-block:: xml 250.0 1.5 1.5 KUKA-KR270 0, 0, 0, 0, 0, 0 To start the application: 1. Start launch file: .. code-block:: console roslaunch 2. Start pitasc executor .. code-block:: console pitasc_executor_rossrv 3. Start :code:`rqt`, start the piteacher and load your xml file to start the program .. code-block:: console rqt -s "Pi Teacher"