Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of C027_Support_Plus_Dialing by
Diff: MDM.cpp
- Revision:
- 77:55788e619858
- Parent:
- 76:f7c3dd568dae
- Child:
- 78:caf0014375cb
--- a/MDM.cpp Mon May 19 13:05:41 2014 +0000 +++ b/MDM.cpp Mon May 19 16:18:29 2014 +0000 @@ -361,10 +361,7 @@ if ((RESP_OK != ret) && (RESP_ERROR != ret)) return false; // Enter PIN if needed - if (_dev.sim == SIM_MISSING) { - ERROR("SIM not inserted\r\n"); - return false; - } else if (_dev.sim == SIM_PIN) { + if (_dev.sim == SIM_PIN) { if (!simpin) { ERROR("SIM PIN not available\r\n"); return false; @@ -376,8 +373,11 @@ RELAX_MS(1000); } } - if (_dev.sim != SIM_READY) + if (_dev.sim != SIM_READY) { + if (_dev.sim == SIM_MISSING) + ERROR("SIM not inserted\r\n"); return false; + } // get the manufacturer sendFormated("AT+CGMI\r\n"); if (RESP_OK != waitFinalResp(_cbString, _dev.manu))