Lumia SensorCore SDK 1.1 Preview

Dn924551.SensorCore_SDK(en-us,WIN.10).png

The Lumia SensorCore SDK is a collection of APIs that utilize data from different sensors, for example, the accelerometer and the GPS. SensorCore APIs can be used to track a user's physical activities and motion. The sensors run constantly in the background, collecting and preserving data for up to the past ten days. Even though the sensors are constantly active, they run in a low power mode, consuming only a negligible amount of battery. Since the sensors provide access to users' private data, data privacy is a critical part of the design. The user has options for controlling SensorCore SDK sensors and collected data through the motion data settings application.

Dn924551.samples(en-us,WIN.10).jpg

The following features are included in Lumia SensorCore SDK 1.1 Preview:

  • Step Counter - Counts the user's walking and running steps.
  • Activity Monitor - Determines the current type of motion of the phone and the user.
  • Place Monitor - Identifies the user's home, work, and visited places.
  • Track Point Monitor - Records location points along the route the user has taken.
  • Triggers - For background tasks, for example, for recognizing changes in the step count, or if the user has changed essential settings (location or motion data) in the phone.

Key characteristics of SensorCore SDK

  • Power and memory efficient
  • Secure data storage on the phone
  • Access to motion history for up to ten days

This documentation contains an overview of each SensorCore SDK API, a Quick Start to get you started, and some more advanced samples. Essential practices and Best practices sections offer guides on how to implement SensorCore SDK support in your application safely and how to handle the required hardware and privacy requirements. There is also a link to the full Lumia SensorCore API reference.

The SDK is delivered via the NuGet service. Instructions on how to add the libraries to your project in Visual Studio can be found in the Quick Start.

What's new in SensorCore SDK 1.1 Preview?

All SensorCore SDK1.0 functionality has been carried forward. In addition, the following table describes the new features and functionality in SensorCore SDK 1.1 Preview. Some of the new functionality will be available just by switching to the new SDK, but most of the new features are available for phones that have the motion data settings application 2.0 and WP 8.1 Update 2.

Lumia devices previous to WP 8.1 and Cyan software update do not support SensorCore.

Feature

SensorCore SDK 1.1

Lumia Windows Phone 8.1 Update 2 Firmware

Motion Data Settings 2.0

Step Counter and Activity Monitor data is always available

With new motion data settings, app steps and activity data will always be available meaning that the user doesn't need to enable motion data for this data to get collected.

X

Motion data has two levels for data collection quality

With new motion data settings, app motion data can be set to two different modes: basic and detailed. Basic mode has negligible battery impact and is always available. Detailed mode consumes a little bit more battery, but collects much more accurate data for Place Monitor, Track Point Monitor, and Activity Monitor. The user must explicitly enable detailed mode.

X1

X

X

MovingInVehicle activity class

This is an extension to the Activity Monitor API. The API now offers a separate activity class for being inside a moving vehicle like a car or a bus. The MovingInVehicle activity class is available in both basic and detailed motion data modes, but will work more reliably in detailed mode.

X

X

X

Biking activity class

This is an extension to the Activity Monitor API. The API now offers a separate activity class for riding a bicycle. This activity class is only available when motion data is set to detailed mode.

X

X

X

Extensions to Place Monitor

There is now a new API for querying place history. Also, places now provide data on how many times a place has been visited, and how much time has been spent in the place.

X

X

X

New settings APIs

There is now a new API for querying the motion data settings (including data collection quality mode) and an API for querying the supported API set.

X

Improvements to simulators

It is now possible to load sensor recordings from a URL instead of having to include the recording in the application package.

X

1 - Existing SensorCore SDK 1.0 apps which use TrackPoint Monitor – will receive more accurate data if the consumer has changed the setting to detailed mode. In order for the app to query the setting and prompt the user, it must be implemented with SensorCore SDK 1.1

API changes in SensorCore SDK 1.1 Preview

Because of the separation of location (Place Monitor and TrackPoint Monitor) and non-location based sensors (Activity Monitor and Step Counter), the GetApiStateAsync API call in SenseHelper has become obsolete and has been removed from SensorCore SDK 1.1. Existing applications that use the API will need to be refactored. For more information, see the Migrating apps to SensorCore 1.1 SDK section. Applications compiled with an older version of the SDK will continue to work with some caveats: the API will report the SenseEnabled property always as true when the device is running Motion data settings 2.0.