c++ - BlueTooth connection faliure -
environment
- ubuntu 16.04
- standard usb bluetooth dongle
- c++
- bluez
- running root
problem description
while hcitool & sdptool operate, code fail connecting sdp errno == 2 ( enoent ), following failing code:
m_psdpsession = sdp_connect(bdaddr_any, bdaddr_local, sdp_retry_if_busy | sdp_wait_on_close);
why 'sdp_connect' failing? how can have resolved ?
edit /usr/lib/systemd/system/bluetooth.service
, includ flag in execstart option.
execstart=/usr/libexec/bluetooth/bluetoothd --compat
then
$ systemctl daemon-reload
$ systemctl restart bluetooth.service
Comments
Post a Comment