KUKA robots

RoboDK supports all KUKA robot controllers since KRC2, including KUKA KRC3 and KRC4 controllers. This documentation is based on a KRC4 controller.The KRC4 robot controller runs the Microsoft Embedded Windows 7 operating system. Previous controllers, such as KRC2, run Windows 95. The robot teach pendant shows an “HMI” which is a program that KUKA developed to run on Windows and it is the interface that the robot user must use manipulate the robot.

The following sections demonstrate typical operations using a KUKA robot teach pendant to prepare a new program in RoboDK and transfer it to the robot.

Transfer a robot program

Follow these steps to load a program form a USB disk to your KUKA KRC4 robot controller.

1.Insert the USB disk on the robot controller (it is much faster than using the teach pendant connection)

2.If we don’t see the USB disk we must enter inAdministratormode

3.Select the file from the USB disk

4.SelectEditCopy

5.Select a folder in the KRC unit

6.SelectEditPaste

Robots KUKA - Image 1Robots KUKA - Image 2

Post Processor behavior

When generating robot programs for KUKA KRC robot controllers you can define the coordinate systems ($BASE) and tools ($TOOL) given the same coordinates you entered in RoboDK or numbered coordinate systems and numbered tools respectively.

By default, RoboDK exports the full pose (XYZABC values) of your tool and coordinate system the same way you entered them in RoboDK. The following code shows an example of what RoboDK generates for a KUKA SRC robot program:

; ---- Setting tool (TCP) ----------

; TOOL_DATA[3]={FRAME: X 116.058,Y 0.0,Z 219.481,A 0.0,B 60.0,C 0.0}

$TOOL = {FRAME: X 116.058,Y 0.0,Z 219.481,A 0.0,B 60.0,C 0.0}

; $TOOL=TOOL_DATA[3]

; ----------------------------------

; ---- Setting reference (Base) ----

; BASE_DATA[1]={FRAME: X 640.289,Y -290.0,Z 0.0,A 90.0,B 0.0,C 0.0}

$BASE = {FRAME: X 640.289,Y -290.0,Z 0.0,A 90.0,B 0.0,C 0.0}

; $BASE = BASE_DATA[1]

; ----------------------------------

On the other hand, if you prefer linking your tool ($TOOL variable) and coordinate system ($BASE variable) to numbered tools and reference frames, you can change the following variables in your post processor:

FRAME_INDEX: Set this variable to True to link your coordinate system to a numbered base frame. You should make sure your reference frame has a number in your RoboDK station as shown in the following image.

TOOL_INDEX: Set this variable to True to link your tool to a numbered tool. You should make sure your tool has a number in your RoboDK station as shown in the following image.

Robots KUKA - Image 3

Start a robot program

Follow these steps to start a robot program on your KUKA KRC4 controller.

1.从选择一个项目KRC memory unit

2.SelectSelecton the screen

3.Select the button “R” (top) andReset program

4.Start the program by selecting green “Play” button on the teach pendant

Robots KUKA - Image 4Robots KUKA - Image 5

Retrieving the TCP

The following steps allow you to create or modify robot tools (TCP) from your robot controller, also known as$TOOLin KUKA KRC robot programming):

1.SelectMENUStart-upCalibrateTool

2.Select a tool and edit or retrieve the X,Y,Z position of the TCP.

Robots KUKA - Image 6Robots KUKA - Image 7

Retrieving the robot joints

The following steps allow you to retrieve the robot joints from your robot:

1.SelectMENUDisplayActual position

2.SelectJointsmode and use the left column to take the robot joints

Robots KUKA - Image 8Robots KUKA - Image 9

Administrator mode

Some menu sections require “Administrator” rights. The following steps allow entering in “Administrator” mode:

1.SelectMENUConfigurationUser group

2.SelectAdministrator(or other).

3.Enter the password if required (default password is “kuka”)

Robots KUKA - Image 10Robots KUKA - Image 11


RoboDK driver for KUKA

Robot drivers provide an alternative to Offline Programming (where a program is generated, then, transferred to the robot and executed). With robot drivers, it is possible to run a simulation directly on the robot (Online Programming). More information available in theRobot Driverssection.

A connection between RoboDK and the KUKA robot can be established to move the robot automatically from a connected PC using RoboDK. This allows using the RoboDKRun on robotoption for online programming and debugging. The connection can be established through a standard Ethernet connection (TCP/IP).

Follow these steps to set up the RoboDK driver for KUKA:

1.Connect a mouse (optional, but strongly recommended).
It is possible to plug USB devices to the teach pendant or the controller (reboot is not required).
Alternatively, it is possible to establish a remote desktop connection.
These steps can also be accomplished using the teach pendant’s touch screen and the virtual keyboard.

2.Using the KUKA HMI application it is possible to open the main menu using the KUKA buttonRobots KUKA - Image 12, at the top left of the screen:

a.Robots KUKA - Image 13KUKAConfigurationUser groupchooseAdministrator(password:kuka)

b.Robots KUKA - Image 14KUKAStart-upServiceMinimize HMI(the windows screen will appear)

3.Copy the KUKAVARPROXY folder on the Desktop (or somewhere in the controller PC)

4.Allow port 7000 for TCP/UDP communication (this step is not required on KUKA KRC2 controllers):

a.Select the HMI.

b.Robots KUKA - Image 15KUKAStart-upNetwork configurationAdvanced

c.NATAdd portPort number 7000

d.Set permitted protocols:tcp/udp

5.Start the KUKAVARPROXY.EXE program on the robot controller (running on Windows).

6.The following steps allow starting the driver automatically on the controller on reboot (recommended):

a.Create a shortcut of the KUKAVARPROXY.EXE file

b.Select WindowsSTARTAll programsRight click startupOpen

c.Paste the shortcut in the startup folder

The KUKAVARPROXY server is now ready. You can leave this program running. This server allows exchanging global variables from the KUKA controller to the remote PC.

The next steps are to set up the main program that will handle the robot movements:

1.Add the declaration of the following global variables:
To do so, locate and modify the file “KRC\R1\STEU\$config.dat” (or in “KRC\R1\System\$config.dat” for KRC2 controllers). The folder “KRC\R1\” can also be accessed from the C:\ drive at the following Windows path: “C:\KRC\ROBOTER\KRC\”.

INT COM_ACTION=0

INT COM_ACTCNT=0

REAL COM_ROUNDM=0

REAL COM_VALUE1=0

REAL COM_VALUE2=0

REAL COM_VALUE3=0

REAL COM_VALUE4=0

DECL E6AXIS COM_E6AXIS

DECL FRAME COM_FRAME

DECL POS COM_POS

2.Copy the SRC program provided (RoboDKsynch.src) to the folderKRC\R1.

3.Manually start theRoboDKsynch.srcprogram to make the robot behave like a server that responds to move commands coming from the PC.

如果RoboDKsynch。src程序没有运行,抢劫oDK will still be able to read the robot joints anytime if the KUKAVARPROXY program is running in the robot controller.

External axes

You should be able to use the driver with KUKA robots even when you use external axes. On the other hand, it is recommended to use a numbered coordinate system or a coordinate system you have defined on your robot controller. By following this procedure, you don’t need to perfectly match the kinematics of your external axes in RoboDK.

For example, to be able to use the RoboDK driver by default, the kinematics of your external axes defined in the robot controller should match the kinematics created in RoboDK. Also, if you have a turntable, the root point of the turntable should match the position of the turntable defined in RoboDK.

Follow these steps to use the driver using a known coordinate system:

1.SelectToolsOptionsDriverstab.

2.Check the optionProvide Cartesian coordinates with respect to the reference.

Robots KUKA - Image 16

3.Replace the$BASEvariable of yourRoboDKsynch.srcprogram file by the coordinate system you want to use.

For example, if you want to use the base reference frame number 5, the RoboDKsync.src file should look like this (the first line is commented, you should find it around line 25):

; $BASE = {FRAME: X 0,Y 0,Z 0,A 0,B 0,C 0}

$BASE = BASE_DATA[5]

This coordinate system must have been defined in the KUKA robot controller and RoboDK will not override this value.

Robot calibration

You can use RoboDK to calibrate KUKA robots that have already been calibrated by KUKA using the Absolute Accuracy option. However, you should make sure to deactivate this option in the KUKA robot controller. When you calibrate a KUKA robot that has already been calibrated by KUKA using the Absolute Accuracy option it is important to deactivate this option so you can calibrate it using RoboDK.

To deactivate KUKA’s Absolute Accuracyyou should set variableDEACTIVATE_ABS_ACCURtoTRUE. You can find this variable in the fileKRC:\STEU\MADA\$custom.dat(around line 73).

你可以确保库卡的绝对准确性option has been properly deactivated by moving the robot to a known position (for example, move the robot axes of the real robot and in RoboDK to the home position) and make sure the Cartesian position displayed by the robot controller matches the same Cartesian position displayed by RoboDK.