Suggestions from users of Light Dimmers/Switches and Alexa with OH2 Skill

Hi All
Just wondering who is using these features and has configured routines or the skill in a way that allows both the switch and the dimmer to work for a living room?

I have for example:

‘Alexa, turn on the living room lights’ as a routine but I also have the same thing for the Dimmer item as the Switch so naturally I get issues with the same name being used and Alexa gets upset.

I’d like to be able to dim the lights by certain percentages and switch the lights on and off.


Hi, Kris (@dastrix80). If you declare a single Dimmer Item per physical dimmer device and use the “Lighting” tag for Hue Emulation, it should work. A Dimmer Item is a specialized version of a Switch Item, so it will accept an OnOffType or a PercentType as a command, i.e., you can tell Alexa to “turn OFF my light” or “set my light to 50%.”

You should be able to verify this by using the Alexa app to forget the Switch definition for one of your doubly defined dimmers, then issue voice commands for both ON/OFF and percent levels for the remaining, non-duplicated Dimmer Item definition.

One of my working item definitions:

Dimmer  OfficeFanLts            "Office Fan Lights"             (gOF,gOFLts,gOFLtsOn,gUpstairsLts,gLTs,G_PresenceSimulation)            ["Lighting"]

I have an issue when the command ON is issued to a dimmer that uses the MQTTv1 binding. The ON command is interpreted as 1%, but I think that is an issue in the way my MQTTv1 Dimmer Items are defined. My Z-Wave dimmers don’t exhibit the problem.

Hi Scott, So rather than have both my switch and my dimmer tagged, like below, you would only tag the dimmer item?

/*ZWave Dimmer 2 Living Room Lights*/
Switch LivingRoomSw1  "Living Room"                                    (gAllLights,gInsideLights)                [ "Lighting" ]      { channel="zwave:device:c5b08a5b:node6:switch_dimmer1" }
Dimmer LivingRoomDim1 "Living Room [%d %%]"                            (gAllDimmers)                             [ "Lighting" ]      { channel="zwave:device:c5b08a5b:node6:switch_dimmer1" }
Number LivingRoomNum1 "Living Room - Current Consumption [%.1f W]"     (gAllLightsUsage)                                             { channel="zwave:device:c5b08a5b:node6:meter_watts" }
Number LivingRoomNum2 "Living Room - Usage [%.1f kW]"                  (gPowerUsage)                                                 { channel="zwave:device:c5b08a5b:node6:meter_kwh" }


Correct. I only now see you referenced the Alexa skill, which I do not use. However, the issue is a Dimmer vs. a Switch Item and the commands they accept. Like I said, a Dimmer Item is a specialized Switch Item, which will accept both OnOff and PercentType commands.

1 Like

Thanks Scott, ill try this :slight_smile:

You’re welcome. Good luck!

1 Like