4-195
Detailed explanation of command words
4MELFA-BASIC IV
Error (error)
[Function]
This instruction makes a program generate an error (9000s number).
[Format]
[Terminology]
<Error No.>
Either a constant or numeric operation expression can be set. Designate the No. within the range
of 9000 to 9299.
[Reference Program]
(1) Generate the error 9000.
:
10 Error 9000
(2) Change the error number to generate corresponding to the value of M1.
4 If M1 <> 0 Then *LERR
' When M1 is not 0, branches to "*LERR".
:
14 *LERR
15 MERR=9000+M1*10
' Calculate the error number according to the value of M1.
16 Error MERR
' The calculated error number is generated.
17 End
[Explanation]
(1) It is possible to generate any error in the 9000's number range by executing this instruction.
(2) If a LOW level or HIGH level error is generated, the program is paused.
Steps after the Error instruction are not executed. A CAUTION error does not pause a program; the
next step and onward are executed. The action of system by error number is shown in the
.
(3) It is possible to create up to 20 error messages using parameters UER1 to UER20.
(4) A system error occurs if a value outside the error number range shown in
Table 4-16:Action of system by error number
[Related parameter]
UER1 to 20
Error[]<Error No.>
No.
System behavior
9000 to 9099
(H level error)
The program execution is stopped, and the servo power is shut off.
The error state is reset when error reset is input.
9100 to 9199
(L level error)
The program execution is stopped.
The error state is reset when error reset is input.
9200 to 9299
(CAUTION)
The program execution is continued.
The error state is reset when error reset is input.