These are simple switch items I created in text files super simple and are not needed too use the dimmer switches they are only a part of my setup ![]()
on my setup heres what they do
Bed trigger is a switch I use too tell openhab Iām going too bed so it can run a routine that turns off lights and sockets and arms my security system I use its state in that rule so it can run the end of the routine and turn off my bedroom light and also if this mode is on that im in bed and have requested my lights too turn on
Morning mode ready is the same itās a simple switch that when on it waits for motion at the bottom of my stairs that then triggers the full morning mode routine turning lights on sockets on and disarm my security system
other.items
Switch Bed_Trigger "Bed Trigger"
Switch Morning_Mode_Ready "Wait for morning Trigger"
That will be possible but Iām not sure how you use the http binding like I say Iām not an expert I only used it for the hue switches following instructions make a post on the fouroum somobody will help you with that ![]()
**Adding Hue Dimmer Switches to OH**
- Add the dimmer switch too openhab using paperUI creating the thing only
- create the items in text files (copy and edit this too the items folder save as hue.items edit the channels at the end of the items too match the ones listed in the thing on paperUI
Number KitSwitchWhat "Kitchen Switch Button [%s]" {channel="hue:0820:001788781cca:57:dimmer_switch" }
DateTime KitSwitchWhen "Kitchen Switch When [%s]" {channel="hue:0820:001788781cca:57:last_updated" }
Number KitSwitchBattery "Kitchen Switch Battery [%.0f %%]" {channel="hue:0820:001788781cca:57:battery_level"}
the channels at the end of the item files are listed on the thing on paperUI marked in a square you can just copy them using copy marked with a circle saves alot of typing and mistakes
{channel="hue:0820:001788781cca:57:dimmer_switch" }

- create the rule in text files (copy and edit this too the rules folder save as hue.rules edit the rule so it does what you want
rule "Dimmer Switch Rule"
when
Item KitSwitchWhen changed
then
Thread::sleep(1500) // wait too not confuse OH
if( KitSwitchWhat.state == 4002.0 ) { // Bottom Button
// put stuff you want it too do here
}
if( KitSwitchWhat.state == 3002.0 ) { // Second Button
// put stuff you want it too do here
}
if( KitSwitchWhat.state == 2002.0 ) { // Third Button
// put stuff you want it too do here
}
if( KitSwitchWhat.state == 1002.0 ) { // Top Button
// put stuff you want it too do here
}
end