From 8f0e20c3fc1edf8251226ea5252c3de25edbf394 Mon Sep 17 00:00:00 2001 From: Noah Overcash Date: Fri, 8 May 2020 10:18:15 -0400 Subject: [PATCH] Add smart grid features to SmartSavingMode refrigerator enum My refrigerator (LFXS28566D) supports the three added options as part of it's "smart grid" functionality. None of the initial three options were in my fridge, so I figure they are mutually exclusive modes (although OFF and SMART_GRID_OFF are similar, as is CUSTOM and SMART_GRID_CUSTOM). As best I can tell, SMART_GRID_OFF is for when the smart grid feature is disabled overall, SMART_GRID_DEMAND_RESPONSE is something certain power companies can do to tell the fridge not to defrost when the power grid is stressed (I cannot test as I am ineligible), and SMART_GRID_CUSTOM is used whenever the button on the fridge is pushed or "Seasonal Energy Saver" is enabled in the app. For reference, here is an excerpt from my model's JSON dump: ```json5 { ... "SmartSavingMode": { "type": "Enum", "default": "0", "option": { "0": "@CP_OFF_EN_W", "2": "@RE_TERM_DELAY_DEFROST_CAPABILITY_W", "3": "@RE_TERM_DEMAND_RESPONSE_FUNCTIONALITY_W" } } ... } ``` --- wideq/refrigerator.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/wideq/refrigerator.py b/wideq/refrigerator.py index c35fd0b..7dff39f 100644 --- a/wideq/refrigerator.py +++ b/wideq/refrigerator.py @@ -28,6 +28,9 @@ class SmartSavingMode(enum.Enum): OFF = "@CP_TERM_USE_NOT_W" NIGHT = "@RE_SMARTSAVING_MODE_NIGHT_W" CUSTOM = "@RE_SMARTSAVING_MODE_CUSTOM_W" + SMART_GRID_OFF = "@CP_OFF_EN_W" + SMART_GRID_DEMAND_RESPONSE = "@RE_TERM_DEMAND_RESPONSE_FUNCTIONALITY_W" + SMART_GRID_CUSTOM = "@RE_TERM_DELAY_DEFROST_CAPABILITY_W" EMPTY = ""