This discussion is archived
3 Replies Latest reply: Mar 28, 2012 5:34 PM by 922951 RSS

How can an app know when the phone has a data connection?

889589 Newbie
Currently Being Moderated
I'm developing a SIM Tookit app which needs to do an 'automatic' Launch Browser (i.e. NOT triggered by a user menu) sometime shortly after the phone starts up. Obviously it needs a data connection (GPRS, HSCSD…) to work properly, but how can my app know when the data connection is active? Any ideas anyone?
I'm currently using a Timer Management command to set up a 20(ish) second delay which is usually long enough for the phone to establish it's data connection. However this is not ideal as a) it's not a reliable technique and b) Timers are not a well supported/implemented feature in many phones.
Is there a better way of ensuring a data connection before issuing Launch Browser, alternatively is there a way of implementing a reliable delay without using Stk timers?
  • 1. Re: How can an app know when the phone has a data connection?
    922951 Newbie
    Currently Being Moderated
    Dear Tim ,
    Peace upon you ,

    I think you need to read the BIP part in the Interoperability Stepping Stones document issued by SIMAlliance.

    the event you need to register your applet with it is EVENT DOWNLOAD – Data available.


    If the applet is registered to this event (through the ToolkitRegistry.setEvent() method), and once the
    targeted channel buffer is empty when new data arrives in it, the ME informs the UICC that this has occurred, by using
    the ENVELOPE (EVENT DOWNLOAD – Data available).


    Hope to be useful.


    BR
    Nabil
  • 2. Re: How can an app know when the phone has a data connection?
    889589 Newbie
    Currently Being Moderated
    Hi Nabil
    You are of course correct. Thank you for your prompt reply.
    Unfortunately I'm targetting Android phones, which generally have very limited SIM Toolkit support - and certainly not the data commands (Open Channel etc) :-(
  • 3. Re: How can an app know when the phone has a data connection?
    922951 Newbie
    Currently Being Moderated
    Hi Tim ,

    Peace upon you.

    In document i mentioned it above under section 16.3.4 which titled with "Terminal Profile indication for BIP" you will find next:

    The ME indicates support of the BIP commands and events as well as the relevant network capabilities in its Terminal Profile.

    According to ETSI TS 102 223 the BIP commands are separated into 2 classes, class “e“ and “f“, which can be found in the Terminal Profile Bytes of the ME:(GO to read the mentioned section)

    Hope to be useful inshALLAH

    Best Regards
    Nabil

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points