App di Windows
Comprimi il sommario
Espandi il sommario
EN
Il contenuto non è disponibile nella lingua di destinazione, ma solo in inglese.

MagnetometerReading class

[ Updated for UWP apps on Windows 10. For Windows 8.x articles, see the archive ]

Represents a magnetometer reading.

Syntax


public sealed class MagnetometerReading

Members

The MagnetometerReading class has these types of members:

Properties

The MagnetometerReading class has these properties.

PropertyAccess typeDescription

DirectionalAccuracy

Read-onlyGets the magnetometer's directional accuracy.

MagneticFieldX

Read-onlyGets the magnetic field strength in microteslas along the X axis.

MagneticFieldY

Read-onlyGets the magnetic field strength in microteslas along the Y axis.

MagneticFieldZ

Read-onlyGets the magnetic field strength in microteslas along the Z axis.

Timestamp

Read-onlyGets the time at which the sensor reported the reading.

 

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.

Requirements (Windows 10 device family)

Device family

Universal

API contract

Windows.Foundation.UniversalApiContract, introduced version 1.0

Namespace

Windows.Devices.Sensors
Windows::Devices::Sensors [C++]

Metadata

Windows.Foundation.UniversalApiContract.winmd

Requirements (Windows 8.x and Windows Phone 8.x)

Minimum supported client

None supported

Minimum supported server

None supported

Minimum supported phone

Windows Phone 8.1 [Windows Phone Silverlight 8.1 and Windows Runtime apps]

Namespace

Windows.Devices.Sensors
Windows::Devices::Sensors [C++]

Metadata

Windows.winmd

Attributes

[DualApiPartition()]
[MarshalingBehavior(Agile)]
[Threading(Both)]
[Version(0x06030000)]

See also

Object

 

 

Mostra:
© 2016 Microsoft