views:

877

answers:

6

Hi. I want to write some small program. It will run on my computer(laptop) with bluetooth adapter and then discover all the visible bluetooth adapters(phones, printers, other computers, etc.), but i've not worked with bluetooth in Java before... Help me to find starting point, pls. What SDKs or libraries i must download first? What literature to read?

I've googled BlueCove but it doesn't support my Samsung D600 so i could not test my app...

+1  A: 

I'd say start here: http://www.javabluetooth.com/

It contains TONS of resources and links to further resources, both paid and for free.

http://www.javabluetooth.org/ Here is a free implementation of the Bluetooth specification. It however does not support javax.obex

AlbertoPL
+5  A: 

This java sample will discover all visible devices, and it works with both the BlueCove and Avetana libraries ( http://www.avetana-gmbh.de/avetana-gmbh/produkte/jsr82.eng.xml ):

http://www.jsr82.com/jsr-82-sample-device-discovery/

Brad Brown
+1  A: 

Bluecove tends to be the best supported lib, however, you will find that the various underlying native bluetooth stacks on Windows vary dramatically in quality. The native Windows stack is only marginally supported by the Java APIs. BlueSoleil is slightly better, and Widcomm is generally the preferred.

However, neither BlueSoleil nor Widcomm are free if they didn't come with your adapter, though Widcomm can be hacked to work with non-officially supported adapters. The big limitation with it is that Bluecove does not support Widcomm on 64bit Windows.

Personally, I ended up just using Linux for Bluetooth development as it all just works there. :) I have not tried Avetana at all.

jsight
oh, i'm real noob in bluetooth ^_^can you pm me on [email protected] or icq:2136013 ?
Olexandr
+1  A: 

Ok, sorry for annoying. I've found an answer and it is BlueCove. After installing additional libs it works perfect on Linux Mint 7 now. Even, not listed in compatibility list Samsung D600 was discovered perfectly. Test program output:

run:
BlueCove version 2.1.0 on bluez
Address: 0006C990021D
Name: hostname-0
Starting device inquiry...
Device discovered: 0015B95BEA0F
INQUIRY_COMPLETED
Device Inquiry Completed. 
Bluetooth Devices: 
1. 0015B95BEA0F (zl0-b0tan)
BlueCove stack shutdown completed
BUILD SUCCESSFUL (total time: 13 seconds)
Olexandr
A: 

hey Olexandr, do you mind contacting me regarding your code test program output of your run on Bluecove. I'm trying to create a Java application which locks the user workstation when the user's cellphone is away from the computer.My mail is [email protected]

Thanks!!

Alfredo
A: 

i want to create Bluetooth application for Desktop since JDK(J2SE) does not contain the bluetooth api JSR-82 compliant. What things are requried for creating appication?

plz give url from where i ca download.......

Vijay
use BlueCove - you can easily find it
Olexandr