Kuka How TO
Kuka How TO
Kuka How TO
1
t
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
Manipulator
Teach pendant
Robotofcontroller
4 Connecting cables
In Figure 1 2
elements
the industrial robot are shown.
3.2
1. Manipulator
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
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
Jog keys
Space Mouse
Overview
Cartesian jogging
Jog keys
Axis-specific jogging
(>>> 4.14.5 "Axis-specific
jogging with the jog keys"
KUKA Robot
June 2016
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
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
June 2016
KUKA Robot
June 2016
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
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
Var Name
$RC RDY1
$ALARM STOP
$USER SAF
$PERI RDY
$ROB CAL
$I O ACTCONF
$STOPMESS
Description
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 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
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
$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
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