You Are Here:

Community: Developer Discussion Boards

Reply « Previous Thread | Next Thread »

#1 Old Nokia phones and WAP Java downloads - 2003-09-12, 14:44

Join Date: Mar 2003
Posts: 11
dmj2000
Offline
Registered User
Hi,

I have made some simple Java demos, which I have tested on my emulators, and works fine for 3410 and 7210. And also on my Motorola T720i.

So, with that side sorted, I developed a WAP site, and created links to my .jad/jar files.

Now on my Motorola T720i, it works great. It shows the description file, and then downloads and installs.
However on the Nokia 3410 (only phone I have to test with), it comes up with file format unknown. On the actual site location of the physical files, I have include a .htaccess file that adds the java types, and still no joy.

Has any done this and got it to work? And if so, who hosted the site?

I can't believe that Motorola has made its phones easier than Nokia to help developers.

Regards

DMJ
Reply With Quote

#2 Old 2003-09-13, 21:09

Join Date: Jun 2003
Posts: 4,325
Location: Cheshire, UK
grahamhughes's Avatar
grahamhughes
Offline
Forum Nokia Champion
I'm using hosting from www.plugsocket.com, and can download onto my Series 40 phone without problem.

If you send me your URL, I'd be happy to try a download to my phone (6100) as a test.

Graham.
Reply With Quote

#3 Old 2003-09-16, 11:28

Join Date: Mar 2003
Posts: 11
dmj2000
Offline
Registered User
Thanks a lot, its just a simple example.
But not much point in going further, if it only works on Motorola phones.


http://www.damaja.co.uk/wap/j2me/helloex.jad



regards

DMJ2000
Reply With Quote

#4 Old 2003-09-17, 02:42

Join Date: Jun 2003
Posts: 4,325
Location: Cheshire, UK
grahamhughes's Avatar
grahamhughes
Offline
Forum Nokia Champion
Yup, I get a "File Format Unknown" too. The response sent by the server has the content-type "text/html" and the status code 302... this is a redirection to another page (http://www23.brinkster.com/d4maja/wap/j2me/helloex.jad). If you follow the redirection, you do get the JAD file content, but with the content-type "application/octet-stream".

I don't know if the phone is following the redirection or not... either way it's not getting the right content-type.

(I'm a bit surprised that nothing minds the "MIDP-2.0" in your JAD... presumably nothing checks this, in which case, why do we have to put it in???)

I have no idea about setting up content-type mappings on Apache... tech support sorted mine out for me, so maybe you need to ask your local equivalent.

Graham.
Reply With Quote

#5 Old 2003-09-17, 13:28

Join Date: Mar 2003
Posts: 11
dmj2000
Offline
Registered User
Thanks.

I'll have a word with TS.
Reply With Quote

#6 Old 2003-09-17, 14:20

Join Date: Mar 2003
Posts: 88
dima_boul
Offline
Regular Contributor
I've took a look on your .jad file

-----------------------------------
MIDlet-Name: HelloEx
MIDlet-Version: 0.0.1
MIDlet-Vendor: Badboy Inc
MicroEdition-Profile: MIDP-2.0
MicroEdition-Configuration: CLDC-1.0
MIDlet-Jar-URL: HelloEx.jar
MIDlet-Jar-Size: 1529
MIDlet-1: HelloEx, , Hello_Project.HelloEx
------------------------------------


one more like manifest file, because it contained such lines as

MicroEdition-Profile: MIDP-2.0
MicroEdition-Configuration: CLDC-1.0


Nokia device could not understand this sting and as result said "File Format Unknown", as well they could not understand "MIDP-2.0".

I've got inversly problem, my test midlet dowloaded on Nokia phones well, but if i try download it on Mot-720 one is hanging

regards Dima
Reply With Quote

#7 Old 2003-09-17, 14:32

Join Date: Mar 2003
Posts: 11
dmj2000
Offline
Registered User
Thanks,

Gets a little confusing though, as I have taken those lines out,
and now on my T720, it says unsupported version.

But I will keep on investigating.

In regards to your question about freezing. Is there anything in your app/game that refers to a phone specific (Nokia only) library? If so, this may cause a problem on non nokia phones.


regards,

DMJ


PS. Does anyone have an example file on a wap site that I can test.
Reply With Quote

#8 Old 2003-09-17, 14:42

Join Date: Jun 2003
Posts: 4,325
Location: Cheshire, UK
grahamhughes's Avatar
grahamhughes
Offline
Forum Nokia Champion
You do need to specify:

MicroEdition-Profile: MIDP-1.0
MicroEdition-Configuration: CLDC-1.0

in your manifest, but they should be optional in the JAD. If the T720 wants them in the JAD, there should be no harm in leaving them. Remember that your current line says "MIDP-2.0", which the 3410 and 7210 won't support.

Graham.
Reply With Quote

#9 Old 2003-09-17, 15:38

Join Date: Mar 2003
Posts: 11
dmj2000
Offline
Registered User
I admit now, I am confused.

I was using WTK 2.0, hence the JAD file with 2.0 in it.
I have now dropped down to an earlier version, and confusion has set in.
It creates the jad and jar files, but also this MANIFEST.MF
What am I to do with that?
Reply With Quote

#10 Old 2003-09-17, 15:48

Join Date: Mar 2003
Posts: 11
dmj2000
Offline
Registered User
Sorry to be a pain, but can anyone with any other phone than a Motorola T720i just try it to see if it works.

I just find it hard to believe that I have no problems with Motorola, and every other manufacturer fails.

regards,

DMJ2000

PS. url is
http://www23.brinkster.com/d4maja/wap/j2me/helloex.jad
Reply With Quote

#11 Old 2003-09-17, 16:21

Join Date: Mar 2003
Posts: 88
dima_boul
Offline
Regular Contributor
I try donload simple application "helloworld" from JBuilder's examples? and one does not uploaded on 720 (not i), just frozen.

I also tried your link, my Nokia 7650 said "WAP: replay unknown", and in your jad still are lines

MicroEdition-Profile: MIDP-2.0
MicroEdition-Configuration: CLDC-1.0
Reply With Quote

#12 Old 2003-09-17, 16:47

Join Date: Mar 2003
Posts: 11
dmj2000
Offline
Registered User
you might need to refresh or clear the cache, as I have uploaded a new version.

You may need to use the othe url:
http://www.damaja.co.uk/wap/j2me/helloex.jad

or just W@P:
http://www.damaja.co.uk
in the JAVA GAMES (hopeful) section.

I still can't believe its this difficult to download JAVA.
Reply With Quote

#13 Old 2003-09-17, 21:55

Join Date: Jun 2003
Posts: 4,325
Location: Cheshire, UK
grahamhughes's Avatar
grahamhughes
Offline
Forum Nokia Champion
MANIFEST.MF goes in your JAR file. All application JARs have a manifest file... it tells the VM a bit about the application, particularly which class is the "main" class of the app (contains the main() method for J2SE, or is an instantiable subclass of MIDlet for MIDP).

Your JAD and JAR contents are fine. (Both refer to a HelloEx.png, which you don't have in the JAR, but the phone doesn't seem to mind.) As a side issue... you will find that the 7210 emulator will run programs that the real phone won't, unless you start it with the "-provisioning" option:

7210.exe -provisioning helloex.jad

Only in provisioning-mode does it perform all the same checks on the JAD and JAR as the real phone. Anyhoo, I downloaded the files and installed them to my 6100 by IR using the Application Installer. It works fine.

But it doesn't download by WAP. It won't, as long as the server insists on saying that both files are "application/octet-stream". Presumably the Motorola phone will make assumptions beyond the content-type it's told, and the Nokia phone won't.

It will download fine once you have the correct content-types configured on the server.

Graham.
Reply With Quote

#14 Old 2003-09-18, 10:41

Join Date: Mar 2003
Posts: 11
dmj2000
Offline
Registered User
Graham,

as I don't have a 7210, can you just tell me, what is this Application Installer?

I have a friend, who has the 7210, but not really that clued up with the technology. But I would like to try out this ir stuff.

Is it free with the phone, or where is it sourced from.

regards




DMJ2000
Reply With Quote

#15 Old 2003-09-18, 13:24

Join Date: Jun 2003
Posts: 4,325
Location: Cheshire, UK
grahamhughes's Avatar
grahamhughes
Offline
Forum Nokia Champion
Sorry. The Application Installer is one of a set of bits that comes on a CD with the phone. There are also tools for backing up your phone book, that kind of thing. The AI lets you choose a JAD from your hard disk, and installs it (and the JAR to which it refers) to the phone... it can do this by IR (if you have IR), or cable (if you have cable). (If you have neither IR nor cable, you just have to close your eyes and imagine.)

I find that if I install using the AI, I can't install upgrades... it won't install anything if there is a MIDlet already there with the same name, even if the one you're installing has a newer version number. Installing upgrades Over-The-Air works fine, as long as you installed OTA in the first place.

Graham.
Reply With Quote
Reply « Previous Thread | Next Thread »
Display Modes
Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
[IMG] code is Off
HTML code is Off
Forum Jump

Rate This

 
Bookmark this page: DeliciousDiggFacebookGoogleYahooStumbleUponRedditDiigoTechnocratiTwitter  Share this page Share this page Print this Page Print this page Invite a friend Invite a friend
京ICP备05048969号    Email Newsletters Press Terms & Conditions Privacy Policy Sitemap Contact Us © 2009 Nokia