2 - 24 2 - 24
MELSEC-Q
2 USING THE E-MAIL FUNCTION
(3) Sample program
The following is a sample program for receiving e-mail by a PLC CPU.
It performs reception processing of e-mail using the receive command (X21).
When I/O signals of the Ethernet module are X/Y00 to X/Y1F.
Designate to make inquiry
to the server.
Designate to read the head mail.
Designate to adjust to the data
length of the receive mail.
Designate to adjust to the header
data length of the receive mail.
Read receive mails.
Processing program when normal completion
Processing program when abnormal completion
The following explains the types of execution that can be designated in the MRECV
instruction's control data. For more details on how to designate the execution types,
see Section 6.2 "MRECV Instruction".
Type of MRECV instruction execution
Designate whether or not to read the next mail
after executing the MRECV instruction.
b9 b8
Complete type
Setting value for
designating the
type of execution
b9
b8
Setting type
Description of processing
Merit
Demerit
0
0
Do not inquire
Do not read
Execute only e-mail read processing.
The inquiry (read) processing of the
remaining receive mail information is
executed after the time set with a
parameter of GX Developer has
elapsed.
Inquiries to the mail
server can be less
frequent.
The next receive mail
cannot be read
immediately.
Mails tend to
accumulate on the
mail server.
1
0
Inquire
Read
Execute read processing of e-mails.
After executing the MRECV
instruction, the inquiry (read)
processing of the remaining receive
mail information is also executed.
Mails received by the
mail server can be
read in succession.
Inquiries to the mail
server become more
frequent.
More processing in the
module affects other
internal processing.
Содержание QJ71E71-100 Series
Страница 2: ......
Страница 214: ...6 65 6 65 MELSEC Q 6 DEDICATED INSTRUCTIONS MEMO ...
Страница 219: ......