SensorState Enumeration

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

An enumeration of values for expressing the current state of the accelerometer. The state of a sensor can be obtained using its State property.

Namespace:  Microsoft.Devices.Sensors
Assembly:  Microsoft.Devices.Sensors (in Microsoft.Devices.Sensors.dll)

Syntax

Public Enumeration SensorState
public enum SensorState
<object property="enumerationValue" .../>

Members

Member name Description
NotSupported The sensor hardware is unavailable.
Ready The sensor is available and resolving data.
Initializing The sensor is available and initializing.
NoData The sensor is unable to obtain data.
NoPermissions The caller does not have permission to access the sensor’s data.
Disabled The sensor is disabled.

Remarks

Capabilities

If you use this API in your app, you must specify the following capabilities in the app manifest. Otherwise, your app might not work correctly or it might exit unexpectedly.

ID_CAP_SENSORS

Windows Phone 8, Windows Phone OS 7.1

For more info, see App capabilities and hardware requirements for Windows Phone 8.

Version Information

Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Platforms

Windows Phone

See Also

Reference

Microsoft.Devices.Sensors Namespace