De-Lag

This layer calculates the amount of time taken for a total amount to be counted based on a rate.

Parameters

NameDefaultMeaning
rateThe rate property (in Asset.Property format)
timebase1The number of seconds per unit measurement
target60Total amount of flow/distance/use (substitutable)
destLagName of the final attribute
length0Length of the resulting time-window

Description

This is generally used to compensate for lag on linear production lines or conveyor systems, so that you can snapshot machine conditions when a particular product/batch/item was passing a certain piece of equipment or stage of production.

For example, in a system where pieces of equipment are 200m apart and connected by a conveyor, you can use the conveyor speed to determine how long it took a product to go from A to B.

This layer may cause frame looping.

The resulting attributes will be named…

NameValue
LagStartStart Time
LagEndEnd Time
LagSecondsTotal Time Offset

Note that the Start Time and End Time is based on the length of your current frame. If you have a 20 minute batch, your resulting Lag Start Time and Lag End Time will cover 20 minutes - unless you specify a non-zero length parameter.

Example

[{
   "type": "get_aql",
   "points": ["Machine.Speed"],
   "samples": 200,
   "comment": "Load Machine Speed Data"
},
{
   "type": "delag",
   "rate": "Machine.Speed",
   "timebase": 60,
    "target": 150
    "comment": "Get Time from 150m Earlier",
    "dest": "Wrapping "
}]

In the example above, our capture is triggered by an inspection, which is the last step of the process.

We want to find out some information about what happened in the wrapping machine - but the wrapping machine is 150m upstream from the inspection station, meaning we need to look backwards to find out when the item being inspected passed through the wrapper.

To do this, we load the Machine.Speed property, then we search backwards until we've seen 150m of movement (assuming that the Machine.Speed metric is in meters per minute).

We will have three new attributes - Wrapping Start, Wrapping End and Wrapping Seconds. We can use these values in further queries to get the state of the wrapping machine at the correct time, even if the machine speed was erratic, there were stoppages or other problems with timing.