Classification
OTL Syntax
EventSourceTerm = Measure.DeviceEventSource(OtxLink);
Description
The DeviceEventSource term accepts a link to a DeviceSignature of a device that is to be made an event source. This term enables an OTX sequence to use a measurement device as a source for events in the context of the OTX EventHandling extension. A measurement device (driver) shall trigger an event every time a new output parameter from one of its services has arrived.
Return Value
The Term returns the value, see table below.
|
|
In OTX, Terms are categorized according to its return data type!
|
Data Type |
Description
|
EventSource |
EventSource from a measurement.
|
Properties
Name |
Data Type |
Class |
Default |
Cardinality |
Description
|
Device |
- |
OtxLink |
- |
[1] |
Represents the to-be-monitored device. If an output parameter of an earlier triggered device service becomes available, the event shall be fired, causing an embedding event:WaitForEventAction to exit.
|
OTL Examples
/// Signatures
package Measure.DeviceSignature DeviceSignature1
{
Measure.DeviceServiceSignature Add(in Integer a, out Measure.Measurement Measurement);
}
/// Global Declarations
public procedure main()
{
/// Local Declarations
Measure.Measurement Measurement1;
Integer a1 = 10;
EventHandling.EventSource EventSource1;
/// Flow
EventSource1 = Measure.DeviceEventSource(DeviceSignature1);
Measure.ExecuteDeviceService(DeviceSignature1, Add, {a = a1, Measurement = Measurement1}, false, false);
}
See also
IsDeviceEvent
GetDeviceServiceNameFromEvent