Browse Source

Set CFUN in Sequans init - else fails

Signed-off-by: Sara Damiano <sdamiano@stroudcenter.org>
v_master
Sara Damiano 5 years ago
parent
commit
033092f8fe
1 changed files with 7 additions and 0 deletions
  1. +7
    -0
      src/TinyGsmClientSequansMonarch.h

+ 7
- 0
src/TinyGsmClientSequansMonarch.h View File

@ -210,6 +210,13 @@ public:
DBG(GF("### Modem:"), getModemName());
// Make sure the module is enabled. Unlike others, the VZN20Q powers on
// with CFUN=0 not CFUN=1 (that is, at minimum functionality instead of full functionality
// The module cannot even detect the sim card if the cellular functionality is disabled so
// unless we explicitly enable the functionality the init will fail.
sendAT(GF("+CFUN=1")); // turn off error codes
waitResponse();
int ret = getSimStatus();
// if the sim isn't ready and a pin has been provided, try to unlock the sim
if (ret != SIM_READY && pin != NULL && strlen(pin) > 0) {


Loading…
Cancel
Save