- Platform information:
- Hardware: rPi 3
- OS: openHABianPi 4.9.80-v7
- openHAB version:2.3.0-1 (Release Build)
- Issue of the topic: dash button rule doesn’t work
dashbut1.rules: copied exactly from the example page
rule “dash_button_pressed”
when
Channel “amazondashbutton:dashbutton:68-37-e9-xx-yy-zz:press” triggered
then
logInfo(“amazondashbutton”, “My Dash Button has been pressed”)
end
dashbut1.things
Thing amazondashbutton:dashbutton:68-37-e9-xx-yy-zz “brabantia” @ “Dragons Lair” [
macAddress=“68:37:e9:xx:yy:zz”, pcapNetworkInterfaceName=“eth0”, packetInterval=5002 ]
The sitemap doesn’t have any reference to this rule, so it’s not included. (Could be why it’s not working?)
I have read & followed all the setup pages, and copied the rule from the sample in the Dash Button Binding page.
The dash button Thing definitely works (the 5002ms is my check method of seeing it worked in the paper UI), and we know this because the openhab log has the (textbook) triggered entry:
2018-11-13 21:54:28.428 [vent.ChannelTriggeredEvent] - amazondashbutton:dashbutton:68-37-e9-xx-yy-zz:press triggered
But no rule happens. The rule shows a logInfo command, exactly as the sample code, but it produces no log entry as it should. I’ve also tried an MQTT command:
{mqtt=">[mqtth2:Dragon/Basem/Lights1/cmnd/power1:command:TOGGLE:toggle]" }
but the rule doesn’t fire, so it’s not much of a test really (!).
What I’d like to do it add it to the sitemap so that the “switch” item:
Switch item=Pwr_B_1 icon=“light” label=“Basement Pwr 1”
gets toggled - so it shows in the UI as well as sending the (working) MQTT command to the switch.
Can anyone please nudge me in the right direction please? I have carefully checked the syntax for missing characters, but can’t see my mistake.
Many thanks in advance, much appreciated.
Lee
ps - the xx_yy_zz are replacements for the actual mac address