Fade lights feature

I have just posted the below to Smartthings support and they say they will pass it on to the relevant department. Maybe if enough people ask for the same update it might get pushed up the list???

*I really like the ability to fade my lights in an automation. What would make this feature much more usable would be to remove the necessity for a start level. Ie it would fade from the current light level to the target level. *
Also it would be great to be able to specify a much shorter fade duration.

3 Likes

I’d like this feature for local Matter lights where the cloud lighting goodies like the circadian rhythm are not available (well, they are if you create a group with them because groups are cloud-based).

Matter drivers at least actually have that fade function, you can invoke setLevel with a target level and a rate argument and SmartThings or the light will gradually “move” the level from current to the target level. It’s just not exposed to the routines interface in a user friendly way.

Also miss simple relative commands like “increase brightness” or “decrease brightness”, which are available in other smart home platforms.

switchLevel is exposed but only for the default values of that capability and not with the rate value attribute as defined in the driver because it’s not included in the device presentation. Therefore the rate defaults to 0. One could certainly create a custom presentation that would allow for setting the rate as part of the Actions.

local function handle_set_level(driver, device, cmd)
  local endpoint_id = device:component_to_endpoint(cmd.component)
  local level = math.floor(cmd.args.level/100.0 * 254)
  local req = clusters.LevelControl.server.commands.MoveToLevelWithOnOff(device, endpoint_id, level, cmd.args.rate or 0, 0 ,0)
  device:send(req)
end 
           {
                "component": "main",
                "capability": "switchLevel",
                "version": 1,
                "values": [],
                "patch": [],
                "exclusion": []
            },

Indeed, and being such a basic feature I believe it should be SmartThings the one adding it, along with the Increase / Decrease brightness by X% which I find more important because it would make so much easier to use buttons to change the brightness without resorting to “hacks”.

Making a custom matter-switch driver just for that seems overkill, especially with the Matter driver evolving so fast.

ST seems to go for the LCD (Least Common Denominator). I’ve seen plenty of capabilities that should be exposed in the Automations and Actions section of the Presentation that aren’t. Hence the need for community developed drivers.

2 Likes

My point exactly, every smart light has an adjustable brightness level, doesn’t even matter the technology. A command to increase or decrease the brightness seems the most basic thing you should be able to do with any smart light and yet, you can’t. Not because it’s not available in the presentation, the command does not even exist!

No, the command does exist and is available in the AWA and CLI with the option for specifying a rate:

? Select a device. 94

Smart Color Night Light

Capabilities:
───────────────────────────
 1  switch                 
 2  switchLevel            
 3  colorTemperature       
 4  colorControl           
 5  motionSensor           
 6  illuminanceMeasurement 
 7  firmwareUpdate         
 8  refresh                
───────────────────────────

? Enter capability index or id 2

Commands:
──────────────────────────────────────────────
 1  setLevel(level<integer>, [rate<integer>]) 
──────────────────────────────────────────────

? Enter command 

As I said, the rate is not available in the mobile app because it is not defined in the presentation. Setting the dim level is defined and available in the mobile app.

1 Like

That’s not a command to increase or decrease the brightness, that’s a command to set an absolute value. You can’t put a negative number there to decrease the level 10% for instance.

Fair enough, but I’m not sure that increase/decrease is a “basic” function. IMO, basic function is setting an absolute dim level.

A more sophisticated rules engine like sharptools.io does offer the ability to increase/decrease the dim level from one value to another over a period of time.

I’d say most smart home platforms have it, Google Home with the script editor and Alexa definitely do. The point of Matter is being local though, cloud services is not the solution.

I guess it all comes to using smart buttons or not. If you do it’s a basic feature. Many smart buttons can’t be used in SmartThings to change the brightness because you can’t map a button to increase or decrease.

Some custom drivers have the option, it’s easy to implement, but in my opinion should be a stock feature. It’s just adding a setRelativeLevel command, getting the last known level and add the amount.