W3C home > Mailing lists > Public > public-device-apis-log@w3.org > May 2017

Re: [sensors] Use ''sampling frequency" instead of "polling frequency"

From: Alexander Shalamov via GitHub <sysbot+gh@w3.org>
Date: Fri, 26 May 2017 08:00:28 +0000
To: public-device-apis-log@w3.org
Message-ID: <issue_comment.created-304218311-1495785626-sysbot+gh@w3.org>
The 'reading' term is commonly used in platform APIs. I would keep it **+1**

As for 'sampling', maybe we can use 'reporting' frequency? Because that is what {frequency: Hz} is doing at the moment. I added some info that might be relevant in #198

Otherwise, we would need something like `let options = {samplingFrequency: 1600, reportingFrequency: 60};`

Is it important to know sampling frequency? For example, quite many motion sensors have 2 main modes: 
- low-power (step counter, sudden motion), 50Hz sampling freq.
- full-mode, max supported sampling freq.

In 'full' mode, developer can select at which rate data would be delivered, or poll at max possible rate. I think I saw few specs where max output rate < max sampling rate, HW samples data at max kHz rates, then filters / calibration / compensations take some time, and you get much lower output rate after that.

Maybe it would be better to use same terms in GenericSensor API?

HW sensor will 'report' readings at frequency that is optimal for all Sensor instances. Sensor instance will 'report' about reading change events according to it's own frequency.

What do you think?

-- 
GitHub Notification of comment by alexshalamov
Please view or discuss this issue at https://github.com/w3c/sensors/issues/209#issuecomment-304218311 using your GitHub account
Received on Friday, 26 May 2017 08:00:34 UTC

This archive was generated by hypermail 2.3.1 : Monday, 23 October 2017 12:18:53 UTC