- added fix for SAC temperature sensors (#40)

This commit is contained in:
Jack Simbach 2021-09-01 18:15:48 -04:00
parent 281879f66d
commit 0844dc31d2
5 changed files with 22 additions and 5 deletions

View File

@ -8,7 +8,7 @@
- Added logic to prevent multiple configurations of the same GE account
- Fixed device info when serial not present (@Xe138)
- Fixed issue with ovens when raw temperature not available (@chadohalloran)
- Fixed issue where Split A/C temperature sensors report UOM incorrectly (@RobertusIT)
## 0.4.3
- Enabled support for appliances without serial numbers

View File

@ -5,7 +5,7 @@ from homeassistant.helpers.entity import Entity
from gehomesdk.erd import ErdCode, ErdApplianceType
from .base import ApplianceApi
from ..entities import GeSacClimate, GeErdSensor, GeErdBinarySensor, GeErdSwitch, ErdOnOffBoolConverter
from ..entities import GeSacClimate, GeSacTemperatureSensor, GeErdSensor, GeErdSwitch, ErdOnOffBoolConverter
_LOGGER = logging.getLogger(__name__)
@ -19,8 +19,8 @@ class SacApi(ApplianceApi):
sac_entities = [
GeSacClimate(self),
GeErdSensor(self, ErdCode.AC_TARGET_TEMPERATURE),
GeErdSensor(self, ErdCode.AC_AMBIENT_TEMPERATURE),
GeSacTemperatureSensor(self, ErdCode.AC_TARGET_TEMPERATURE),
GeSacTemperatureSensor(self, ErdCode.AC_AMBIENT_TEMPERATURE),
GeErdSensor(self, ErdCode.AC_FAN_SETTING, icon_override="mdi:fan"),
GeErdSensor(self, ErdCode.AC_OPERATION_MODE),
GeErdSwitch(self, ErdCode.AC_POWER_STATUS, bool_converter=ErdOnOffBoolConverter(), icon_on_override="mdi:power-on", icon_off_override="mdi:power-off"),

View File

@ -1,3 +1,4 @@
from .ge_wac_climate import GeWacClimate
from .ge_sac_climate import GeSacClimate
from .ge_pac_climate import GePacClimate
from .ge_pac_climate import GePacClimate
from .ge_sac_temperature_sensor import GeSacTemperatureSensor

View File

@ -0,0 +1,15 @@
import logging
from typing import Any, List, Optional
from homeassistant.const import (
TEMP_FAHRENHEIT
)
from ..common import GeErdSensor
class GeSacTemperatureSensor(GeErdSensor):
"""Class for Split A/C temperature sensors"""
@property
def temperature_unit(self):
#SAC appears to be hard coded to use Fahrenheit internally, no matter what the display shows
return TEMP_FAHRENHEIT

View File

@ -71,6 +71,7 @@ A/C Controls:
- Advantium fixes (@willhayslett)
- Fixed device info when serial not present (@Xe138)
- Fixed issue with ovens when raw temperature not available (@chadohalloran)
- Fixed issue where Split A/C temperature sensors report UOM incorrectly (@RobertusIT)
{% endif %}
{% if version_installed.split('.') | map('int') < '0.4.3'.split('.') | map('int') %}