nl.lxtreme.ols.api.acquisition
Interface AcquisitionResult

All Known Implementing Classes:
CapturedData, DataContainer

public interface AcquisitionResult

Denotes a concrete result of a single acquisition.


Method Summary
 long getAbsoluteLength()
          Returns the absolute length of the captured data, or, in other words, the largest available timestamp plus some padding to make the last sample visible.
 int getChannels()
          Returns the number of channels in the sample data.
 int getEnabledChannels()
          Returns a bitmask of enabled channels in the sample data.
 int getSampleIndex(long aTimeValue)
          Returns the sample index from the given absolute time value.
 int getSampleRate()
          Returns the sample rate in which this data was captured.
 long[] getTimestamps()
          Returns the time stamps of the individual samples.
 long getTriggerPosition()
          Returns the trigger position, as (absolute) time-value.
 int[] getValues()
          Returns the actual sample values.
 boolean hasTimingData()
          Returns wether or not the object contains timing data
 boolean hasTriggerData()
          Returns whether or not the object contains trigger data
 

Method Detail

getAbsoluteLength

long getAbsoluteLength()
Returns the absolute length of the captured data, or, in other words, the largest available timestamp plus some padding to make the last sample visible.

Returns:
the absolute length, >= 0.

getChannels

int getChannels()
Returns the number of channels in the sample data.

Returns:
the channel count, >= 0.

getEnabledChannels

int getEnabledChannels()
Returns a bitmask of enabled channels in the sample data.

Returns:
a bitmask of enabled channels, for example, 0xFF for the first 8 channels.

getSampleIndex

int getSampleIndex(long aTimeValue)
Returns the sample index from the given absolute time value.

Parameters:
aTimeValue - the (absolute) time value to convert to a sample index.
Returns:
the sample number before the selected absolute time.

getSampleRate

int getSampleRate()
Returns the sample rate in which this data was captured.

Returns:
a sample rate in hertz (Hz).

getTimestamps

long[] getTimestamps()
Returns the time stamps of the individual samples.

The time values returned should represent an ever increasing time line. So, timestamp[n-1] < timestamp[n] < timestamp[n+1] for all elements of the returned array.

NOTE: the length of this array must be equal to the length of the array returned by getValues()!

Returns:
the time stamps, as array of long values.
See Also:
getValues()

getTriggerPosition

long getTriggerPosition()
Returns the trigger position, as (absolute) time-value.

Returns:
a value representing the trigger position in time.

getValues

int[] getValues()
Returns the actual sample values.

NOTE: the length of this array must be equal to the length of the array returned by getTimestamps()!

Returns:
the sample values, as array of integers.
See Also:
getTimestamps()

hasTimingData

boolean hasTimingData()
Returns wether or not the object contains timing data

Returns:
true when timing data is available

hasTriggerData

boolean hasTriggerData()
Returns whether or not the object contains trigger data

Returns:
true when trigger data is available


Copyright © 2012 L'Xtreme IT consultancy. All Rights Reserved.