Skip to content

Commit

Permalink
Adapt to virtual sensor changes in w3c/sensors#475 (#57)
Browse files Browse the repository at this point in the history
w3c/sensors#475 removed the "virtual sensor type" item from the "virtual
sensor metadata" struct and turned it into a string that is referenced from
the automation bits as well as (optionally) defined by a sensor type.

Adapt to it here by removing mentions of `[=virtual sensor metadata/virtual
sensor type=]` from the spec and adding virtual sensor types to each sensor
type defined here.
  • Loading branch information
Raphael Kubo da Costa authored Nov 27, 2023
1 parent 7b4a298 commit 361f1e2
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,9 @@ The <a>Geolocation Sensor</a> has an associated {{PermissionName}} which is

The <a>Geolocation Sensor</a> is a [=policy-controlled feature=] identified by the string "geolocation". Its [=default allowlist=] is `'self'`.

The <a>Geolocation Sensor</a> has an associated [=virtual sensor type=] which is
"<code><dfn data-lt="geolocation virtual sensor type">geolocation</dfn></code>".

A <dfn>latest geolocation reading</dfn> is a [=latest reading=] for a {{Sensor}} of
<a>Geolocation Sensor</a> <a>sensor type</a>. It includes [=map/entries=] whose [=map/keys=]
are "latitude", "longitude", "altitude", "accuracy", "altitudeAccuracy", "heading", "speed"
Expand Down Expand Up @@ -320,9 +323,9 @@ This section extends [[GENERIC-SENSOR#automation]] by providing [=Geolocation Se

The [=per-type virtual sensor metadata=] [=map=] must have the following [=map/entry=]:
: [=map/key=]
:: "`geolocation`"
:: "<code>[=geolocation virtual sensor type|geolocation=]</code>"
: [=map/value=]
:: A [=virtual sensor metadata=] whose [=virtual sensor metadata/virtual sensor type=] is [=Geolocation Sensor=] and [=reading parsing algorithm=] is the [=geolocation reading parsing algorithm=].
:: A [=virtual sensor metadata=] whose [=virtual sensor metadata/reading parsing algorithm=] is the [=geolocation reading parsing algorithm=].

<h3 dfn>Geolocation reading parsing algorithm</h3>
<div algorithm="geolocation reading parsing algorithm">
Expand Down

0 comments on commit 361f1e2

Please sign in to comment.