ESenseSamplingPackage class

The eSense sampling package supporting the following measures:

  • dk.cachet.carp.esense.button
  • dk.cachet.carp.esense.sensor

Both measure types are continous collection of eSense data from an eSense device, which are:

  • Event-based measure.
  • Uses the ESenseDevice connected device for data collection.
  • No sampling configuration needed.

An example of a study protocol configuration might be:

  // Add a background task that immediately starts collecting eSense button
  // and sensor events from the eSense device.
  protocol.addTriggeredTask(
      ImmediateTrigger(),
      BackgroundTask()
        ..addMeasure(Measure(type: ESenseSamplingPackage.ESENSE_BUTTON))
        ..addMeasure(Measure(type: ESenseSamplingPackage.ESENSE_SENSOR)),
      eSense);

To use this package, register it in the carp_mobile_sensing package using

  SamplingPackageRegistry.register(ESenseSamplingPackage());

Constructors

ESenseSamplingPackage()

Properties

dataTypes List<DataTypeMetaData>
The list of data type this package supports.
no setteroverride
deviceManager → DeviceManager<DeviceConfiguration<DeviceRegistration>>
Get the DeviceManager for the device used by this package.
no setteroverride
deviceType String
What device type is this package using?
no setteroverride
hashCode int
The hash code for this object.
no setterinherited
permissions List<Permission>
The list of permissions that this package need in order to run.
no setteroverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
samplingSchemes → DataTypeSamplingSchemeMap
The default sampling schemes for all dataTypes in this package.
no setteroverride

Methods

create(String type) → Probe?
Creates a new Probe of the specified type. Note that type should be one of the dataTypes that this package supports. Returns null if a probe cannot be created for the type.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
onRegister() → void
Callback method when this package is being registered.
override
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Constants

ESENSE_BUTTON → const String
Measure type for continous collection of eSense button events (pressed/released).
ESENSE_NAMESPACE → const String
ESENSE_SENSOR → const String
Measure type for continous collection of eSense sensor events (accelorometer & gyroscope).