While doing a project on GSM based energy meter billing system, Students came up with a requirement that the system should be able to detect if the SIM card has been inserted in GSM modem or not.
The idea was, if the customer removes the SIM card from GSM modem then the power supply should be disconnected. SIM300 GSM modem was used in the project to send and receive SMS. I am sharing the details of the command i found on SIM300 datasheet.
AT Command to detect SIM card in GSM modem :
SIM300 provides AT command to detect whether SIM card has been inserted or not.
+CSMINS: 0,1 - if SIM card is inserted or present
+CSMINS: 0,0 - if SIM card is removed or not present
As soon as you issue the "AT+CSMINS? "command, The SIM300 modem will respond with " +CSMINS: 0,1 " if the SIM card has been inserted, or responds with " +CSMINS: 0,0 " if the SIM card has not been inserted.
Decoding the response :
As you see that the response from the SIM300 modem for SIM card presence command is the digit after the ','(comma) character. So if you are using a microcontroller to talk to the GSM modem then your program must look for the ',' character and the next character to it will be your answer.
Also see :
- SIM300 SMS/Call Not Working
- SIM300 SMS and Call Commands
- Mobile DDR / mDDR / Low Power DDR / LPDDR
- Where to buy electronics components in India?