bluez: fix a2dp source

Actually compile the codec config and declare the config as extern
or else it's just all 0.
Only acquire the transport when ACTIVE.
Implement transport state_change signal and acquire the transport
when going to pending/active.
Try to acquire the transport before we expose the device if we
can.
Force device expose when we get the device ServicesResolved=1 property
update.
Free transport when the rfcomm is closed.
Implement various DBus signals to detect dynamic property updates.
This commit is contained in:
Wim Taymans 2019-05-16 13:18:45 +02:00
parent c348790ca1
commit 6cfddde39c
6 changed files with 213 additions and 34 deletions

View file

@ -284,15 +284,15 @@ static inline int a2dp_sbc_get_frequency(a2dp_sbc_t *config)
}
}
const a2dp_sbc_t bluez_a2dp_sbc;
extern const a2dp_sbc_t bluez_a2dp_sbc;
#if ENABLE_MP3
const a2dp_mpeg_t bluez_a2dp_mpeg;
extern const a2dp_mpeg_t bluez_a2dp_mpeg;
#endif
#if ENABLE_AAC
const a2dp_aac_t bluez_a2dp_aac;
extern const a2dp_aac_t bluez_a2dp_aac;
#endif
#if ENABLE_APTX
const a2dp_aptx_t bluez_a2dp_aptx;
extern const a2dp_aptx_t bluez_a2dp_aptx;
#endif
#endif