Rockwell Automation Logix5000 Controllers Tasks, Programs, and Routines Programming Manual User Manual

Page 69

Advertising
background image

Manage event tasks Chapter 2

Attribute

Data Type

Instruction

Description

Status

DINT

GSV
SSV

Provides status information about the task. Once the controller sets a bit, you must manually clear the bit to
determine if another fault of that type occurred.
To determine if

Examine this bit

An EVENT instruction triggered the task (event task only).

0

A timeout triggered the task (event task only).

1

An overlap occurred for this task.

2

Example

If a timeout occurs for the event task, communication with the triggering device might have failed. This requires the process to shut down. To shut down
the controller, the event task calls the fault routine for the program and supplies a user-defined fault code (999 in this example).
1.

The GSV instruction sets Task_2_Status = Status attribute for Task_2 (DINT value).

2.

If Task_2_Status.1 = 1, then a timeout occurred so shut down the controller and set the major fault code to 999.

The JSR instruction calls the fault routine for the program. This produces a major fault.
The major fault code = 999 (value of the input parameter of 999).

3.

If Condition_1 = 1, then clear the bits of the Status attribute for Task_2.

The SSV instruction sets the Status attribute of Task_2 = Zero. Zero is a DINT tag with a value of 0.

Rockwell Automation Publication 1756-PM005-EN-P - October 2014

69

Advertising