 |
bladox.com Turbo SIM Toolkit Adapter Forums
|
View previous topic :: View next topic |
Author |
Message |
mitchy_g Guest
|
Posted: Wed Jan 04, 2006 12:12 pm Post subject: Reading SMS data |
|
|
Hi,
I want to somehow get information from an sms that was recieved, my code has the following:
Called when a sms is recieved
Code: |
case ACTION_SMS:
stk_thread(message_rec, data);
|
This is the signature of the function i have that wants to get information from the sms recieved. Is this correct?
Code: |
void message_rec (File_apdu_data *fd)
|
If all is ok, how can i go about extracting such things as the message text from the data passed ot the function?
Thanks
Mitch |
|
Back to top |
|
 |
pz Guest
|
Posted: Thu Jan 05, 2006 11:57 am Post subject: |
|
|
Please look at source of e.g. pager, it's used there.
u8 * data=fd->data points on the actual SMS received as being stored to EF_SMS (see 11.11), skip 1 byte (state), few bytes SMSC (first bytes is the length to skip) and you are at the beginning of TPDU itself. There is tpdu_seek() to get to the position of needed data (e.g. the text itself). |
|
Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|