Daylight dimming control

A fairly standard control for commercial applications and also required by energy codes is daylight dimming controls. Even after searching through this site, and even looking at Hue, I did not see this functionality mentioned. A simpler version would be to do stepped dimming. I’ve got hardware to sense light, a hub (or cloud) to process it, and the dimmer to control the lights, but the software solution seems elusive. Is anyone aware of an approach to do this (preferably out of the box, but would consider custom apps too).

Unless Im missing something, in automations you can set the “If” to your device that measures Illuminance and use that.

In automations, I can set if luminance is >fixed value 1 set dimmer level 1 or luminance <= fixed value 2, set dimmer level 2, but that’s it and the light needs to be on to change these values (e.g. I can’t pre-set the dimming level before the light turns on).

I need to be able to do this: fixed value 1<luminance <= fixed value 2, set dimmer level 3 or alternatively something that says vary dimming from 20-100 vs luminance from 20 to 5.