Skip to content

Commit

Permalink
Merge remote-tracking branch 'remotes/origin/dev'
Browse files Browse the repository at this point in the history
  • Loading branch information
simbaja committed Jan 2, 2025
2 parents cfc92be + 6499306 commit 96aaab7
Show file tree
Hide file tree
Showing 11 changed files with 38 additions and 25 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@

# GE Home Appliances (SmartHQ) Changelog

## 0.6.15

- Feature: Improved Support for Laundry
- Breaking: Some enums changed names/values and may need updates to client code
- Bugfix: More deprecation fixes

## 0.6.14

- Bugfix: Error checking socket status [#304]
Expand Down
2 changes: 1 addition & 1 deletion custom_components/ge_home/devices/advantium.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def get_all_entities(self) -> List[Entity]:
base_entities = super().get_all_entities()

advantium_entities = [
GeErdSensor(self, ErdCode.UNIT_TYPE),
GeErdSensor(self, ErdCode.PERSONALITY),
GeErdBinarySensor(self, ErdCode.UPPER_OVEN_REMOTE_ENABLED, self._single_name(ErdCode.UPPER_OVEN_REMOTE_ENABLED)),
GeErdBinarySensor(self, ErdCode.MICROWAVE_REMOTE_ENABLE),
GeErdSensor(self, ErdCode.UPPER_OVEN_DISPLAY_TEMPERATURE, self._single_name(ErdCode.UPPER_OVEN_DISPLAY_TEMPERATURE)),
Expand Down
9 changes: 5 additions & 4 deletions custom_components/ge_home/devices/dryer.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ def get_all_entities(self) -> List[Entity]:
GeErdSensor(self, ErdCode.LAUNDRY_DELAY_TIME_REMAINING),
GeErdBinarySensor(self, ErdCode.LAUNDRY_DOOR),
GeErdBinarySensor(self, ErdCode.LAUNDRY_REMOTE_STATUS, icon_on_override="mdi:tumble-dryer", icon_off_override="mdi:tumble-dryer"),
GeErdBinarySensor(self, ErdCode.LAUNDRY_DRYER_BLOCKED_VENT_FAULT, icon_on_override="mid:alert-circle", icon_off_override="mdi:alert-circle"),
]

dryer_entities = self.get_dryer_entities()
Expand All @@ -48,8 +49,8 @@ def get_dryer_entities(self):
dryer_entities.extend([GeErdSensor(self, ErdCode.LAUNDRY_DRYER_TEMPERATURENEW_OPTION)])
if self.has_erd_code(ErdCode.LAUNDRY_DRYER_TUMBLE_STATUS):
dryer_entities.extend([GeErdSensor(self, ErdCode.LAUNDRY_DRYER_TUMBLE_STATUS)])
if self.has_erd_code(ErdCode.LAUNDRY_DRYER_TUMBLENEW_STATUS):
dryer_entities.extend([GeErdSensor(self, ErdCode.LAUNDRY_DRYER_TUMBLENEW_STATUS)])
if self.has_erd_code(ErdCode.LAUNDRY_DRYER_EXTENDED_TUMBLE_OPTION_SELECTION):
dryer_entities.extend([GeErdSensor(self, ErdCode.LAUNDRY_DRYER_EXTENDED_TUMBLE_OPTION_SELECTION)])
if self.has_erd_code(ErdCode.LAUNDRY_DRYER_WASHERLINK_STATUS):
dryer_entities.extend([GeErdBinarySensor(self, ErdCode.LAUNDRY_DRYER_WASHERLINK_STATUS)])
if self.has_erd_code(ErdCode.LAUNDRY_DRYER_LEVEL_SENSOR_DISABLED):
Expand All @@ -58,8 +59,8 @@ def get_dryer_entities(self):
dryer_entities.extend([GeErdSensor(self, ErdCode.LAUNDRY_DRYER_SHEET_USAGE_CONFIGURATION)])
if self.has_erd_code(ErdCode.LAUNDRY_DRYER_SHEET_INVENTORY):
dryer_entities.extend([GeErdSensor(self, ErdCode.LAUNDRY_DRYER_SHEET_INVENTORY, icon_override="mdi:tray-full", uom_override="sheets")])
if self.has_erd_code(ErdCode.LAUNDRY_DRYER_ECODRY_STATUS):
dryer_entities.extend([GeErdSensor(self, ErdCode.LAUNDRY_DRYER_ECODRY_STATUS)])
if self.has_erd_code(ErdCode.LAUNDRY_DRYER_ECODRY_OPTION_SELECTION):
dryer_entities.extend([GeErdSensor(self, ErdCode.LAUNDRY_DRYER_ECODRY_OPTION_SELECTION)])

return dryer_entities

2 changes: 1 addition & 1 deletion custom_components/ge_home/devices/oven.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ def get_all_entities(self) -> List[Entity]:
if lower_warm_drawer is not None:
oven_entities.append(GeOvenWarmingStateSelect(self, ErdCode.LOWER_OVEN_WARMING_DRAWER_STATE))
if has_lower_probe_temperature:
oven_entities.append(GeErdSensor(self, ErdCode.LOWER_OVEN_PROBE_DISPLAY_TEMP, ErdCode.LOWER_OVEN_PROBE_DISPLAY_TEMP))
oven_entities.append(GeErdSensor(self, ErdCode.LOWER_OVEN_PROBE_DISPLAY_TEMP))

oven_entities.extend([
GeErdSensor(self, ErdCode.UPPER_OVEN_COOK_MODE, self._single_name(ErdCode.UPPER_OVEN_COOK_MODE, ~oven_config.has_lower_oven)),
Expand Down
2 changes: 1 addition & 1 deletion custom_components/ge_home/entities/advantium/const.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from homeassistant.components.water_heater import WaterHeaterEntityFeature

SUPPORT_NONE = 0
SUPPORT_NONE = WaterHeaterEntityFeature(0)
GE_ADVANTIUM_WITH_TEMPERATURE = (WaterHeaterEntityFeature.OPERATION_MODE | WaterHeaterEntityFeature.TARGET_TEMPERATURE)
GE_ADVANTIUM = WaterHeaterEntityFeature.OPERATION_MODE
8 changes: 4 additions & 4 deletions custom_components/ge_home/entities/advantium/ge_advantium.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

from gehomesdk import (
ErdCode,
ErdUnitType,
ErdPersonality,
ErdAdvantiumCookStatus,
ErdAdvantiumCookSetting,
AdvantiumOperationMode,
Expand Down Expand Up @@ -48,9 +48,9 @@ def name(self) -> Optional[str]:
return f"{self.serial_number} Advantium"

@property
def unit_type(self) -> Optional[ErdUnitType]:
def personality(self) -> Optional[ErdPersonality]:
try:
return self.appliance.get_erd_value(ErdCode.UNIT_TYPE)
return self.appliance.get_erd_value(ErdCode.PERSONALITY)
except:
return None

Expand Down Expand Up @@ -272,7 +272,7 @@ async def _ensure_operation_mode(self):

async def _convert_target_temperature(self, temp_120v: int, temp_240v: int):
unit_type = self.unit_type
target_temp_f = temp_240v if unit_type in [ErdUnitType.TYPE_240V_MONOGRAM, ErdUnitType.TYPE_240V_CAFE] else temp_120v
target_temp_f = temp_240v if unit_type in [ErdPersonality.PERSONALITY_240V_MONOGRAM, ErdPersonality.PERSONALITY_240V_CAFE] else temp_120v
if self.temperature_unit == SensorDeviceClass.FAHRENHEIT:
return float(target_temp_f)
else:
Expand Down
12 changes: 3 additions & 9 deletions custom_components/ge_home/entities/common/ge_erd_light.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,8 @@

from gehomesdk import ErdCodeType
from homeassistant.components.light import (
ColorMode,
ATTR_BRIGHTNESS,
COLOR_MODE_BRIGHTNESS,
SUPPORT_BRIGHTNESS,
LightEntity
)

Expand All @@ -25,19 +24,14 @@ def to_hass_level(level):
class GeErdLight(GeErdEntity, LightEntity):
"""Lights for ERD codes."""

def __init__(self, api: ApplianceApi, erd_code: ErdCodeType, erd_override: str = None, color_mode = COLOR_MODE_BRIGHTNESS):
def __init__(self, api: ApplianceApi, erd_code: ErdCodeType, erd_override: str = None, color_mode = ColorMode.BRIGHTNESS):
super().__init__(api, erd_code, erd_override)
self._color_mode = color_mode

@property
def supported_features(self):
"""Flag supported features."""
return SUPPORT_BRIGHTNESS

@property
def supported_color_modes(self):
"""Flag supported color modes."""
return {COLOR_MODE_BRIGHTNESS}
return ColorMode.BRIGHTNESS

@property
def color_mode(self):
Expand Down
2 changes: 1 addition & 1 deletion custom_components/ge_home/entities/oven/const.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from homeassistant.components.water_heater import WaterHeaterEntityFeature
from gehomesdk import ErdOvenCookMode

SUPPORT_NONE = 0
SUPPORT_NONE = WaterHeaterEntityFeature(0)
GE_OVEN_SUPPORT = (WaterHeaterEntityFeature.OPERATION_MODE | WaterHeaterEntityFeature.TARGET_TEMPERATURE)

OP_MODE_OFF = "Off"
Expand Down
4 changes: 2 additions & 2 deletions custom_components/ge_home/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"integration_type": "hub",
"iot_class": "cloud_push",
"documentation": "https://github.com/simbaja/ha_gehome",
"requirements": ["gehomesdk==0.5.30","magicattr==0.1.6","slixmpp==1.8.3"],
"requirements": ["gehomesdk==0.5.41","magicattr==0.1.6","slixmpp==1.8.3"],
"codeowners": ["@simbaja"],
"version": "0.6.14"
"version": "0.6.15"
}
2 changes: 1 addition & 1 deletion hacs.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "GE Home (SmartHQ)",
"homeassistant": "2024.2.0",
"homeassistant": "2024.9.0",
"domains": ["binary_sensor", "sensor", "switch", "water_heater", "select", "button", "climate", "light", "number"],
"iot_class": "Cloud Polling"
}
14 changes: 13 additions & 1 deletion info.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@ A/C Controls:

#### Breaking Changes

{% if version_installed.split('.') | map('int') < '0.6.15'.split('.') | map('int') %}
- Some enums changed names/values and may need updates to client code
{% endif %}

{% if version_installed.split('.') | map('int') < '0.6.6'.split('.') | map('int') %}
- Requires HA version 2022.12.0 or later
{% endif %}
Expand All @@ -69,6 +73,10 @@ A/C Controls:

#### Features

{% if version_installed.split('.') | map('int') < '0.6.15'.split('.') | map('int') %}
- Improved Support for Laundry
{% endif %}

{% if version_installed.split('.') | map('int') < '0.6.9'.split('.') | map('int') %}
- Added additional fridge controls (#200)
{% endif %}
Expand Down Expand Up @@ -127,8 +135,12 @@ A/C Controls:

#### Bugfixes

{% if version_installed.split('.') | map('int') < '0.6.14'.split('.') | map('int') %}
{% if version_installed.split('.') | map('int') < '0.6.15'.split('.') | map('int') %}
- Bugfix: More deprecation fixes
{% endif %}


{% if version_installed.split('.') | map('int') < '0.6.14'.split('.') | map('int') %}
- Bugfix: Error checking socket status [#304]
- Bugfix: Error with setup [#301]
- Bugfix: Logger deprecations
Expand Down

0 comments on commit 96aaab7

Please sign in to comment.