IDEC FC6A-C16K1CE Communications Manual page 90

Fc6a series microsmart all-in-one type
Hide thumbs Also See for FC6A-C16K1CE:
Table of Contents

Advertisement

5: U
C
SER
OMMUNICATION
Multi-byte Start Delimiter
A start delimiter can be programmed at the first bytes in the receive format of a RXD instruction; the FC6A Series MicroSmart will
recognize the beginning of valid communication, although a RXD instruction without a start delimiter can also be executed. A
maximum of 5 consecutive constants that are either character or hexadecimal from the first byte of the receive format are
considered a multi-byte start delimiter.
If a RXD instruction with a start delimiter is executed and another RXD instruction with the same start delimiter is executed, user
communication error code 5 is stored in the data register designated as the receive status of the second RXD instruction. When the
error occurs, the second RXD instruction is canceled, and the first RXD instruction executed is kept.
If a multi-byte start delimiter is assigned, and the incoming data does not match the entire multi-byte start delimiter, the FC6A
Series MicroSmart discards the incoming data and waits for the next communication.
When the first one byte is received, a timer is started to monitor the interval between incoming data even when a multi-byte start
delimiter is assigned. If data is not received in the period specified for the receive timeout value after receiving one byte of data, a
receive timeout error occurs, and user communication error code 11 is stored in the status data register.
Examples: Multi-byte Start Delimiter
Multi-byte start delimiter is determined in the structure of the Receive Format. The following examples show how multi-byte start
delimiter is determined.
Constants are followed by data register, skip, or BCC
Const
Receive Format
Start
Delimiter
Const Const Const
Receive Format
Note: Constants following data register, skip, or BCC are not considered start delimiter even if these are in the first five bytes of the receive format.
More than 5 constants are specified from the first byte
Const Const Const Const Const Const
Receive Format
Note: Constants that are neither start delimiters or end delimiters are considered constants for verification. See "Constant for Verification" on page
5-17.
Example: Start Delimiter Duplication Error
When input I0 is turned on, the first RXD instruction is executed and status code 32 is stored in the receive status D200, indicating
the RXD instruction is waiting for the incoming data. When input I1 is turned on, another RXD instruction is executed, but since
two RXD instructions have the same start delimiter, the second RXD instruction is not executed, and user communication error
code 5 is stored in the receive status D300.
RXD
SOTU
1
I0
Const
Receive Format S1
(05h)
Start
Delimiter
RXD
SOTU
1
I1
Const
Receive Format S1
(05h)
Start
Delimiter
5-14
I
NSTRUCTIONS
DR
etc.
Data Register, Skip, or BCC
DR
etc.
Start Delimiter
Data Register, Skip, or BCC
Start Delimiter
S1
D1
16
M20
D200
DR
Const
D210
(05h)
S1
D1
16
M30
D300
DR
Const
D310
(0Ah)
FC6A S
M
S
A
ERIES
ICRO
MART
Communication port:
D2
Receive completion output:
Receive status register:
Receive data byte count:
D200
M20
Communication port:
D2
Receive completion output:
Receive status register:
Receive data byte count:
D300
M30
-
-O
T
C
LL
IN
NE
YPE
OMMUNICATION
Port 1
M20
D200
D201
32
OFF
Port 1
M30
D300
D301
5
OFF
M
FC9Y-B1730
ANUAL

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents