W3C home > Mailing lists > Public > public-device-apis@w3.org > March 2010

RE: Bluetooth / NFC APIs

From: Nilsson, Claes1 <Claes1.Nilsson@sonyericsson.com>
Date: Mon, 1 Mar 2010 14:41:29 +0100
To: 'Max Froumentin' <maxfro@opera.com>
CC: Nikolai Onken <nikolai@uxebu.com>, "public-device-apis@w3.org" <public-device-apis@w3.org>
Message-ID: <6DFA1B20D858A14488A66D6EEDF26AA3232A1FB2F4@seldmbx03.corpusers.net>
Hi Max,

Yes, if we want to keep this simple it has, for each property, to be clarified which attribute the thresholds apply to.

However, if we want it more flexible would it be possible add a way for the author to define which attribute the thresholds apply to? I am considering for example a proximity sensor that is only capable of detecting "near" and "far". In that case the value attribute is null and we can't define threshold values, i.e. not trigger when the device is "near" and "far" from for example the user's ear/face as. Would it complicate the "watch" method to much if we add the possible for the author to define which attribute the thresholds apply to? Your view?

Furthermore, is it correct that if no threshold values are stated when the "watch" method is called, this means that a successCallback is invoked when any of the properties attributes changed its value? If this is correct interpreted this means that a device implementation of an API for an external sensor will have to be able to continuously report sensor values. Even though all implementation details (beare, protocols etc) are hidden buy this simple API for web developers, have you though if issues like battery drain etc?

At last, a small comment on an editorial error. In the example in the beginning of section 4.8 I guess that maxThreshold should be

Best regards


> -----Original Message-----
> From: Max Froumentin [mailto:maxfro@opera.com]
> Sent: fredag den 26 februari 2010 18:12
> To: Nilsson, Claes1
> Cc: Nikolai Onken; public-device-apis@w3.org
> Subject: Re: Bluetooth / NFC APIs
> On 26/02/2010 17:07, Nilsson, Claes1 wrote:
> > When reading your editor's draft again one question popped up. The
> > high and lowThreshold attributes are included in the general
> > "Options" interface. In the example in the beginning of section 4.8,
> > how do you define which sensor attribute, value or normalizedValue
> > the "maxThreshold: 0.9" attribute refers to?
> I was thinking that maxThreshold would apply to the sensor's value (the
> "value" attribute), but it's not explicit in the draft.
> In fact I should make it explicit what the thresholds apply to, for
> each
> property. Something like: for "CPU" they apply to "value".
> If you think that's ok, I'll update the draft for each property.
> Max.

Received on Monday, 1 March 2010 13:42:02 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 19:32:18 UTC