[RELEASE] Fibaro Dimmer 2 (FGD-212) - Advanced DTH (V2)

Yes, you will need to enable Scene Activation by setting parameter #28 to 1. The DTH will then update the scene attribute with the appropriate scene number (which a smartapp can then subscribe to):

As an example, I have what might be considered a fairly advanced setup for one of my bedside lights. With a double momentary switch connected to both inputs I get the following functionality:

S1: Bedside light control:

  • Single-tap: Toggle bedside light on/off.
  • Double-tap: Set level to 100%
  • Triple-tap: N/A
  • Hold: Dim up/down.

S2: Other devices:

  • Single-tap: Cycle through colour presets for bedroom mood lighting (via Fibaro RGBW).
  • Double-tap: Turn off mood lighting.
  • Triple-tap: Activate Going to bed routine (turns off most lights and appliances in the house, enables nightmode for lighting, arms the alarm, etc).
  • Hold: Adjust angle of the venetian window blinds (angle cycles slowly from +90 to -90 and back).

All S2 functionality is achieved with a custom smartapp that subscribes to the scene attribute.

3 Likes

Awesome, thanks! On my way to the store. . .

1 Like

FYI, Vesternet appear to have 20% off the Fibaro Dimmer 2 for the Easter weekend.

1 Like

I am new to ST and do not understand. Have set #28 to 1 but what is next? If I have Smart lightning app, how do I make it subscribe to scene attribute?

Thanks, have installed Core earlier but not tried it yet. Will look into it.

Is there any way we could consider a slow dim like this

I have a fibaro dimmer installed in my theatre room and would be nice to have an option to dim the lights over 20 seconds or so automatically when I press play :slight_smile:

Ok, will have a play… I’m not that good with CORE but the only option I saw was a stepped dim which was obviously stepped, I was trying to get around this and a smoother dim

Changed this manually and it looks ace, guessing to fire it using core I would have to set up some sort of virtual switch to change the parameter and have core turn that on?

At the moment I am using plex plus from here to monitor if media is playing. This can start a routine or change a device status which I’m guessing core can monitor and use to change the parameter, dim the light and then change the parameter back? I’m guessing there would be some lag here but that shouldn’t be a problem if I am intending to dim slowly anyway? I guess I could step it fast to 50% and then slowly dim down to 10 for a proper theatre effect?

Would be good to still have it able to flick on on pause and then slowly dim up again on stop at the end. PlexPlus can monitor this and trigger actions it’s just figuring out how to program those actions!

Like I say I’m new to ST and CoRE but am competent enough at tech. This is a whole new world of possibility though!

Hi Robin, I was wondering if you could help a little.
I am trying to follow your instructions on CoRE how to use double press and scene ID, how ever I am using a Fibaro FGS-223 dual switch with Erocm1231 Device-handler it does support Scene ID.

When I try to follow instructions I don’t get all the same scenarios, I don’t get Attrbute and under Value I only get ON or OFF.

I have already posted at the Pistion help page with out any luck.

Do you have any advice for me.

I have an outdoor floodlight/motion detector that I was going to automate using a Fibaro FGD-223 by connecting the motion detector output to S2 on the Fibaro and my wall switch to S1 (I have continuous power to the fixture). The lights would only be connected to Q1, so my wall switch would be my way of manually turning on the lights and using CoRE, I could read S2 to know when motion was detected and run actions based on that input. I know how to get that all wired up, so my question is, can I use an FGD-212 to accomplish the same thing and also have the ability to dim my outside lights.

My specific question is, can I connect the motion detector output to S2 on an FGD-212 and then read that S2 was triggered so that I can run actions based on that? I know how to use CoRE, but I don’t yet own a FGD-212 to try it out.

Yes. Not sure if it would be best to configure S2 as toggle or momentary, but either way you would get Scene Activation events (and corresponding scene attribute events) when S2 changed state.

Both the FGD-212 and FGD-223 have two switch inputs, the key difference is that the FGD-212 only has one output (load) whereas the FGD-223 has two (but not dimmable).

1 Like

Hi - I upgraded from the prior V1 device handler and for my devices the old parameters are showing alongside the new ones? I’m not sure if it’s related, but I’m getting some missed events, etc, now and want to clean things up on this new handler just to be sure. Does anyone know if there’s an easy way of removing and re-adding the devices at the software level without having to z-wave unpair/pair each 212 device individually?

I find the easiest thing to do is just to remove the orphaned settings values one-by-one manually from the bottom of the settings screen. You can also do it from the IDE by deleting each value, but I don’t recommend that, as it’s important that all changes are done from the Smartphone to ensure that the updated() method runs correctly.

1 Like

Ah, I never thought to just try and delete those values. It works, I’m back to just the delivered ones thanks!

Thanks. I’m not real clear on scenes and associations yet, so I just wanted to make sure that S2 could be read by CoRE and used like I can with S2 on the FGD-223. I won’t need the 2nd load for this setup, but will use the dimming function of the 212.

Thanks for this, can’t seem to get this to work properly, do the values input as numbers or decimals?

I’m wondering if I need a gap between actions, as possibly this is too quick

1.set dim to 10ms
2.dim to 30%
3.set dim to 1ms

I think its telling it to dim to 30% but then setting it to 1ms and thus dimming it quickly. Obviously after it has triggered the command I would want the state of the light, switches etc. to return to normal.

Is there anything clever I can do with parameter 6 vs 8? I’ve tried changing 6 manually as thought the auto would be if triggered but this slows everything down.

I think you could be right, try adding a delay. To do this you would need to call all the commands together from one function though, e.g.:

def fade(targetLevel, fadeRate) {
    log.debug "fade(targetLevel: $targetLevel,fadeRate: $fadeRate)"
    secureSequence([
            zwave.configurationV1.configurationSet(parameterNumber: 6, size: 2, scaledConfigurationValue: fadeRate),
            // might need a short delay here too?
            zwave.basicV1.basicSet(value: Math.round(targetLevel* 99 / 100 )),
            "delay 10000", // wait 10s for fade to execute, then reset the Dimming Step Time
            zwave.configurationV1.configurationSet(parameterNumber: 6, size: 2, scaledConfigurationValue: state.defaultFadeRate)
    ])    
}

Note, you’d need to define the state.defaultFadeRate somewhere.

Note to self: implement setParameter() and fade() commands in official version.

1 Like

FYI

The latest Android update (2.3.5/2.3.6/2.3.7) completly broke the tiles on this handler for me:

Temp solution is to remove the icons on the tiles not working:

To do this just comment out the icon part at line 101,104,109 and 112

valueTile("instMode", "device.dispPower", decoration: "flat", width: 2, height: 1) {
    state "default", label:'Now:', action:"refresh"//, icon: "https://raw.githubusercontent.com/codersaur/SmartThings/master/icons/tile_2x1_refresh.png"
}
valueTile("power", "device.dispPower", decoration: "flat", width: 2, height: 1) {
    state "default", label:'${currentValue}'//, icon: "https://raw.githubusercontent.com/codersaur/SmartThings/master/icons/tile_2x1_top_bottom_2.png"
}

// Accumulated Energy:
valueTile("energyLastReset", "device.energyLastReset", decoration: "flat", width: 2, height: 1) {
    state "default", label:'Since:  ${currentValue}', action:"resetEnergy"//, icon: "https://raw.githubusercontent.com/codersaur/SmartThings/master/icons/tile_2x1_stopwatch_reset.png"
}
valueTile("energy", "device.dispEnergy", width: 2, height: 1) {
    state "default", label:'${currentValue}'//, icon: "https://raw.githubusercontent.com/codersaur/SmartThings/master/icons/tile_2x1_top_bottom_2.png"

I paste the code into “from code” then hit “Create”, I get the following error. Please forgive me for getting started.

No signature of method: script1494686894845220832054.metadata() is applicable for argument types: (script1494686894845220832054$_run_closure1) values: [script1494686894845220832054$_run_closure1@c061185] Possible solutions: getMetadata(), getState(), setState(java.lang.Object), metaClass(groovy.lang.Closure)

Double-check what you’ve actually pasted. It’s possible you’ve inadvertently included line numbers or other text if copying from the GitHub webpage.