When a Zigbee bulb gets disconnected from the mains and reconnected afterwarts, it usually lights up in a standard white color at 100% brightness. Osram / Ledvance has an option that sets the current color and brightness attributes as default, so when you disconnect and reconnect the bulb, it will light up according to the settings you’ve chosen.
It looks like Osram/Ledvance issues a 0x01 command to the 0xFC0F (for Osram Lightify) or 0XFC01 (for Ledvance) cluster to store the current settings as the power-on defaults.
In Home Assistant with ZHA, these clusters are visible but no commands or attributes are available for those specific Zigbee clusters. Could the 0x001 command be made available? And would it be possible to include a noob-friendly button labeled “Set power-on default” that executes the 0x01 command?
Deconz has made this already, so it might be worth to check this: Feature request: support power-on defaults for OSRAM lights · Issue #102 · dresden-elektronik/deconz-rest-plugin · GitHub
EDIT:
The setting also appears to exist in ZHA:
"""Osram quirks elements."""
from zigpy.quirks import CustomCluster
OSRAM = "OSRAM"
class OsramLightCluster(CustomCluster):
"""OsramLightCluster."""
cluster_id = 0xFC0F
ep_attribute = "osram_light"
name = "OsramLight"
manufacturer_server_commands = {0x0001: ("save_defaults", (), False)}