pub struct PpgReading {
pub index: u16,
pub ppg_channel: usize,
pub timestamp: f64,
pub samples: Vec<u32>,
}Expand description
A PPG (photoplethysmography) reading from the optical heart-rate sensor.
Available on Muse 2 and Muse S only. Each notification carries 6 raw 24-bit samples at 64 Hz.
Fields§
§index: u16Sequential packet index (wraps at 0xFFFF), same purpose as EegReading::index.
ppg_channel: usizeOptical channel:
- 0 = ambient (background light subtraction)
- 1 = infrared
- 2 = red
timestamp: f64Wall-clock timestamp in milliseconds since Unix epoch for the first sample.
samples: Vec<u32>Raw 24-bit ADC values (not scaled to physical units). 6 samples per notification at 64 Hz.
Trait Implementations§
Source§impl Clone for PpgReading
impl Clone for PpgReading
Source§fn clone(&self) -> PpgReading
fn clone(&self) -> PpgReading
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for PpgReading
impl RefUnwindSafe for PpgReading
impl Send for PpgReading
impl Sync for PpgReading
impl Unpin for PpgReading
impl UnsafeUnpin for PpgReading
impl UnwindSafe for PpgReading
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more