×

Discussion Board

Results 1 to 2 of 2

Hybrid View

  1. #1
    Registered User
    Join Date
    Aug 2010
    Posts
    2

    Issue in getting LAC - cell informations on Nokia E72

    Hi All,

    I want to get the following parameters in Nokia E72 [series 60 FP2]mobile set:-
    1. CelliD 2. LAC 3. MCC 4.MNC

    I tried the following code on E72 device but not able to get LAC.


    package cms.gps;
    public class NetworkCredentials {
    public String cellID = "";
    public String lac = "";
    public String mcc = "";
    public String mnc = "";
    public String imsi = "";


    public NetworkCredentials()
    {
    updateCredentials();
    }

    private void updateCredentials()
    {
    updateForDefault();
    UpdateNokiaCredentials();
    }


    private void updateForDefault()
    {
    //cell id
    cellID = System.getProperty("Cell-ID");
    if( cellID == null || cellID.equals("null") || cellID.equals("")){
    cellID = System.getProperty("CellID");
    }
    if( cellID == null || cellID.equals("null") || cellID.equals("")){
    cellID = System.getProperty("phone.cid");
    }

    //lac
    lac = System.getProperty("phone.lac");

    //imsi
    imsi = System.getProperty("IMSI");
    if( imsi == null || imsi.equals("null") || imsi.equals("")){
    imsi = System.getProperty("phone.imsi") ;
    }

    //mcc
    mcc = System.getProperty("phone.mcc") ;

    //mnc
    mnc = System.getProperty("phone.mnc") ;
    }

    private void UpdateNokiaCredentials()
    {
    //cellid
    if( cellID == null || cellID.equals("null") || cellID.equals("")){
    cellID = System.getProperty("com.nokia.mid.cellid");
    }

    //lac
    if( lac == null || lac.equals("null") || lac.equals("")){
    lac = System.getProperty("com.nokia.mid.lac");
    }

    //imsi
    //imsi = System.getProperty("IMSI");
    if( imsi == null || imsi.equals("null") || imsi.equals("")){
    imsi = System.getProperty("com.nokia.mid.mobinfo.IMSI");
    }
    if( imsi == null || imsi.equals("null") || imsi.equals("")){
    imsi = System.getProperty("com.nokia.mid.imsi");
    }

    //mcc
    if( mcc == null || mcc.equals("null") || mcc.equals("")){
    mcc = System.getProperty("com.nokia.mid.countrycode");
    }

    //mnc
    if( mnc == null || mnc.equals("null") || mnc.equals("")){
    if(imsi!= null && !imsi.equals("")){
    mnc = imsi.substring(3,5);
    }
    }
    if( mnc == null || mnc.equals("null") || mnc.equals("")){
    mnc = System.getProperty("com.nokia.mid.mnc");
    }
    if( mnc == null || mnc.equals("null") || mnc.equals("")){
    mnc = System.getProperty("com.nokia.mid.networkID");
    }
    if( mnc == null || mnc.equals("null") || mnc.equals("")){
    mnc = System.getProperty("com.nokia.mid.networkid");
    }
    }
    }

    I tried code for Samsung JET device and got the value of LAC properly
    The code I tried on Samsung is :-

    package cms.gps;
    public class NetworkCredentials {
    public String cellID = "";
    public String lac = "";
    public String mcc = "";
    public String mnc = "";
    public String imsi = "";




    public NetworkCredentials()
    {
    updateCredentials();
    }

    private void updateCredentials()
    {
    updateForDefault();
    updateSamsungsCredentials();
    }



    private void updateForDefault()
    {
    //cell id
    cellID = System.getProperty("Cell-ID");
    if( cellID == null || cellID.equals("null") || cellID.equals("")){
    cellID = System.getProperty("CellID");
    }
    if( cellID == null || cellID.equals("null") || cellID.equals("")){
    cellID = System.getProperty("phone.cid");
    }

    //lac
    lac = System.getProperty("phone.lac");

    //imsi
    imsi = System.getProperty("IMSI");
    if( imsi == null || imsi.equals("null") || imsi.equals("")){
    imsi = System.getProperty("phone.imsi") ;
    }

    //mcc
    mcc = System.getProperty("phone.mcc") ;

    //mnc
    mnc = System.getProperty("phone.mnc") ;
    }




    private void updateSamsungsCredentials()
    {
    //cellid
    if( cellID == null || cellID.equals("null") || cellID.equals("")){
    cellID = System.getProperty("com.samsung.cellid");
    }
    if( cellID == null || cellID.equals("null") || cellID.equals("")){
    cellID = System.getProperty("CELLID");
    }

    //lac
    if( lac == null || lac.equals("null") || lac.equals("")){
    lac = System.getProperty("com.samsung.cellid");
    }
    if( lac == null || lac.equals("null") || lac.equals("")){
    lac = System.getProperty("LAC");
    }

    //imsi
    //no special code for it

    //mcc
    //no special code for it @vishal
    if( mcc == null || mcc.equals("null") || mcc.equals("")){
    mcc = System.getProperty("MCC");
    }

    //mnc
    //no special code for it @vishal
    if( mnc == null || mnc.equals("null") || mnc.equals("")){
    mnc = System.getProperty("MNC");
    }
    }
    }
    I will appreciate if someone let me know the reason why i am not able to get the value of LAC in case of nokia device.

    Thanks
    Peeyush

  2. #2
    Nokia Developer Moderator
    Join Date
    Mar 2003
    Location
    Lempäälä/Finland
    Posts
    29,143

    Re: Issue in getting LAC - cell informations on Nokia E72

    No need to multipost, I suppose you already noticed that it is better to ask under the technology you want to use: http://discussion.forum.nokia.com/fo...okia-series-60

Similar Threads

  1. Replies: 12
    Last Post: 2012-11-30, 06:57
  2. Nokia E72-1 transceiver issue
    By the_real_techsolo in forum General Development Questions
    Replies: 3
    Last Post: 2010-09-26, 15:00
  3. Cell Id and LAC Information
    By shyam9 in forum Symbian Networking & Messaging (Closed)
    Replies: 10
    Last Post: 2010-06-22, 07:34
  4. E72 Nokia Email messaging Service Issue - please help!!
    By alirazafazal in forum General Development Questions
    Replies: 2
    Last Post: 2010-01-11, 13:01
  5. Symbian API to get Cell ID and LAC for Nokia mobile...
    By SanjayKhuntia in forum Symbian Tools & SDKs
    Replies: 6
    Last Post: 2008-08-12, 09:34

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •