Need help with HA automation. Dim to 33% on single tap 1 hour after sundown, double tap to 100%. At sun up act as normal

So I bought your dimmer because of it’s options and configurability, But I think it’s bit me in the ankle. I want an HA automation for my master bathroom light to only go to 33% on a single tap 1 hour after sundown, but it still acts like a normal dimmer all the other times.

Basically we’re tired of being blinded on a light nite bathroom run.

Have an automation change “On Level (Load Control)” to 83 or 84 at the appropriate time, and then in the morning have it change it to 254.

I just recently started playing around with “Adaptive Lighting”, available on HACS, where I have my bathroom lights turn on around 50% during the day (pre AL setup), and dimming lower after sunset, to nice and dim during the evening. If the dimming level is altered, it will override AL until the switch is turned off, then AL will take control again next time it is turned on.

You can configure min/max dimming levels and even specify start/end times if you don’t want to use actual sunrise/sunset times.

If I want it full brightness, I just use the double tap up to turn it all the way up.

Thank you for the reply, I’m sorry I have no idea what that means. I’m kinda new to HA automatons. Is there a blueprint maybe that will get me the results I’m looking for?

I have Adaptive lighting integration installed but I haven’t been able to figure it out yet. I think it’s the key to get the timing down right by the sun up sun down timing, I just don’t have a grasp of it.

Well, let’s see if I can give a clear enough explanation on how to get you up and running…

While you have it installed (from HACS), have you added the integration yet? Settings>Devices & services>Add integration>Adaptive Lighting

Now, in your Integrations, click on Adaptive Lighting and “Add entry” to create a new instance. Once it is created, click on the Settings icon and choose the device you will be controlling… in this instance it will be your dimmer. Set your min_brightness and max_brightness… for your example, this will be 33% and 100%. Now comes the timing of everything…

By default, this will start gradually dimming from sunset to midnight, going from your max to min brightness. If you want the same as your example, you can modify this.

To match your example, you will want to set a sunset_offset to 3600 seconds, which is the same as 1 hour after sunset. To accomplish the instant changing at that time, we will want to make other changes as well.

Set the brightness_mode to “tanh” instead of “default”, and set both the brightness_mode_time_dark and brightness_mode_time_light to 0. That setting of 0 determines how many seconds it takes to change brightness, starting from either sunrise or sunset respectively, so if you would like to have it go down gradually over 2 hours instead, you would use a value of 7200 (seconds).

So, with a sunset offset of 3600 seconds, and a transition time of 0, at 1 hour after sunset, it will change the brightness from max to minimum immediately, and at the time of sunrise, from min to max immediately.

You will then want to make sure you check the box to detect_non_ha_changes, so it will operate when you turn the lights on at the switch, and the only_once box so they will only be affected when they are turned on… You don’t want to be in the bathroom at 59 minutes after sunset and have the lights dim on you while you are in there after all :slight_smile:

You can likely leave the rest of the setting at their defaults and click Submit at the bottom of the settings window.

Adaptive Lighting has 3 separate functions, one for brightness, one for color temperature (for smart bulbs; unused for this), and one for sleep mode (unused for this), which can all be toggled on or off individually and you also have a “master” toggle to enable or disable the entire instance.