Chapter 6 Communication mode
6 - 83
[EHV-CPU]
(2) Description of sample program
S parameter and sending data area are fulfilled at the first scan after power ON.
By setting R0 ON, TRNS 9 is executed and following initial setting shown in below table will be sent to port 2 of
EH-SIO module mounted on Unit 0 (basic unit) slot A.
(In this example, when initial setting of EH-SIO is completed, initial setting completion flag XA29 is set ON.
Once Hi-Protocol mode is configured, this mode will be kept after CPU is in STOP status. In this sample program,
initial setting program works only when initial setting has not been configured yet.)
TRNS 9 ( WYA5 , WR0 , M0 )
WR7 = H0000 … Initial setting command
WR8 = 200 … Command timeout time
DR9 =ADR(WR100) … I/O address of sending data area
( WR100 )
DRB = ADR(WR200) … I/O address of receiving data area
( WR200 )
WRD = H0002 … Size of receiving data area
WR100 = H0006 … No. of send data (byte)
WR101 = H0020 … Communication mode
WR102 = H0001 … Task code type
WR103 = H2700 … Station number
Sending data area
(Parameter for initial
setting)