Binding developers: PLEASE READ!

437 views
Skip to first unread message

Kai Kreuzer

unread,
Dec 22, 2014, 4:20:59 PM12/22/14
to
Hi all,

First of all: Thanks that so many of you have already started implementing / porting bindings for openHAB 2!
I can see already a long list of pull requests to be processed: https://github.com/openhab/openhab2/pulls?q=is%3Aopen+is%3Apr

Besides these already "finished" bindings, I would be interested in who else is already working on a binding. To make sure that there are not different people working on the same thing, I would like to ask all of you to enter an issue with the label "newbinding" in the issue tracker: https://github.com/openhab/openhab2/issues?q=is%3Aopen+is%3Aissue+label%3Anewbinding - this would be very helpful for getting an overview, especially as I will also learn what to take special care about when potentially doing backward compatibility breaking changes in the API.

Secondly, I have to apologize that I didn't process all of the pull requests so far - this is partly due to the fact that I simply didn't yet find the time up to now for reviewing them, but also because we have meanwhile worked on extensions to the thing definitions. It is now possible to describe things in much more detail, e.g. by grouping channels together into functional units, by giving valid ranged through min/max values or providing options for values. All of this is available since today in the very latest openHAB 2 (but note that it is not yet officially merged into Eclipse SmartHome, so the documentation is not yet at Eclipse). You will find an updated tutorial here: https://github.com/eclipse/smarthome/tree/master/docs/sources/howtos/bindings.md#describing-things and a general explanation about channels here: https://github.com/eclipse/smarthome/tree/master/docs/sources/architecture/thing-definition.md#channels. Additional information about the thing XML structure is given here: https://github.com/eclipse/smarthome/tree/master/docs/sources/architecture/configuration.md#xml-structure-for-thing-descriptions

It would be great if you could enhance your bindings, so that they also provide this detailed information - once this is done, please leave a comment on your PR and I will do my very best to process it asap!

If you have any questions or concerns, please let me know!

Best regards,
Kai

Karel Goderis

unread,
Dec 23, 2014, 5:14:21 AM12/23/14
to open...@googlegroups.com
Kai

will have a go at this and provide feedback on possible problems/enhancements. One that comes to mind : Channels : SoundVolume category should also be Dimmer type…. I think that there should also be a default category if a good mapping is not possible. What is missing are things like:  Voltage, Current, Volume (as in m3), Weight…. anyways, there is a lot to plough through

K

On 22 Dec 2014, at 22:20, Kai Kreuzer <k...@openhab.org> wrote:

Hi all,

First of all: Thanks that so many of you have already started implementing / porting bindings for openHAB 2!
I can see already a long list of pull requests to be processed: https://github.com/openhab/openhab2/pulls?q=is%3Aopen+is%3Apr

Besides these already "finished" bindings, I would be interested in who else is already working on a binding. To make sure that there are not different people working on the same thing, I would like to ask all of you to enter an issue with the label "newbinding" in the issue tracker: https://github.com/openhab/openhab2/issues?q=is%3Aopen+is%3Aissue+label%3Anewbinding - this would be very helpful for getting an overview, especially as I will also learn what to take special care about when potentially doing backward compatibility breaking changes in the API.

Secondly, I have to apologize that I didn't process all of the pull requests so far - this is partly due to the fact that I simply didn't yet find the time up to now for reviewing them, but also because we have meanwhile worked on extensions to the thing definitions. It is now possible to describe things in much more detail, e.g. by grouping channels together into functional units, by giving valid ranged through min/max values or providing options for values. All of this is available since today in the very latest openHAB 2 (but note that it is not yet officially merged into Eclipse SmartHome, so the documentation is not yet at Eclipse). You will find an updated tutorial here: https://github.com/openhab/smarthome/blob/future-master/docs/sources/howtos/bindings.md#describing-things and a general explanation about channels here: https://github.com/openhab/smarthome/blob/future-master/docs/sources/architecture/thing-definition.md#channels. Additional information about the thing XML structure is given here: https://github.com/openhab/smarthome/blob/future-master/docs/sources/architecture/configuration.md#xml-structure-for-thing-descriptions

It would be great if you could enhance your bindings, so that they also provide this detailed information - once this is done, please leave a comment on your PR and I will do my very best to process it asap!

If you have any questions or concerns, please let me know!

Best regards,
Kai


--
You received this message because you are subscribed to the Google Groups "openhab2" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openhab2+u...@googlegroups.com.
To post to this group, send email to open...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/openhab2/94aa7ac9-0b67-427e-8d15-2af7d286a090%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Kai Kreuzer

unread,
Dec 23, 2014, 6:37:10 AM12/23/14
to open...@googlegroups.com
Karel,

Thanks - probably best for you to start with Sonos :-)
Note that the categories are not meant as a full-blown device ontology, but rather as some meta-information that allows UIs to choose an adequate icon. Leaving the category element out is absolutely fine as a „default category“.

Regarding voltage, current, weight, etc.: There are a few more coarse grained categories like „energy“ and „flow“. For all others, we will introduce a unit property to Number items, so that measurement values can be specified more correctly. Creating a category for all of this would lead to far - so we only chose the most commonly used things. Nonetheless, this list is open for discussion - I would suggest that we create a topic at https://www.eclipse.org/forums/index.php/f/271/

Best regards,
Kai

Marcel Verpaalen

unread,
Jan 2, 2015, 10:14:58 AM1/2/15
to open...@googlegroups.com
Hi Kai,

Can it be that the extensions to the thing definitions  can't be used yet.
When I edit the xml files with these new attributes I get errors in the IDE as well as during startup.

Is there anything else I need to do besides using reload button on the openhab target in the plug-in settings?

Op maandag 22 december 2014 22:20:59 UTC+1 schreef Kai Kreuzer:

Kai Kreuzer

unread,
Jan 2, 2015, 11:22:47 AM1/2/15
to open...@googlegroups.com
Hi Marcel,

You are right, the latest schemas (which are used to validate against) were not yet uploaded to eclipse.org - I have just done so and now content completion and validation should work well!

Best regards,
Kai

--
You received this message because you are subscribed to the Google Groups "openhab2" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openhab2+u...@googlegroups.com.
To post to this group, send email to open...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages