Skip to content

Commit

Permalink
🔌 improve for outlet
Browse files Browse the repository at this point in the history
  • Loading branch information
al-one committed Jan 31, 2024
1 parent 5757334 commit 577fa43
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions custom_components/xiaomi_miot/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1562,8 +1562,8 @@ async def async_update_for_main_entity(self):
)
self._update_sub_entities(
[
'battery_level', 'ble_battery_level', 'charging_state', 'voltage', 'power_consumption',
'electric_current', 'leakage_current', 'surge_power', 'electric_power', 'elec_count',
'battery_level', 'ble_battery_level', 'charging_state', 'voltage', 'electric_power',
'electric_current', 'leakage_current', 'surge_power', 'elec_count',
],
['battery', 'power_consumption', 'electricity'],
domain='sensor',
Expand Down
10 changes: 5 additions & 5 deletions custom_components/xiaomi_miot/core/device_customizes.py
Original file line number Diff line number Diff line change
Expand Up @@ -311,6 +311,11 @@
'cuco.plug.cp5pro:power_cost_month': {
'value_ratio': 1,
},
'cuco.plug.p8amd': {
'main_miot_services': 'switch-2',
'switch_properties': 'usb_switch.on,light,light.mode',
'select_properties': 'default_power_on_state',
},
'cuco.plug.sp5': {
'main_miot_services': 'switch-2',
'exclude_miot_services': 'custome,physical_controls_locked,indicator_light',
Expand Down Expand Up @@ -1508,11 +1513,6 @@
'select_properties': 'link',
'light_services': 'light',
},
'cuco.plug.p8amd': {
'main_miot_services': 'switch-2',
'switch_properties': 'usb_switch.on,light,light.mode',
'select_properties': 'default_power_on_state',
},

'*.aircondition.*': {
'sensor_properties': 'electricity.electricity',
Expand Down

0 comments on commit 577fa43

Please sign in to comment.