ORKAccelerometerRecorder Class Reference
| Inherits from | ORKRecorder : NSObject |
|---|---|
| Declared in | ORKAccelerometerRecorder.h ORKAccelerometerRecorder.m |
Overview
The ORKAccelerometerRecorder class represents a recorder that requests and collects raw accelerometer data from CoreMotion at a fixed frequency.
The accelerometer recorder continues to record when the application enters the background by using the background task support provided by UIApplication.
Other Methods
– initWithIdentifier:frequency:step:outputDirectory:
Returns an initialized accelerometer recorder using the specified frequency.
- (instancetype)initWithIdentifier:(NSString *)identifier frequency:(double)frequency step:(ORKStep *)step outputDirectory:(NSURL *)outputDirectoryParameters
identifier |
The unique identifier of the recorder (assigned by the recorder configuration). |
|---|---|
frequency |
The frequency of accelerometer data collected from CoreMotion, in hertz (Hz). |
step |
The step that requested this recorder. |
outputDirectory |
The directory in which the accelerometer data should be stored. |
Return Value
An initialized accelerometer recorder.
Declared In
ORKAccelerometerRecorder.h
– stop
Stops data recording, which generally triggers the return of results.
- (void)stopDiscussion
If an error occurs when stopping the recorder, it is returned through the delegate.
Subclasses should call finishRecordingWithError: rather than calling super.
Declared In
ORKRecorder.h
– isRecording
A Boolean value indicating whether the recorder is currently recording.
- (BOOL)isRecordingReturn Value
YES if the recorder is recording; otherwise, NO.
Declared In
ORKRecorder.h
Other Methods
frequency
The frequency of accelerometer data collected from CoreMotion, in hertz (Hz).
@property (nonatomic, readonly) double frequencyDeclared In
ORKAccelerometerRecorder.h