Add in-app speaker discovery and connection guide

This commit is contained in:
lda committed 2026-10-25 04:59:07 +07:00 Verified
1 parent 038e152bbc
commit f75d3fb558
7 files changed
+287 -28

No files matched your search

+1 -12
View File
@@ -3,18 +3,7 @@
import argparse
import asyncio
# MX-T40 model advertisements from the Android APK's strings.xml. These
# identify discovery records; they are not assumed to be writable services.
MODEL_UUIDS = {
f"0000{short}-0000-1000-8000-00805f9b34fb" for short in ("ff40", "fe40", "ff41", "fe41")
}
def is_candidate(device, advertisement):
names = f"{device.name or ''} {advertisement.local_name or ''}".upper()
return "T40" in names or bool(
MODEL_UUIDS.intersection(value.lower() for value in advertisement.service_uuids)
)
from controller.discovery import is_candidate
async def inspect(timeout):