Update sensor.py

This commit is contained in:
t0urista 2024-10-30 14:14:32 +01:00 committed by GitHub
parent 2a4d78b81e
commit 258ab994ed
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -42,13 +42,13 @@ CONFIG_SCHEMA = cv.Schema(
),
cv.Optional(CONF_ILLUMINANCE): sensor.sensor_schema(
unit_of_measurement=UNIT_LUX,
accuracy_decimals=2,
accuracy_decimals=0,
device_class=DEVICE_CLASS_ILLUMINANCE,
state_class=STATE_CLASS_MEASUREMENT,
),
cv.Optional(CONF_HUMIDITY): sensor.sensor_schema(
unit_of_measurement=UNIT_PERCENT,
accuracy_decimals=2,
accuracy_decimals=0,
device_class=DEVICE_CLASS_HUMIDITY,
state_class=STATE_CLASS_MEASUREMENT,
),