Search code examples
javaat-commandjavax.commsim-card

Finding out SIM card operator


My JAVA program can find a modem connected with serial port. Like:

COM1: Serial
COM3: Serial  // This is my modem
LPT1: Parallel
LPT2: Parallel

Is there any AT Command or other process which can help me to find out the operators identity (name), who's SIM is being used in the modem?


Solution

  • The command for finding out which network you are registered on is

    AT+COPS?
    

    On mine, that outputs

    +COPS: 0,0,"giffgaff",2
    

    Where the string in the quotes is the operator's name.