Set connections on device for acaia (#132064)

pull/132195/head
Josef Zweck 2024-12-02 15:27:44 +01:00 committed by Franck Nijhof
parent d3a577ad89
commit 3f1286b338
No known key found for this signature in database
GPG Key ID: D62583BA8AB11CA3
2 changed files with 10 additions and 1 deletions

View File

@ -2,7 +2,11 @@
from dataclasses import dataclass
from homeassistant.helpers.device_registry import DeviceInfo, format_mac
from homeassistant.helpers.device_registry import (
CONNECTION_BLUETOOTH,
DeviceInfo,
format_mac,
)
from homeassistant.helpers.entity import EntityDescription
from homeassistant.helpers.update_coordinator import CoordinatorEntity
@ -33,6 +37,7 @@ class AcaiaEntity(CoordinatorEntity[AcaiaCoordinator]):
manufacturer="Acaia",
model=self._scale.model,
suggested_area="Kitchen",
connections={(CONNECTION_BLUETOOTH, self._scale.mac)},
)
@property

View File

@ -5,6 +5,10 @@
'config_entries': <ANY>,
'configuration_url': None,
'connections': set({
tuple(
'bluetooth',
'aa:bb:cc:dd:ee:ff',
),
}),
'disabled_by': None,
'entry_type': None,