View previous topic :: View next topic |
Author |
Message |
joof
Joined: 11 May 2012 Posts: 3
|
Posted: Fri May 11, 2012 8:29 pm Post subject: Android application <-> Turbo SIM communication? |
|
|
Is there any way at all that an Android application (running on a stock ROM) can communicate with Turbo SIM? Preferably a way that does not require sending data out towards the network and back. |
|
Back to top |
|
|
pz
Joined: 12 Mar 2004 Posts: 1161
|
Posted: Sat May 12, 2012 6:30 pm Post subject: |
|
|
You can do it using SmsManager public Android API. There are following methods:
make new SMS in SIM storage:
public boolean copyMessageToIcc(byte[] smsc, byte[] pdu, int status);
remove SMS from SIM storage:
public boolean deleteMessageFromIcc(int messageIndex);
update SMS already stored in SIM storage:
public boolean updateMessageOnIcc(int messageIndex, int newStatus, byte[] pdu);
With these you can read/write to a SMS record. In Turbo SIM register EF_SMS and process the request accordingly. See e.g. secure/procsms app source for this. |
|
Back to top |
|
|
joof
Joined: 11 May 2012 Posts: 3
|
Posted: Sun May 13, 2012 4:03 pm Post subject: |
|
|
Thanks a bunch for the pointer. I do wish there were a way to do this with the official SDK, and not hidden functions that are not guaranteed to work :-/ I wonder why Android is so insistent on removing access to basic SIM functionality. |
|
Back to top |
|
|
pz
Joined: 12 Mar 2004 Posts: 1161
|
Posted: Mon May 14, 2012 6:48 am Post subject: |
|
|
There is work on some official API(s), it will be even more needed while NFC is more deployed. This SmsManager works and has to be there until Android wants to have SMS on SIM.
And on Android nothing seems to be guaranteed to work in longer tern anyway :-/ |
|
Back to top |
|
|
joof
Joined: 11 May 2012 Posts: 3
|
Posted: Mon May 14, 2012 11:56 am Post subject: |
|
|
Until then we can only deploy and pray Thank you again! |
|
Back to top |
|
|
|