Magnetometer​Reading Magnetometer​Reading Magnetometer​Reading Class

Definition

Represents a magnetometer reading.

public sealed class MagnetometerReading : IMagnetometerReadingpublic sealed class MagnetometerReading : IMagnetometerReadingPublic NotInheritable Class MagnetometerReading Implements IMagnetometerReading
Attributes
Windows 10 requirements
Device family
Windows 10 (introduced v10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)

Remarks

This object is accessed when you invoke the GetCurrentReading method; and, it is accessed when you retrieve the Reading property of the MagnetometerReadingChangedEventArgs object in the event callback method.

Properties

DirectionalAccuracy DirectionalAccuracy DirectionalAccuracy

Gets the magnetometer's directional accuracy.

public MagnetometerAccuracy DirectionalAccuracy { get; }public MagnetometerAccuracy DirectionalAccuracy { get; }Public ReadOnly Property DirectionalAccuracy As MagnetometerAccuracy
Value
MagnetometerAccuracy MagnetometerAccuracy MagnetometerAccuracy

The magnetometer's directional accuracy.

Attributes

MagneticFieldX MagneticFieldX MagneticFieldX

Gets the magnetic field strength in microteslas along the X axis.

public float MagneticFieldX { get; }public float MagneticFieldX { get; }Public ReadOnly Property MagneticFieldX As float
Value
float float float

The magnetic field strength in microteslas along the X axis.

Attributes

Remarks

The accuracy of this value depends on the state of magnetometer calibration reflected in the DirectionalAccuracy property.

MagneticFieldY MagneticFieldY MagneticFieldY

Gets the magnetic field strength in microteslas along the Y axis.

public float MagneticFieldY { get; }public float MagneticFieldY { get; }Public ReadOnly Property MagneticFieldY As float
Value
float float float

The magnetic field strength in microteslas along the Y axis.

Attributes

Remarks

The accuracy of this value depends on the state of magnetometer calibration reflected in the DirectionalAccuracy property.

MagneticFieldZ MagneticFieldZ MagneticFieldZ

Gets the magnetic field strength in microteslas along the Z axis.

public float MagneticFieldZ { get; }public float MagneticFieldZ { get; }Public ReadOnly Property MagneticFieldZ As float
Value
float float float

The magnetic field strength in microteslas along the Z axis.

Attributes

Remarks

The accuracy of this value depends on the state of magnetometer calibration reflected in the DirectionalAccuracy property.

Timestamp Timestamp Timestamp

Gets the time at which the sensor reported the reading.

public DateTime Timestamp { get; }public DateTimeOffset Timestamp { get; }Public ReadOnly Property Timestamp As DateTimeOffset
Value
DateTime DateTime DateTime

The time at which the sensor reported the reading.

Attributes