feat: update device mapping for T0x13(22222222)

This commit is contained in:
Cyborg2017
2026-01-30 13:59:20 +08:00
parent c879f911d1
commit a3ed31b212
3 changed files with 55 additions and 2 deletions

View File

@@ -1,5 +1,5 @@
from homeassistant.components.fan import DIRECTION_FORWARD, DIRECTION_REVERSE
from homeassistant.const import Platform, UnitOfTemperature, PRECISION_WHOLE
from homeassistant.const import Platform, UnitOfTemperature, UnitOfTime, PRECISION_WHOLE
DEVICE_MAPPING = {
"default": {
@@ -141,5 +141,40 @@ DEVICE_MAPPING = {
}
}
}
},
"22222222": {
"rationale": ["off", "on"],
"queries": [{}],
"centralized": [],
"entities": {
Platform.LIGHT: {
"light": {
"power": "power",
"brightness": {"brightness": [0, 255]},
"color_temp": {
"color_temperature": {
"kelvin_range": [2700, 6500],
"device_range": [0, 255]
}
},
"preset_modes": {
"night": {"scene_light": "night"},
"read": {"scene_light": "read"},
"mild": {"scene_light": "mild"},
"life": {"scene_light": "life"},
"film": {"scene_light": "film"},
"manual": {"scene_light": "manual"},
}
}
},
Platform.NUMBER: {
"delay_light_off": {
"min": 0,
"max": 60,
"step": 1,
"unit_of_measurement": UnitOfTime.MINUTES
}
}
}
}
}

View File

@@ -2203,6 +2203,9 @@
}
},
"number": {
"delay_light_off": {
"name": "Delay Light Off"
},
"hosting_upper": {
"name": "PM2.5 Upper(Auto Purification)"
},

View File

@@ -2493,10 +2493,25 @@
},
"light": {
"light": {
"name": "电灯"
"name": "电灯",
"state_attributes": {
"effect": {
"state": {
"night": "夜灯",
"read": "阅读",
"mild": "柔和",
"life": "生活",
"film": "影院",
"manual": "自定义"
}
}
}
}
},
"number": {
"delay_light_off": {
"name": "延时关灯"
},
"hosting_upper": {
"name": "PM2.5上阈值(自动净化)"
},