[ Pobierz całość w formacie PDF ]
8 registersÿthe other programs can not repeat in
using.
HR ROR DR K
Range
R0 R5000 D0
Ope-
#" #" #"
rand
R3839 R8071 D3999
Pt 1^ÿ4
SR Ë% Ë% Ë%
WR Ë% Ë%* Ë%
Descriptions
1. FUN150 (M-BUS) instruction makes PLC act as Modbus RTU/ASCII master through Port 1^ÿ4, thus it is very
easy to communicate with the intelligent peripheral with Modbus RTU/ASCII protocol.
2. The master PLC may connect with 247 slave stations through the RS485 interface.
3. Only the master PLC needs to use M-BUS instruction.
4. It employs the program coding method or table filling method to plan for the data flow controls; i.e. from which
one of the slave station to get which type of data and save them to the master PLC, or from the master PLC
to write which type of data to the assigned slave station. It needs only seven registries to make definition;
every seven registers define one packet of data transaction.
5. When execution control 0EN0changes from 0’!1 and the input ABT is 0, and if Port 1/2/3/4 hasn t been
controlled by other communication instructions [i.e. M1960 (Port1)0 M1962 (Port2) 0 M1936 (Port3) 0
M1938 (Port4) = 1], this instruction will control the Port 1/2/3/4 immediately and set the M19600M19620
M19360M1938 to be 0 (which means it is being occupied), then going on a packet of data transaction
immediately. If Port 1/2/3/4 has been controlled (M19600M19620M19360M1938 = 0), then this instruction will
enter into the standby status until the controlling communication instruction completes its transaction or
pause/abort its operation to release the control right (M19600M19620M19360M1938 =1), and then this
instruction will become enactive, set M19600M19620M19360M1938 to be 0, and going on the data
transaction immediately.
6. While in transaction processing, if operation control ABT becomes 1, this instruction will abort this
transaction immediately and release the control right (M19600M19620M19360M1938 = 1). Next time, when
this instruction takes over the transmission right again, it will restart from the first packet of data transaction.
7. While0A/R0=0ÿModbus RTU protocolÿ0A/R0=1ÿModbus ASCII protocol0
8. While it is in the data transaction, the output indication ACT will be ON.
9. If there is error occurred when it finishes a packet of data transaction, the output indication DN & ERR will
be ON.
10. If there is no error occurred when it finishes a packet of data transaction, the output indication DN will be
ON.
Note : Modbus ASCII Mode has been supported after OS Version 4.24 and later
13-40
FBs-PLC LINK
FUN150 FUN150
Convenient Instruction for Modbus RTU/ASCII Master
M-BUS M-BUS
ÿWhich makes PLC as the Modbus RTU/ASCII master through Port 1^ÿ4 ÿ
0Interface Signals0
Dedicated Relays and Registers for corresponding port :
Comm Port
Port 1 Port 2 Port 3 Port 4
Signals
1. Port Ready Indicator M1960 M1962 M1936 M1938
2. Port Finished Indicator M1961 M1963 M1937 M1939
3. Port Communication Parameters R4146 R4158 R4043 R4044
4. TX Delay & RX Time-out Span R4147 R4159 R4045 R4048
5. Setting of RX Time-out Span D4043
6. Edge Trigger Execution D4044
1. Port Ready IndicatorÿThis signal is generated from CPU.
ON, it represents that port is free and ready.
OFF, it represents that port is busy, data transaction is going.
2. Port Finished Indicator : This signal is generated from CPU.
When the communication program completed the last packet of data transaction, this signal will be ON for
one scan time (for successive data transaction).
When the communication program completed the last packet of data transaction, this signal will be still ON
(for single packet of data transmission)
3. Port Communication Parameters :
The register is for communication parameters setting of corresponding port. (please refer to the chapter of
communication parameters setting).
4. TX Delay & RX Time-out Span :
The content of Low Byte defines the receive time-out span of M-BUS instruction; its unit is 0.01 second
(the default is 50, which means 0.5 second)
The M-BUS instruction employs receive time-out span to judge whether the slave station on line or not.
When the master PLC sent out the read/write command to the slave station, the slave station didn t reply
[ Pobierz całość w formacie PDF ]