Skip to content

Commit

Permalink
Add syslog
Browse files Browse the repository at this point in the history
Signed-off-by: Sara Damiano <[email protected]>
  • Loading branch information
SRGDamia1 committed Jan 20, 2025
1 parent ccbf266 commit c6b5347
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/TinyGsmClientEspressif.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,14 @@ class TinyGsmEspressif : public TinyGsmModem<EspressifType>,
}
thisModem().sendAT(GF("E0")); // Echo Off
if (thisModem().waitResponse() != 1) { return false; }

#ifdef TINY_GSM_DEBUG
thisModem().sendAT(GF("+SYSLOG=1")); // turn on verbose error codes
#else
thisModem().sendAT(GF("+SYSLOG=0")); // turn off error codes
#endif
thisModem().waitResponse();

thisModem().sendAT(GF("+CIPMUX=1")); // Enable Multiple Connections
if (thisModem().waitResponse() != 1) { return false; }
thisModem().sendAT(GF("+CWMODE=1")); // Put into "station" mode
Expand Down Expand Up @@ -136,7 +144,7 @@ class TinyGsmEspressif : public TinyGsmModem<EspressifType>,

// Gets the modem firmware version
String getModemRevisionImpl() {
thisModem().sendAT(GF("GMR")); // GMR instead of CGMR
thisModem().sendAT(GF("+GMR")); // GMR instead of CGMR
String res;
if (thisModem().waitResponse(1000L, res) != 1) { return ""; }
thisModem().cleanResponseString(res);
Expand Down

0 comments on commit c6b5347

Please sign in to comment.