FunctionMLTrigReadTimePipe Network motion icon

Description

Returns the time of the moment where the block was triggered in milliseconds. This value is only valid when TrigIsTrigged() returns TRUE. The output is computed from the timestampClosedA timestamp is a sequence of characters, denoting the date and/or time at which a certain event occurred of a Fast InputClosedThe inputs are taken into account at each cycle depending on the system periodicity (for example each millisecond). Under certain circumstances this can be insufficient when more accuracy is needed, or if a quick response is required from the system. To fill the gap, a drive may have some Fast Input connections (generally one or two). When an event happens that triggers a Fast Input (e.g. when a sensor sends a rising edge), the detection of a signal occurs faster (which can be 1000 times more accurate than the system periodicity). Then the timestamp associated with this input can be provided to the IPC to take corrective action time event

Once triggered, a block has to be reset before it can be triggered again. All events that are sent to a block while in a triggered state are ignored and the position and time information is lost.

MLTrigReadTime

 

Figure 7-119: MLTrigReadTime

Arguments

Input

BlockID

Description

ID number of an initiated Trigger object

 

Data type

DINT

 

Range

[-2147483648, 2147483648]

 

Unit

N/A

 

Default

Output

Time

Description

Returns the time that the Trigger Block's selected Fast Input was triggered

 

Data type

LREAL

 

Unit

milliseconds

Related Functions

MLTrigIsTrigged

MLTrigReadPos

MLTrigClearFlag

MLAxisRstFastIn

See Also

Previous Function Name

MLTrigGetTime

Example

//Save time when Fast Input event occurs

Trig_Time := MLTrigReadTime( PipeNetwork.TRIGGER );

Ladder Diagram

MLTrigReadTime: LD example

Function Block Diagram

MLTrigReadTime: FBD example