Hour and Event Meters

Hour meter and Event meter refer to the Value Mode option settings on tags in Transaction Groups. The Value mode drives values that are used to create values that determine how long a value was true. While the selected Value Mode for most transactions is Direct, however, the Hour meter mode accumulates value for the duration of a condition, and the Event meter accumulates count in response to the condition.

Hour Meter

It is common to write to a tag during the time when a tag's value is true. An hour meter simplifies this effort. Hour meters can be meters that accumulate the millisecond, second, minute, hour, or day.

To count the duration of a tag being true

  1. From OPC Browser or Tag Browser, drag a boolean tag into the Basic OPC/Groups Items area of a Standard transaction group.

  2. From OPC Browser or Tag Browser, drag a memory tag or OPC tag (must be a numeric data type) into the Basic OPC/Groups Items portion of the Standard transaction group.

  3. Right-click on the boolean tag in the transaction group and select Edit to edit it.
    The Edit group tag window is displayed.

  4. In the Edit group tag window, for Value Mode, select Hour meter.

  5. In the Edit group tag window, for Target Type select Other tag from the dropdown menu, and in Target Name enter the name of the memory tag as the target, and click OK.

  6. In the Basic OPC/Groups Items area where the tags are located, go to the Target Name column, left-click on each tag to get the dropdown menu, and set the following:

    1. For the boolean tag, select the memory tag from the dropdown which is set previously as the target tag to write the hour meter to.

    2. For the memory tag, select Read-only from the dropdown.

  7. Click Enabled at the top of the page, and do a File > Save to start the group.

  8. Make the boolean tag true to the start the Hour meter.

Event Meter

Another common scenario is to count the number of times an event occurred. For example, where there is boolean tag and you want to count the number of cycles the boolean tag has experienced.

To count in response to a tag being true

  1. From OPC Browser or Tag Browser, drag a boolean tag into the Basic OPC/Groups Items area of a Standard transaction group.

  2. From OPC Browser or Tag Browser, drag a memory tag or OPC tag (must be a numeric data type) into the Basic OPC/Groups Items portion of the Standard transaction group.

  3. Right-click on the boolean tag in the transaction group and select Edit to edit it.
    The Edit group tag window is displayed.

  4. In the Edit group tag window, for Value Mode, select Event meter.

  5. In the Edit group tag window, for Target Type select Other tag from the dropdown menu, and in Target Name enter the name of the memory tag as the target, and click OK.

  6. In the Basic OPC/Groups Items area where the tags are located, go to the Target Name column, left-click on each tag to get the dropdown menu, and set the following:

    1. For the boolean tag, select the memory tag from the dropdown which is set previously as the target tag to write the hour meter to.

    2. For the memory tag, select Read-only from the dropdown.

  7. Click Enabled at the top of the page, and do a File > Save to start the group.

  8. Make the boolean tag true to start the Event meter.

Reset an hour or event meter based on a condition

You can set the hour or event meter based on a condition.

  1. In the Basic OPC/Group Items section, right-click and Edit a tag that is serving as the Hour or Event meter.
    The edit group tag window is displayed.

  2. In the Value Mode area, select the Reset on condition check box, click the tag icon to display the Choose Tag window, and select a Group Tag from the pop-up window .

  3. Click OK.

  4. Next to the tag icon, choose the operator sign, and enter a number.

  5. Click OK.
    The target tag will now reset in response to the condition.

Next...