Bluetooth command commands for ADB

I am currently studying automation for testing a Bluetooth connection between an android phone and another device.

I have found many useful ADB commands, such as

  • adb shell service call bluetooth_manager 6
  • adb shell am start -a android.bluetooth.adapter.action.REQUEST_ENABLE
  • adb shell am start -a android.bluetooth.adapter.action.REQUEST_DISCOVERABLE
  • adb shell service call bluetooth_manager 8

but could not find anything for the following actions:

  • Scan for detected Bluetooth devices
  • Pair with this detected Bluetooth device.
  • Forget about an earlier paired Bluetooth device.
  • Connect to an earlier paired Bluetooth device.
  • Disconnect from an earlier paired Bluetooth device.

Are there any Or do I need to write an Android wrapper application that can do this?

+5
source share

Source: https://habr.com/ru/post/1262644/


All Articles