Use _attr_precision in entities (#77477)
This commit is contained in:
parent
d4c020b675
commit
e19e65908a
12 changed files with 14 additions and 73 deletions
|
@ -106,6 +106,7 @@ class VenstarThermostat(VenstarEntity, ClimateEntity):
|
|||
|
||||
_attr_fan_modes = [FAN_ON, FAN_AUTO]
|
||||
_attr_hvac_modes = [HVACMode.HEAT, HVACMode.COOL, HVACMode.OFF, HVACMode.AUTO]
|
||||
_attr_precision = PRECISION_HALVES
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
|
@ -139,15 +140,6 @@ class VenstarThermostat(VenstarEntity, ClimateEntity):
|
|||
|
||||
return features
|
||||
|
||||
@property
|
||||
def precision(self):
|
||||
"""Return the precision of the system.
|
||||
|
||||
Venstar temperature values are passed back and forth in the
|
||||
API in C or F, with half-degree accuracy.
|
||||
"""
|
||||
return PRECISION_HALVES
|
||||
|
||||
@property
|
||||
def temperature_unit(self):
|
||||
"""Return the unit of measurement, as defined by the API."""
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue