• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

BluetoothStateException

 
Ransika deSilva
Ranch Hand
Posts: 524
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,
We want to write a Java SE application which uses bluetooth as well. I am using netbeans 4.1 as the IDE. I added the JSR 82 jar to the application library. I connected a bluetooth dongle (hardware) to the USB port of the PC. I am tring out the following application.

The application compiles perfectly but when I run the program, I get the following RuntimeException: javax.bluetooth.BluetoothStateException: java.lang.NoClassDefFoundError: com/sun/kvem/jsr082/bluetooth/DiscoveryAgentImpl

Any idea what the problem is. Looking forward for a solution.
Thank you.
Regards.
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
JSR 82 is for J2ME only, there is no Bluetooth API available for Java SE, J2SE.

Using the JSR82 API will not work on your PC.

Mark
 
john kenedi
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I have same problem, But it means we can't have a j2se application to discover our BT devices around?
I don't think so, but still now, I get that exception!!!
Isn't there any Idea?
I read in a forum, someone could do this, with a tiny code, I used that code, too, but same problem!!!

thanks in advance...
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have not heard of any BlueTooth apis yet for J2SE. But I don't hear everything that might be in the open source or commercial third party arenas.

Mark
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic