[x]
Posted via EE Mobile

Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again.

Question
[x]
Attachment Details

Run a proactive command on a SIM toolkit applet when invoked from a midlet with JSR177-APDU

Asked by lcguedesphd in Global System for Mobile Communications (GSM), Java 2 Micro-Edition (J2ME)

Tags: SIM toolkit, JSR177-APDU

Hi,

I need to run a proactive command on a toolkit applet when invoked from a midlet with JSR177-APDU.

I have written a simple applet that runs perfectly when called from the menu but when I send an APDU from my Midlet, it is received by process(apdu) fucntion but there is no proactive handler available at this time. Then I register to receive EVENT_PROACTIVE_HANDLER_AVAILABLE events, but they never come!

Although it is not related to NFC usage, I tried the code from http://developer.gemalto.com/home/nfc/nfc-applet-development/use-of-stk-for-contactless.html with an APDU sent by my midlet but the toolkit event never arrives on my processToolkit(event) funcion.


My apdu is an envelope APDU with an arbitrary TLV (0x4E):

A0 C2 00 00 09 4E 07 12 34 56 78 90 12 34

Actually, before noticing that the process(apdu) function was called, I thought that sending this apdu to the applet would trigger the toolkit EVENT_UNRECOGNIZED_ENVELOPE event. But it didn't. I do not know if 4E is a recognized value, but this is also an event that never arrived for me.

Am I missing something or am I trying to do something that is not supported? I must say that it does not seem to me to be an extraordinay thing an applet being able to run a proactive command when invoked from a midlet. It must have a solution!

Any help or suggestions will be really appreciated.

Thanks in advance,

Luiz.
 
Loading Advertisement...
20091111-EE-VQP-92 - Hierarchy / EE_QW_3_20080625