- From: Dave Raggett <dsr@w3.org>
- Date: Tue, 2 Jun 2015 17:50:12 +0100
- To: David Janes <davidjanes@davidjanes.com>
- Cc: public-web-of-things@w3.org
- Message-Id: <B8D39DA4-DB41-4396-9F3B-28D29415AACD@w3.org>
> On 2 Jun 2015, at 16:13, David Janes <davidjanes@davidjanes.com> wrote: > > One issue you are going to face as you start modelling 'real world' things is there's a lot of 'near duplication' of semantic terms. > > For example, in DR's definitions you end up with something like this for Lights (my apologies if this isn't 100% correct) > on: turn the light on /off - { write: true } > is_on: is this on or off - { read: true } For an on/off light switch it is easier to have a single writeable boolean property. The proxy object can use getter and setter methods so that assigning true or false result in the switch being turned on and off respectively. If a human activates the switch, then the proxied property will be updated automatically to match. Of course it is good practice to re-use ontologies/vocabularies where possible as this will simplify the lives of developers. > Now consider a Denon Audio / Visual Receiver. It has, amongst other things: > on > volume > band > mute > So you end up with a parallel set of definitions > is_on > actual_volume > actual_band > is_muted Why not stick with the first set of properties and make them writeable? I am not sure what you mean by the difference between control values and actual values, can you provide an example that clarifies your distinction? — Dave Raggett <dsr@w3.org <mailto:dsr@w3.org>>
Received on Tuesday, 2 June 2015 16:50:16 UTC