<< Click to Display Table of Contents >>
Event Syncing with Redundancy |
If the Sync Events with Stby Driver option is enabled, each DNP Slave Driver must have two Block Tags to receive and send events to quit.
By using a Tag Block with the B2 parameter equal to -22, users can read events quit on one Driver and by using a Tag Block with the B2 parameterequal to -23, users can write events to quit to another Driver.
In both cases, this Block Tag must have six Elements, described next:
•Element 0: Object × 100 + Variation
•Element 1: Index
•Element 2: Class (one, two, or three)
•Element 3: Value
•Element 4: Valid timestamp (1: Valid or 0: Invalid)
•Element 5: Timestamp (64-bit floating point format)
Example of a code in E3 or Elipse Power, assuming the existence of SlaveDriver1 quitting events in SlaveDriver2 and vice versa:
Sub SyncEvtsRead_OnRead() //Script in SlaveDriver1
Set EvtTag = Application.GetObject("SlaveDriver2.SyncEvtsWrite")
EvtTag.Item("Element1").Value = Item("Element1").Value
EvtTag.Item("Element2").Value = Item("Element2").Value
EvtTag.Item("Element3").Value = Item("Element3").Value
EvtTag.Item("Element4").Value = Item("Element4").Value
EvtTag.Item("Element5").Value = Item("Element5").Value
EvtTag.Item("Element6").Value = Item("Element6").Value
EvtTag.Write()
End Sub
Sub SyncEvtsRead_OnRead() //Script em SlaveDriver2
Set EvtTag = Application.GetObject("SlaveDriver1.SyncEvtsWrite")
EvtTag.Item("Element1").Value = Item("Element1").Value
EvtTag.Item("Element2").Value = Item("Element2").Value
EvtTag.Item("Element3").Value = Item("Element3").Value
EvtTag.Item("Element4").Value = Item("Element4").Value
EvtTag.Item("Element5").Value = Item("Element5").Value
EvtTag.Item("Element6").Value = Item("Element6").Value
EvtTag.Write()
End Sub