!&
SAMPLE PROGRAM - Eltrmsmp.tsk (Cont.)
PRINT USING#2,fmt$,Value
' Prints initial number
DO
Keypress=INCHAR(2)
LOOP WHILE Keypress=0
IF Keypress=13 THEN
CLRLINE 3
CLRLINE 4
DISP 4,5,"Edit Value"
GOSUB GetValue
END IF
IF keypress<>27 THEN GOTO Get_Repeat
repeat=value
RETURN
Execute:
' This section executes all of
ACCEL=50
' the parameters
DECEL=50
WNDGS=1
CLRSCRN
DISP 1,2,"MOTION IN PROGRESS"
X=0
DO UNTIL X=Repeat
MOVEI=Distance
WAITDONE
X=X+1
LOOP
RETURN
JOG_Forward:
CLRSCRN
' Print to the Display
DISP 2,1,"Jogging Forward"
' motor status
DISP 4,1,"Push <Esc> to STOP"
JOG=1
' Start jog cycle
DO
' Wait until the escape
Keypress=INCHAR(2) ' Key is pressed
LOOP WHILE Keypress<>27
STOP
' Stop jog cycle
RETURN
JOG_Reverse:
CLRSCRN
' Print motor status to the Display
DISP 2,1,"Jogging Reverse"
DISP 4,1,"Push <Esc> to STOP"
JOG=-1
' Start jog cycle
Vox Remote Operator Panel +1-972-234-4343 Richardson Texas 75081 USA http://www.voxtechnologies.com
StockCheck.com