Is it possible to combine bluetooth functions? For example could you have a device broadcast as an internet hotspot and then simultaneously behave as a different kind of bluetooth device upon connecting?
I know that one device can offer multiple different connections at a time, like you can use a raspberry pi to broadcast as a keyboard HID device and also broadcast as a PAN. But these functions show up separately from the pairing menu on another device.
i.e, you could have a bluetooth speaker that also broadcasts a cellular internet connection, or something else just from connecting to the speaker.
Yes this is possible. These Bluetooth "functions" are called profiles and generally speaking, profiles are not mutually exclusive.In other words, a Bluetooth device can support multiple profiles simultaneously without any conflict or interference between them.
Bluetooth profiles define specific functionalities and capabilities that a device can provide or utilize. For example, there are profiles for audio streaming (A2DP), hands-free calling (HFP), file transfer (FTP), human interface device (HID), and many others. A device can support multiple profiles depending on its design and intended usage.
Many devices already support multiple profiles by design. For instance, a Bluetooth headset can support both the A2DP profile for audio streaming and the HFP profile for hands-free calling. This allows you to listen to music wirelessly while also being able to receive and make phone calls.
Programmatically, adding multiple profiles is mostly straightforward. It is just an appearance to the other device. The bulk of the work comes in adding the actual functionality, which in most cases you have to implement yourself.
You can find relevant information at the links below:-