EasyManuals Logo

Omron TJ2-MC64 - PROGRAMMING User Manual

Omron TJ2-MC64 - PROGRAMMING
362 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #55 background imageLoading...
Page #55 background image
BASIC commands
PROGRAMMING MANUAL 49
Revision 1.0
Example A suction pick and place system must vary its speed depending on the load
carried. The mechanism has a load cell which inputs to the controller on the
analogue channel (AIN).
The move profile is fixed, but the time taken to complete this move must be
varied depending on the AIN. The AIN value varies from 100 to 800, which
must result in a move time of 1 to 8 seconds. If the speed is set to 10000 units
per second and the required time is 1 to 8 seconds, then the distance param-
eter must range from 10000 to 80000. (distance = speed x time).
The return trip can be completed in 0.5 seconds and so the distance value of
5000 is fixed for the return movement. The Multiplier is set to -1 to reverse the
motion.
GOSUB profile_gen 'loads the cam profile into the table
SPEED=10000:ACCEL=SPEED*1000:DECEL=SPEED*1000
WHILE IN(2)=ON
OP(15,ON) 'turn on suction
load=AIN(0) 'capture load value
distance = 100*load 'calculate the distance parameter
CAM(0,200,50,distance) 'move 50mm forward in time calculated
WAIT IDLE
OP(15,OFF) 'turn off suction
WA(100)
CAM(0,200,-50,5000) 'move back to pick up position
WEND
profile_gen:
num_p=201
scale=400 'set scale so that multiplier is in mm
FOR p=0 TO num_p-1
TABLE(p,((-SIN(PI*2*p/num_p)/(PI*2))+p/num_p)*scale)
NEXT p
RETURN
See also ACCEL, AXIS, CAMBOX, SPEED, TABLE.

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Omron TJ2-MC64 - PROGRAMMING and is the answer not in the manual?

Omron TJ2-MC64 - PROGRAMMING Specifications

General IconGeneral
BrandOmron
ModelTJ2-MC64 - PROGRAMMING
CategoryController
LanguageEnglish

Related product manuals