Add support for Pet Feeder (cwwsq) in Tuya (#61359)
parent
39b26e5ff7
commit
0a00c77ed6
|
@ -71,6 +71,16 @@ BINARY_SENSORS: dict[str, tuple[TuyaBinarySensorEntityDescription, ...]] = {
|
|||
),
|
||||
TAMPER_BINARY_SENSOR,
|
||||
),
|
||||
# Smart Pet Feeder
|
||||
# https://developer.tuya.com/en/docs/iot/categorycwwsq?id=Kaiuz2b6vydld
|
||||
"cwwsq": (
|
||||
TuyaBinarySensorEntityDescription(
|
||||
key=DPCode.FEED_STATE,
|
||||
name="Feeding",
|
||||
icon="mdi:information",
|
||||
on_value="feeding",
|
||||
),
|
||||
),
|
||||
# Human Presence Sensor
|
||||
# https://developer.tuya.com/en/docs/iot/categoryhps?id=Kaiuz42yhn1hs
|
||||
"hps": (
|
||||
|
|
|
@ -189,6 +189,8 @@ class DPCode(StrEnum):
|
|||
FAN_SPEED_PERCENT = "fan_speed_percent" # Stepless speed
|
||||
FAR_DETECTION = "far_detection"
|
||||
FAULT = "fault"
|
||||
FEED_REPORT = "feed_report"
|
||||
FEED_STATE = "feed_state"
|
||||
FILTER_LIFE = "filter"
|
||||
FILTER_RESET = "filter_reset" # Filter (cartridge) reset
|
||||
FLOODLIGHT_LIGHTNESS = "floodlight_lightness"
|
||||
|
@ -209,6 +211,7 @@ class DPCode(StrEnum):
|
|||
LIGHT_MODE = "light_mode"
|
||||
LOCK = "lock" # Lock / Child lock
|
||||
MACH_OPERATE = "mach_operate"
|
||||
MANUAL_FEED = "manual_feed"
|
||||
MATERIAL = "material" # Material
|
||||
MODE = "mode" # Working mode / Mode
|
||||
MOTION_RECORD = "motion_record"
|
||||
|
@ -257,6 +260,7 @@ class DPCode(StrEnum):
|
|||
SHOCK_STATE = "shock_state" # Vibration status
|
||||
SIREN_SWITCH = "siren_switch"
|
||||
SITUATION_SET = "situation_set"
|
||||
SLOW_FEED = "slow_feed"
|
||||
SMOKE_SENSOR_STATE = "smoke_sensor_state"
|
||||
SMOKE_SENSOR_STATUS = "smoke_sensor_status"
|
||||
SMOKE_SENSOR_VALUE = "smoke_sensor_value"
|
||||
|
@ -315,6 +319,7 @@ class DPCode(StrEnum):
|
|||
VOC_STATE = "voc_state"
|
||||
VOC_VALUE = "voc_value"
|
||||
VOICE_SWITCH = "voice_switch"
|
||||
VOICE_TIMES = "voice_times"
|
||||
VOLUME_SET = "volume_set"
|
||||
WARM = "warm" # Heat preservation
|
||||
WARM_TIME = "warm_time" # Heat preservation time
|
||||
|
|
|
@ -55,6 +55,20 @@ NUMBERS: dict[str, tuple[NumberEntityDescription, ...]] = {
|
|||
entity_category=EntityCategory.CONFIG,
|
||||
),
|
||||
),
|
||||
# Smart Pet Feeder
|
||||
# https://developer.tuya.com/en/docs/iot/categorycwwsq?id=Kaiuz2b6vydld
|
||||
"cwwsq": (
|
||||
NumberEntityDescription(
|
||||
key=DPCode.MANUAL_FEED,
|
||||
name="Feed",
|
||||
icon="mdi:bowl",
|
||||
),
|
||||
NumberEntityDescription(
|
||||
key=DPCode.VOICE_TIMES,
|
||||
name="Voice Times",
|
||||
icon="mdi:microphone",
|
||||
),
|
||||
),
|
||||
# Human Presence Sensor
|
||||
# https://developer.tuya.com/en/docs/iot/categoryhps?id=Kaiuz42yhn1hs
|
||||
"hps": (
|
||||
|
|
|
@ -137,6 +137,16 @@ SENSORS: dict[str, tuple[TuyaSensorEntityDescription, ...]] = {
|
|||
),
|
||||
*BATTERY_SENSORS,
|
||||
),
|
||||
# Smart Pet Feeder
|
||||
# https://developer.tuya.com/en/docs/iot/categorycwwsq?id=Kaiuz2b6vydld
|
||||
"cwwsq": (
|
||||
TuyaSensorEntityDescription(
|
||||
key=DPCode.FEED_REPORT,
|
||||
name="Last Amount",
|
||||
icon="mdi:counter",
|
||||
state_class=SensorStateClass.MEASUREMENT,
|
||||
),
|
||||
),
|
||||
# Air Quality Monitor
|
||||
# No specification on Tuya portal
|
||||
"hjjcy": (
|
||||
|
|
|
@ -38,6 +38,16 @@ SWITCHES: dict[str, tuple[SwitchEntityDescription, ...]] = {
|
|||
entity_category=EntityCategory.CONFIG,
|
||||
),
|
||||
),
|
||||
# Smart Pet Feeder
|
||||
# https://developer.tuya.com/en/docs/iot/categorycwwsq?id=Kaiuz2b6vydld
|
||||
"cwwsq": (
|
||||
SwitchEntityDescription(
|
||||
key=DPCode.SLOW_FEED,
|
||||
name="Slow Feed",
|
||||
icon="mdi:speedometer-slow",
|
||||
entity_category=EntityCategory.CONFIG,
|
||||
),
|
||||
),
|
||||
# Pet Water Feeder
|
||||
# https://developer.tuya.com/en/docs/iot/f?id=K9gf46aewxem5
|
||||
"cwysj": (
|
||||
|
|
Loading…
Reference in New Issue