Служба SMS для приложения отслеживания J2ME

Я создал приложение J2ME для отслеживания всех водителей грузовиков, зарегистрированных в моей организации, по их идентификатору сотовой связи. Приложение каждые полчаса будет отправлять нам SMS с LAC, MCC, MNC, Cell ID соответствующего водителя (чтобы узнать об их текущем местонахождении) и сохранять его в виде CSV в нашем листе DB/Excel.

Теперь проблема, с которой я столкнулся, заключается в том, что после установки приложения на любой S40 / S60 с поддержкой Java, как я могу заставить работать архитектуру интерфейса, то есть как я могу продолжить, чтобы приложение извлекло детали и отправило SMS на наш предопределенный номер ?

Причина вопроса в том, что меня немного смущает это утверждение «Мы не можем получать SMS на стандартный порт с JAVA ME». Означает ли это, что мы действительно не можем получать SMS-сообщения?

Это то, что у меня есть в настоящее время только для устройств Nokia:

/**
 * get the cell id in the phone
 * 
 * @return
 */
public static String getCellId(){
    String out = "";
    try{

        out = System.getProperty("Cell-ID");
        if(out== null ||out.equals("null")|| out.equals(""))
            out = System.getProperty("com.nokia.mid.cellid");
        #endif

    }catch(Exception e){
        return out==null?"":out;
      }

    return out==null?"":out;
}

/**
 * get the LAC string from phone
 */
public static String getLAC(){
    String out = "";
    try{

        out = System.getProperty("phone.lac");
        if(out== null ||out.equals("null")|| out.equals(""))
            out = System.getProperty("com.nokia.mid.lac");
        #endif

    }catch(Exception e){
        return out==null?"":out;
    }

    return out==null?"":out;
}

/**
 * get the IMSI string from phone
 */

public static String getIMSI(){
    String out = "";
    try{

        out = System.getProperty("IMSI");
        if(out== null ||out.equals("null")|| out.equals(""))
            out = System.getProperty("com.nokia.mid.mobinfo.IMSI");
        if(out== null ||out.equals("null")|| out.equals(""))
            out = System.getProperty("com.nokia.mid.imsi");
        #endif

    }catch(Exception e){
        return out==null?"":out;

        }

    return out==null?"":out;
}


/**
 * get the MCC string from phone
 */

public static String getMCC(){
    String out = "";
    try{

        if(out== null ||out.equals("null")|| out.equals(""))
            out = System.getProperty("com.nokia.mid.mobinfo.IMSI");
        #endif

    }catch(Exception e){
        return out==null?"":out;
    }

    return out==null?"":out;
}

/**
 * get the MNC string from phone
 */
public static String getMNC(){
    String out = "";
    try{

        if(out== null ||out.equals("null")|| out.equals(""))
            out = getIMSI().equals("")?"": getIMSI().substring(3,5);
        #endif

    }catch(Exception e){
        return out==null?"":out;
    }

    return out==null?"":out;
}

person Debarun Pal    schedule 22.07.2014    source источник
comment
Это правда, что вы не можете получать SMS на стандартный порт. Но вы можете отправить SMS на любой порт, включая стандартный порт. (Это означает, что получатель получит SMS в свой почтовый ящик). stackoverflow.com/questions/13225426/   -  person mr_lou    schedule 23.07.2014
comment
Спасибо. Это помогает частично.   -  person Debarun Pal    schedule 23.07.2014