API Scope.FindOutput

From Flowcode Help
Revision as of 12:19, 14 May 2013 by JonnyW (talk | contribs) (XML import API changes)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

<sidebar>API contents</sidebar> Searches back through the output history for a value, returns offset of found sample from TimeUS, 0 if not found

Class hierarchy

Scope

FindOutput

Parameters

HANDLE StreamH

The stream that is to be read

LONG TimeUS

The time offset to start the search from, in microseconds

LONG SearchMax

The maximum number of microseconds to look back over, -ve to search backwards

FLOAT Value

The target value to search for

ULONG SearchFlags

Bit 0 is find lower, bit 1 is equal, 2 is find higher
Typical values for this parameter:
Name Description
Find_Lower Match a search when output is lower than the target value
Find_Equal Match a search when output is equal to the target value
Find_Higher Match a search when output is greater than the target value
Find_LowHigh Match a search when output goes lower to higher than the target
Find_HighLow Match a search when output goes higher to lower than the target


Return value

LONG Returns offset of found sample from TimeUS, 0 if not found


Detailed description

No additional information


Examples

Calling in a calculation

  • Declare a variable 'result' of type LONG
  • Add to a calculation icon:
    result = ::Scope.FindOutput(streamh, timeus, searchmax, value, ::Scope.Find_Lower)

No additional information