4-130 Multitask function
4MELFA-BASIC V
4.3.6 Example of using multitask
An example of the multitask execution is given in this section.
(1) Robot work details.
The robot programs are the "movement program" and "position data lead-in program".
The "movement program" is executed with slot 1, and the "position data lead-in program" is executed with
slot 2. If a start command is output to the sensor while the robot is moving, a request for data will be made
to the personal computer via the position data lead-in program. The personal computer sends the position
data to the robot based on the data request. The robot side leads in the compensation data via the position
data lead-in program.
<Process flow>
P1: Workpiece pickup position (Vacuum timer Dly 0.05)
P2: Workpiece placing position (Release timer Dly 0.05)
P3: Vision pre-position (Do not stop at penetration point Cnt)
P4: Vision shutter position (Do not stop at penetration point Cnt)
P_01: Vision compensation data
P20: Position obtained by adding P2 to vision compensation data (relative operation)
Workpiece pickup
Sensor start
Sensor recognition
Workpiece mounting
Operation program
Position data lead
-in program
Data confirmation
Start
Sensor start
Personal computer
Position data
setting
Data reception
Background execution
P1
P4
P2
P20
RS-
232C
StartStart
Data reception
Data reception
Position data
transmission
Above mounting
position
P1
X
Y
0
P2
P3 :No acceleration/deceleration
P4 : No acceleration/deceleration
Position to move vision