Calling j2me methods from a jcvm
Hi!
is there anybody who knows if there is a chance to call j2me methods from a jcvm (or if anybody heard that it will be possible in some future release of javacard and j2me).
In an application context the question is: It is possible or it will be possible to call applications residing on a consumer device using javacard applets residing on a smartcard ?
Thanx in advance to everybody
[419 byte] By [
gdamilano] at [2007-9-26 2:54:34]

did you ever find out anything about having j2me communicate with jcvm, i'm trying to make a reader currently that runs on j2me and try to make it communicate with a java card, found some success and some problems, any suggestions.
narian at 2007-6-29 10:44:10 >

To respond to the initial question: With a card complying to the Java Card standard (2.1.x or 2.2.x) and no vendor-specific extension that would do that it is not possible.
Java Cards and smartcards in general are passive - they wait for a command, process it and return a result. The card can not on it's own send requests to the terminal.
If you design for 2.2.x compliant cards, you have RMI support which allows you to transparently invoke methods on the card from a terminal application but not the other way around.
If you really need to invoke a method of the terminal application from the card applet, you have to code this yourself. This is easiest done by splitting a given task on the card into subtasks that require a separate APDU each. Between sending the APDUs you invoke the methods in the application. The result of the previous APDU exchange could even return an indication which method to invoke.
You must however very carefully consider the security implications.