7 - 5 7 - 5
MELSEC-Q
7 COMMUNICATION WITH EXTERNAL DEVICES
For example, in order to execute the ZOPEN instruction, it is necessary to set the baud
rate, character length, parity, and stop bit parameters. If too many parameters are
listed after the instruction, however, the program will be hard to read.
If a control table is used here, the actual instruction becomes concise and the
parameters can be written simply as well.
Using a control table
100P%(0)=9600
:’
Baud rate
110P%(1)=&H108
:’
Parity & character length
120P%(2)=1
:’
Stop bit
130ZOPEN #1, P%( )