IMS MicroLYNX Quick Manual page 64

Hide thumbs Also See for MicroLYNX:
Table of Contents

Advertisement

S t e p 2 : D e f i n e P a r a m e t e r s
A program will typically perform functions such as monitor a switch, control a
solenoid or relay, drive a motor, read an encoder, etc. In order for the program to
react to external devices through the I/O, the I/O parameters should be set before
running the program.
Global variables or flags should also be defined at this point. Motion parameters
should be set also.
All these can be entered into the text editor. See program following next step for
example.
S t e p 3 : P r o g r a m E n t r y
The program is now entered into the text editor. The following program example
is broken down into its separate components for clarity. This example follows the
plan illustrated in the flowchart figure 11.1. This is a working program illustrating
how an output can be switched on-the-fly using the position trip functions. An
LED can be connected to I/O line 21 and this program can be entered as shown.
'******** Parameter Setup ********
MUNIT
VI
=
ACCL = 20
DECL = 50
IOS 21 = 0,1,0
'******** Main Program ********
PGM
LBL
ONTHEFLY
TP1 = 5, PSUB1
TP2 = 10, PSUB2
TPE1
TPE2 = 1
VM = 10
MOVA 4.25, 1
HOLD
VM = 2
MOVA 10.5
HOLD 2
DELAY 250
VM = 10
MOVA 0
HOLD 2
END
'******** Subroutines ********
LBL PSUB1
IO 21 = 1
RET
LBL PSUB2
IO 21 = 0
RET
PGM
62
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Arrow.com.
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
Downloaded from
=
51200
0.500
'set i/o 21 to:output - gen. purpose,
'active low
200
'configure 1st position trip at 5 revs
'configure 2nd position trip at 10 revs
=
1
'enable both position trips
'initial max speed 10 rps
'move out to 4.25 revs at 10 rps
0
'reduce max speed to 2 rps
'move to 10.5 revs
'reset max speed to 10 rps
'return to origin
'turn on output at 5 revs.
'turn off output at 10 revs

Advertisement

Table of Contents
loading

Table of Contents