simbaja / ha_gehome

GE Home Appliances (SmartHQ) for Home Assistant
MIT License
346 stars 80 forks source link

Support Cafe Speciality Grind and Brew #251

Open Treygec opened 6 months ago

Treygec commented 6 months ago

Hoping to get the Cafe Speciality Grind and Brew added. I've installed the gehomesdk and got the output logs and can see the device working there. However, it appears to have ERD codes that other coffee makers don't, as well as missing at least one that others do (CCM_BREW_TEMPERATURE_RANGE). Below are the error logs from Home Assistant noting that there is keyerror for this ERD code.

Additionally, below is the full output from the logs when I run the gehomesdk. I have highlighted all the parts that reference the coffee maker, to make it easier to see what's going on amidst all of it. I just wanted to provide the full log in case parts I'm not aware of are helpful.

Finally, I'm a beginner to moderate level programmer. Would be happy to tackle this myself if a little guidance could be given around how to decode the bytestrings coming back or some opinion on how you'd like to see this device added (modify existing "coffee maker" stuff or create a new device type "grind and brew" and keep it all seperate in there). At the moment though, I am most unsure of how to handle the bytestrings as I can't make sense of them.

ERD codes I have meaning for from gehomesdk (will work to figure out more in the coming days):

0x9058 =Brew Profile 3 0x9054 = Brew Profile 1 0x9051 = Adhoc brew settings / current brew settings 0x902C = Clean basket status (boolean sensor to check if basket has been opened since last brew)

ERROR FROM HOME ASSISTANT

2024-05-04 07:33:33.454 ERROR (MainThread) [homeassistant] Error doing job: Task exception was never retrieved Traceback (most recent call last): File "/config/custom_components/ge_home/update_coordinator.py", line 337, in on_device_initial_update self.maybe_add_appliance_api(appliance) File "/config/custom_components/ge_home/update_coordinator.py", line 150, in maybe_add_appliance_api api = self._get_appliance_api(appliance) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/ge_home/update_coordinator.py", line 138, in _get_appliance_api return api_type(self, appliance) ^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/ge_home/devices/coffee_maker.py", line 36, in init self._brew_temperature_entity = GeCcmBrewTemperatureNumber(self) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/ge_home/entities/ccm/ge_ccm_brew_temperature.py", line 8, in init min_temp, maxtemp, = api.appliance.get_erd_value(ErdCode.CCM_BREW_TEMPERATURE_RANGE) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/gehomesdk/ge_appliance.py", line 136, in get_erd_value return self._property_cache[erd_code]


KeyError: <ErdCode.CCM_BREW_TEMPERATURE_RANGE: '0x9002'>

# LOG FROM GEHOMESDK
Using slower stringprep, consider compiling the faster cython/libidn one.
2024-05-04 08:05:22,707 DEBUG    Using selector: EpollSelector
2024-05-04 08:05:22,708 DEBUG    Getting OAuth2 token
2024-05-04 08:05:22,708 DEBUG    received event: state_changed, processing callbacks...
2024-05-04 08:05:22,708 DEBUG    processing callback: <bound method GeBaseClient._on_state_change of <gehomesdk.clients.websocket_client.GeWebsocketClient object at 0x7f9e767b4e10>>
2024-05-04 08:05:22,711 DEBUG    Client changed state: GeClientState.INITIALIZING to GeClientState.AUTHORIZING_OAUTH
2024-05-04 08:05:24,193 DEBUG    Getting WS credentials
2024-05-04 08:05:24,193 DEBUG    received event: state_changed, processing callbacks...
2024-05-04 08:05:24,193 DEBUG    processing callback: <bound method GeBaseClient._on_state_change of <gehomesdk.clients.websocket_client.GeWebsocketClient object at 0x7f9e767b4e10>>
2024-05-04 08:05:24,193 DEBUG    Client changed state: GeClientState.AUTHORIZING_OAUTH to GeClientState.AUTHORIZING_CLIENT
2024-05-04 08:05:24,370 INFO     Starting GE Appliances client
2024-05-04 08:05:24,371 DEBUG    received event: state_changed, processing callbacks...
2024-05-04 08:05:24,371 DEBUG    processing callback: <bound method GeBaseClient._on_state_change of <gehomesdk.clients.websocket_client.GeWebsocketClient object at 0x7f9e767b4e10>>
2024-05-04 08:05:24,384 DEBUG    Client changed state: GeClientState.AUTHORIZING_CLIENT to GeClientState.CONNECTING
2024-05-04 08:05:24,486 DEBUG    = connection is CONNECTING
2024-05-04 08:05:24,530 DEBUG    > GET /?access_token=ue1cpe8uravqwu4tf00f513jxsih3xb4 HTTP/1.1
2024-05-04 08:05:24,530 DEBUG    > Host: ws-us-east-1.brillion.geappliances.com
2024-05-04 08:05:24,530 DEBUG    > Upgrade: websocket
2024-05-04 08:05:24,530 DEBUG    > Connection: Upgrade
2024-05-04 08:05:24,530 DEBUG    > Sec-WebSocket-Key: mgZGW4wXTwgpdBC8gzms0g
2024-05-04 08:05:24,531 DEBUG    > Sec-WebSocket-Version: 13
2024-05-04 08:05:24,531 DEBUG    > User-Agent: Python/3.11 websockets/12.0
2024-05-04 08:05:24,737 DEBUG    < HTTP/1.1 101 Switching Protocols
2024-05-04 08:05:24,737 DEBUG    < Date: Sat, 04 May 2024 13:05:24 GMT
2024-05-04 08:05:24,737 DEBUG    < Connection: upgrade
2024-05-04 08:05:24,738 DEBUG    < upgrade: websocket
2024-05-04 08:05:24,738 DEBUG    < sec-websocket-accept: 1cNE5d1/NsCHTIkti8KFk7cUx1o=
2024-05-04 08:05:24,738 DEBUG    = connection is OPEN
2024-05-04 08:05:24,738 DEBUG    > TEXT '{"kind": "websocket#subscribe", "action": "subs...["/appliance/*/erd/*"]}' [91 bytes]
2024-05-04 08:05:24,738 DEBUG    received event: state_changed, processing callbacks...
2024-05-04 08:05:24,739 DEBUG    processing callback: <bound method GeBaseClient._on_state_change of <gehomesdk.clients.websocket_client.GeWebsocketClient object at 0x7f9e767b4e10>>
2024-05-04 08:05:24,739 DEBUG    > TEXT '{"kind": "websocket#api", "action": "api", "hos...id": "List-appliances"}' [150 bytes]
2024-05-04 08:05:24,739 DEBUG    Client changed state: GeClientState.CONNECTING to GeClientState.CONNECTED
2024-05-04 08:05:24,739 DEBUG    received event: connected, processing callbacks...
2024-05-04 08:05:24,824 DEBUG    < TEXT '{"kind":"websocket#subscribe","success":true}' [45 bytes]
2024-05-04 08:05:24,959 DEBUG    < TEXT '{"kind":"websocket#api","id":"List-appliances",...5-04T11:22:39.929Z"}]}}' [608 bytes]
2024-05-04 08:05:24,960 DEBUG    < TEXT '{"kind":"websocket#connect","success":true}' [43 bytes]
2024-05-04 08:05:24,961 DEBUG    D828C9439E31 marked available
2024-05-04 08:05:24,961 DEBUG    Adding appliance D828C9439E31
2024-05-04 08:05:24,961 DEBUG    received event: add_appliance, processing callbacks...
2024-05-04 08:05:24,961 DEBUG    processing callback: <function do_periodic_update at 0x7f9e767ad3a0>
2024-05-04 08:05:24,962 DEBUG    Requesting update for client D828C9439E31
2024-05-04 08:05:24,962 DEBUG    > TEXT '{"kind": "websocket#api", "action": "api", "hos... "D828C9439E31-allErd"}' [171 bytes]
2024-05-04 08:05:24,962 DEBUG    Registering update callback for GeAppliance(D828C9439E31) (Unknown Type)
2024-05-04 08:05:24,963 DEBUG    Requesting features for client D828C9439E31
2024-05-04 08:05:24,963 DEBUG    > TEXT '{"kind": "websocket#api", "action": "api", "hos...d": "Request-features"}' [172 bytes]
2024-05-04 08:05:24,963 DEBUG    020000351B20 marked available
2024-05-04 08:05:24,964 DEBUG    Adding appliance 020000351B20
2024-05-04 08:05:24,964 DEBUG    received event: add_appliance, processing callbacks...
2024-05-04 08:05:24,964 DEBUG    processing callback: <function do_periodic_update at 0x7f9e767ad3a0>
2024-05-04 08:05:24,964 DEBUG    Requesting update for client 020000351B20
2024-05-04 08:05:24,964 DEBUG    > TEXT '{"kind": "websocket#api", "action": "api", "hos... "020000351B20-allErd"}' [171 bytes]
2024-05-04 08:05:24,964 DEBUG    Registering update callback for GeAppliance(020000351B20) (Unknown Type)
2024-05-04 08:05:24,965 DEBUG    Requesting features for client 020000351B20
2024-05-04 08:05:24,965 DEBUG    > TEXT '{"kind": "websocket#api", "action": "api", "hos...d": "Request-features"}' [172 bytes]
2024-05-04 08:05:24,965 DEBUG    received event: got_appliance_list, processing callbacks...
2024-05-04 08:05:25,087 DEBUG    < TEXT '{"resource":"/appliance/*/erd/*","kind":"websoc...:true,"change":"ADDED"}' [97 bytes]
2024-05-04 08:05:25,177 DEBUG    < TEXT '{"kind":"websocket#api","id":"Request-features"...MMON_V1_SOUND_LEVEL"]}}' [900 bytes]
**2024-05-04 08:05:25,177 DEBUG    Received features ['COFFEE_BREWER_V2_BREW_BASKET_MISSING_OR_NOT_LOCKED', 'COFFEE_BREWER_V2_BREW_CANCEL', 'COFFEE_BREWER_V2_BREW_STATUS', 'COFFEE_BREWER_V2_CLEAN_BREW_BASKET', 'COFFEE_BREWER_V2_DESCALE_STATUS', 'COFFEE_BREWER_V2_DISABLE_GRINDER', 'COFFEE_BREWER_V2_FILTER_STATUS', 'COFFEE_BREWER_V2_FOUNDATION', 'COFFEE_BREWER_V2_GRINDER_MISSING_OR_NOT_LOCKED', 'COFFEE_BREWER_V2_GRIND_SETTING', 'COFFEE_BREWER_V2_MODEL_CONFIGURATION', 'COFFEE_BREWER_V2_OUT_OF_BEANS', 'COFFEE_BREWER_V2_OUT_OF_WATER_DETECTION', 'COFFEE_BREWER_V2_POT_PRESENCE', 'COFFEE_BREWER_V2_STANDBY', 'COFFEE_BREWER_V2_THREE_FAVORITE_BREWS', 'COMMON_V1_SOUND_LEVEL'] for 020000351B20**
2024-05-04 08:05:25,177 DEBUG    received event: got_appliance_features, processing callbacks...
2024-05-04 08:05:25,193 DEBUG    < TEXT '{"kind":"websocket#api","id":"Request-features"...MOTE_PRECISION_COOK"]}}' [626 bytes]
2024-05-04 08:05:25,193 DEBUG    Received features ['COMMON_V1_CONTROL_LOCK', 'COMMON_V1_SABBATH', 'COMMON_V1_SOUND_LEVEL', 'COOKING_V1_COOKTOP_FOUNDATION', 'COOKING_V1_LOWER_OVEN_FOUNDATION', 'COOKING_V1_MENU_TREE', 'COOKING_V1_UPPER_OVEN_FOUNDATION', 'COOKING_V1_UPPER_OVEN_KITCHEN_TIMER', 'COOKING_V2_LOWER_CAVITY_REMOTE_PRECISION_COOK', 'COOKING_V2_UPPER_CAVITY_REMOTE_PRECISION_COOK'] for D828C9439E31
2024-05-04 08:05:25,193 DEBUG    received event: got_appliance_features, processing callbacks...
2024-05-04 08:05:25,219 DEBUG    < TEXT '{"kind":"websocket#api","id":"D828C9439E31-allE...erd":"0x520D","value":"' [4096 bytes, continued]
2024-05-04 08:05:25,219 DEBUG    < CONT '0044","time":"2024-05-04T12:52:48.151Z"},{"erd"...4-05T11:36:19.493Z"}]}}' [text, 1731 bytes]
2024-05-04 08:05:25,220 DEBUG    Setting ErdCode.MODEL_NUMBER to PGS960SEL4SS
2024-05-04 08:05:25,220 DEBUG    Setting ErdCode.SERIAL_NUMBER to SQVR174098P
2024-05-04 08:05:25,220 DEBUG    Setting ErdCode.CLOCK_FORMAT to ErdClockFormat.TWELVE_HOUR
2024-05-04 08:05:25,220 DEBUG    Setting ErdCode.TEMPERATURE_UNIT to ErdMeasurementUnits.IMPERIAL
2024-05-04 08:05:25,220 DEBUG    Setting ErdCode.APPLIANCE_TYPE to ErdApplianceType.OVEN
2024-05-04 08:05:25,220 DEBUG    Setting ErdCode.SABBATH_MODE to False
2024-05-04 08:05:25,220 DEBUG    Setting ErdCode.SOUND_LEVEL to ErdSoundLevel.HIGH
2024-05-04 08:05:25,221 DEBUG    Setting ErdCode.UNIT_TYPE to ErdUnitType.UNKNOWN
2024-05-04 08:05:25,221 DEBUG    Setting ErdCode.BRAND to ErdBrand.UNKNOWN
2024-05-04 08:05:25,221 DEBUG    Setting ErdCode.WIFI_MODULE_SW_VERSION to 0.2.5.122
2024-05-04 08:05:25,221 DEBUG    Setting ErdCode.WIFI_MODULE_SW_VERSION_AVAILABLE to 0.0.0.0
2024-05-04 08:05:25,221 DEBUG    Setting ErdCode.ACM_UPDATING to False
2024-05-04 08:05:25,221 DEBUG    Setting ErdCode.APPLIANCE_SW_VERSION to 2.0.28.145
2024-05-04 08:05:25,221 DEBUG    Setting ErdCode.APPLIANCE_SW_VERSION_AVAILABLE to 0.0.0.0
2024-05-04 08:05:25,221 DEBUG    Setting ErdCode.APPLIANCE_UPDATING to False
2024-05-04 08:05:25,221 DEBUG    Setting ErdCode.LCD_SW_VERSION to 0.0.0.0
2024-05-04 08:05:25,221 DEBUG    Setting ErdCode.LCD_SW_VERSION_AVAILABLE to 0.0.0.0
2024-05-04 08:05:25,222 DEBUG    Setting ErdCode.LCD_UPDATING to False
2024-05-04 08:05:25,222 DEBUG    Setting ErdCode.HOUR_12_SHUTOFF_ENABLED to True
2024-05-04 08:05:25,222 DEBUG    Setting ErdCode.END_TONE to ErdEndTone.REPEATED_BEEP
2024-05-04 08:05:25,222 DEBUG    Setting ErdCode.CONVECTION_CONVERSION to True
2024-05-04 08:05:25,222 DEBUG    Setting ErdCode.KEY_PRESSED to b'\x00'
2024-05-04 08:05:25,222 DEBUG    Setting ErdCode.OVEN_CONFIGURATION to OvenConfiguration(has_knob=False, has_warming_drawer=False, has_light_bar=False, has_lower_oven=True, has_lower_oven_kitchen_timer=False, raw_value='0888')
2024-05-04 08:05:25,222 DEBUG    Setting ErdCode.OVEN_MODE_MIN_MAX_TEMP to OvenRanges(lower=170, upper=550)
2024-05-04 08:05:25,222 DEBUG    Setting ErdCode.WARMING_DRAWER_STATE to ErdOvenWarmingState.OFF
2024-05-04 08:05:25,222 DEBUG    Setting 0x5027 to b'\x01\xf4\x01,'
2024-05-04 08:05:25,222 DEBUG    Setting ErdCode.UPPER_OVEN_COOK_MODE to Off
2024-05-04 08:05:25,223 DEBUG    Setting ErdCode.UPPER_OVEN_CURRENT_STATE to Off
2024-05-04 08:05:25,223 DEBUG    Setting ErdCode.UPPER_OVEN_DELAY_TIME_REMAINING to 0:00:00
2024-05-04 08:05:25,223 DEBUG    Setting ErdCode.UPPER_OVEN_PROBE_DISPLAY_TEMP to 0
2024-05-04 08:05:25,223 DEBUG    Setting ErdCode.UPPER_OVEN_COOK_TIME_REMAINING to 0:00:00
2024-05-04 08:05:25,223 DEBUG    Setting ErdCode.UPPER_OVEN_KITCHEN_TIMER to 0:00:00
2024-05-04 08:05:25,223 DEBUG    Setting ErdCode.UPPER_OVEN_USER_TEMP_OFFSET to 0
2024-05-04 08:05:25,223 DEBUG    Setting ErdCode.UPPER_OVEN_PROBE_PRESENT to False
2024-05-04 08:05:25,223 DEBUG    Got timespan value of 65535. Treating as None.
2024-05-04 08:05:25,223 DEBUG    Setting ErdCode.UPPER_OVEN_DISPLAY_TEMPERATURE to 100
2024-05-04 08:05:25,223 DEBUG    Setting ErdCode.UPPER_OVEN_REMOTE_ENABLED to True
2024-05-04 08:05:25,223 DEBUG    Setting ErdCode.UPPER_OVEN_AVAILABLE_COOK_MODES to {<ErdOvenCookMode.BAKE_NOOPTION: 1>, <ErdOvenCookMode.BAKED_GOODS: 60>, <ErdOvenCookMode.FROZEN_PIZZA: 58>, <ErdOvenCookMode.FROZEN_SNACKS: 56>}
2024-05-04 08:05:25,223 DEBUG    Setting ErdCode.UPPER_OVEN_RAW_TEMPERATURE to 68
2024-05-04 08:05:25,224 DEBUG    Setting ErdCode.UPPER_OVEN_LIGHT to ErdOvenLightLevel.OFF
2024-05-04 08:05:25,224 DEBUG    Setting ErdCode.UPPER_OVEN_LIGHT_AVAILABILITY to ErdOvenLightLevelAvailability(z1=False, z2=True, z3=False, z4=True, z5=False, raw_value='03')
2024-05-04 08:05:25,224 DEBUG    Setting ErdCode.UPPER_OVEN_EXTENDED_COOK_MODES to set()
2024-05-04 08:05:25,224 DEBUG    Setting ErdCode.LOWER_OVEN_COOK_MODE to Off
2024-05-04 08:05:25,224 DEBUG    Setting ErdCode.LOWER_OVEN_CURRENT_STATE to Off
2024-05-04 08:05:25,224 DEBUG    Setting ErdCode.LOWER_OVEN_DELAY_TIME_REMAINING to 0:00:00
2024-05-04 08:05:25,224 DEBUG    Setting ErdCode.LOWER_OVEN_PROBE_DISPLAY_TEMP to 0
2024-05-04 08:05:25,224 DEBUG    Setting ErdCode.LOWER_OVEN_COOK_TIME_REMAINING to 0:00:00
2024-05-04 08:05:25,224 DEBUG    Setting ErdCode.LOWER_OVEN_KITCHEN_TIMER to 0:00:00
2024-05-04 08:05:25,224 DEBUG    Setting ErdCode.LOWER_OVEN_USER_TEMP_OFFSET to 0
2024-05-04 08:05:25,224 DEBUG    Setting ErdCode.LOWER_OVEN_PROBE_PRESENT to False
2024-05-04 08:05:25,224 DEBUG    Got timespan value of 65535. Treating as None.
2024-05-04 08:05:25,224 DEBUG    Setting ErdCode.LOWER_OVEN_DISPLAY_TEMPERATURE to 100
2024-05-04 08:05:25,225 DEBUG    Setting ErdCode.LOWER_OVEN_REMOTE_ENABLED to True
2024-05-04 08:05:25,225 DEBUG    Setting ErdCode.LOWER_OVEN_AVAILABLE_COOK_MODES to {<ErdOvenCookMode.CONVMULTIBAKE_NOOPTION: 27>, <ErdOvenCookMode.BAKED_GOODS: 60>, <ErdOvenCookMode.FROZEN_SNACKS: 56>, <ErdOvenCookMode.BAKE_NOOPTION: 1>, <ErdOvenCookMode.FROZEN_PIZZA_MULTI: 59>, <ErdOvenCookMode.FROZEN_SNACKS_MULTI: 57>, <ErdOvenCookMode.CONVROAST_NOOPTION: 36>, <ErdOvenCookMode.FROZEN_PIZZA: 58>}
2024-05-04 08:05:25,225 DEBUG    Setting ErdCode.LOWER_OVEN_RAW_TEMPERATURE to 68
2024-05-04 08:05:25,225 DEBUG    Setting ErdCode.LOWER_OVEN_LIGHT to ErdOvenLightLevel.OFF
2024-05-04 08:05:25,225 DEBUG    Setting ErdCode.LOWER_OVEN_LIGHT_AVAILABILITY to ErdOvenLightLevelAvailability(z1=False, z2=True, z3=False, z4=True, z5=False, raw_value='03')
2024-05-04 08:05:25,225 DEBUG    Setting ErdCode.LOWER_OVEN_EXTENDED_COOK_MODES to set()
2024-05-04 08:05:25,225 DEBUG    Setting ErdCode.MICROWAVE_RECIPE_STATUS to b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00'
2024-05-04 08:05:25,225 DEBUG    Setting ErdCode.ADVANTIUM_PRECISION_VERSION to b'\x0e\xe6\x15C\xd6\xa3\x91I\xbd<\xa43\xa3\x81\xe2\xdd\x91\xc5\x8e\xa2\xe4\x83\xb1Aq\xea; \xfbN\xd9#'
2024-05-04 08:05:25,225 DEBUG    Setting 0x5411 to b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00'
2024-05-04 08:05:25,226 DEBUG    Setting 0x5412 to b'\x00'
2024-05-04 08:05:25,226 DEBUG    Setting 0x5414 to b'\x00'
2024-05-04 08:05:25,226 DEBUG    Setting 0x5421 to b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00'
2024-05-04 08:05:25,226 DEBUG    Setting 0x5422 to b'9'
2024-05-04 08:05:25,226 DEBUG    Setting 0x5424 to b'\x00'
2024-05-04 08:05:25,226 DEBUG    Setting ErdCode.COOKTOP_CONFIG to ErdCooktopConfig.PRESENT
2024-05-04 08:05:25,226 DEBUG    Setting ErdCode.COOKTOP_STATUS to CooktopStatus(status=<ErdCooktopStatus.OFF: 0>, burners={'leftFront': <gehomesdk.erd.values.oven.burner.Burner object at 0x7f9e767d12d0>, 'leftRear': <gehomesdk.erd.values.oven.burner.Burner object at 0x7f9e7684d050>, 'centerFront': <gehomesdk.erd.values.oven.burner.Burner object at 0x7f9e7684d190>, 'centerRear': <gehomesdk.erd.values.oven.burner.Burner object at 0x7f9e7684d0d0>, 'rightFront': <gehomesdk.erd.values.oven.burner.Burner object at 0x7f9e7684d150>, 'rightRear': <gehomesdk.erd.values.oven.burner.Burner object at 0x7f9e7684d1d0>}, raw_value='0000FF00FF00FF00FF00FF00FF')
2024-05-04 08:05:25,226 DEBUG    Setting ErdCode.PRECISION_COOKING_PROBE_CONTROL_MODE to ErdPrecisionCookingAppProbeControlMode.INACTIVE
2024-05-04 08:05:25,226 DEBUG    Setting ErdCode.PRECISION_COOKING_PROBE_STATUS to 0
2024-05-04 08:05:25,226 DEBUG    Setting ErdCode.PRECISION_COOKING_PROBE_TEMP_TARGET to 0
2024-05-04 08:05:25,226 DEBUG    Setting ErdCode.PRECISION_COOKING_PROBE_TEMP_CURRENT to 0
2024-05-04 08:05:25,226 DEBUG    Setting ErdCode.PRECISION_COOKING_PROBE_TIME_TARGET to 0:00:00
2024-05-04 08:05:25,226 DEBUG    Setting ErdCode.PRECISION_COOKING_START_SOUS_VIDE_TIMER_ACTIVE_STATUS to ErdPrecisionCookingStartSousVideTimerActiveStatus.INACTIVE
2024-05-04 08:05:25,227 DEBUG    Setting ErdCode.PRECISION_COOKING_PROBE_TIME_CURRENT to 0:00:00
2024-05-04 08:05:25,227 DEBUG    Setting ErdCode.PRECISION_COOKING_PROBE_TARGET_TIME_REACHED to ErdPrecisionCookingProbeTargetTimeReached.NO
2024-05-04 08:05:25,227 DEBUG    Setting ErdCode.PRECISION_COOKING_PROBE_BATTERY_STATUS to ErdPrecisionCookingProbeBatteryStatus.OK
2024-05-04 08:05:25,227 DEBUG    received event: appliance_state_change, processing callbacks...
2024-05-04 08:05:25,227 DEBUG    processing callback: <bound method GeBaseClient._maybe_trigger_appliance_init_event of <gehomesdk.clients.websocket_client.GeWebsocketClient object at 0x7f9e767b4e10>>
2024-05-04 08:05:25,227 DEBUG    processing callback: <function log_state_change at 0x7f9e78214360>
2024-05-04 08:05:25,228 DEBUG    received event: appliance_update_received, processing callbacks...
2024-05-04 08:05:25,228 DEBUG    Got initial appliance type for GeAppliance(D828C9439E31) (ErdApplianceType.OVEN)
2024-05-04 08:05:25,228 DEBUG    received event: appliance_got_type, processing callbacks...
2024-05-04 08:05:25,228 DEBUG    processing callback: <function detect_appliance_type at 0x7f9e767b1580>
2024-05-04 08:05:25,228 DEBUG    Appliance state change detected in GeAppliance(D828C9439E31) (ErdApplianceType.OVEN). Updated keys: ErdCode.MODEL_NUMBER, ErdCode.SERIAL_NUMBER, ErdCode.CLOCK_FORMAT, ErdCode.TEMPERATURE_UNIT, ErdCode.APPLIANCE_TYPE, ErdCode.SABBATH_MODE, ErdCode.SOUND_LEVEL, ErdCode.UNIT_TYPE, ErdCode.BRAND, ErdCode.WIFI_MODULE_SW_VERSION, ErdCode.WIFI_MODULE_SW_VERSION_AVAILABLE, ErdCode.ACM_UPDATING, ErdCode.APPLIANCE_SW_VERSION, ErdCode.APPLIANCE_SW_VERSION_AVAILABLE, ErdCode.APPLIANCE_UPDATING, ErdCode.LCD_SW_VERSION, ErdCode.LCD_SW_VERSION_AVAILABLE, ErdCode.LCD_UPDATING, ErdCode.HOUR_12_SHUTOFF_ENABLED, ErdCode.END_TONE, ErdCode.CONVECTION_CONVERSION, ErdCode.KEY_PRESSED, ErdCode.OVEN_CONFIGURATION, ErdCode.OVEN_MODE_MIN_MAX_TEMP, ErdCode.WARMING_DRAWER_STATE, 0x5027, ErdCode.UPPER_OVEN_COOK_MODE, ErdCode.UPPER_OVEN_CURRENT_STATE, ErdCode.UPPER_OVEN_DELAY_TIME_REMAINING, ErdCode.UPPER_OVEN_PROBE_DISPLAY_TEMP, ErdCode.UPPER_OVEN_COOK_TIME_REMAINING, ErdCode.UPPER_OVEN_KITCHEN_TIMER, ErdCode.UPPER_OVEN_USER_TEMP_OFFSET, ErdCode.UPPER_OVEN_PROBE_PRESENT, ErdCode.UPPER_OVEN_DISPLAY_TEMPERATURE, ErdCode.UPPER_OVEN_REMOTE_ENABLED, ErdCode.UPPER_OVEN_AVAILABLE_COOK_MODES, ErdCode.UPPER_OVEN_RAW_TEMPERATURE, ErdCode.UPPER_OVEN_LIGHT, ErdCode.UPPER_OVEN_LIGHT_AVAILABILITY, ErdCode.UPPER_OVEN_EXTENDED_COOK_MODES, ErdCode.LOWER_OVEN_COOK_MODE, ErdCode.LOWER_OVEN_CURRENT_STATE, ErdCode.LOWER_OVEN_DELAY_TIME_REMAINING, ErdCode.LOWER_OVEN_PROBE_DISPLAY_TEMP, ErdCode.LOWER_OVEN_COOK_TIME_REMAINING, ErdCode.LOWER_OVEN_KITCHEN_TIMER, ErdCode.LOWER_OVEN_USER_TEMP_OFFSET, ErdCode.LOWER_OVEN_PROBE_PRESENT, ErdCode.LOWER_OVEN_DISPLAY_TEMPERATURE, ErdCode.LOWER_OVEN_REMOTE_ENABLED, ErdCode.LOWER_OVEN_AVAILABLE_COOK_MODES, ErdCode.LOWER_OVEN_RAW_TEMPERATURE, ErdCode.LOWER_OVEN_LIGHT, ErdCode.LOWER_OVEN_LIGHT_AVAILABILITY, ErdCode.LOWER_OVEN_EXTENDED_COOK_MODES, ErdCode.MICROWAVE_RECIPE_STATUS, ErdCode.ADVANTIUM_PRECISION_VERSION, 0x5411, 0x5412, 0x5414, 0x5421, 0x5422, 0x5424, ErdCode.COOKTOP_CONFIG, ErdCode.COOKTOP_STATUS, ErdCode.PRECISION_COOKING_PROBE_CONTROL_MODE, ErdCode.PRECISION_COOKING_PROBE_STATUS, ErdCode.PRECISION_COOKING_PROBE_TEMP_TARGET, ErdCode.PRECISION_COOKING_PROBE_TEMP_CURRENT, ErdCode.PRECISION_COOKING_PROBE_TIME_TARGET, ErdCode.PRECISION_COOKING_START_SOUS_VIDE_TIMER_ACTIVE_STATUS, ErdCode.PRECISION_COOKING_PROBE_TIME_CURRENT, ErdCode.PRECISION_COOKING_PROBE_TARGET_TIME_REACHED, ErdCode.PRECISION_COOKING_PROBE_BATTERY_STATUS
2024-05-04 08:05:25,229 DEBUG    Appliance state change detected in GeAppliance(D828C9439E31) (ErdApplianceType.OVEN)
2024-05-04 08:05:25,229 DEBUG    < TEXT '{"kind":"websocket#api","id":"020000351B20-allE...5-04T11:24:40.965Z"}]}}' [2755 bytes]
**2024-05-04 08:05:25,229 DEBUG    Setting ErdCode.MODEL_NUMBER to C7CGAAS3T1D3
2024-05-04 08:05:25,229 DEBUG    Setting ErdCode.SERIAL_NUMBER to C7CGAAS3T1D3
2024-05-04 08:05:25,229 DEBUG    Setting ErdCode.CLOCK_FORMAT to ErdClockFormat.TWELVE_HOUR
2024-05-04 08:05:25,229 DEBUG    Setting ErdCode.TEMPERATURE_UNIT to ErdMeasurementUnits.IMPERIAL
2024-05-04 08:05:25,230 DEBUG    Setting ErdCode.APPLIANCE_TYPE to ErdApplianceType.CAFE_COFFEE_MAKER
2024-05-04 08:05:25,230 DEBUG    Setting ErdCode.SOUND_LEVEL to ErdSoundLevel.LOW
2024-05-04 08:05:25,230 DEBUG    Setting ErdCode.UNIT_TYPE to ErdUnitType.UNKNOWN
2024-05-04 08:05:25,230 DEBUG    Setting ErdCode.BRAND to ErdBrand.GE_CAFE
2024-05-04 08:05:25,230 DEBUG    Setting ErdCode.WIFI_MODULE_SW_VERSION to 0.3.15.116
2024-05-04 08:05:25,230 DEBUG    Setting ErdCode.WIFI_MODULE_SW_VERSION_AVAILABLE to 0.0.0.0
2024-05-04 08:05:25,230 DEBUG    Setting ErdCode.ACM_UPDATING to False
2024-05-04 08:05:25,230 DEBUG    Setting ErdCode.APPLIANCE_SW_VERSION to 45.0.5.196
2024-05-04 08:05:25,230 DEBUG    Setting ErdCode.APPLIANCE_SW_VERSION_AVAILABLE to 0.0.0.0
2024-05-04 08:05:25,230 DEBUG    Setting ErdCode.APPLIANCE_UPDATING to False
2024-05-04 08:05:25,230 DEBUG    Setting ErdCode.CCM_IS_BREWING to False
2024-05-04 08:05:25,230 DEBUG    Setting ErdCode.CCM_POT_PRESENT to True
2024-05-04 08:05:25,230 DEBUG    Setting ErdCode.CCM_OUT_OF_WATER to False
2024-05-04 08:05:25,230 DEBUG    Setting 0x9024 to b'\x07\x08\x03\x84\n\x8c'
2024-05-04 08:05:25,230 DEBUG    Setting 0x902B to b'\x01'
2024-05-04 08:05:25,231 DEBUG    Setting 0x902C to b'\x01'
2024-05-04 08:05:25,231 DEBUG    Setting 0x902D to b'\x00'
2024-05-04 08:05:25,231 DEBUG    Setting 0x9030 to b'\x00'
2024-05-04 08:05:25,231 DEBUG    Setting 0x9044 to b'\x00\x04F\xc8'
2024-05-04 08:05:25,231 DEBUG    Setting 0x904D to b'\x03\x01\x06'
2024-05-04 08:05:25,231 DEBUG    Setting 0x904F to b'\x00'
2024-05-04 08:05:25,231 DEBUG    Setting 0x9051 to b'\x00\x01\x00\x00\x02\xc8\x18\x08\x00\x00\x00\x1e'
2024-05-04 08:05:25,231 DEBUG    Setting 0x9053 to b'\x00'
2024-05-04 08:05:25,231 DEBUG    Setting 0x9054 to b'\x01\x00\x00\x00\x03\xc8\x18\n\x00\x00\x00\x00'
2024-05-04 08:05:25,231 DEBUG    Setting 0x9056 to b'\x01\x00\x00\x00\x03\xc8\x18\n\x00\x00\x00\x00'
2024-05-04 08:05:25,231 DEBUG    Setting 0x9058 to b'\x01\x00\x00\x00\x03\xc8\x18\n\x00\x00\x00\x00'
2024-05-04 08:05:25,231 DEBUG    Setting 0x905A to b'\x00\x03\xb9\xcd\x06\x18\x04\n\x00\x00\x00\x00\x00\x05\x00\x1e'
2024-05-04 08:05:25,231 DEBUG    Setting 0x905B to b'\x01\x05'
2024-05-04 08:05:25,231 DEBUG    Setting 0x905C to b'\x01'
2024-05-04 08:05:25,232 DEBUG    Setting ErdCode.OIM_FILTER_STATUS to ErdOimFilterStatus.OK**
2024-05-04 08:05:25,232 DEBUG    received event: appliance_state_change, processing callbacks...
2024-05-04 08:05:25,232 DEBUG    processing callback: <bound method GeBaseClient._maybe_trigger_appliance_init_event of <gehomesdk.clients.websocket_client.GeWebsocketClient object at 0x7f9e767b4e10>>
2024-05-04 08:05:25,233 DEBUG    processing callback: <function log_state_change at 0x7f9e78214360>
2024-05-04 08:05:25,233 DEBUG    received event: appliance_update_received, processing callbacks...
2024-05-04 08:05:25,233 DEBUG    Got initial appliance type for GeAppliance(020000351B20) (ErdApplianceType.CAFE_COFFEE_MAKER)
2024-05-04 08:05:25,233 DEBUG    received event: appliance_got_type, processing callbacks...
2024-05-04 08:05:25,233 DEBUG    processing callback: <function detect_appliance_type at 0x7f9e767b1580>
**2024-05-04 08:05:25,234 DEBUG    Appliance state change detected in GeAppliance(020000351B20) (ErdApplianceType.CAFE_COFFEE_MAKER). Updated keys: ErdCode.MODEL_NUMBER, ErdCode.SERIAL_NUMBER, ErdCode.CLOCK_FORMAT, ErdCode.TEMPERATURE_UNIT, ErdCode.APPLIANCE_TYPE, ErdCode.SOUND_LEVEL, ErdCode.UNIT_TYPE, ErdCode.BRAND, ErdCode.WIFI_MODULE_SW_VERSION, ErdCode.WIFI_MODULE_SW_VERSION_AVAILABLE, ErdCode.ACM_UPDATING, ErdCode.APPLIANCE_SW_VERSION, ErdCode.APPLIANCE_SW_VERSION_AVAILABLE, ErdCode.APPLIANCE_UPDATING, ErdCode.CCM_IS_BREWING, ErdCode.CCM_POT_PRESENT, ErdCode.CCM_OUT_OF_WATER, 0x9024, 0x902B, 0x902C, 0x902D, 0x9030, 0x9044, 0x904D, 0x904F, 0x9051, 0x9053, 0x9054, 0x9056, 0x9058, 0x905A, 0x905B, 0x905C, ErdCode.OIM_FILTER_STATUS
2024-05-04 08:05:25,234 DEBUG    Appliance state change detected in GeAppliance(020000351B20) (ErdApplianceType.CAFE_COFFEE_MAKER)**
simbaja commented 6 months ago

Yeah, the byte settings are tough to decipher, and I unfortunately don't have any access to documentation. The single byte values are generally easier once you figure out how to map them. I'd suggest starting with those and then we can add more over time as they are figured out.

First step is to get all this into the SDK, then we can create additional logic for this new coffee maker. Looks like it presents itself as a CAFE_COFFEE_MAKER (like the existing devices), so we'll probably need some if logic to get these new entities in here.

Treygec commented 6 months ago

Bytestring values by position in string.

#1 = Gold toggle
#2 = bloom toggle
#3 = always x00 ???
#4 = single toggle
#5 = Brew Strength: light=x00, medium = x01, bold =x02, gold =x03
#6 = Temperate: 185=xb9,190=xbe,195=xc3,200=xc8,205=xcd
# 7 = Ounces: 6=x06,8=x08,10=n,12=x0c,14=x0e,16=x10,18=x12,20=x14,22=x16,24=x18
# 8 = Cups: 4=x04, 5=x05, 6=x06, 7=x07, 8=x08, 9=t, 10=n
# 9 = always x00 ???
# 10 = always x00 ???
# 11 = always x00 ???
# 12 = bloom time: 5=x05, 10=n, 15=x0f,20=x14,25=x19,30=x1e

"bytestring example": b'\x01\x00\x00\x00\x03\xc8\x18\n\x00\x00\x00\x00',

Above is the best I could do to figure out what the brew settings were as bytestring. Honestly, still no idea how they are encoded and there are 4 I can't get to change at all no matter what settings I use. My guess is that those unchanging ones are for things this coffee maker doesn't have, like a pot warmer / standby mode, and things like that.

Below are the ERD codes I was able to decipher. Again, wasn't able to get all of them to come across the sdk log, which might be a result of GE reusing components for coffee makers and this one just not having some of those items.

Features received (this list came from the gehomesdk logs) = 'COFFEE_BREWER_V2_BREW_BASKET_MISSING_OR_NOT_LOCKED', 0x904F changes to b'\x01 when missing / unlocked. 'COFFEE_BREWER_V2_BREW_CANCEL', Pressing and holding to cancel only activated ErdCode.CCM_IS_BREWING right below this. 'COFFEE_BREWER_V2_BREW_STATUS', mapped to ErdCode.CCM_IS_BREWING and True / False 'COFFEE_BREWER_V2_CLEAN_BREW_BASKET', 0x902C (sets to b'\x00 once basket opens and closes, b'\x01 after brew completes) 'COFFEE_BREWER_V2_DESCALE_STATUS', Brand new device and 74 gallons away from triggering a descale notification 'COFFEE_BREWER_V2_DISABLE_GRINDER', 0x9053 = Grinder status: b'\x01 = "Grind Off" b'\x00' = "Grind On" 'COFFEE_BREWER_V2_FILTER_STATUS', Not using the water filter but will put one in and try to monitor for this one too. Might map to existing ErdCode.OIM_FILTER_STATUS but I'm not sure 'COFFEE_BREWER_V2_FOUNDATION', 'COFFEE_BREWER_V2_GRINDER_MISSING_OR_NOT_LOCKED', 0x902B = "b'\x00" when UNLOCKED 'COFFEE_BREWER_V2_GRIND_SETTING': "0x9053 = Grinder status: b'\x01 = "Grind Off" b'\x00' = "Grind On"", 'COFFEE_BREWER_V2_MODEL_CONFIGURATION', 'COFFEE_BREWER_V2_OUT_OF_BEANS', tomorrow 'COFFEE_BREWER_V2_OUT_OF_WATER_DETECTION', mapped to existing ErdCode.CCM_OUT_OF_WATER 'COFFEE_BREWER_V2_POT_PRESENCE', removing / adding the pot doesn't do anything 'COFFEE_BREWER_V2_STANDBY', I set auto shutdown for 30 minutes after brew and no messages or changes were made when that time passed in the gehomesdk 'COFFEE_BREWER_V2_THREE_FAVORITE_BREWS', 0x9054 = Profile 1, 0x9056 = Profile 2, 0x9058 = Profile 3 'COMMON_V1_SOUND_LEVEL', maps to existing ErdCode.SOUND_LEVEL with ErdSoundLevel.OFF / ON

updated keys = ErdCode.MODEL_NUMBER, ErdCode.SERIAL_NUMBER, ErdCode.CLOCK_FORMAT, ErdCode.TEMPERATURE_UNIT, ErdCode.APPLIANCE_TYPE, ErdCode.SOUND_LEVEL, ErdCode.UNIT_TYPE, ErdCode.BRAND, ErdCode.WIFI_MODULE_SW_VERSION, ErdCode.WIFI_MODULE_SW_VERSION_AVAILABLE, ErdCode.ACM_UPDATING, ErdCode.APPLIANCE_SW_VERSION, ErdCode.APPLIANCE_SW_VERSION_AVAILABLE, ErdCode.APPLIANCE_UPDATING, ErdCode.CCM_IS_BREWING, ErdCode.CCM_POT_PRESENT, ErdCode.CCM_OUT_OF_WATER, 0x9024, 0x902B, 'COFFEE_BREWER_V2_GRINDER_MISSING_OR_NOT_LOCKED' 0x902C, 'COFFEE_BREWER_V2_CLEAN_BREW_BASKET' 0x902D, 0x9030, 0x9044, 0x904D, 0x904F, 'COFFEE_BREWER_V2_BREW_BASKET_MISSING_OR_NOT_LOCKED', 0x9051, adhoc brew instructions (could potentially be 'COFFEE_BREWER_V2_MODEL_CONFIGURATION' or 'COFFEE_BREWER_V2_FOUNDATION' just based on their names and the fact I can't get anything else resembling either to come across the sdk monitoring) 0x9053, COFFEE_BREWER_V2_GRIND_SETTING' 0x9054, Profile 1 0x9056, Profile 2 0x9058, Profile 3 0x905A, 0x905B, 0x905C, ErdCode.OIM_FILTER_STATUS