Download as pdf or txt
Download as pdf or txt
You are on page 1of 14

3.

1
t

Overview of the industrial robot


The industrial robot consists of the following components:

Manipulator
KUKA Robot
Robot controller

June 2016

Teach pendant

Robot
specifications
Connecting
cables
Software
Kuka industrial robot type: KR360R2830 C4 FLR with controller type: KRC4 v8.3.17.
Options, accessories

Fig. 3-1: Example of an industrial robot


Figure 1: Industrial robot KUKA with controller KRC4
1

Manipulator

Teach pendant

Robotofcontroller
4 Connecting cables
In Figure 1 2
elements
the industrial robot are shown.

3.2

1. Manipulator

Overview of the robot controller

2. Robot controller

3. Teach pendant

4. Connecting cables
The robot controller consists of the following components:

1.1

Robot
Axis
Control
PClimits
(KPC) and Coordinate Systems

Low-voltage power supply unit


In KRC4 kuka robot controller four different coordinate systems are defined for motion:
Drive power supply with drive controller: KUKA Power Pack (KPP)
Drive
controller:
KUKA Servo
Packis(KSP)
TOOL
- origin
of this coordinate
system
the tip of the tool attached to the robots head
Teach pendant (KUKA smartPAD)
BASE - origin of this coordinate system is located at the workpiece
Cabinet Control Unit (CCU)
Controller
System
Panel (CSP)
WORLD
- reference
coordinate
system
Safety Interface Board (SIB)
ROBOT BASE - origin of this coordinate system is robots base
Fuse elements
Batteries
If necessary,
additional auxiliary coordinate system can be defined. The four coordinate systems
above
Fansare graphically shown in Figure 2.
mentioned
Connection panel

Issued: 26.01.2015 Version: BA KR C4 GI V11

15 / 221

WORLD

ROBROOT

BASE

KUKA Robot

June 2016

TOOL

Figure 2: of
Industrial
robot
KUKA coordinate systems
Fig. 4-12: Overview
coordinate
systems
KUKA System Software 8.3

Description
WORLD
Tip point of kuka robot has 6 Degrees of Freedom (DOF) which is made available with synchronous
rotation of the 6 axes of the robot. Axes are name as Ai, i=1..6. Figure 3 shows kuka robots axes
rotation directions. Limits of rotation of all axes areIssued:
given 14.01.2015
in Table 1.
Version: KSS 8.3 SI V4

Figure 3: Industrial robot KUKA axess range of motion


Fig. 4-13: Axis-specific jogging
There are 2 operator control elements that can be used for jogging the robot:

Jog keys

Space Mouse

Overview

Cartesian jogging
Jog keys

(>>> 4.14.6 "Cartesian jogging with the jog keys"

Axis-specific jogging
(>>> 4.14.5 "Axis-specific
jogging with the jog keys"

KUKA Robot

June 2016

Table 1: KUKA Robots axes limits


Axis
A1
A2
A3
A4
A5
A6

1.2

Limits [ ]
min max
-185
185
-130
20
-100
144
-350
350
-120
120
-350
350

Operating Modes

KUKA robot has four operating modes from which two are teaching and two are automatic. Table
2 lists operating modes of KUKA robot.
Table 2: KUKA robots operating modes
Operating Mode
$T1
$T2
$AUT
$EXT

1.2.1

Definition
Teaching mode with reduces speed
Teaching mode with full speed
Automatic mode
Automatic mode with external control

Operating mode: $EXT

When external operating mode is selected, KUKA robot is controlled via PLC. Selected motion
programs are inserted in the CELL.SRC file in the case switch. Before changing to external mode,
CELL.SRC program needs to be selected in T1 mode. CELL.SRC is run until BCO path reached
appears as an acknowledgment. After this operation has been carried out, KUKA robot can be
switched to external mode.
Example of the case switch in CELL.SRC is given in Listing 1.
Listing 1: CELL.SRC
DEF

CELL ( )

INIT
BASISTECH INI
CHECK HOME
PTP HOME Vel= 100 % DEFAULT
AUTOEXT INI
LOOP
P00 (#EXT PGNO,#PGNO GET,DMY[ ] , 0 )
SWITCH PGNO ; S e l e c t with Programnumber
CASE 0
;DO NOTHING
CASE 1

KUKA Robot

P00 (#EXT PGNO,#PGNO ACKN,DMY[ ] , 0 )


GET FROM LBS( )
PULSE($OUT[ 6 5 ] , TRUE, 1 )
CASE 2
P00 (#EXT PGNO,#PGNO ACKN,DMY[ ] , 0 )
PUT TO FWD1( )
PULSE($OUT[ 6 6 ] , TRUE, 1 )
CASE 3
P00 (#EXT PGNO,#PGNO ACKN,DMY[ ] , 0 )
PUT TO FWD2( )
PULSE($OUT[ 6 7 ] , TRUE, 1 )
CASE 4
P00 (#EXT PGNO,#PGNO ACKN,DMY[ ] , 0 )
GET FROM FWD1( )
PULSE($OUT[ 6 8 ] , TRUE, 1 )
CASE 5
P00 (#EXT PGNO,#PGNO ACKN,DMY[ ] , 0 )
GET FROM FWD2( )
PULSE($OUT[ 6 9 ] , TRUE, 1 )
CASE 6
P00 (#EXT PGNO,#PGNO ACKN,DMY[ ] , 0 )
PUT TO BIS ( )
PULSE($OUT[ 7 0 ] , TRUE, 1 )
CASE 7
P00 (#EXT PGNO,#PGNO ACKN,DMY[ ] , 0 )
GET FROM BIS( )
PULSE($OUT[ 7 1 ] , TRUE, 1 )
CASE 8
P00 (#EXT PGNO,#PGNO ACKN,DMY[ ] , 0 )
PUT TO CCO1( )
PULSE($OUT[ 7 2 ] , TRUE, 1 )
CASE 9
P00 (#EXT PGNO,#PGNO ACKN,DMY[ ] , 0 )
PUT TO CCO2( )
PULSE($OUT[ 7 3 ] , TRUE, 1 )
CASE 10
P00 (#EXT PGNO,#PGNO ACKN,DMY[ ] , 0 )
GET FROM CCO1( )
PULSE($OUT[ 7 4 ] , TRUE, 1 )
CASE 11
P00 (#EXT PGNO,#PGNO ACKN,DMY[ ] , 0 )

June 2016

KUKA Robot

June 2016

GET FROM CCO2( )


PULSE($OUT[ 7 5 ] , TRUE, 1 )
CASE 12
P00 (#EXT PGNO,#PGNO ACKN,DMY[ ] , 0 )
PUT TO DOF( )
PULSE($OUT[ 7 6 ] , TRUE, 1 )
CASE 13
P00 (#EXT PGNO,#PGNO ACKN,DMY[ ] , 0 )
LINER WEIGHT MEASUREMENT( )
PULSE($OUT[ 7 6 ] , TRUE, 1 )
DEFAULT
P00 (#EXT PGNO,#PGNO FAULT,DMY[ ] , 0 )
ENDSWITCH
ENDLOOP
END
Key variables to be configured for operation in external mode of KUKA robot are described in Table
3 and Table 4, inputs and outputs respectively.
Table 3: Digital inputs to KUKA robot and system variables to be configured for external mode
operation

Digital Inputs To
KUKA/KUKA
system vars

Var Name

sys var

PGNO TYPE

sys var

PGNO LENGTH

$IN[25]

PGNO FBIT

$IN[50]

$EXT START

$IN[60]

$MOVE ENABLE

$IN[70]

$CONF MESS

$IN[60]

$DRIVES OFF

$IN[80]

$DRIVES ON

$IN[33] to $IN[120]

feedRate

Description

How program number sent from


PLC is read by KUKA; Value: 1,
2, 3
Length in bits of program number sent from PLC; Maximum 16
bit
First bit of the program number
Start/Resume program on rising
edge
HIGH signal required at all time
Pulse required to acknowledgment
Kept HIGH; when LOW pulse
detected drives are turned off
HIGH pulse to turn drives ON
8 bit integer input for feedrate in
EXT mode

Program is selected by setting a digital input to KUKA robot to HIGH. Variables, PGNO TYPE,
PGNO LENGTH and PGNO FBIT described in Table 3 are used send program number from PLC
to KUKA robot.
PGNO TYPE variable can have values 1, 2 and 3. In this it is selected 3. This settings finds the

KUKA Robot

June 2016

Table 4: Digital outputs to KUKA robot and system variables to be configured for external mode
operation

Digital Outputs From


KUKA/KUKA
system vars
$OUT[137]
$OUT[2]
$OUT[3]
$OUT[4]
$OUT[5]
$OUT[140]
$OUT[7]
$OUT[8]
$OUT[9]
$OUT[20]
$OUT[33]
$OUT[34]
$OUT[23]
$OUT[40]
FALSE
FALSE
FALSE
FALSE
FALSE
$OUT[50]
$OUT[147]
$OUT[52]
$OUT[60]
$OUT[61]
$OUT[62]
$OUT[63]

Var Name

$RC RDY1
$ALARM STOP
$USER SAF
$PERI RDY
$ROB CAL
$I O ACTCONF
$STOPMESS

Description

controller state; HIGH if ready


HIGH if emergency circuit closed
HIGH if operator safety closed
HIGH if drives are ready
HIGH if robot is mastered
HIGH if interface is active
HIGH if there is a collective fault
first bit if program mirroring is
PGNO FBIT REFL
TRUE
HIGH if there is internal emer$ALARM STOP I
gency STOP
$PRO ACT
HIGH if there is active program
HIGH if request for prog no is
PGNO REQ
sent
HIGH if motion program is acAPPL RUN
tive and running
$PRO MOVE
HIGH if robot is moving
HIGH if robot is in HOME posi$IN HOME
tion
HIGH if robot is in HOME1 po$IN HOME1
sition
HIGH if robot is in HOME2 po$IN HOME2
sition
HIGH if robot is in HOME3 po$IN HOME3
sition
HIGH if robot is in HOME4 po$IN HOME4
sition
HIGH if robot is in HOME5 po$IN HOME5
sition
$ON PATH
HIGH if robot is on path
$NEAR POSRET
HIGH if robot is near path
$ROB STOPPED
HIGH if robot is stopped
$T1
HIGH if operating mode is T1
$T2
HIGH if operating mode is T2
HIGH if operating mode is auto$AUT
matic
HIGH if operating mode is exter$EXT
nal

KUKA Robot

June 2016

one in an array of zeros and counts its place, thus setting program number.
PGNO FBIT variable tells KUKA from which KUKA digital input the program number definition
starts. Here it starts from $IN[25].
PGNO LENGTH is the number of bits (digital inputs to KUKA) used to define the program number. Program number definition starts at $IN[25] adding 16, which is the value of PGNO LENGTH,
and ends at $IN[40].
In Table 5 in Appendix A profinet and KUKA digital inputs/outputs mapping is shown.

SPS.SUB-cyclically executed program in KUKA KRC4


controller

SPS.SUB routine is cyclically executed in KUKA KRC4 controller. Under USER DEFINED
PLC code is added to overwrite feed rate of KUKA robot in external mode, and another piece of
code is added which sends KUKA robots TCP position along x, y and z-axes to PLC
User PLC code is given in Listing 2.
Listing 2: User PLC in SPS.SUB routine
; Send p o s i t i o n t o PLC
IF $PRO MOVE==TRUE THEN
; c o n v e r t p o s i t i o n from r e a l t o i n t by
; m u l t i p l y i n g with 10 t o r e t a i n one d e c i m a l p l a c e
intXpos=$POS ACT .X10 ; p o s i t i o n a l o n g x
intYpos=$POS ACT .Y10 ; p o s i t i o n a l o n g y
i n t Z p o s=$POS ACT . Z10 ; p o s i t i o n a l o n g z
; check f o r n e g a t i v e v a l u e s , change t o
; p o s i t i v e and s e t s i g n b i t t o HIGH
IF intXpos <0 THEN
intXpos=1intXpos ; x p o s i t i o n
$OUT[ 2 0 3 ] =TRUE
; sign bit
ELSE
$OUT[ 2 0 3 ] =FALSE
ENDIF
IF intYpos <0 THEN
intYpos=1intYpos ; y p o s i t i o n
$OUT[ 2 0 4 ] =TRUE
; sign bit
ELSE
$OUT[ 2 0 4 ] =FALSE
ENDIF
IF i n t Z p o s <0 THEN
i n t Z p o s=1i n t Z p o s ; z p o s i t i o n
$OUT[ 2 0 5 ] =TRUE
; sign bit
ELSE
$OUT[ 2 0 5 ] =FALSE
ENDIF
; send p o s i t i o n t o a s s i g n e d D i g i t a l Outputs
xPos=intXpos ; 16 b i t from OUT[ 2 4 1 ] t o OUT[ 2 5 6 ]
yPos=intYpos ; 16 b i t from OUT[ 2 2 5 ] t o OUT[ 2 4 0 ]

KUKA Robot

June 2016

zPos=i n t Z p o s ; 16 b i t from OUT[ 1 7 7 ] t o OUT[ 1 9 2 ]


ENDIF
; s t o p and c a n c e l program i n EXT mode
IF $MODE OP==#EX THEN
; check i f f e e d r a t e i s v a l i d
; i f i n v a l i d s e t to v a l i d
IF f e e d R a t e > 100 THEN
f e e d R a t e = 100
ENDIF
IF f e e d R a t e < 0 THEN
feedRate = 0
ENDIF
; set feedrate
$OV PRO = f e e d R a t e ;
IF $IN [ 2 0 0 ] == TRUE THEN
CWRITE($CMD, STAT,MODE, STOP ) ; s t o p program , c o n t i n u e with $EXT START
ENDIF
IF $IN [ 2 0 1 ] == TRUE THEN
CWRITE($CMD, STAT,MODE, CANCEL ) ; c a n c e l s e l e c t e d program
ENDIF
ENDIF
; workspace s e l e c t i o n
; i n p u t s a f e t y zone
SWITCH s a f e t y Z o n e S e l e c t
CASE 1
s e l e c t e d S a f e t y Z o n e=#Green
CASE 2
s e l e c t e d S a f e t y Z o n e=#Pu rple
CASE 3
s e l e c t e d S a f e t y Z o n e=#BLUE
CASE 4
s e l e c t e d S a f e t y Z o n e=#Magenta
DEFAULT
s e l e c t e d S a f e t y Z o n e=#none
ENDSWITCH
; a c t i v a t e s a f e t y zone
IF s e l e c t e d S a f e t y Z o n e == #none THEN
$WORKSPACE [ 1 ] .MODE=#OFF
$WORKSPACE [ 2 ] .MODE=#OFF
$WORKSPACE [ 3 ] .MODE=#OFF
$WORKSPACE [ 4 ] .MODE=#OFF
ENDIF
IF s e l e c t e d S a f e t y Z o n e == #Purp le THEN
$WORKSPACE [ 1 ] .MODE=#OFF

KUKA Robot

June 2016

$WORKSPACE [ 2 ] .MODE=#OFF
$WORKSPACE [ 3 ] .MODE=#OFF
$WORKSPACE [ 4 ] .MODE=#OFF
ENDIF
IF s e l e c t e d S a f e t y Z o n e == #Blue THEN
$WORKSPACE [ 1 ] .MODE=#OFF
$WORKSPACE [ 2 ] .MODE=#OFF
$WORKSPACE [ 3 ] .MODE=#OFF
$WORKSPACE [ 4 ] .MODE=#OFF
ENDIF
IF s e l e c t e d S a f e t y Z o n e == #Magenta THEN
$WORKSPACE [ 1 ] .MODE=#OFF
$WORKSPACE [ 2 ] .MODE=#OFF
$WORKSPACE [ 3 ] .MODE=#OFF
$WORKSPACE [ 4 ] .MODE=#OFF
ENDIF

IO mapping
Table 5: KUKA Robot IO - Profinet signal mapping

Profinet
KUKA IO

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22

KUKA IN
DI
36.0
36.1
36.2
36.3
36.4
36.5
36.6
36.7
37.0
37.1
37.2
37.3
37.4
37.5
37.6
37.7
38.0
38.1
38.2
38.3
38.4
38.5

DQ
36.0
36.1
36.2
36.3
36.4
36.5
36.6
36.7
37.0
37.1
37.2
37.3
37.4
37.5
37.6
37.7
38.0
38.1
38.2
38.3
38.4
38.5

KUKA OUT

$ALARM STOP
$USER SAF
$PERI RDY
$ROB CAL

$STOPMESS
PGNO FBIT REFL
$ALARM STOP I

$PRO ACT

KUKA Robot

June 2016

23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59

38.6
38.7
39.0
39.1
39.2
39.3
39.4
39.5
39.6
39.7
40.0
40.1
40.2
40.3
40.4
40.5
40.6
40.7
41.0
41.1
41.2
41.3
41.4
41.5
41.6
41.7
42.0
42.1
42.2
42.3
42.4
42.5
42.6
42.7
43.0
43.1
43.2

38.6
38.7
39.0
39.1
39.2
39.3
39.4
39.5
39.6
39.7
40.0
40.1
40.2
40.3
40.4
40.5
40.6
40.7
41.0
41.1
41.2
41.3
41.4
41.5
41.6
41.7
42.0
42.1
42.2
42.3
42.4
42.5
42.6
42.7
43.0
43.1
43.2

60

43.3 43.3

61
62
63
64
65
66
67
68
69
70
71
72

43.4
43.5
43.6
43.7
44.0
44.1
44.2
44.3
44.4
44.5
44.6
44.7

43.4
43.5
43.6
43.7
44.0
44.1
44.2
44.3
44.4
44.5
44.6
44.7

PGNO
PGNO
PGNO
PGNO
PGNO
PGNO
PGNO
PGNO
PGNO
PGNO
PGNO
PGNO
PGNO
PGNO
PGNO
PGNO

$EXT START

$MOVE ENABLE &


$DRIVES OFF

$CONF MESS

$PRO MOVE

PGNO REQ
APPL RUN

$IN HOME

$ON PATH

$ROB STOPPED

$T1
$T2
$AUT
$EXT

KUKA Robot

June 2016

73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123

45.0
45.1
45.2
45.3
45.4
45.5
45.6
45.7
46.0
46.1
46.2
46.3
46.4
46.5
46.6
46.7
47.0
47.1
47.2
47.3
47.4
47.5
47.6
47.7
48.0
48.1
48.2
48.3
48.4
48.5
48.6
48.7
49.0
49.1
49.2
49.3
49.4
49.5
49.6
49.7
50.0
50.1
50.2
50.3
50.4
50.5
50.6
50.7
51.0
51.1
51.2

45.0
45.1
45.2
45.3
45.4
45.5
45.6
45.7
46.0
46.1
46.2
46.3
46.4
46.5
46.6
46.7
47.0
47.1
47.2
47.3
47.4
47.5
47.6
47.7
48.0
48.1
48.2
48.3
48.4
48.5
48.6
48.7
49.0
49.1
49.2
49.3
49.4
49.5
49.6
49.7
50.0
50.1
50.2
50.3
50.4
50.5
50.6
50.7
51.0
51.1
51.2

$DRIVES ON

feed Rate
feed Rate
feed Rate
feed Rate
feed Rate
feed Rate
feed Rate
feed Rate
feed Rate
feed Rate
feed Rate
feed Rate
feed Rate
feed Rate
feed Rate
feed Rate

KUKA Robot

June 2016

124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174

51.3
51.4
51.5
51.6
51.7
52.0
52.1
52.2
52.3
52.4
52.5
52.6
52.7
53.0
53.1
53.2
53.3
53.4
53.5
53.6
53.7
54.0
54.1
54.2
54.3
54.4
54.5
54.6
54.7
55.0
55.1
55.2
55.3
55.4
55.5
55.6
55.7
56.0
56.1
56.2
56.3
56.4
56.5
56.6
56.7
57.0
57.1
57.2
57.3
57.4
57.5

51.3
51.4
51.5
51.6
51.7
52.0
52.1
52.2
52.3
52.4
52.5
52.6
52.7
53.0
53.1
53.2
53.3
53.4
53.5
53.6
53.7
54.0
54.1
54.2
54.3
54.4
54.5
54.6
54.7
55.0
55.1
55.2
55.3
55.4
55.5
55.6
55.7
56.0
56.1
56.2
56.3
56.4
56.5
56.6
56.7
57.0
57.1
57.2
57.3
57.4
57.5

$RC RDY1

$I O ACTCONF

$NEAR POSRET

KUKA Robot

June 2016

175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225

57.6
57.7
58.0
58.1
58.2
58.3
58.4
58.5
58.6
58.7
59.0
59.1
59.2
59.3
59.4
59.5
59.6
59.7
60.0
60.1
60.2
60.3
60.4
60.5
60.6
60.7
61.0
61.1
61.2
61.3
61.4
61.5
61.6
61.7
62.0
62.1
62.2
62.3
62.4
62.5
62.6
62.7
63.0
63.1
63.2
63.3
63.4
63.5
63.6
63.7
64.0

57.6
57.7
58.0
58.1
58.2
58.3
58.4
58.5
58.6
58.7
59.0
59.1
59.2
59.3
59.4
59.5
59.6
59.7
60.0
60.1
60.2
60.3
60.4
60.5
60.6
60.7
61.0
61.1
61.2
61.3
61.4
61.5
61.6
61.7
62.0
62.1
62.2
62.3
62.4
62.5
62.6
62.7
63.0
63.1
63.2
63.3
63.4
63.5
63.6
63.7
64.0

zPos sign bit 205; bit1


zPos sign bit 205; bit2
zPos sign bit 205; bit3
zPos sign bit 205; bit4
zPos sign bit 205; bit5
zPos sign bit 205; bit6
zPos sign bit 205; bit7
zPos sign bit 205; bit8
zPos sign bit 205; bit9
zPos sign bit 205; bit10
zPos sign bit 205; bit11
zPos sign bit 205; bit12
zPos sign bit 205; bit13
zPos sign bit 205; bit14
zPos sign bit 205; bit15
zPos sign bit 205; bit16

xPos sign bit


yPos sign bit
zPos sign bit

yPos sign bit 204; bit1

KUKA Robot

June 2016

226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256

64.1
64.2
64.3
64.4
64.5
64.6
64.7
65.0
65.1
65.2
65.3
65.4
65.5
65.6
65.7
66.0
66.1
66.2
66.3
66.4
66.5
66.6
66.7
67.0
67.1
67.2
67.3
67.4
67.5
67.6
67.7

64.1
64.2
64.3
64.4
64.5
64.6
64.7
65.0
65.1
65.2
65.3
65.4
65.5
65.6
65.7
66.0
66.1
66.2
66.3
66.4
66.5
66.6
66.7
67.0
67.1
67.2
67.3
67.4
67.5
67.6
67.7

yPos sign bit 204; bit2


yPos sign bit 204; bit3
yPos sign bit 204; bit4
yPos sign bit 204; bit5
yPos sign bit 204; bit6
yPos sign bit 204; bit7
yPos sign bit 204; bit8
yPos sign bit 204; bit9
yPos sign bit 204; bit10
yPos sign bit 204; bit11
yPos sign bit 204; bit12
yPos sign bit 204; bit13
yPos sign bit 204; bit14
yPos sign bit 204; bit15
yPos sign bit 204; bit16
xPos sign bit 203; bit1
xPos sign bit 203; bit2
xPos sign bit 203; bit3
xPos sign bit 203; bit4
xPos sign bit 203; bit5
xPos sign bit 203; bit6
xPos sign bit 203; bit7
xPos sign bit 203; bit8
xPos sign bit 203; bit9
xPos sign bit 203; bit10
xPos sign bit 203; bit11
xPos sign bit 203; bit12
xPos sign bit 203; bit13
xPos sign bit 203; bit14
xPos sign bit 203; bit15
xPos sign bit 203; bit16

You might also like