BlackBerry Forums Support Community               

Closed Thread
 
LinkBack Thread Tools
Old 03-27-2008, 03:14 PM   #1 (permalink)
Thumbs Must Hurt
 
Join Date: Sep 2006
Location: Ontario, Canada
Model: 9700
Carrier: Rogers
Posts: 92
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default issues regarding bluetooth development

Please Login to Remove!

Okay, so I've done basic bluetooth stuff before, but right now all I want to do is connect to my PC via bluetooth.

I've used the following code to come up with a list of Bluetooth devices that I've paired with:

Code:
            _portInfo = BluetoothSerialPort.getSerialPortInfo();
            _devices = new String[_portInfo.length];
            for (int b = 0; b < _portInfo.length; b++)
            {
                _devices[b] = _portInfo[b].getDeviceName();
            }
This works, however it doesn't list ALL the devices. I.E. my jabra headset isn't listed, my PC isn't listed. It does list my friends cell phone, and my bluetooth GPS device... is there maybe something I'm missing?
__________________
http://www.ryannickel.com for my awesomeness!
Offline  
Old 03-27-2008, 05:04 PM   #2 (permalink)
Talking BlackBerry Encyclopedia
 
richard.puckett's Avatar
 
Join Date: Oct 2007
Location: Seattle, WA
Model: 9020
PIN: N/A
Carrier: T-Mobile
Posts: 212
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

The docs say getSerialPortInfo "[r]etrieves serial port information for the currently paired devices." Is your PC already paired?

Perhaps you should try JSR-82 to get back a list of all discoverable devices?
__________________
Do your homework and know how to ask a good question.
Offline  
Old 03-27-2008, 06:59 PM   #3 (permalink)
Thumbs Must Hurt
 
Join Date: Sep 2006
Location: Ontario, Canada
Model: 9700
Carrier: Rogers
Posts: 92
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

The device is already paired, yes
__________________
http://www.ryannickel.com for my awesomeness!
Offline  
Old 03-28-2008, 08:51 AM   #4 (permalink)
BlackBerry Extraordinaire
 
Join Date: Jan 2006
Model: LEZ10
OS: 10.0.10
Carrier: Rogers CA
Posts: 1,704
Post Thanks: 20
Thanked 77 Times in 68 Posts
Default

It will also only return connections that support the Bluetooth Serial Port Protocol (SPP). Start your PC Bluetooth manager, go to the COM Ports tab, add an incoming port, attach a program to that port (Hyperterminal will work). On the BB go to Bluetooth options, select the PC from the Paired Devices list, go to Device Properties, select Refresh Service List from the main menu. The COM Port should show up.
Offline  
Old 03-28-2008, 11:32 AM   #5 (permalink)
Thumbs Must Hurt
 
Join Date: Sep 2006
Location: Ontario, Canada
Model: 9700
Carrier: Rogers
Posts: 92
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

After connecting my phone to my computer in this way I'll be able to send data to the PC via BlueTooth?
__________________
http://www.ryannickel.com for my awesomeness!
Offline  
Old 03-28-2008, 11:35 AM   #6 (permalink)
Thumbs Must Hurt
 
Join Date: Sep 2006
Location: Ontario, Canada
Model: 9700
Carrier: Rogers
Posts: 92
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

and my computer now shows up btw
__________________
http://www.ryannickel.com for my awesomeness!
Offline  
Old 03-30-2008, 06:42 PM   #7 (permalink)
BlackBerry Extraordinaire
 
Join Date: Jan 2006
Model: LEZ10
OS: 10.0.10
Carrier: Rogers CA
Posts: 1,704
Post Thanks: 20
Thanked 77 Times in 68 Posts
Default

Quote:
Originally Posted by rnickel View Post
After connecting my phone to my computer in this way I'll be able to send data to the PC via BlueTooth?
Yes, once you have HyperTerm or such, connected and can see the port, the Blackberry should be able to connect and send text that will appear on the HyperTerm window.
Offline  
Closed Thread


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On





Copyright 2004-2014 BlackBerryForums.com.
The names RIM and BlackBerry are registered Trademarks of BlackBerry Inc.