The UK Home Automation Archive

Archive Home
Group Home
Search Archive


Advanced Search

The UKHA-ARCHIVE IS CEASING OPERATIONS 31 DEC 2024


[Message Prev][Message Next][Thread Prev][Thread Next][Message Index][Thread Index]

Re: Re: HA Object Model or Taxonomy?



On 18 Mar 2012, at 16:58, ewenjc wrote:
Thanks Ewen - state machines are definitely the way to implement this kind
of state-watching behaviour, and would be a likely candidate when someone
actually chooses to implement some of these objects. Whether this is done
in Ruby, Java, Perl, Scala or something else is still very much an open
question (indeed, one which has not even yet been asked!). My personal
feeling is that the model should be language-agnostic, such that devices
could be implemented in whatever language is most appropriate. This does,
however, limit the general applicability of the model - it might be better
to define a reference language and ensure that bridging to/from it is
trivial. It's certainly worth bearing in mind that one of the reasons to
develop a public automation model is to make it easy to write code against
it - it might be easier to make a sort of "automation sandbox"
for experimentation and tinkering if there was a clearly defined language
and environment. What does everyone think?

Cheers,

Gavin


> I've not had time to read through this thread in detail but wonder if
state machines are relevant. They allow for the definition of State and
Transitions etc. For this sort of issue in Ruby on Rails I'd turn to https://github.com/pluginaweek/state_machine.
It might not be useful directly but may have addressed some of the issues
you're working through.
> -Ewen
>
> --- In ukha_d@xxxxxxx, alan.trevennor@... wrote:
> >
> > Following on the general discussion of a "getStatus"
method..
> >
> > I would suggest "GetState" is a better name for this
method, pretty much anything has a state. For example, a cushion always has
a state, but not really a status, since it doesn't have a formalised set of
statuses, whereas, an aircon unit definitely has a set of formalised
states).
> >
> > I see the main jobs of an object model as being to codify a
subset of objects in the real world (in this case objects of all kinds
found in the home) and to be able to indicate, in some way, their permanent
or dynamic relationships to one another (the ontology).
> >
> > Having a separate ontology is essential if dealing with a subject
areas such as published books and music CDs, where there is a dynamic
relationship between writers and artists and the things they create: For
example such an ontology needs to indicate that Brandon Flowers was a
member of The Killers, but is also a songwriter and solo artist and
producer.
> >
> > However, in the HA case, I think the relationships are more
settled and may be adequately conveyed in the object model structure. For
example, an illuminated house sign is always going to be under something
like:
> >
> > \fittings\illumination\lighting\outdoor
> >
> > As to the level of detail.....
> > in theory, an object model should be capable of accommodating any
possible level of detail. For example:
> >
> >
\furnishings\accessories\comfortItems\cushions\footCushions\fillings\hollowFibre\tufts
> >
> > would allow you to model each tuft of hollow fibre in the
aforementioned cushion, but of course it would be looney for the HA model
to go into such detail, but the possibility should exist. Who knows, one
day we may have intelligent hollow-fibre filling that can be commanded from
an HA network to reshape itself electrically. Ah! Brave new world!
> >
> > However I think that, to preserve sanity, at some point in any
practical object model you have to resort to allowing "freeform"
responses. So, to continue the looney example, I see no problem with an
instance of a cushion having a "getState" method that returns a
collection of filling object whose state is just a set of self-describing
XML objects - i.e. objects which are not formally described in the model.
Further, I think that in the HA sphere - since it's unfeasible to model
every type and individual variant of - say - TVs. So, at some point TV
objects just have to return a freeform string of data that only some custom
piece of code can interpret.
> >
> > Anyway, I am probably pre-empting the kinds of discussions we
need to have about the scope and limits of an HA model that we might
develop.
> >
> > Regards
> > Alan T
> >


[Non-text portions of this message have been removed]



------------------------------------

<*> Join the Automated Home Forums
http://www.automatedhome.co.uk/vbulletin/


UKHA_D Main Index | UKHA_D Thread Index | UKHA_D Home | Archives Home

Comments to the Webmaster are always welcomed, please use this contact form . Note that as this site is a mailing list archive, the Webmaster has no control over the contents of the messages. Comments about message content should be directed to the relevant mailing list.