I want to create a broadcast receiver which will listen when bluetooth device is connected with other device.
I only find this.
<intent-filter> <action android:name="android.bluetooth.device.action.ACL_CONNECTED" />
<action android:name="android.bluetooth.device.action.ACL_DISCONNECT_REQUESTED" />
<action android:name="android.bluetooth.device.action.ACL_DISCONNECTED" />
</intent-filter>
but I think that ACL_CONNECTED is only activated when searching for services not when bluetooth connection with other device is established.
Am I right or how can I do this?
You are right – ACL is a lower layer part of the Bluetooth stack (it’s the logical transport layer).
If you want to listen to Bluetooth connections being made or broken between some device and some Android app you do not own, you need to check for RFCOMM connections or even SPP connections.
However, if you own the application making these connections, there is no need to listen to generic events.