QtFit
0.1
Native Qt library for Garmin FIT format
|
The MagnetometerDataMessage class represents a FIT MagnetometerDataMessage data message. More...
Public Member Functions | |
MagnetometerDataMessage () | |
Constructs a MagnetometerDataMessage object. More... | |
DateTime | timestamp () const |
Returns the MagnetometerDataMessage data message's timestamp field's current value. More... | |
quint16 | timestampMs () const |
Returns the MagnetometerDataMessage data message's timestampMs field's current value. More... | |
quint16 | sampleTimeOffset () const |
Returns the MagnetometerDataMessage data message's sampleTimeOffset field's current value. More... | |
quint16 | magX () const |
Returns the MagnetometerDataMessage data message's magX field's current value. More... | |
quint16 | magY () const |
Returns the MagnetometerDataMessage data message's magY field's current value. More... | |
quint16 | magZ () const |
Returns the MagnetometerDataMessage data message's magZ field's current value. More... | |
float | calibratedMagX () const |
Returns the MagnetometerDataMessage data message's calibratedMagX field's current value. More... | |
float | calibratedMagY () const |
Returns the MagnetometerDataMessage data message's calibratedMagY field's current value. More... | |
float | calibratedMagZ () const |
Returns the MagnetometerDataMessage data message's calibratedMagZ field's current value. More... | |
void | setTimestamp (const DateTime timestamp) |
Sets the timestamp field to timestamp. More... | |
void | setTimestampMs (const quint16 timestampMs) |
Sets the timestampMs field to timestampMs. More... | |
void | setSampleTimeOffset (const quint16 sampleTimeOffset) |
Sets the sampleTimeOffset field to sampleTimeOffset. More... | |
void | setMagX (const quint16 magX) |
Sets the magX field to magX. More... | |
void | setMagY (const quint16 magY) |
Sets the magY field to magY. More... | |
void | setMagZ (const quint16 magZ) |
Sets the magZ field to magZ. More... | |
void | setCalibratedMagX (const float calibratedMagX) |
Sets the calibratedMagX field to calibratedMagX. More... | |
void | setCalibratedMagY (const float calibratedMagY) |
Sets the calibratedMagY field to calibratedMagY. More... | |
void | setCalibratedMagZ (const float calibratedMagZ) |
Sets the calibratedMagZ field to calibratedMagZ. More... | |
![]() | |
~AbstractDataMessage () | |
Destroys the AbstractDataMessage object. | |
MesgNum | globalMessageNumber () const |
Returns the data message's global message number. More... | |
Additional Inherited Members | |
![]() | |
static AbstractDataMessage * | fromData (const DataDefinition *const defn, const QByteArray &record) |
Constructs the relevant AbstractDataMessage-derived class to parse record according to defn. More... | |
The MagnetometerDataMessage class represents a FIT MagnetometerDataMessage data message.
MagnetometerDataMessage::MagnetometerDataMessage | ( | ) |
Constructs a MagnetometerDataMessage object.
Typically, instances of this class will be returned by FitStreamReader::readNext, but this constructor may be used, along with the relevant setter methods, to create a valid message.
float MagnetometerDataMessage::calibratedMagX | ( | ) | const |
Returns the MagnetometerDataMessage data message's calibratedMagX
field's current value.
Calibrated Magnetometer reading
calibratedMagX
field value. float MagnetometerDataMessage::calibratedMagY | ( | ) | const |
Returns the MagnetometerDataMessage data message's calibratedMagY
field's current value.
Calibrated Magnetometer reading
calibratedMagY
field value. float MagnetometerDataMessage::calibratedMagZ | ( | ) | const |
Returns the MagnetometerDataMessage data message's calibratedMagZ
field's current value.
Calibrated Magnetometer reading
calibratedMagZ
field value. quint16 MagnetometerDataMessage::magX | ( | ) | const |
Returns the MagnetometerDataMessage data message's magX
field's current value.
These are the raw ADC reading. Maximum number of samples is 30 in each message. The samples may span across seconds. A conversion will need to be done on this data once read.
magX
field value. quint16 MagnetometerDataMessage::magY | ( | ) | const |
Returns the MagnetometerDataMessage data message's magY
field's current value.
These are the raw ADC reading. Maximum number of samples is 30 in each message. The samples may span across seconds. A conversion will need to be done on this data once read.
magY
field value. quint16 MagnetometerDataMessage::magZ | ( | ) | const |
Returns the MagnetometerDataMessage data message's magZ
field's current value.
These are the raw ADC reading. Maximum number of samples is 30 in each message. The samples may span across seconds. A conversion will need to be done on this data once read.
magZ
field value. quint16 MagnetometerDataMessage::sampleTimeOffset | ( | ) | const |
Returns the MagnetometerDataMessage data message's sampleTimeOffset
field's current value.
Each time in the array describes the time at which the compass sample with the corrosponding index was taken. Limited to 30 samples in each message. The samples may span across seconds. Array size must match the number of samples in cmps_x and cmps_y and cmps_z
sampleTimeOffset
field value. void MagnetometerDataMessage::setCalibratedMagX | ( | const float | calibratedMagX | ) |
Sets the calibratedMagX
field to calibratedMagX.
calibratedMagX | The field value to set. |
void MagnetometerDataMessage::setCalibratedMagY | ( | const float | calibratedMagY | ) |
Sets the calibratedMagY
field to calibratedMagY.
calibratedMagY | The field value to set. |
void MagnetometerDataMessage::setCalibratedMagZ | ( | const float | calibratedMagZ | ) |
Sets the calibratedMagZ
field to calibratedMagZ.
calibratedMagZ | The field value to set. |
void MagnetometerDataMessage::setMagX | ( | const quint16 | magX | ) |
Sets the magX
field to magX.
magX | The field value to set. |
void MagnetometerDataMessage::setMagY | ( | const quint16 | magY | ) |
Sets the magY
field to magY.
magY | The field value to set. |
void MagnetometerDataMessage::setMagZ | ( | const quint16 | magZ | ) |
Sets the magZ
field to magZ.
magZ | The field value to set. |
void MagnetometerDataMessage::setSampleTimeOffset | ( | const quint16 | sampleTimeOffset | ) |
Sets the sampleTimeOffset
field to sampleTimeOffset.
sampleTimeOffset | The field value to set. |
void MagnetometerDataMessage::setTimestamp | ( | const DateTime | timestamp | ) |
Sets the timestamp
field to timestamp.
timestamp | The field value to set. |
void MagnetometerDataMessage::setTimestampMs | ( | const quint16 | timestampMs | ) |
Sets the timestampMs
field to timestampMs.
timestampMs | The field value to set. |
DateTime MagnetometerDataMessage::timestamp | ( | ) | const |
Returns the MagnetometerDataMessage data message's timestamp
field's current value.
Whole second part of the timestamp
timestamp
field value. quint16 MagnetometerDataMessage::timestampMs | ( | ) | const |
Returns the MagnetometerDataMessage data message's timestampMs
field's current value.
Millisecond part of the timestamp.
timestampMs
field value.