Download V+ Language User`s Guide, Ver. 13.0

Transcript
Chapter 5
Program Interrupt Instructions
45
MOVE b
46
LOCK 20;Defer any REACTions to "alarm"
47
MOVE c
48
MOVE d
49
LOCK 0;Allow REACTions
50
MOVE e
51
52
; Disable monitoring of signal 1001
53
54
IGNORE −1001
55 .
If signal 1001 transitions during execution of step 43, step 43 will complete, the
subroutine alarm will be called, and execution will resume at step 44.
If signal 1001 transitions during execution of step 47, steps 47, 48, and 49 will
complete (since the program had been given a higher priority than REACT), the
subroutine alarm will be called, and execution will resume at step 50.1
REACTE
REACTE enables a reaction program that is run whenever a system error that
would cause program execution to terminate is encountered. This includes all
robot errors, hardware errors, and most system errors (it does NOT include I/O
errors).
Unlike REACT and REACTI, REACTE cannot be deferred based on priority
considerations. The instruction:
REACTE trouble
will enable monitoring of system errors and execute the program trouble
whenever a system error is generated.
1
The LOCK instruction can be used to control execution of a program after a REACT or REACTI
subroutine has completed.
V+ Language User’s Guide, Rev A
137