diff --git a/src/TinyGSM.h b/src/TinyGSM.h new file mode 100644 index 0000000..850e346 --- /dev/null +++ b/src/TinyGSM.h @@ -0,0 +1,6 @@ +#ifndef TINYGSM_H +#define TINYGSM_H + +#include "TinyGsmClient.h" + +#endif diff --git a/src/TinyGsmClientUBLOX.h b/src/TinyGsmClientUBLOX.h index 6a95a6d..da547b2 100644 --- a/src/TinyGsmClientUBLOX.h +++ b/src/TinyGsmClientUBLOX.h @@ -224,7 +224,6 @@ class TinyGsmUBLOX : public TinyGsmModem, res2.trim(); String name = res1 + String(' ') + res2; - DBG("### Modem:", name); if (name.startsWith("u-blox SARA-R4") || name.startsWith("u-blox SARA-N4")) { DBG("### WARNING: You are using the wrong TinyGSM modem!"); @@ -272,6 +271,29 @@ class TinyGsmUBLOX : public TinyGsmModem, return (RegStatus)getRegistrationStatusXREG("CGREG"); } + bool setRadioAccessTecnology(int selected) { + // selected: + // 0: GSM / GPRS / eGPRS (single mode) + // 1: GSM / UMTS (dual mode) + // 2: UMTS (single mode) + // 3: LTE (single mode) + // 4: GSM / UMTS / LTE (tri mode) + // 5: GSM / LTE (dual mode) + // 6: UMTS / LTE (dual mode) + // preferred: + // 0: GSM / GPRS / eGPRS + // 2: UTRAN + // 3: LTE + sendAT(GF("+URAT="), selected, GF(","), preferred); + if (waitResponse() != 1) { return false; } + return true; + } + + bool getCurrentRadioAccessTecnology(int & selected) { + // @TODO + return false; + } + protected: bool isNetworkConnectedImpl() { RegStatus s = getRegistrationStatus(); @@ -774,7 +796,7 @@ class TinyGsmUBLOX : public TinyGsmModem, if (len >= 0 && len <= 1024) { sockets[mux]->sock_available = len; } } data = ""; - DBG("### URC Data Received:", len, "on", mux); + //DBG("### URC Data Received:", len, "on", mux); } else if (data.endsWith(GF("+UUSOCL:"))) { int8_t mux = streamGetIntBefore('\n'); if (mux >= 0 && mux < TINY_GSM_MUX_COUNT && sockets[mux]) {