bluez5: Add BAP_SINK/SOURCE from PACS UUID to adapter profiles

BAP sink/source are characteristics of the PACS profile, but we're more
interested by those characteristics then the more generic profile.
This commit is contained in:
Frédéric Danis 2022-07-07 11:23:17 +02:00 committed by Wim Taymans
parent 496dda1bcc
commit 284da66deb
2 changed files with 7 additions and 0 deletions

View file

@ -848,6 +848,12 @@ static int adapter_update_props(struct spa_bt_adapter *adapter,
if (profile && (adapter->profiles & profile) == 0) {
spa_log_debug(monitor->log, "adapter %p: add UUID=%s", adapter, uuid);
adapter->profiles |= profile;
} else if (strcasecmp(uuid, SPA_BT_UUID_PACS) == 0 &&
(adapter->profiles & SPA_BT_PROFILE_BAP_SINK) == 0) {
spa_log_debug(monitor->log, "adapter %p: add UUID=%s", adapter, SPA_BT_UUID_BAP_SINK);
adapter->profiles |= SPA_BT_PROFILE_BAP_SINK;
spa_log_debug(monitor->log, "adapter %p: add UUID=%s", adapter, SPA_BT_UUID_BAP_SOURCE);
adapter->profiles |= SPA_BT_PROFILE_BAP_SOURCE;
}
dbus_message_iter_next(&iter);
}

View file

@ -141,6 +141,7 @@ extern "C" {
#define SPA_BT_UUID_HSP_AG "00001112-0000-1000-8000-00805f9b34fb"
#define SPA_BT_UUID_HFP_HF "0000111e-0000-1000-8000-00805f9b34fb"
#define SPA_BT_UUID_HFP_AG "0000111f-0000-1000-8000-00805f9b34fb"
#define SPA_BT_UUID_PACS "00001850-0000-1000-8000-00805f9b34fb"
#define SPA_BT_UUID_BAP_SINK "00002bc9-0000-1000-8000-00805f9b34fb"
#define SPA_BT_UUID_BAP_SOURCE "00002bcb-0000-1000-8000-00805f9b34fb"