Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve viomi.fridge.m1 #1596

Merged
merged 2 commits into from
Mar 27, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
add Indoor Temp sensor entity for viomi.fridge.m1
ptbsare committed Mar 27, 2024
commit 42d0fff5d01e1d1e207c492d7ff8c153721a5b4d
3 changes: 3 additions & 0 deletions custom_components/xiaomi_miot/core/device_customizes.py
Original file line number Diff line number Diff line change
@@ -1271,6 +1271,9 @@
2: 0, # Descent-limit
},
},
'viomi.fridge.m1': {
'sensor_properties': 'fridge.temperature',
},
'viomi.hood.v1': {
'main_miot_services': 'hood-2',
'number_properties': 'off_delay_time',
5 changes: 3 additions & 2 deletions custom_components/xiaomi_miot/core/miio2miot_specs.py
Original file line number Diff line number Diff line change
@@ -1244,8 +1244,8 @@ def cbk(prop, params, props, **kwargs):
# ["none",8 ,-15 ,"on" ,0 ,30 ,"off" ,"off"]
# 'chunk_properties': 8,
'chunk_properties': 1,
'miio_props': ['ScreenOn', 'Error', 'SmartCool', 'SmartFreeze', 'IndoorTemp'],
'entity_attrs': ['ScreenOn', 'Error', 'SmartCool', 'SmartFreeze', 'IndoorTemp'],
'miio_props': ['ScreenOn', 'Error', 'SmartCool', 'SmartFreeze'],
'entity_attrs': ['ScreenOn', 'Error', 'SmartCool', 'SmartFreeze'],
'miio_specs': {
'prop.2.1': {'prop': 'Mode', 'setter': 'setMode', 'dict': {
'smart': 1,
@@ -1258,6 +1258,7 @@ def cbk(prop, params, props, **kwargs):
'prop.3.3': {'prop': 'RCSetTemp'},
'prop.4.1': {'prop': 'FCSetTemp', 'setter': 'setFCSetTemp'},
'prop.4.2': {'prop': 'FCSetTemp'},
'prop.2.2': {'prop': 'IndoorTemp'},
},
},
'viomi.juicer.v1': {
16 changes: 16 additions & 0 deletions custom_components/xiaomi_miot/core/miot_specs_extend.json
Original file line number Diff line number Diff line change
@@ -766,6 +766,22 @@
]
}
],
"viomi.fridge.m1": [
{
"iid": 2,
"properties": [
{
"iid": 2,
"type": "urn:miot-spec-v2:property:temperature",
"description": "Indoor Temperature",
"format": "float",
"access": ["read"],
"unit": "celsius",
"value-range": [-40, 125, 1]
}
]
}
],

"viomi.vacuum.v7": [
{