[BTicino/OpenWebNet] New openHAB2 binding ready for testing

Hello Massimo

Thank you for the work that you and others have done to produce this binding. I am using it with openHab to develop the lighting system for a new art gallery, using the MyHome bus system (I live in Italy!)

I know it may be a little off topic, but I need a replacement for the F429 DALI light interface. I am making a virtual “F429” using a raspberry pi 3, with a DALI HAT board as a headless interface. I can connect to the SCS bus with an OpenWebServer F454, but not with the MyHome Server1 as this uses HMAC password verification. Could you tell where the routines for password verification are in your binding source code to save a lot of time search through the files.

Any other tips or comments on how to access the MyHome Server1 would be greatly appreciated.

Thanks

before asking a question at least you should read/search the first message of this thread, should you?

it seems it’s a OpenWebNet gateway, so it should be supported.
Try it (you have to add it manually, it will not be discovered automatically) and let me know so I can add it to the list of tested supported gateways.

This post was flagged by the community and is temporarily hidden.

this is worth reading for everyone:

Communication on this forum is exclusively in English language. Thanks for your attention.

Massimo

Thank you for posting a link to the Hmac.pdf Although I now understand the protocol and can capture the logon messages passed between MyHome Suite and the MyHome Server, I cannot replicate the correct responses. Do you know of any other documentation or examples that you could direct me to.

I know it is off topic, but after a day and a half of frustration work I am getting desperate.

Paul Gregory

Hi @massi ,

My gateway firmware version is 1.2.3.
You mentionned adding a parameter to handle the inversion, should I open an issue on your github repository ? As a java developer, I might be able to help (and would be glad to).

I have already taken notes about which files and lines to add/change. Up/Down conversion happens in OpenMessageFactory, but I can’t find openwebnet-lib sources (I had to decompile), are they available somewhere ?

Regards,
Cyril

Yes, I have tested and it totally works

thanks!
but my problem is that on alexa the blinds moves inverted and ON-OFF doesn’t work

whis is my configuration:

Bridge openwebnet:bus_gateway:MH201_b07494f3 "BUS Gateway MH201" @ "Soggiorno" [ host="192.168.82.196", port=20000, passwd="12345"] {
	bus_automation    TapparellaStanzaGiochi_NEW  "TapparellaStanzaGiochi_NEW"  [ where="13", shutterRun="17000"]
}	

Rollershutter	iTapparellaStanzaGiochi_NEW	 "iTapparellaStanzaGiochi_NEW [%.0f %%]" <rollershutter>  (Gruppo_Tapparelle,Gruppo_Camera_Bambine)[ "Blinds" ]   { channel="openwebnet:bus_automation:b07494f3:TapparellaStanzaGiochi_NEW:shutter" }

what is the problem?
I try also with new v3 tag alexa=“PercentageController.percentage” [category=“SWITCH”] but alexa doesn’t found any new device

This configuration works but inverted and the command UP & DOWN is not recognized because the command sent is ON and OFF: how can I reverse and “translate” the command?

Dimmer iTapparellaStanzaGiochi_4 "iTapparellaStanzaGiochi_4 [%.0f %%]" <rollershutter>  (Gruppo_Tapparelle,Gruppo_Camera_Bambine) {alexa="Switchable" , channel="openwebnet:bus_automation:99eef840:shutter" }

Hi, you should open a dedicated thread for your issue.
what is your openhab version? try follow configuration:

Rollershutter iTapparellaStanzaGiochi_4 "iTapparellaStanzaGiochi_4 [%.0f %%]" <rollershutter>  (Gruppo_Tapparelle,Gruppo_Camera_Bambine) {channel="openwebnet:bus_automation:99eef840:shutter", alexa="PercentageController.percentage" [category="SWITCH"]}

than you can say “alexa, imposta %nometapparella% al 50%”

Edit:
If you have problem with V3 tags try old v2 tag:

Rollershutter iTapparellaStanzaGiochi_4 "iTapparellaStanzaGiochi_4 [%.0f %%]" <rollershutter>  (Gruppo_Tapparelle,Gruppo_Camera_Bambine) ["Switchable"] {channel="openwebnet:bus_automation:99eef840:shutter"}

thanks but I’ve already tried that combinations and the blind is moving but inverted and ON/OFF none

the version of OH is 2.4

I’ll open a dedicated thread

Hi @Daniele_Z

I’m afraid your problem is related to mine : if I understood binding’s code correctly, every automation command is automatically inverted, and you cannot change that for now:

if ((localBaseOpenMessage1 instanceof Automation)) {
   localBaseOpenMessage2 = (BaseOpenMessage)convertUpDown((Automation)localBaseOpenMessage1);
}
public static OpenMessage convertUpDown(Automation paramAutomation) {
    if (paramAutomation.isUp()) {
       a.debug("###################################################################");
       a.debug("###################################################################");
       a.debug("##openwebnet## converting Automation UP {} > DOWN", paramAutomation);
       return parse(paramAutomation.getValue().replaceFirst("\\*2\\*1", "\\*2\\*2")); }
    if (paramAutomation.isDown()) {
       a.debug("###################################################################");
       a.debug("###################################################################");
       a.debug("##openwebnet## converting Automation DOWN {} > UP", paramAutomation);
       return parse(paramAutomation.getValue().replaceFirst("\\*2\\*2", "\\*2\\*1"));
    }
    return paramAutomation;
}

I do not believe that the command are inverted: the system refers to the opening of the roller, to the unfolding of the shutter.
I would like the commands to work in reverse and the ON and OFF commands to be translated into UP and DOWN plus the STOP command

Ok, thanks, I must be missing something.

Hello everyone! Since this morning my myhomeserver is offline while all worked very well yesterday.binding problem?

019-09-15 07:00:24.120 [INFO ] [bnet.handler.OpenWebNetBridgeHandler] - ==OWN== BridgeHandler status still UNKNOWN. Setting device=openwebnet:bus_gateway:MYHOMESERVER1 to OFFLINE

==> /var/log/openhab2/events.log <==

2019-09-15 07:00:24.135 [hingStatusInfoChangedEvent] - ‘openwebnet:bus_gateway:MYHOMESERVER1’ changed from UNKNOWN to OFFLINE (COMMUNICATION_ERROR)

1 Like

same problem here!

i suppose the binding is again expired, very bad surprise …

@killer: in the binding Automation messages are inverted only for radio (Zigbee) automation using USB stick BTicino 3578, and only if USB stick firmware version is <= 1.2.3.
I will correct this in the next binding version.
I do not have radio automation devices so I cannot know up to which firmware version the inversion of UP/DOWN is present (it’s probably a bug from BTicino).
Apparently USB dongle firmware 1.2.3 is not affected.