Standalone programs will not process a move command if the axis is already moving. This can create problems when the JOG function is used. Many times the following program is written:
WHILE 1=1
IF DI1=1
JOGX+
ELSE
STOPX
ENDIF
ENDWHILE
This becomes a problem because, if digital input 1 is triggered for too long, multiple JOG commands can be sent. Once the second JOG command is issued, the standalone program will wait for motion to stop before proceeding. This prevents the standalone program from issuing the STOP command. To resolve this issue, a program like the following should be used:
V1=0
WHILE 1=1
IF DI1=1
IF V1=0
JOGX+
V1=1
ENDIF
ELSE
STOPX
V1=0
ENDIF
ENDWHILE
This program will prevent the standalone program from issuing multiple JOG commands between STOP commands.
0 Comments