Industrial Robot Laboratory Staeubli
Industrial Robot Laboratory Staeubli
Industrial Robot Laboratory Staeubli
microRoboticLab
TABLE OF CONTENTS
1.
2.
3.
4.
5.
2.1.
Starting up ............................................................................................................................... 4
2.2.
2.2.1.
2.2.2.
2.2.3.
2.2.4.
2.2.5.
Programming ................................................................................................................................... 7
3.1.
Overview.................................................................................................................................. 7
3.2.
3.3.
3.3.1.
Data ................................................................................................................................. 8
3.3.2.
Programs ......................................................................................................................... 9
4.2.
4.2.1.
Comment ....................................................................................................................... 13
4.2.2.
4.2.3.
4.2.4.
4.2.5.
4.2.6.
4.2.7.
5.2.
microRoboticLab
1. CONFIGURATION OF THE ROBOT
The figure shows the assembling. The Robot (1) Arm RS20 by Stubli is a SCARA robot. There are also
two Cameras (2+3) to detect the pieces.
Camera1
key
green button
CS8C M
Rotation Table
MCP
Camera2
microRoboticLab
2. GETTING STARTED
2.1. STARTING UP
-
Put the key to manual mode and be sure the emergency switches are released
Remove the MCP from the holder and remount it
press the green button on the right
(if there is a message appearing on the screen, you have to remove and remount the MCP
again)
microRoboticLab
2.2.1. MOVING WITH JOINT MODE
Press the Joint button and then move the robot with +/- x,
y and z. Take care; the z-direction is very fast!
j1=x
j2=y
j3=rz
Rz
Ry
2.2.3. SAVE POINTS
Rx
microRoboticLab
2.2.4. RUN A PROGRAM
-
If something dangerous happen: Press as fast as possible the red emergency shutdown!
microRoboticLab
3. PROGRAMMING
3.1. OVERVIEW
Cell Manager
Defines the robot which is used
VAL3 Studio
The Editor to Write VAL3 code,
is only working with the dongle
(small green USB-Stick)
CS8 Emulator
Simulation of the controller,
there you can check network
connection, programs and so
on as the robot would run.
3D Studio
Shows the robot as 3D Model,
when connected with the
Emulator you see the movement
Transfer Manager
Makes a connection to the robot,
to transfer files or points between
robot and PC
microRoboticLab
3.3.
VAL3 STUDIO
3.3.1. DATA
Your Program
microRoboticLab
3.3.2. PROGRAMS
A program is a sequence of VAL3 instructions to be
executed. A program consists of the following elements:
Your Program
microRoboticLab
4. THE VAL3 LANGUAGE ELEMENTS
The VAL3 language does not have any terminator at the end of each line. Brackets are not often used
as well. But the loops are, always terminated with a terminator, like while. endWhile.
Detail informations are in the VAL3 Help search VAL3 language elements. In the hand out is just a
little overview with the most important informations.
bBool = true
nPi = 3.141592653
sString = "this is a string"
Structured Types:
-
program dummy
p = {{100, -50, 200, 0, 0, 0}, {sfree, efree, wfree}}
in another program:
call dummy
10
microRoboticLab
4.2. IMPORTANT INSTRUCTIONS
To move the robot
movel(pPosition, tTool, mDesc)
movej(pPosition, tTool, mDesc)
movej(jPosition, tTool, mDesc)
pPosition:
jPoint:
tTool:
mDesc:
Note:
The difference between points and joints is that a joint position is defined by only
one arm configuration. In opposition, almost all points can be reached in two
different arm configurations (left and right) -> we saw it in chapter 2.2.1 and 2.2.2
waitEndMove()
wait until the arm reaches the destination point
note:
without the command waitEndMove() the controller goes on even if the movements
are not completed or its not even possible to complete them.
To define a specific frame and move relative to it
setFrame(pPoint01,pPoint02,pPoint03,fFrame)
pPoint04 = compose(pPoint01, fFrame,
{j*trTrsform.x,k*trTrsform.y,0,0,0,0})
movej(pPoint04, tTool, mDesc)
fFrame:
trTrsform:
is a variable world-frame
is a variable Trsf
trTrsform define the steps in x and y direction in the frame
11
microRoboticLab
To use the vacuum griper
dioLink (dVacuum, io:valve2)
dioLink (dBlow, io:valve1)
dVacuum=true ; dVacuum=false
dBlow = true ; dBlow = false
sioVariable = string
string = sioVariable
toString()
insert()
Computes the numerical represented at the beginning of the string specified, and
returns a string in which all the characters have been deleted until the next
representation of a numerical value
Returns a character string representing nValue according to the display format
Returns a string which a string is inserted after positon index character
12
microRoboticLab
4.3. SEQUENCE CONTROL INSTRUCTION
4.3.1. COMMENT
// This is an example of a comment
//s = ?
if a==0
s=0
endIf
//s= a=0 If a=0, else a<>0
if a==0
s= a=0
else
s=a<>0
endIf
13
microRoboticLab
4.3.4. WHILE CONTROL INSTRUCTION
The instructions between while and endWhile are executed when the Boolean Condition expression
is (true). If the Boolean Condition expression is not true at the first evaluation, the instructions
between while and endWhile are not executed.
Parameter
bool bCondition
14
microRoboticLab
jDest = {0,0,0,0,0,0}
// Rotates axis 1 from 90 to -90 in -10-degree steps
for i = 90 to -90 step -10
jDest.j1 = i
movej(jDest, flange, mNomSpeed)
waitEndMove()
endFor
num nMenu
string s
// Tests the menu key pressed
nMenu = get()
switch nMenu
case 271
s = "Menu 1"
break
case 272
s= "Menu 2"
break
case 273, 274, 275, 276, 277, 278
s = "Menu 3 to 8"
break
default
s = "this key is not a menu key"
break
endSwitch
15
microRoboticLab
5. VISIO OPENCV
5.1. GETTING STARTED
A. Start the PC labelled as OpenCV Stubli OLD
B. Login local (Username: labo-533 Password: labo-533
16
microRoboticLab
6. EXERCISES ROBOTPC
6.1. EXERCISE 1 FIRST STEPS
make a program to move the robot like a P&P with adapted speed and precision
teach points and run the program
17