Android: Two Bluetooth modules

Viewed 125

I am in the planning stages of a project and potential issue has come up and I can't find the answer.

I am going to use a raspberry pi 4 with Android installed. To achieve my goal I will have to use a Bluetooth USB adapter with an external aerial. Because the raspberry and pi already has an onboard Bluetooth module, how will the OS cope with a second module being plugged in?

Can I disable the on board Bluetooth or force Android to use a particular module exclusively e.g the usb module?

Thanks

2 Answers

Unfortunately this is either not doable or at least not straight-forward. The reason is that the Android OS was designed to have one adapter only that does the Bluetooth functionality (as can be seen here and here). Even if you find a way to do it on the OS level, I would personally advice against it as there's very little resources on how that is done and you might soon find yourself stuck on another issue.

Is there a reason why you wouldn't use Linux and the BlueZ stack instead? There are many resources and examples on how to do this and with BlueZ and you should be able to use multiple adapters without an issue. If using Android is a must, then another recommendation is to use another MCU to connect to the Bluetooth dongle and do the translation from BT/USB and then have the Raspberry Pi connected to the external MCU over USB.

Below are a few links with people having a similar problem:-

Related