Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
New Developer
Posts: 13
Registered: ‎06-17-2009
My Device: Not Specified
Accepted Solution

Multiple simultaneous Bluetooth connections

I would like to apologize to reproducing my post from another section here, but it seems like here my question would more appropriate:

 

Is it possible for a Blackberry device to function as a Bluetooth Master in a Bluetooth PAN/piconet? In other words, can it open multiple serial ports to accept/send data from/to multiple Bluetooth devices simultaneously (of course it is not literaly simultaneous, there is time interleaving in the receiving/transmission processes effectively lowering the bandwidth for every link).

 

I am interested in having a BB device get continuous data from two Bluetooth -enabled sensors which continuously stream data via SPP/RFCOMM. Could a BB device support such a scenario? I tried to test that scenario with the Blackberry Simulator but the simulator does not support Bluetooth . I don't currently have a BB device to test that on, but I do not want to purchase one and then find out that what I wanna do is not implementable.

 

I have not been able to find any relevant answer to this question and I am guessing there are a few developers who would be very pleased if they could have an answer on this. As a result I would greatly appreciate any help/clarification from any of the senior developers or from the forum's administrators that could shed any light on this...;-)


What someone who actually owns a BB device could try is to get the following property which returns "The maximum number of connected devices supported":

LocalDevice.getProperty("bluetooth.connected.devices.max");

 

you would just need to: import javax.bluetooth.LocalDevice;

 

In case this returns something greater than 0 or 1, then I can safely assume that multiple (up to 7 normally) simultaneous Bluetooth connections can be supported, whereby the available bandwidth would be divided among the connected clients to the BB phone, enabling them all to function & communicate concurrently.

I would be much obliged to anyone that could try this for me... (the above statement always results in a NullPointerException in the Simulator)

Guru I
Posts: 19,020
Registered: ‎07-29-2008
My Device: Passport, Playbook, 9320BES
My Carrier: Bouygues _ SFR

Re: Multiple simultaneous Bluetooth connections

hello,

the appropriate board is "Java development". I have asked a moderator to move the discussion over there.



The search box on top-right of this page is your true friend, and the public Knowledge Base too:
New Developer
Posts: 13
Registered: ‎06-17-2009
My Device: Not Specified

Re: Multiple simultaneous Bluetooth connections

Thanks for that Xandrex and sorry for posting in a wrong board...

 

While I am still trying to find an answer to the above question I found the following on:

http://www.blackberry.com/btsc/microsites/search.do?cmd=displayKC&docType=kc&externalId=KB05167&slic...

 

"When the BlackBerry device is connected to a device enabled with Bluetooth wireless technology (for example, headset, car kit, laptop), it cannot be discovered by another device enabled with Bluetooth technology. For example, if the BlackBerry device is paired with a headset, you cannot discover the BlackBerry device using a laptop (even if the BlackBerry device is in discoverable mode). However, the BlackBerry device can still connect to multiple devices, as long as you initiate the connection from the BlackBerry device."

 

 This effectively means that a BB device can indeed function a as a Bluetooth master when only if it initiates the connections to the slaves, which is exactly what I need to do

 

However, I still have some doubts, for example since on http://gadgetguide.bluetooth.com/ all Blackberry devices appear to not support data transfer although Blackberry clearly states on the specifications of its latest models at least that SPP protocol is supported...

 

I wish someone could shed some light on the whole issue...

New Developer
Posts: 13
Registered: ‎06-17-2009
My Device: Not Specified

Re: Multiple simultaneous Bluetooth connections

I 'm gonna repeat my newest answer here from the other post...

 

In the Bluetooth Demo found at http://na.blackberry.com/eng/developers/resources/developer_labs.jsp#tab_tab_jde at the bottom of the screen, there is a class named AppScreen.

Within that class, in the loop for every Bluetooth device that the BB can connect to there is a comment that says:

 

// A single device can provide multiple serial port connections (or services).

 

I am guessing this comment does indeed imply that a single BB device is capable of connecting to multiple BT devices simultanesously, e.g. it can open several virtual COM ports (up to 7 as the BT-standard states?) to communicate with more than one BT-enabled peripheral and thus set-up a PAN-piconet.

 

If only someone had tested this and could let us know...

 

New Developer
Posts: 13
Registered: ‎06-17-2009
My Device: Not Specified

Re: Multiple simultaneous Bluetooth connections

As it can be seen in my post at this thread:

http://supportforums.blackberry.com/rim/board/message?board.id=9500&message.id=37539#M37539

 

a BB Bold device (that's all I can say for sure) is capable of communicating with multiple SPP Bluetooth peripherals/ports concurrently. The only thing that is required, is to start up a new thread to set up and monitor every serial port.

Visitor
Posts: 1
Registered: ‎05-26-2013
My Device: BlackBerry Z10
My Carrier: Telus

Re: Multiple simultaneous Bluetooth connections

I am currently having BlueTooth connection problems when trying to connect a keyboard to my Z10. I am informed that the phone is "Unable to connect to more than two devices." This is in spite of the fact that when trying to connect the keyboard there are no BlueTooth devices actually connected at the time. I would say that the limit of simultaneous BlueTooth connections is two, this based on the fact that there is an error window saying so.

Hope this was some help.
Developer
Posts: 19,636
Registered: ‎07-14-2008
My Device: Not Specified

Re: Multiple simultaneous Bluetooth connections

Thanks for the input.

 

Unfortunately Z10 is a different OS to the JAva devices that this forum supports, so the rules are different for it.