Openhab Triggers On and Off with Single press

Hello,

i am trying to migrate from fhem to openhab and want to give it a shot.
For now i am happy with the ground setup and it seams to work fine, but i have one problem, where i haven’t found a solution and it’s quite major.
For simplicity:
I have a LD382A which i added with the Wifiled Addon and i have setup an Homegear with HM-CFG-LAN and peered a switch (HM-PB-6-WM55).
So far all seams to work fine, i can for example switch my light on and off via the Control Panel in the Paper UI. And in the Eventlog i see the buttons triggered of my switch.
Now i linked them and it does not work, because the light is enabled and instantly disabled again.
Here is what i mean what shows up in the log with a single press of a button on my switch:

2018-10-28 02:19:38.332 [vent.ChannelTriggeredEvent] - homematic:HG-HM-PB-6-WM55:63b0d0a3:NEQ0434267:1#PRESS triggered SHORT

2018-10-28 02:19:38.341 [vent.ItemStateChangedEvent] - Bettlampe changed from OFF to ON

2018-10-28 02:19:40.332 [vent.ItemStateChangedEvent] - Bettlampe changed from ON to OFF

I only used Paper UI for adding the things, create a power item for the light and linked the switch to it.

Is there something obvious i don’t see or could done wrong?
Thank you for any help, i appreciate it :slight_smile:

regards Michael

I suspect what is happening is the honeatic switch really toggles on then off when you press it. If you just link that channel to the light, the light will just switch on then immediately off, because they use what the switch is doing.

Unfortunately you will have to use rules to solve this problem. Something like…

Create a separate item for the button.

rule "toggle light"
when
    Item Honeatic ton received command ON
then
    if(Bettlampe.state == ON) Bettlampe.sendCommand(OFF)
    else Bettlampe.sendCommand(ON)
end

I don’t know this binding, you may be able to trigger the Rule straight from the Channel and not need a separate Item.

1 Like

Thank your very much,
i solved it buy using the experimental Rule Engine.
That’s great :slight_smile:

I just did not understand the “link” of things and items.
Thank your for your help