EegFrame

class EegFrame(val samples: FloatArray, val accel: FloatArray?, val gyro: FloatArray?, val sampleIndex: Long, val isDummy: Boolean, val batteryPct: Float)

One decoded sample (one time-point across all active electrodes), typed so consumers no longer reconstruct the legacy positional FloatArray [ch…, accX, accY, accZ, gyroX, gyroY, gyroZ, sampleIndex, dummyFlag, battery] by hand.

This is the wire truth: IMU values are the device's raw int16 counts, exactly as captured in the golden decode vectors. :core converts them to physical units per DeviceHardware when it builds an EegChunk (m/s² and deg/s, the C core's contract).

Constructors

Link copied to clipboard
constructor(samples: FloatArray, accel: FloatArray?, gyro: FloatArray?, sampleIndex: Long, isDummy: Boolean, batteryPct: Float)

Properties

Link copied to clipboard

[x, y, z] accelerometer reading in raw counts, or null when the hardware has no accelerometer (DeviceHardware.hasAccel). One reading per packet, repeated on each sample.

Link copied to clipboard

last known battery percentage (-1 until first battery read).

Link copied to clipboard

[x, y, z] gyroscope reading in raw counts, or null when the hardware has no gyroscope (DeviceHardware.hasGyro). One reading per packet, repeated on each sample.

Link copied to clipboard

true when this is a zero-filled gap sample (missing on the wire).

Link copied to clipboard

device sample counter for this sample (gaps detectable).

Link copied to clipboard

per-active-electrode values, in column order. µV in normal mode; in impedance mode, device-computed electrode impedance in kΩ (NOT a raw ADC count — the device applies Ohm's law on-chip and streams kΩ directly).