Change BiDirectional Prefix (#101764)

This commit is contained in:
Hessel 2023-10-10 21:23:02 +02:00 committed by GitHub
parent 265f6653c3
commit 535e2b81ce
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -4,7 +4,7 @@ from enum import StrEnum
DOMAIN = "wallbox" DOMAIN = "wallbox"
UPDATE_INTERVAL = 30 UPDATE_INTERVAL = 30
BIDIRECTIONAL_MODEL_PREFIXES = ["QSX"] BIDIRECTIONAL_MODEL_PREFIXES = ["QS"]
CODE_KEY = "code" CODE_KEY = "code"
CONF_STATION = "station" CONF_STATION = "station"

View File

@ -80,7 +80,7 @@ class WallboxNumber(WallboxEntity, NumberEntity):
self._coordinator = coordinator self._coordinator = coordinator
self._attr_unique_id = f"{description.key}-{coordinator.data[CHARGER_DATA_KEY][CHARGER_SERIAL_NUMBER_KEY]}" self._attr_unique_id = f"{description.key}-{coordinator.data[CHARGER_DATA_KEY][CHARGER_SERIAL_NUMBER_KEY]}"
self._is_bidirectional = ( self._is_bidirectional = (
coordinator.data[CHARGER_DATA_KEY][CHARGER_PART_NUMBER_KEY][0:3] coordinator.data[CHARGER_DATA_KEY][CHARGER_PART_NUMBER_KEY][0:2]
in BIDIRECTIONAL_MODEL_PREFIXES in BIDIRECTIONAL_MODEL_PREFIXES
) )