JSR082 - LocalDevice.getLocalDevice() returns null

1k Views Asked by At

Using JSR082_1.1.jar from Java Wireless Toolkit 3.0,
I'm trying to get the local device (for later discovery of others)
but i keep getting null for the call LocalDevice.getLocalDevice()

while in the docs they say this method cannot return null... docs

My bluetooth is ON, checked on 2 computers (Win7 & OSX 10.6)

Help! Thanks

1

There are 1 best solutions below

1
On BEST ANSWER

I believe the JSR-82 JAR file distributed with the Wireless Toolkit contains only the interfaces, not a working implementation of the Bluetooth API. This allows you to compile code that uses JSR-82 but not to test it.

You should get a copy of Bluecove, a free implementation of JSR-82 you can run on the desktop. Make sure you're using the 32-bit JVM, though (use the -d32 command line argument).