
4.CONVERSATIONAL MACRO FUNCTION AND AUXILIARY MACRO FUNCTION B-63943EN-2/01
- 72 -
Termination
Terminate execution of the conversational macro function using one
of the following methods:
(1) Press a function key (such as
POS
or
PROG
) on the MDI
panel.
(2) Set the control variable for executing a conversational macro
(#8500) to 0.
(3) Screen switching request from the system due to an alarm or
another event
When a program end command (execution control code M99 or
M99Pp) in the main program is executed, the conversational macro
function determines whether any of the above factors that terminates
the conversational macro function has occurred.
If a factor that terminates execution has occurred, the screen display is
switched to a selected screen in the case of (1), or the screen display
returns to the screen displayed before selection of the conversational
macro screen in the case of (2). In the case of (3), the screen display
is switched to the screen requested by the system.
Carefully program a conversational macro because the conversational
macro function uses a program end command in the main program as
a timing as described above.
If the written program is like the following bad sample program, the
screen cannot be switched to another screen and the system enters the
hang-up state.
Bad sample Good sample
Key input?
O1234 ;
NO
YES
Key input processing
M99 ;
Key input?
O1234 ;
NO
YES
Key input processing
M99 ;
When programming a conversational macro, always specify M99 in
the same way as for a PMC ladder program to create a program which
returns to the beginning of the main program. Alternatively, specify
M99Pp to create a cyclic program which returns to the sequence
number specified for M99Pp.
For the above reasons, do not program a conversational macro in
which the GOTO command causes a branch in the backward
direction.