![Mitsubishi Electric A173UHCPU Скачать руководство пользователя страница 371](http://html.mh-extra.com/html/mitsubishi-electric/a173uhcpu/a173uhcpu_programming-manual_238567371.webp)
APPENDICES
APP
−
54
4.2
Error Code Reading
A program that reads the error code when an error occurs is shown here.
The following signals are used to determine whether or not an error has occurred:
•
Minor errors, major errors............Error detection signal (M2407+20n)
•
Servo errors .................................Servo error detection signal (M2408+20n)
POINT
(1) The following delay occurs between the leading edge (OFF
→
ON) of
M2407+20n/M2408+20n and storage of the error code.
(a) If the sequence program scan time is less than 80 ms, there will be a
delay of up to 80 ms.
(b) If the sequence program scan time is longer than 80 ms, there will be
a delay of up to one scan time.
Program so that error code reading is executed after sufficient time
has elapsed for error codes to be written in the various error code
storage areas after M2407+20n/M2408+20n comes ON.
[Program Example]
(1) A program that converts the error code to BCD and outputs it to Y000 to Y00F
when an axis 1 error occurs (minor error, major error) is shown here.
System configuration
Sequence program
M2407
BCD
P
D6
Y0000
CIRCUIT END
0
K4
Error detection signal for axis 1
Y000 to Y00F designation
Error code storage area for
axis 1
BCD conversion instruction
BCD
P
D7
Y0000
K4
M2408
BCD
P
D8
Y0000
K4
<>
D6
0
<>
D7
0
<>
D8
0
Major error code storage area
for axis 1
Minor error code storage area
for axis 1
For determining whether or not
an error code is stored
Minor error output
Servo error output
K
K
K
A273UH
CPU
A278
LX
AY40
Y000
to
Y00F
P
o
wer s
upp
ly
m
odul
e
A61P