openHAB 2.0 binding
-
Hi Tomas!
Thanks for the hint, I will take a closer look!
@ofverstedt said:
I would like to send out numbers to my sensor nodes from rules.
This is currently not possible, but it will be. It is on my ToDo list. :-)
The current solution with the serial binding in OH 1.X is complicated, but leaves a lot of freedom for the user and I would like to preserve as much freedom as possible.I've implemented some new features a while ago, like resending of messages if no ACK is received. But the Repo is out of date. I will fix that.
-
Hi Tim0.
Really nice work with this binding. Huge step forward into a official MySensors OpenHAB binding.It would be nice to have the repo updated so as to try the new features you have implemented.
Have you had time to check why we are gewtting that error at OpenHAB 2 Beta while trying to install the binding?
Let me know if there is any way in which I can help.
Thanks, regards!Gonzalo.
-
Hi @gonzalonal !
I'm working on it. Due to the changes in the OH git repository my environment is all messed up. :-(
-
This kind of problem (as I've read online) in this release of OH seems to be not only related to this binding. One suggestion that I found is here: https://github.com/openhab/openhab-distro/issues/82 (last comment) or here: https://github.com/openhab/openhab-distro/issues/81
I've tested it without success but I don't know if I've done it right. I've also try to build myself a rfxcom binding (this one use gnu.io) and it has the same issue
hope this help
EDIT: this work for me, run on OSGI console: feature:install openhab-transport-serial and restart OH
-
This kind of problem (as I've read online) in this release of OH seems to be not only related to this binding. One suggestion that I found is here: https://github.com/openhab/openhab-distro/issues/82 (last comment) or here: https://github.com/openhab/openhab-distro/issues/81
I've tested it without success but I don't know if I've done it right. I've also try to build myself a rfxcom binding (this one use gnu.io) and it has the same issue
hope this help
EDIT: this work for me, run on OSGI console: feature:install openhab-transport-serial and restart OH
@andreacioni said:
This kind of problem (as I've read online) in this release of OH seems to be not only related to this binding. One suggestion that I found is here: https://github.com/openhab/openhab-distro/issues/82 (last comment) or here: https://github.com/openhab/openhab-distro/issues/81
I've tested it without success but I don't know if I've done it right. I've also try to build myself a rfxcom binding (this one use gnu.io) and it has the same issue
hope this help
EDIT: this work for me, run on OSGI console: feature:install openhab-transport-serial and restart OH
Hi @andreacioni.
You saved the day. It worked for me.
Here the steps I did to make it work.1- Download latest snapshot from https://openhab.ci.cloudbees.com/job/openHAB-Distribution/ (Download offline version)
2- Unzip the file.
3- Run start_debug.sh
4- In console write "feature:install openhab-runtime-compat1x"
5- Ctrl-D to exit/shutdown OpenHAB
6- Once exited, copy MySensors binding to addons folder.
7- Start againg OpenHAB-
8- Thats it. It should workRemember to copy your serial thing to things folder.
Regards!
Gonzalo -
This kind of problem (as I've read online) in this release of OH seems to be not only related to this binding. One suggestion that I found is here: https://github.com/openhab/openhab-distro/issues/82 (last comment) or here: https://github.com/openhab/openhab-distro/issues/81
I've tested it without success but I don't know if I've done it right. I've also try to build myself a rfxcom binding (this one use gnu.io) and it has the same issue
hope this help
EDIT: this work for me, run on OSGI console: feature:install openhab-transport-serial and restart OH
@andreacioni: Absolultly amazing! Thanks!
I don't understand why this helps though because the changes in the code I have to do have nothing to do with OH1 (compability).
I hope to provide an adjusted version today or tomorrow along with a clean and working repository.
Thanks for your patience! :-)
-
@andreacioni: Absolultly amazing! Thanks!
I don't understand why this helps though because the changes in the code I have to do have nothing to do with OH1 (compability).
I hope to provide an adjusted version today or tomorrow along with a clean and working repository.
Thanks for your patience! :-)
@TimO I'think the OH1 compatibility is not the problem. It seems that OH2 beta1 have not installed transport feature and so it has no definition for the gno.io pakage, so I'think there's nothing to do on your code :D
PS tell me when the new repo is OK that I download it and try to add the baudrate config ;) Thanks!!
-
So, I would like to show you my current status. I've tested it against my mini MySensors environment and it looks good so far. Feel free to test.
-
Download latest snapshot from cloudbees: https://openhab.ci.cloudbees.com/job/openHAB-Distribution/lastSuccessfulBuild/artifact/distributions/openhab-offline/target/openhab-offline-2.0.0-SNAPSHOT.zip
-
Unzip file (into a directory like oh2).
-
Download the current binding from Binding and place it in the addons directory under oh2.
-
Configure addons, things, items and sitemap. Example?! addons.cfg, demo.things , demo.items, demo.sitemap
-
Start "start_debug.sh", "start_debug.bat" ...
-
In the karaf console enter: "feature:install openhab-transport-serial".
-
MySensors Plugin "should" start. ;-)
8: "log:set debug" + "log:tail" to see debug output.
Github and documentation will follow, please refer to the "old" Readme and the examples.
-
-
So, I would like to show you my current status. I've tested it against my mini MySensors environment and it looks good so far. Feel free to test.
-
Download latest snapshot from cloudbees: https://openhab.ci.cloudbees.com/job/openHAB-Distribution/lastSuccessfulBuild/artifact/distributions/openhab-offline/target/openhab-offline-2.0.0-SNAPSHOT.zip
-
Unzip file (into a directory like oh2).
-
Download the current binding from Binding and place it in the addons directory under oh2.
-
Configure addons, things, items and sitemap. Example?! addons.cfg, demo.things , demo.items, demo.sitemap
-
Start "start_debug.sh", "start_debug.bat" ...
-
In the karaf console enter: "feature:install openhab-transport-serial".
-
MySensors Plugin "should" start. ;-)
8: "log:set debug" + "log:tail" to see debug output.
Github and documentation will follow, please refer to the "old" Readme and the examples.
@TimO Hi Tim, for debugging outupt of the binding I need to write:
log:set DEBUG org.openhab.binding.mysensors, without this I cannot see anything about binding logs -
-
@TimO Hi Tim, for debugging outupt of the binding I need to write:
log:set DEBUG org.openhab.binding.mysensors, without this I cannot see anything about binding logs@andreacioni Hi andreacioni. Same issue with debug mode with me. Thanks for the tip!
@TimO: V_STOP for Rollershutter sensors, is a MySensors binding limitation, or it is not implemented in OH2 yet?
Another thing I've noticed is that every item added, despite being a regular switch or a rollershutter, is is being added as:
Battery Level
mysensors:cover:gateway:Cover_1_0:battery
MySensors Battery ChannelIs this the intended behavior for every node of my sensor, despite having or not a battery?
Regards.
Gonzalo. -
@gonzalonal said:
V_STOP for Rollershutter sensors, is a MySensors binding limitation, or it is not implemented in OH2 yet?
It is a limitation of OH2 and I don't understand the limitation. It is very confusing, because with the "RollerShutter" widget in OH2 I get three buttons: UP, DOWN and STOP. UP and down calls the handler in which I generate the MySensors message. STOP don't call the handler and therefore I can't do anything. I need to dig deeper.
Battery Level
mysensors:cover:gateway:Cover_1_0:battery
MySensors Battery ChannelIs this the intended behavior for every node of my sensor, despite having or not a battery?
This is intended behavior. The battery status is send via an internal message and there is no presentation if a sensor has a battery or not.
I've therefore added the battery channel to every item. In Paper UI you are able to simply disable the channel by clicking the blue circle next to the battery channel or in the configuration file you have to specify the channel, if you want to use it. If the battery channel is not defined for a thing it won't receive the battery status.For the future: maybe there is a way to hide the channel as long as there was no battery status received and display it only when used. But currently I don't see an easy way to implement that.
Greetings!
Tim -
@gonzalonal said:
V_STOP for Rollershutter sensors, is a MySensors binding limitation, or it is not implemented in OH2 yet?
It is a limitation of OH2 and I don't understand the limitation. It is very confusing, because with the "RollerShutter" widget in OH2 I get three buttons: UP, DOWN and STOP. UP and down calls the handler in which I generate the MySensors message. STOP don't call the handler and therefore I can't do anything. I need to dig deeper.
Battery Level
mysensors:cover:gateway:Cover_1_0:battery
MySensors Battery ChannelIs this the intended behavior for every node of my sensor, despite having or not a battery?
This is intended behavior. The battery status is send via an internal message and there is no presentation if a sensor has a battery or not.
I've therefore added the battery channel to every item. In Paper UI you are able to simply disable the channel by clicking the blue circle next to the battery channel or in the configuration file you have to specify the channel, if you want to use it. If the battery channel is not defined for a thing it won't receive the battery status.For the future: maybe there is a way to hide the channel as long as there was no battery status received and display it only when used. But currently I don't see an easy way to implement that.
Greetings!
Tim@TimO
Great TimO. Thanks for clarifying this topic.
Regards.
Gonzalo -
@gonzalonal : I found a solution for V_STOP! It will be available soon.
But more important: @andreacioni is doing some great work improving the stability and performance of the binding!!
I just wanted to let you know, that the binding is currently under heavy development. :+1:
-
@gonzalonal : I found a solution for V_STOP! It will be available soon.
But more important: @andreacioni is doing some great work improving the stability and performance of the binding!!
I just wanted to let you know, that the binding is currently under heavy development. :+1:
@TimO
Great news TimO. Really nice to hear that.
Regarding STOP functionality for the binding, I have read somewhere that the supported commands by OpenHAB, for RollerShutter items, are Up, Down and StopMove. Have yoy tried something like this?Regards
Gonzalo. -
@gonzalonal said:
Regarding STOP functionality for the binding, I have read somewhere that the supported commands by OpenHAB, for RollerShutter items, are Up, Down and StopMove. Have yoy tried something like this?
Yeah, my problem till yesterday was, that I was not able to cast the given state to StopMoveType in case of Stop, while casting the state to UpDownType for Up and Down was no problem. :-)
I changed the way how the binding handles this type of message and it works now.
-
@gonzalonal said:
Regarding STOP functionality for the binding, I have read somewhere that the supported commands by OpenHAB, for RollerShutter items, are Up, Down and StopMove. Have yoy tried something like this?
Yeah, my problem till yesterday was, that I was not able to cast the given state to StopMoveType in case of Stop, while casting the state to UpDownType for Up and Down was no problem. :-)
I changed the way how the binding handles this type of message and it works now.
@TimO
Can we clone the latest source code from this binding? I think that your github repository is outdated and I want to work this weekend with it, 'cause I would like to integrate the mysensors 2.0-beta "smartSleep" feature with your binding in my home sensors setup (ESP8266 Ethernet GW).Also, if there are any ISSUE y your TODO list in which I can help you, please tell me.
Regards
-
@TimO
Can we clone the latest source code from this binding? I think that your github repository is outdated and I want to work this weekend with it, 'cause I would like to integrate the mysensors 2.0-beta "smartSleep" feature with your binding in my home sensors setup (ESP8266 Ethernet GW).Also, if there are any ISSUE y your TODO list in which I can help you, please tell me.
Regards
Hi Sebastián, what repository have you checked? Currently the development is not on the old https://github.com/wishmoooop/openhab2/tree/master/addons/binding/org.openhab.binding.mysensors but was moved here: https://github.com/tobof/openhab2-addons/tree/MySensors/addons/binding/org.openhab.binding.mysensors
Hope this help :)
-
Hi Sebastián, what repository have you checked? Currently the development is not on the old https://github.com/wishmoooop/openhab2/tree/master/addons/binding/org.openhab.binding.mysensors but was moved here: https://github.com/tobof/openhab2-addons/tree/MySensors/addons/binding/org.openhab.binding.mysensors
Hope this help :)
@andreacioni said:
Hi Sebastián, what repository have you checked? Currently the development is not on the old https://github.com/wishmoooop/openhab2/tree/master/addons/binding/org.openhab.binding.mysensors but was moved here: https://github.com/tobof/openhab2-addons/tree/MySensors/addons/binding/org.openhab.binding.mysensors
Hope this help :)
Thanks @andreacioni
I was working on the old repo! :) -
I've updated the first posting in this thread. You'll find the current repo there (also). ;-)
I've added a Wiki to the repo and made a brief description of the installation and configuration process.
https://github.com/tobof/openhab2-addons/wiki
The current binding (jar) is also in the repo now. You'll find the link in the wiki under "Installation".
Modifications in the current version:
- RollerShutter now supports STOP
- Performance of the binding improved. Big thanks to @andreacioni !!
- Stability improved. Also big thanks to @andreacioni
- Error handling on connection loss improved
- The baud rate of the serial gateway is now adjustable. (@andreacioni again!)
- some code cleanup: removed not needed debug output etc.
Please let me know if you found the time to test the binding and what the results are. :-)
-
I've updated the first posting in this thread. You'll find the current repo there (also). ;-)
I've added a Wiki to the repo and made a brief description of the installation and configuration process.
https://github.com/tobof/openhab2-addons/wiki
The current binding (jar) is also in the repo now. You'll find the link in the wiki under "Installation".
Modifications in the current version:
- RollerShutter now supports STOP
- Performance of the binding improved. Big thanks to @andreacioni !!
- Stability improved. Also big thanks to @andreacioni
- Error handling on connection loss improved
- The baud rate of the serial gateway is now adjustable. (@andreacioni again!)
- some code cleanup: removed not needed debug output etc.
Please let me know if you found the time to test the binding and what the results are. :-)
@TimO said:
I've updated the first posting in this thread. You'll find the current repo there (also). ;-)
I've added a Wiki to the repo and made a brief description of the installation and configuration process.
https://github.com/tobof/openhab2-addons/wiki
The current binding (jar) is also in the repo now. You'll find the link in the wiki under "Installation".
Modifications in the current version:
- RollerShutter now supports STOP
- Performance of the binding improved. Big thanks to @andreacioni !!
- Stability improved. Also big thanks to @andreacioni
- Error handling on connection loss improved
- The baud rate of the serial gateway is now adjustable. (@andreacioni again!)
- some code cleanup: removed not needed debug output etc.
Please let me know if you found the time to test the binding and what the results are. :-)
Thank you @TimO !
This weekend I started migrating from my OH1.8 + mqtt GW setup to OH 2 beta + your binding. At the moment all is working fine, I spent some time learning about OH2 / Eclipse smartHome and watching your code, because I want to implement the smartSleep feature (https://github.com/mysensors/Arduino/pull/271) in the mysensors binding.My idea is: when the handler don't receive an ACK from a message, it store the message for a while, waiting a heartbeat from a node, and, if the binding has some message stored for this node, then send it again. I don't know if this is correct, or if you thinks there is a better solution.
Regards