Bluetooth connection without pairing

android, bluetooth, connection

Solution

You may create an insecure bluetooth serial connection between two devices.

To create a connection:

Identify the `BluetoothDevice` and call its method `createInsecureRfcommSocketToServiceRecord`

To receive a connection:

Get hold of `BluetoothAdapter` and call the method `listenUsingInsecureRfcommWithServiceRecord`

This technique won't require the devices to establish a connection using pairing code. Its available in API level 10 and above.

Problem

I was looking to find a method to connect two phones using bluetooth without having to first pair them. I am trying to omit the annoying bluetooth pop up request. There is an app on the google store that does this called Bluehood. I wanted to use that style of connection for an app I am building in a totally different niche. You can search for the app on the google store called "Bluehood Social Bluetooth". https://play.google.com/store/apps/details?id=com.mobile.bluehood

Original source