W3C home > Mailing lists > Public > public-device-apis-log@w3.org > October 2016

Re: [sensors] Default sensor configuration

From: Tobie Langel via GitHub <sysbot+gh@w3.org>
Date: Thu, 27 Oct 2016 12:54:41 +0000
To: public-device-apis-log@w3.org
Message-ID: <issue_comment.created-256632571-1477572880-sysbot+gh@w3.org>
> Our team has implemented Generic Sensor API based sensors 
(AmbientLight, Accelerometer, Gyroscope and Magnetometer) in Chromium 
for all the supported platforms (Android, Windows, Chrome OS/Linux, 
> We can confirm that platform sensor APIs on Android, Windows, Chrome
 OS/Linux (IIO) accept polling frequency as an input parameter for any
 sensor type, whatever reporting mode it provides.

My understanding from reading the [Android 
 was that the sampling period meant something very different for 
'on-change' reporting mode. Specifically, that "[the] 
sampling_period_ns parameter passed to the batch function is used to 
set the minimum time between consecutive events, meaning an event 
should not be generated until sampling_period_ns nanoseconds elapsed 
since the last event, even if the value changed since then."

So this is something completely different than poll frequency for, 
say, a gyroscope. It's a value that says: don't give me data more 
often than once every _n_ seconds.

Is there a way to set the actual polling frequency of the underlying 
hardware sensor for an `on-change` sensor on Android?

GitHub Notification of comment by tobie
Please view or discuss this issue at 
https://github.com/w3c/sensors/issues/126#issuecomment-256632571 using
 your GitHub account
Received on Thursday, 27 October 2016 12:54:47 UTC

This archive was generated by hypermail 2.4.0 : Monday, 4 July 2022 12:47:52 UTC