androidbluetootharduinoapp-inventor

Scaning for bluetooth device with MIT App Inventor 2


I am trying to connect an arduino has bluetooh(HC-06) with an android phone. I found and applied below block but I can only connect to paired devices without scanning.

How can I scan for available bluetooth devices and connect them using MIT App Inventor 2? What should be the block for scan operation?

enter image description here


Solution

  • See the documentation of the bluetooth component

    As you can see, there is no block available to scan for devices, you only can get a list of paired Bluetooth devices....

    AddressesAndNames
    The addresses and names of paired Bluetooth devices

    However you can create your own extension and create your own blocks, for more information, see the announcement here.

    Btw... see the following screenshot for how to connect correctly enter image description here

    EDIT: to scan for devices you can use the classic bluetooth extension.
    Note: I'm the author of that extension.