What are the things do i need so that i can develop bluetooth programs on a mobile phone(NOKIA)?
I have downloaded WTK2.1 but it says it does not have JSR-82 support.. But i have the JSR-82 source files, so i was wondering if i could just compile those source files and i can get bluetooth up and running with my program just like that.
Now there is WTK2.2 beta and it has JSR-82 support in it already.. But the problem is i'm using EclipseMe plugin for Eclipse but it doesn't have WTK2.2 support yet..
So can i just compile the java source files of JSR-82 and i can use bluetooth already in my programs? I tried to compile the source files but then when i run the program, with bluetooth functions in it, it caughts an exception: "NoClassDefFoundError"..
Or should I have to use WTK2.2 and change to another IDE?
The JSR 82 "source code" is only the interface to bluetooth. It does not contain any implementation. So, it is completely useless to compile them. To use bluetooth with WTK, you have to upgrade to v2.2 and above.
Put the JSR-82 stub files you have into the class path and compile. You should be able to run it then on your Nokia mobile phone. But please remember - currently only these two Nokia mobile phones Nokia 6600 and Nokia 6230 support JSR-82 and do not include these stubs into the JAR. There are not muc more which do at the moment (Siemens SX1, Sony Ericsson P900 both with latest firmware) but there are coming a lot more this year.
You do not need any Bluetooth implementation within these stubs. But then you have to do all your testing on a real device. If you want to test your Bluetooth application, I recommend either the WTK 2.2 or a J2ME emulator from Nokia. Personally I work with the Nokia 6230/6600/9500 Concept SDKs under Linux and EclipseME successfully.
The Windows version from Nokia allow even more features.
In my small experince EclipseME is great for the start but it makes not very good real MIDP apps in the output. In my case I had to enable Java 1.1 compatible class generation, manually redoing the preverifying and package the JAR correctly. Even the outputed MANIFEST.MF is wrong according to MIDP 1.0 specification. Anyway I use it. :roll: [ July 10, 2004: Message edited by: Alexander Traud ]
EclipseME makes not very good JAR files. The classes are not preferified sometimes (have not figured out why yet), it is not compiled with Java 1.1 compatible byte code (can be fixed via the project settings or better via the preferences of Eclipse) and the JAR is filled with unnecessary files (I see no possible solution for this). I read the full documentation - perhaps I am too stupid. Anyway the JAD and the MANIFEST file need fine tuning, so I have to repackage it anyway.
EclipseME is great for the developing and debugging phase but when it comes to the final release, you'll have to go over it manually.
But I think my next (very) big J2ME project will be made within a text editor and the command line utilities. Eclipse is too slow here and sometimes the behaviour is obscure. [ July 11, 2004: Message edited by: Alexander Traud ]
Javac is javac. The classes won't get better in an IDE nor do they get worse. It depends on the javac options. Compiling was no problem yet.
How to do it manually? You know the command prompt and "jar" and "preverify"? These command line utilities are your way. Look at their parameters and you will find it. "preverify" does not need an option, just the file and your classpath. "jar" needs several options. Just look for a reference on the net or look into their help pages. I can't give a "general" rule here - it is just passing the right paramters to these apps.
Dude i have another question to you since you are using EclipseMe also.. and noone is answering my post regarding this topic.. hehe
Ahm, im trying out the Series40 SDK(Nokia) with EclipseMe.. I made a simple HelloWorld MIdlet, it supposed to display a "hello world" text.. When I tried to run it thru the Run menu of Eclipse, the 6230 emulator appears, but after a while the emulator will give an error message "Invalid File".. and the midlet doesn't run..
What does this mean?
I tried to run this midlet using a different wireless toolkit(Suns J2ME wireless toolki) and its runs ok..
I recommend to buy a book about Java 2 Micro Edition (J2ME) and CLDC/MIDP. Over the air is done via WAP/HTTP connection. With the Nokia Content Copier you can load your MIDlet via cable, infrared and Bluetooth to your phone. The Nokia SDK even contains this application - it was installed while it installed the emulator...
Nokia Forum has a lot and extremly good documentation about J2ME, too.
Your other question is too "generic". It could be nearly everything. You read the outstanding EclipseME documentation? You have the latest version(s)?
I just posted to the EclipseMe mailing list and apparently its a bug when integrating EclipseMe and Series40 SDK.. What i'm doing now is im just compiling with EclipseMe, and then i'm emulating it and creating a package with Nokia Developer Suite..