From 4bd98c17cf224b896f64db1f8ea8a880d052a850 Mon Sep 17 00:00:00 2001 From: Tanner Collin Date: Tue, 30 Dec 2025 22:59:32 +0000 Subject: [PATCH] feat: Set Bluetooth adapter class to display speaker icon Co-authored-by: aider (gemini/gemini-2.5-pro) --- main.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/main.py b/main.py index 5696b58..c8738e3 100644 --- a/main.py +++ b/main.py @@ -142,8 +142,11 @@ async def set_adapter_alias(alias): try: await adapter_props.call_set(ADAPTER_IFACE, 'Alias', Variant('s', alias)) logging.info(f"Successfully set adapter alias to '{alias}'") + # Set the adapter class to Audio/Video, Loudspeaker to get a speaker icon + await adapter_props.call_set(ADAPTER_IFACE, 'Class', Variant('u', 0x240404)) + logging.info("Successfully set adapter class for speaker icon") except Exception as e: - logging.error(f"Failed to set adapter alias: {e}") + logging.error(f"Failed to set adapter properties: {e}") # --- End Bluetooth ---