Skip to content

Add lamp3 (YLTD03YL) spec in _MODEL_SPECS

xuxiaoqiao requested to merge xuxiaoqiao/python-yeelight:lamp3-model-spec into master

Yeelight Serene Eye-Friendly Desk Lamp (Model: YLTD03YL) is a white dimmable desk lamp. It only supports one color temperature (per website description it's 3700K; however SSDP discovery packets reports 4000K).

It's a BulbType.White light. However, sometimes the guess made by Bulb.bulb_type can be wrong, misidentifying this bulb as BulbType.WhiteTemp. Therefore adding an explicit specification here is necessary.

YLTD03YL properties:

>>> print(desk_lamp.get_properties())
{'power': 'off', 'bright': '100', 'ct': '4000', 'rgb': None, 'hue': None, 'sat': None, 'color_mode': '2', 'flowing': '0', 'delayoff': '0', 'music_on': None, 'name': None, 'bg_power': None, 'bg_flowing': None, 'bg_ct': None, 'bg_bright': None, 'bg_hue': None, 'bg_sat': None, 'bg_rgb': None, 'nl_br': None, 'active_mode': None, 'current_brightness': '100'}

>>> print(desk_lamp.get_capabilities())
{'id': 'redacted', 'model': 'lamp3', 'fw_ver': '34', 'support': 'get_prop set_default set_power set_bright set_scene set_name set_adjust toggle start_cf stop_cf cron_add cron_get cron_del adjust_bright', 'power': 'off', 'bright': '100', 'color_mode': '2', 'ct': '4000', 'rgb': '0', 'hue': '0', 'sat': '0', 'name': ''}
Edited by xuxiaoqiao

Merge request reports