mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-29 05:40:27 -04:00
Bluez5: backend-native: HSP AG release SCO link on AT+CKPD=200
Bluetooth PTS test HSP/AG/ACR/BV-01-I request AG to release the SCO link upon reception of AT+CKPD=200 reception
This commit is contained in:
parent
c2e4e336ac
commit
442a208382
3 changed files with 29 additions and 2 deletions
|
|
@ -1370,12 +1370,34 @@ static void device_connected(void *userdata, bool connected)
|
|||
}
|
||||
}
|
||||
|
||||
static void device_switch_profile(void *userdata)
|
||||
{
|
||||
struct impl *this = userdata;
|
||||
uint32_t profile;
|
||||
|
||||
switch(this->profile) {
|
||||
case DEVICE_PROFILE_OFF:
|
||||
profile = DEVICE_PROFILE_HSP_HFP;
|
||||
break;
|
||||
case DEVICE_PROFILE_HSP_HFP:
|
||||
profile = DEVICE_PROFILE_OFF;
|
||||
break;
|
||||
default:
|
||||
return;
|
||||
}
|
||||
|
||||
spa_log_debug(this->log, "%p: device switch profile %d -> %d", this, this->profile, profile);
|
||||
|
||||
set_profile(this, profile, 0, false);
|
||||
}
|
||||
|
||||
static const struct spa_bt_device_events bt_dev_events = {
|
||||
SPA_VERSION_BT_DEVICE_EVENTS,
|
||||
.connected = device_connected,
|
||||
.codec_switched = codec_switched,
|
||||
.profiles_changed = profiles_changed,
|
||||
.device_set_changed = device_set_changed,
|
||||
.switch_profile = device_switch_profile,
|
||||
};
|
||||
|
||||
static int impl_add_listener(void *object,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue