Difference between revisions of "EcgDevice Class"
NateColeman (talk | contribs) |
NateColeman (talk | contribs) |
||
Line 27: | Line 27: | ||
==Class definition== | ==Class definition== | ||
− | <code>'''public class''' EcgDevice '''extends''' [[VisualizableDevice Class|VisualizableDevice]]</code> | + | <code><span style="color:#0066FF;">'''public class'''</span> EcgDevice <span style="color:#0066FF;">'''extends'''</span> [[VisualizableDevice Class|VisualizableDevice]]</code> |
==Fields Summary== | ==Fields Summary== | ||
Line 35: | Line 35: | ||
|'''Field and Description''' | |'''Field and Description''' | ||
|- valign="top" | |- valign="top" | ||
− | |[[SubscribersNotifier Class|SubscribersNotifier]]<'''Boolean'''> | + | |[[SubscribersNotifier Class|SubscribersNotifier]]<java.lang.'''Boolean'''> |
|[[#electrodesAttachedStateChanged|electrodesAttachedStateChanged]] | |[[#electrodesAttachedStateChanged|electrodesAttachedStateChanged]] | ||
Notifies when electrodes are attached or detached | Notifies when electrodes are attached or detached | ||
To get electrodes state manually use getElectrodesState | To get electrodes state manually use getElectrodesState | ||
|- valign="top" | |- valign="top" | ||
− | |[[SubscribersNotifier Class|SubscribersNotifier]]<'''Double'''> | + | |[[SubscribersNotifier Class|SubscribersNotifier]]<java.lang.'''Double'''> |
|[[#totalSignalDurationChanged|'''totalSignalDurationChanged''']] | |[[#totalSignalDurationChanged|'''totalSignalDurationChanged''']] | ||
Notifies subscribers when signal duration is changed, | Notifies subscribers when signal duration is changed, | ||
Line 66: | Line 66: | ||
==Methods Summary== | ==Methods Summary== | ||
− | + | {| class="wikitable" | |
− | + | |- style="background-color: #dee3e9;" | |
− | + | |'''Modifier and Type''' | |
− | + | |'''Method and Description''' | |
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |'''void''' | |
− | + | |[[#close|close]]() | |
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |'''void''' | |
− | + | |[[#finalize|finalize]]() | |
− | + | |- valign="top" | |
− | + | |java.lang.'''String''' | |
− | + | |[[#getAddress|getAddress]]() | |
− | + | Returns Bluetooth LE MAC address | |
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |'''int''' | |
− | + | |[[#getAverageHeartRateOnInterval|getAverageHeartRateOnInterval]] | |
− | + | Returns average heart rate based on NN-interval values | |
− | + | from specified time interval | |
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |'''int''' | |
− | + | |[[#getBatteryLevel|getBatteryLevel]]() | |
− | + | Returns battery charge level in percents | |
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |'''int''' | |
− | + | |[[#getCurrentHeartRate|getCurrentHeartRate]]() | |
− | + | Calculates heart rate for recently received ECG samples | |
− | + | Use this method to monitor heart rate during signal receiving is active | |
− | + | It's not recommended to use this method to calculate heart rate | |
− | + | while signal receiving is stopped, use [[#getAverageHeartRateOnInterval|getAverageHeartRateOnInterval]] instead | |
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |'''double''' | |
− | + | |[[#getCurrentHeartRateVariability|getCurrentHeartRateVariability]]() | |
− | + | Returns currently detected value of heart rate variability | |
− | + | Use this method to monitor HRV during signal receiving | |
− | + | To get HRV for various intervals while signal receiving is stopped | |
− | + | use [[#getHeartRateVariabilityForInterval|getHeartRateVariabilityForInterval]] | |
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |'''double'''</code></td> | |
− | + | |[[#getCurrentStressIndex|getCurrentStressIndex]]() | |
− | + | Returns value of stress index for real-time monitoring | |
− | + | Use this method to monitor stress index while signal receiving is active | |
− | + | To get stress index for various intervals while signal receiving is stopped | |
− | + | use [[#getStressIndexForInterval|getStressIndexForInterval]] | |
− | + | |- valign="top" | |
− | + | |<span style="color:#0066FF;">'''double'''</span>[] | |
− | + | |[[#getEcgSignal|getEcgSignal]](<span style="color:#0066FF;">double</span> time, <span style="color:#0066FF;">double</span> duration) | |
− | + | Returns ECG signal stored in buffer for selected time interval | |
− | + | If interval exceeds maximum or minimum buffer time, signal samples | |
− | + | for these intervals will be equal to zero | |
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |'''boolean''' | |
− | + | |[[#getElectrodesState|getElectrodesState]]() | |
− | + | Returns flag indicating whether electrodes properly attached or not | |
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |'''double''' | |
− | + | |[[#getHeartRateVariabilityForInterval|getHeartRateVariabilityForInterval]](<span style="color:#0066FF;">double</span> startTime, <span style="color:#0066FF;">double</span> endTime) | |
− | + | Returns average value of heart rate variability on interval | |
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |java.lang.'''String''' | |
− | + | |[[#getName|getName]]() | |
− | + | Returns name of BLE device | |
− | < | + | |- valign="top" |
− | < | + | |style="color:#0066FF;" |[[NeuroDevice Class|NeuroDevice]] |
− | + | |[[#getNeuroDevice|getNeuroDevice]]() | |
− | + | Returns physical device object which this visual device represents | |
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |[[RPeak Class|RPeak]][] | |
− | + | |[[#getRWavesOnInterval|getRWavesOnInterval]](<span style="color:#0066FF;">double</span> startTime, | |
− | + | <span style="color:#0066FF;">double</span> endTime) | |
− | + | Detects R-waves in signal for specified time interval | |
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |'''double''' | |
− | + | |[[#getStressIndexForInterval|getStressIndexForInterval]](<span style="color:#0066FF;">double</span> startTime, | |
− | + | <span style="color:#0066FF;">double</span> endTime) | |
− | |||
− | |||
− | < | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | < | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | < | ||
− | |||
− | |||
<div class="block">Returns average value of stress index on interval</div> | <div class="block">Returns average value of stress index on interval</div> | ||
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |'''double''' | |
− | + | |[[#getTotalSignalDuration|getTotalSignalDuration]]() | |
− | + | Returns total signal duration in current test | |
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |'''void''' | |
− | + | |[[#reset|reset]]() | |
− | + | Clears signal buffer, sets duration to zero | |
− | + | and resets all parameters to default values | |
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |'''void''' | |
− | + | |[[#startReceive|startReceive]]() | |
− | + | |- valign="top" | |
− | + | |style="color:#0066FF;" |'''void''' | |
− | + | |[[#stopReceive|stopReceive]]() | |
− | + | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
<h3>Methods inherited from class java.lang.Object</h3> | <h3>Methods inherited from class java.lang.Object</h3> | ||
<code>clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</code></li> | <code>clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</code></li> | ||
− | + | ||
− | |||
− | |||
− | |||
− | |||
− | |||
==Field Detail== | ==Field Detail== |
Revision as of 07:38, 15 March 2017
ECG Device class implemets methods for using universal sensors as cardiography system.
Contents
- 1 Android
- 1.1 Related Classes
- 1.2 Classes hierarchy
- 1.3 Class definition
- 1.4 Fields Summary
- 1.5 Constructor Summary
- 1.6 Methods Summary
- 1.7 Field Detail
- 1.8 Constructor Detail
- 1.9 Method Detail
- 1.9.1 finalize
- 1.9.2 close
- 1.9.3 getName
- 1.9.4 getAddress
- 1.9.5 getBatteryLevel
- 1.9.6 getNeuroDevice
- 1.9.7 startReceive
- 1.9.8 stopReceive
- 1.9.9 reset
- 1.9.10 getTotalSignalDuration
- 1.9.11 getEcgSignal
- 1.9.12 getRWavesOnInterval
- 1.9.13 getCurrentHeartRate
- 1.9.14 getAverageHeartRateOnInterval
- 1.9.15 getCurrentHeartRateVariability
- 1.9.16 getHeartRateVariabilityForInterval
- 1.9.17 getCurrentStressIndex
- 1.9.18 getStressIndexForInterval
- 1.9.19 getElectrodesState
Android
ru.neurotech.neurodevices.ecg
Class EcgDevice
Related Classes
ru.neurotech.neurodevices.ecg.EcgDeviceConnector
ru.neurotech.neurodevices.ecg.RPeak
Classes hierarchy
- java.lang.Object
- ru.neurotech.common.VisualizableDevice
- ru.neurotech.neurodevices.ecg.EcgDevice
Class definition
public class EcgDevice extends VisualizableDevice
Fields Summary
Modifier and Type | Field and Description |
SubscribersNotifier<java.lang.Boolean> | electrodesAttachedStateChanged
Notifies when electrodes are attached or detached To get electrodes state manually use getElectrodesState |
SubscribersNotifier<java.lang.Double> | totalSignalDurationChanged
Notifies subscribers when signal duration is changed, when new samples received or data been loaded from external storage, or buffers been reset |
Fields inherited from class ru.neurotech.common.VisualizableDevice |
deviceStateChanged |
Constructor Summary
Constructor and Description |
---|
<a href="../../../../ru/neurotech/neurodevices/ecg/EcgDevice.html#EcgDevice-long-">EcgDevice</a>(long nativeObjPtr) |
Methods Summary
Modifier and Type | Method and Description |
void | close() |
void | finalize() |
java.lang.String | getAddress()
Returns Bluetooth LE MAC address |
int | getAverageHeartRateOnInterval
Returns average heart rate based on NN-interval values from specified time interval |
int | getBatteryLevel()
Returns battery charge level in percents |
int | getCurrentHeartRate()
Calculates heart rate for recently received ECG samples Use this method to monitor heart rate during signal receiving is active It's not recommended to use this method to calculate heart rate while signal receiving is stopped, use getAverageHeartRateOnInterval instead |
double | getCurrentHeartRateVariability()
Returns currently detected value of heart rate variability Use this method to monitor HRV during signal receiving To get HRV for various intervals while signal receiving is stopped use getHeartRateVariabilityForInterval |
double</code></td> | getCurrentStressIndex()
Returns value of stress index for real-time monitoring Use this method to monitor stress index while signal receiving is active To get stress index for various intervals while signal receiving is stopped use getStressIndexForInterval |
double[] | getEcgSignal(double time, double duration)
Returns ECG signal stored in buffer for selected time interval If interval exceeds maximum or minimum buffer time, signal samples for these intervals will be equal to zero |
boolean | getElectrodesState()
Returns flag indicating whether electrodes properly attached or not |
double | getHeartRateVariabilityForInterval(double startTime, double endTime)
Returns average value of heart rate variability on interval |
java.lang.String | getName()
Returns name of BLE device |
NeuroDevice | getNeuroDevice()
Returns physical device object which this visual device represents |
RPeak[] | getRWavesOnInterval(double startTime,
double endTime)
Detects R-waves in signal for specified time interval |
double | getStressIndexForInterval(double startTime,
double endTime)
Returns average value of stress index on interval
|
double | getTotalSignalDuration()
Returns total signal duration in current test |
void | reset()
Clears signal buffer, sets duration to zero and resets all parameters to default values |
void | startReceive() |
void | stopReceive()
Methods inherited from class java.lang.Object
Field Detail<a name="totalSignalDurationChanged"> </a>
<a name="electrodesAttachedStateChanged"> </a>
</li> </ul>
Constructor DetailEcgDevicepublic EcgDevice(long nativeObjPtr)
Method Detailfinalizepublic void finalize() throws java.lang.Throwable
</li> </ul> <a name="close--"> </a>
<a name="getName--"> </a>
<a name="getAddress--"> </a>
<a name="getBatteryLevel--"> </a>
<a name="getNeuroDevice--"> </a>
<a name="startReceive--"> </a>
<a name="stopReceive--"> </a>
<a name="reset--"> </a>
<a name="getTotalSignalDuration--"> </a>
<a name="getEcgSignal-double-double-"> </a>
<a name="getRWavesOnInterval-double-double-"> </a>
<a name="getCurrentHeartRate--"> </a>
<a name="getAverageHeartRateOnInterval-double-double-"> </a>
<a name="getCurrentHeartRateVariability--"> </a>
<a name="getHeartRateVariabilityForInterval-double-double-"> </a>
<a name="getCurrentStressIndex--"> </a>
<a name="getStressIndexForInterval-double-double-"> </a>
<a name="getElectrodesState--"> </a>
|