STPWATCH: Stop watch

The STPWATCH (FB410) block determines the time difference between an increasing slope at start input and a decreasing slope at stop input.

Functionality

The block determines the time difference between an increasing slope at start input [Stt] and a decreasing slope at stop input [Stp]. The time difference is available for further processing after the measurement at output [Out]. Output [Out] always contains the last valid measured value for time.

Furthermore, output [TiEld] is available indicating the currently accrued time. This output primarily is used for testing during commissioning.

The entire functionality can be disabled at input [EnFnct]: If [EnFnct] = 0 (No), no new time measurement is carried out.

Output value [Out] is saved remanent, an old value is thus available after startup.

Special cases:

Example for a time-related process of input and output signals:

 

Explanation:

Inputs

Pin

E

Description

EnFnct

p

Enable function.

1 (Yes): The function is enabled.

0 (No): The function is disabled.

Stt

pa

Start.

Stp

pa

Stop

Outputs

Pin

E

Description

Out

fx

Output.

TiEld

a

Elapsed time.

Input values

Pin

Description

Data type

Default value

E.g. Engineering unit or Text group

Min.

Max.

EnFnct

Enable function.

Boolean

1 (Yes)

No, Yes

 

 

Stt

Start.

Boolean

0 (No)

No, Yes

 

 

Stp

Stop

Boolean

0 (No)

No, Yes

 

 

Output values

Pin

Description

Data type

Default value

E.g. Engineering unit or Text group

Min.

Max.

Out

Output.

Time

T#0D_0H_0M_0S_0MS

T#0D_0H_0M_0S_0MS

 

 

TiEld

Elapsed time.

Time

T#0D_0H_0M_0S_0MS

T#0D_0H_0M_0S_0MS

 

 

Application

The start and stop inputs allow for measuring runtimes between two different events, e.g. damper runtime between end switch "closed" and "open", or pause time of a pump between switch-off and the next switch-on (stop time with two buttons).

If the time between two identical events must be measured, e.g. the time between two switch-on events, this can be implemented by sending the event to both the stop input and the start input (timer with 1 button).

Process response

The block is processed with the values at the inputs from the third process cycle onward, as the values at the inputs are considered valid only then. [TiEld] = 0 is issued during the first two process cycles.

From the first process cycle, the remanently saved value is issued at [Out].

Troubleshooting

Standard (see General rules and information).