11 - 416 11 - 416
MELSEC-Q
11 INSTRUCTIONS AND FUNCTIONS
Specifying continuous break characters
Control table format definition
Element position
Item
Description
%(0)
Processing code
Specify the processing code.
%(1)
Setting
Specify whether or not the setting is to be
enabled.
%(2)
Number of
characters
Specify the number of break characters.
Processing Code 24
%(3)
Break characters 1
and 2
Specify the code for break character 1 in the
lower byte and the code for break character 2 in
the higher byte.
Reading continuous break characters
Control table format definition
Element position
Item
Description
%(0)
Processing code
Specify the processing code.
%(1)
Setting
Read whether or not the setting is enabled.
%(2)
Number of
characters
Read the number of break characters.
Processing Code 25
%(3)
Break characters 1
and 2
Read the code for break character 1 into the
lower byte and the code for break character 2
into the higher byte.
• It is possible to set or read continuous break characters of an open
communication channel using these codes.
• Specify 24 for the processing code in order to set the continuous break
characters.
Specify 25 for the processing code in order to read the continuous break
characters.
• Specify whether or not continuous break characters should be enabled in
<setting>.
0 • • • Disabled
1 • • • Enabled
• Specify the number of break characters that ends the execution of a receive
request in <number of characters>.
Always specify 2 for this setting.
• Set the break characters in <break characters 1 and 2>.
Any code from 00
H
to FF
H
can be set as break characters.
If two characters in sequence equal to the set pair of break characters are
detected during the execution of the ZRECEIVE instruction, the reception data
until the continuous break characters is stored in the input element of the receive
request, after which the execution of the receive request is ended.
If only the first character in a given pair of data values matches the first break
character and the second character does not match the second break character,
the data pair is not regarded as a break character and treated as usual data.
Since the break characters 1 add 2 must be specified with the lower and higher bytes in
<control table>, it is convenient to use hexadecimal numbers as shown below.
%(3)=&H
Express the lower byte as
a 2-digit hexadecimal number.
Express the higher byte as
a 2-digit hexadecimal number.