[RELEASE] HomeSeer Wall Dimmer HS-WD200

This is a device handler for the HomeSeer Wall Dimmer (HS-WD200+).

All Features are fully functional with Automations and all the built-in apps, but until Custom Capabilities are fully supported and all of their known bugs have been fixed you’ll need to use the Workaround Child Devices with those SmartApps.

Features

  • Dimmer

  • Switch

  • Button Actions:
    down, down_hold, down_2x, down_3x, down_4x, down_5x, up, up_hold, up_2x, up_3x, up_4x, up_5x

  • LED Mode
    Normal LED Mode(load) / Status LED Mode (custom)

  • Normal LED Color
    white, red, green, blue, magenta, yellow, cyan

  • Status LED Blink Frequency
    You can only change it from the settings, its child device, or WebCoRE because of a bug in custom capabilities

  • Status LED Color (All LEDs)
    off, red, green, blue, magenta, yellow, cyan, white, blinking red, blinking green, blinking blue, blinking magenta, blinking yellow, blinking cyan, blinking white

  • Individual Status LED Color for Each LED (1-7)
    off, red, green, blue, magenta, yellow, cyan, white, blinking red, blinking green, blinking blue, blinking magenta, blinking yellow, blinking cyan, blinking white

Workaround Child Devices

  • Requires the optional Child Device Handlers

  • There’s a setting for each child device that determines if it gets created.

  • Normal Mode:
    Switch On: Normal Mode | Switch Off: Status Mode | Color Control: Sets Normal Mode LED Color

  • Status Mode Blink Frequency:
    Switch On: Restore Last | Switch Off: Disable Blinking | Dimmer Level: Sets Blink Frequency (1=100ms, 2=200ms, etc.)

  • Status Mode LED Color (ALL LEDs):
    Switch On: Restore Last | Switch Off: LED Off | Color Control: Sets LED Color

  • Individual Status LED (1-7):
    Switch On: Restore Last | Switch Off: LED Off | Color Control: Sets LED Color | Color Temperature: Blinking Enabled when value is above 4500

   


HomeSeer Wall Dimmer

               

   


All Workaround Child Devices Enabled

   

   

   


Child Device for Changing LED Mode and Normal LED Color

   


Child Device for Changing Status LED Blink Frequency

   


Child Device for Changing Status Mode LED Color (ALL LEDs)

   

   


Child Device for Changing Individual Status Mode LED Color

      

   


   

Device Handler Code

   


   

Optional Child Devices

2 Likes

Can anyone offer any suggestions on how to get this working with webcore?

If you enable the child devices then you can use them in WebCoRE the same way you would in Automations.

With WebCoRE that’s actually not necessary because the main handler has some custom commands that should provide all the functionality you’re looking for.

Thanks. Can you give an example of how I can use the custom commands in webcore to turn on led 2, make it red, and blink.

Thanks

It’s been a really long time since I’ve used WebCoRE, but I’m pretty sure that when you select the device for an action you’ll see the custom command

setStatusLedColorBlinkFrequency

Once you select it you should be able to set the value of arguments/parameters.

  • The 1st is for the color and it’s a string that can be any of these values: off, red, green, blue, magenta, yellow, cyan, white

  • The 2nd is for the LED # and it’s a number between 1 and 7.

  • The 3rd is for the blink frequency which is a number between 0 and 255. (0 = off, 1 = 100ms, and 255 = 25.5s)

To turn on led 2, make it red, and blink every 1 second you’d enter the values below into the corresponding argument/parameter fields:

argument/parameter #1: red
argument/parameter #2: 2
argument/parameter #3: 10

After you enter those fields I think it should look like below in the “do” section:

setStatusLedColorBlinkFrequency("red", 2, 10);

If that doesn’t provide you enough information to figure it out then post of a screenshot of what you see in WebCoRE after selecting the device and then selecting the “setStatusLedColorBlinkFrequency” command.

UPDATE: I just remembered that if you want to use the default blinking frequency then you can exclude argument/parameter #3 and prefix “blinking” to the color name so it would look like:

setStatusLedColorBlinkFrequency("blinkingRed", 2);

Thanks, im so close! it doesnt blink. Here is what the piston looks like. Any thoughts on getting it to blink?

I just remembered that this device has 1 setting for blinking frequency and a bitmask setting that determines whether or not each led should blink.

Because of that you have to include “blinking” in the color name if you want it to blink.

I also forgot to mention that you can control all the LEDs together by either excluding parameters 2 and 3 or using 0 as the led number.

The color/led and frequency should really be split into 2 custom commands, but this started as the Switch handler and that device only has 1 LED.

If you include the frequency argument then that will change the blinking frequency for all the LEDs, but doesn’t determine if they’re blinking except if you set it to 0 because that completely disables blinking.

To reduce the number of messages being sent to the device every time you change an LED I recommend changing the blink frequency setting to 1 second in the device settings and don’t include that argument in WebCoRE.

What is the setSwitchModeStatus(); line supposed to be doing? I’m pretty sure that’s not a custom command in my handler…

setSwitchModeStatus() was a remnant from an old piston, I removed it. I cant seem to set “status LED Blink Frequency”. When I click the dimmer in smartthings and edit the settings, i see the specific setting for blink frequency. It has a slider to adjust the setting from but it wont go off of 0. It seems to be greyed out. If i click the 0 next to the setting, I can specify 10, for 1 second, however the setting never takes. Thoughts?

I got it! Thank you so much for your help. Turns out that the main screen for the dimmer does not allow you to switch the blinking frequency (bug?). If I go into the settings of the switch, rather than just looking at the main page of the switch, it does allow me to make the change.

i cant control the blink frequency here…

i can control the blink frequency here…

Thank you for your help again! Another question, how do I use webcore to do something if for instance i press the up button twice? When I press up twice, i know the dimmer is seeing it, because i can see in smartthings that the button was toggled up twice. However, if i program something like if button # 2 gets pushed, do this, it never triggers. I suspect it has to do something with supportedButtonValues, but cant figure it out.

iOS or Android?

Are you able to change the color from that screen?

SmartThings basically moved away from the button # implementation and now supports different types of button actions.

The device only has 1 button, but you can trigger automations based on any of these actions:

down, down_hold, down_2x, down_3x, down_4x, down_5x, up, up_hold, up_2x, up_3x, up_4x, up_5x

ios. yes, i can change the color of normal led, status led, and all individual # leds. I just cant change the blink frequency.

With regards to the buttons, i dont see how I can specify down_2x for instance in a piston. Can you provide an example?

I spent tons of time testing all the features with iOS and Android while writing the handler so they must have broken that type of tile type for iOS in a recent update…

I found the post below on the WebCoRE Forum so let me know if that works.

funny, I was just looking at that same post. it works!!!


Thanks!!