7 - 2 7 - 2
MELSEC-Q
7 COMMUNICATION WITH EXTERNAL DEVICES
7
7.2 Preparation for the Communication
Various settings are necessary in order to communicate with external devices and
terminals. The preparations required to perform the communication are described
below.
7.2.1 Communication parameter setting
In order to communicate through the RS-232C (CH1, CH2) or RS-422 (CH3) interface,
the following parameters have to be set using the ZOPEN and ZCNIL instructions prior
to the actual communication. These parameters on the communication module side
and the target device side must correspond correctly.
If they do not correspond correctly, the communication may not be possible or
communication errors may occur.
• The communication parameter settings are not necessary for the parallel
interface (CH4).
• Setting ranges for the communication parameters
(baud rate, character length, etc.) are different for each communication module.
See the user's manual of each communication module.
• Baud rate • • • Specify this parameter when using the ZOPEN instruction.
Specify the speed of the data communication. The following values can be set in
BASIC: 300 bps, 600 bps, 1200 bps, 2400 bps, 4800 bps, 9600 bps, 19200 bps,
38400 bps.
• Character length • • • Specify this parameter when using the ZOPEN instruction.
Specify the number of bits in the codes that represent each character used in the
communication. The following values can be set in BASIC:
• 5 bits • • • 32 characters from 0 through 1F
H
can be represented.
• 6 bits • • • 64 characters from 0 through 3F
H
can be represented.
• 7 bits • • • 128 characters from 0 through 7F
H
can be represented.
• 8 bits • • • 256 characters from 0 through FF
H
can be represented.
• Parity bit • • • Specify this parameter when using the ZOPEN instruction.
Specify how the data is during the communication checked (parity check). The
following can be specified in BASIC:
• No parity check is performed.
• Parity check is performed and even parity bit is used.
• Parity check is performed and odd parity bit is used.
REMARK
Parameter • • • Parameters refer to data that must be specified for the
communication.