E-21 – Rockwell Automation DAG6.5.8 APPLICATION GUIDE SCADA SYSTEM User Manual

Page 403

Advertising
background image

Publication AG-UM008C-EN-P - February 2005

Sample Ladder Logic E-21

Logix DF1 Half-Duplex Slave Report-By-Exception MSG

Logix5550 DF1 Half-Duplex Slave "Report-By-Exception" MSG Logic

Copy all of the "live" discrete and analog values to be written as a "report-by-exception" MSG to the Master into a data compare array. This copying occurs

continuously between successful MSG writes. If multiple changes occur after the MSG begins executing, and before the MSG has s

last change will be recorded and sent during the next MSG execution. Care should be exercised with constantly changing analog data so that the MSG doesn’t

continuously retrigger, thus negating the efficiencies of a "report-by-exception" scheme. In this example, the Logix5550 array "Data_buffer" will be sent immediately

upon any change or every 15 seconds, whichever occurs first.

0

message1.DN

Copy File

Source

Data_buffer[0]

Dest

Data_compare[0]

Length

6

COP

EN

DN

Timer On Delay

Timer

timer1

Preset

15000

Accum

0

TON

Logix5550 DF1 Half-Duplex Slave "Report-By-Exception" MSG Logic

continuously between successful MSG writes. If multiple changes occur after the MSG begins executing, and before the MSG has successfully completed, only

continuously retrigger, thus negating the efficiencies of a "report-by-exception" scheme. In this example, the Logix5550 array

upon any change or every 15 seconds, whichever occurs first.

If 15 seconds have elapsed since the last successful completion of the MSG write, snapshot the current data values for writing to the Master and retrigger the

1

timer1.DN

Copy File

Source

Data_compare[0]

Dest

Data_write[0]

Length

6

COP

U

message1.EN

JMP

label_1

If 15 seconds have elapsed since the last successful completion of the MSG write, snapshot the current data values for writing

MSG (regardless of whether data values have changed since the last write). (regardless of whether data values have changed since the last write).

If the MSG is enabled, skip over the data comparison rungs directly to the MSG rung. If the MSG has just completed in error, r etrigger the MSG immediately and

jump directly to the MSG rung.

2

/

message1.DN

message1.ER

U

message1.EN

JMP

label_1

If the MSG is enabled, skip over the data comparison rungs directly to the MSG rung. If the MSG has just completed in error, r

jump directly to the MSG rung.

Data array comparison rung.

3

RES

control1

control1.IN

U

control1.IN

EN

DN

ER

File Search/Compare

Control

control1

Length

6

Position

5

Mode

ALL

Expression

(Data_compare[control1.pos]<>Data_write[control1.pos])

FSC

Data array comparison rung.

ch will write Data_write to the Master).

4

control1.FD

Copy File

Source

Data_compare[0]

Dest

Data_write[0]

Length

6

COP

U

message1.EN

If values differ between the Data_compare and Data_write arrays, copy Data_compare into Data_write, and trigger the MSG (whi

"Report-by-exception" write instruction to the Master. This MSG block is configured to write "Data_write" out the serial port to the Master (path 2,0), using a PLC5

Typed Write.

5

LBL

label_1

EN

DN

ER

Type - PLC5 Typed Write

Message Control

message1

...

MSG

"Report-by-exception" write instruction to the Master. This MSG block is configured to write "Data_write" out the serial port

Typed Write.

(End)

Advertising