Functions | |
| HomeAssistantBluetoothManager | _get_manager (HomeAssistant hass) |
| bool | async_address_present (HomeAssistant hass, str address, bool connectable=True) |
| BLEDevice|None | async_ble_device_from_address (HomeAssistant hass, str address, bool connectable=True) |
| Iterable[BluetoothServiceInfoBleak] | async_discovered_service_info (HomeAssistant hass, bool connectable=True) |
| Callable[[BluetoothServiceInfoBleak], None] | async_get_advertisement_callback (HomeAssistant hass) |
| float|None | async_get_fallback_availability_interval (HomeAssistant hass, str address) |
| float|None | async_get_learned_advertising_interval (HomeAssistant hass, str address) |
| HaBleakScannerWrapper | async_get_scanner (HomeAssistant hass) |
| BluetoothServiceInfoBleak|None | async_last_service_info (HomeAssistant hass, str address, bool connectable=True) |
| BluetoothServiceInfoBleak | async_process_advertisements (HomeAssistant hass, ProcessAdvertisementCallback callback, BluetoothCallbackMatcher match_dict, BluetoothScanningMode mode, int timeout) |
| None | async_rediscover_address (HomeAssistant hass, str address) |
| Callable[[], None] | async_register_callback (HomeAssistant hass, BluetoothCallback callback, BluetoothCallbackMatcher|None match_dict, BluetoothScanningMode mode) |
| CALLBACK_TYPE | async_register_scanner (HomeAssistant hass, BaseHaScanner scanner, int|None connection_slots=None) |
| BaseHaScanner|None | async_scanner_by_source (HomeAssistant hass, str source) |
| int | async_scanner_count (HomeAssistant hass, bool connectable=True) |
| list[BluetoothScannerDevice] | async_scanner_devices_by_address (HomeAssistant hass, str address, bool connectable=True) |
| None | async_set_fallback_availability_interval (HomeAssistant hass, str address, float interval) |
| Callable[[], None] | async_track_unavailable (HomeAssistant hass, Callable[[BluetoothServiceInfoBleak], None] callback, str address, bool connectable=True) |
The bluetooth integration apis. These APIs are the only documented way to interact with the bluetooth integration.
|
private |
| bool homeassistant.components.bluetooth.api.async_address_present | ( | HomeAssistant | hass, |
| str | address, | ||
| bool | connectable = True |
||
| ) |
| BLEDevice | None homeassistant.components.bluetooth.api.async_ble_device_from_address | ( | HomeAssistant | hass, |
| str | address, | ||
| bool | connectable = True |
||
| ) |
| Iterable[BluetoothServiceInfoBleak] homeassistant.components.bluetooth.api.async_discovered_service_info | ( | HomeAssistant | hass, |
| bool | connectable = True |
||
| ) |
| Callable[[BluetoothServiceInfoBleak], None] homeassistant.components.bluetooth.api.async_get_advertisement_callback | ( | HomeAssistant | hass | ) |
| float | None homeassistant.components.bluetooth.api.async_get_fallback_availability_interval | ( | HomeAssistant | hass, |
| str | address | ||
| ) |
| float | None homeassistant.components.bluetooth.api.async_get_learned_advertising_interval | ( | HomeAssistant | hass, |
| str | address | ||
| ) |
| HaBleakScannerWrapper homeassistant.components.bluetooth.api.async_get_scanner | ( | HomeAssistant | hass | ) |
| BluetoothServiceInfoBleak | None homeassistant.components.bluetooth.api.async_last_service_info | ( | HomeAssistant | hass, |
| str | address, | ||
| bool | connectable = True |
||
| ) |
| BluetoothServiceInfoBleak homeassistant.components.bluetooth.api.async_process_advertisements | ( | HomeAssistant | hass, |
| ProcessAdvertisementCallback | callback, | ||
| BluetoothCallbackMatcher | match_dict, | ||
| BluetoothScanningMode | mode, | ||
| int | timeout | ||
| ) |
| None homeassistant.components.bluetooth.api.async_rediscover_address | ( | HomeAssistant | hass, |
| str | address | ||
| ) |
| Callable[[], None] homeassistant.components.bluetooth.api.async_register_callback | ( | HomeAssistant | hass, |
| BluetoothCallback | callback, | ||
| BluetoothCallbackMatcher | None | match_dict, | ||
| BluetoothScanningMode | mode | ||
| ) |
Register to receive a callback on bluetooth change. mode is currently not used as we only support active scanning. Passive scanning will be available in the future. The flag is required to be present to avoid a future breaking change when we support passive scanning. Returns a callback that can be used to cancel the registration.
| CALLBACK_TYPE homeassistant.components.bluetooth.api.async_register_scanner | ( | HomeAssistant | hass, |
| BaseHaScanner | scanner, | ||
| int | None | connection_slots = None |
||
| ) |
| BaseHaScanner | None homeassistant.components.bluetooth.api.async_scanner_by_source | ( | HomeAssistant | hass, |
| str | source | ||
| ) |
| int homeassistant.components.bluetooth.api.async_scanner_count | ( | HomeAssistant | hass, |
| bool | connectable = True |
||
| ) |
| list[BluetoothScannerDevice] homeassistant.components.bluetooth.api.async_scanner_devices_by_address | ( | HomeAssistant | hass, |
| str | address, | ||
| bool | connectable = True |
||
| ) |
| None homeassistant.components.bluetooth.api.async_set_fallback_availability_interval | ( | HomeAssistant | hass, |
| str | address, | ||
| float | interval | ||
| ) |
| Callable[[], None] homeassistant.components.bluetooth.api.async_track_unavailable | ( | HomeAssistant | hass, |
| Callable[[BluetoothServiceInfoBleak], None] | callback, | ||
| str | address, | ||
| bool | connectable = True |
||
| ) |