Browse Source

Merge EnviroDIY master

v_master
Sara Damiano 6 years ago
parent
commit
5de558352b
13 changed files with 24 additions and 6 deletions
  1. +1
    -1
      library.json
  2. +1
    -1
      library.properties
  3. +1
    -0
      src/TinyGsmClientA6.h
  4. +1
    -0
      src/TinyGsmClientBG96.h
  5. +1
    -0
      src/TinyGsmClientESP8266.h
  6. +1
    -0
      src/TinyGsmClientM590.h
  7. +1
    -0
      src/TinyGsmClientM95.h
  8. +1
    -0
      src/TinyGsmClientMC60.h
  9. +1
    -0
      src/TinyGsmClientSIM7000.h
  10. +1
    -0
      src/TinyGsmClientSIM800.h
  11. +9
    -3
      src/TinyGsmClientUBLOX.h
  12. +2
    -1
      src/TinyGsmClientXBee.h
  13. +3
    -0
      src/TinyGsmCommon.h

+ 1
- 1
library.json View File

@ -1,6 +1,6 @@
{ {
"name": "TinyGSM", "name": "TinyGSM",
"version": "0.6.0",
"version": "0.6.1",
"description": "A small Arduino library for GPRS modules, that just works. Includes examples for Blynk, MQTT, File Download, and Web Client. Supports many GSM, LTE, and WiFi modules with AT command interfaces.", "description": "A small Arduino library for GPRS modules, that just works. Includes examples for Blynk, MQTT, File Download, and Web Client. Supports many GSM, LTE, and WiFi modules with AT command interfaces.",
"keywords": "GSM, AT commands, AT, SIM800, SIM900, A6, A7, M590, ESP8266, SIM7000, SIM800A, SIM800C, SIM800L, SIM800H, SIM808, SIM868, SIM900A, SIM900D, SIM908, SIM968, M95, MC60, MC60E, BG96, ublox, Quectel, SIMCOM, AI Thinker, LTE, LTE-M", "keywords": "GSM, AT commands, AT, SIM800, SIM900, A6, A7, M590, ESP8266, SIM7000, SIM800A, SIM800C, SIM800L, SIM800H, SIM808, SIM868, SIM900A, SIM900D, SIM908, SIM968, M95, MC60, MC60E, BG96, ublox, Quectel, SIMCOM, AI Thinker, LTE, LTE-M",
"authors": "authors":


+ 1
- 1
library.properties View File

@ -1,5 +1,5 @@
name=TinyGSM name=TinyGSM
version=0.6.0
version=0.6.1
author=Volodymyr Shymanskyy author=Volodymyr Shymanskyy
maintainer=Volodymyr Shymanskyy maintainer=Volodymyr Shymanskyy
sentence=A small Arduino library for GPRS modules, that just works. sentence=A small Arduino library for GPRS modules, that just works.


+ 1
- 0
src/TinyGsmClientA6.h View File

@ -184,6 +184,7 @@ public:
*/ */
bool init(const char* pin = NULL) { bool init(const char* pin = NULL) {
DBG(GF("### TinyGSM Version:"), TINYGSM_VERSION);
if (!testAT()) { if (!testAT()) {
return false; return false;
} }


+ 1
- 0
src/TinyGsmClientBG96.h View File

@ -220,6 +220,7 @@ public:
*/ */
bool init(const char* pin = NULL) { bool init(const char* pin = NULL) {
DBG(GF("### TinyGSM Version:"), TINYGSM_VERSION);
if (!testAT()) { if (!testAT()) {
return false; return false;
} }


+ 1
- 0
src/TinyGsmClientESP8266.h View File

@ -201,6 +201,7 @@ public:
*/ */
bool init(const char* pin = NULL) { bool init(const char* pin = NULL) {
DBG(GF("### TinyGSM Version:"), TINYGSM_VERSION);
if (!testAT()) { if (!testAT()) {
return false; return false;
} }


+ 1
- 0
src/TinyGsmClientM590.h View File

@ -181,6 +181,7 @@ public:
*/ */
bool init(const char* pin = NULL) { bool init(const char* pin = NULL) {
DBG(GF("### TinyGSM Version:"), TINYGSM_VERSION);
if (!testAT()) { if (!testAT()) {
return false; return false;
} }


+ 1
- 0
src/TinyGsmClientM95.h View File

@ -220,6 +220,7 @@ public:
*/ */
bool init(const char* pin = NULL) { bool init(const char* pin = NULL) {
DBG(GF("### TinyGSM Version:"), TINYGSM_VERSION);
if (!testAT()) { if (!testAT()) {
return false; return false;
} }


+ 1
- 0
src/TinyGsmClientMC60.h View File

@ -224,6 +224,7 @@ public:
*/ */
bool init(const char* pin = NULL) { bool init(const char* pin = NULL) {
DBG(GF("### TinyGSM Version:"), TINYGSM_VERSION);
if (!testAT()) { if (!testAT()) {
return false; return false;
} }


+ 1
- 0
src/TinyGsmClientSIM7000.h View File

@ -246,6 +246,7 @@ public:
*/ */
bool init(const char* pin = NULL) { bool init(const char* pin = NULL) {
DBG(GF("### TinyGSM Version:"), TINYGSM_VERSION);
if (!testAT()) { if (!testAT()) {
return false; return false;
} }


+ 1
- 0
src/TinyGsmClientSIM800.h View File

@ -241,6 +241,7 @@ public:
*/ */
bool init(const char* pin = NULL) { bool init(const char* pin = NULL) {
DBG(GF("### TinyGSM Version:"), TINYGSM_VERSION);
if (!testAT()) { if (!testAT()) {
return false; return false;
} }


+ 9
- 3
src/TinyGsmClientUBLOX.h View File

@ -251,6 +251,7 @@ public:
*/ */
bool init(const char* pin = NULL) { bool init(const char* pin = NULL) {
DBG(GF("### TinyGSM Version:"), TINYGSM_VERSION);
if (!testAT()) { if (!testAT()) {
return false; return false;
} }
@ -275,10 +276,15 @@ public:
DBG(GF("### SARA N2 NB-IoT modems not supported!"), name); DBG(GF("### SARA N2 NB-IoT modems not supported!"), name);
} }
int ret = getSimStatus(); 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) { if (ret != SIM_READY && pin != NULL && strlen(pin) > 0) {
simUnlock(pin); simUnlock(pin);
return (getSimStatus() == SIM_READY);
}
// if the sim is ready, or it's locked but no pin has been provided, return true
else {
return (ret == SIM_READY || ret == SIM_LOCKED);
} }
return (getSimStatus() == SIM_READY);
} }
String getModemName() { String getModemName() {
@ -383,7 +389,7 @@ public:
if (waitResponse(10000L) != 1) { if (waitResponse(10000L) != 1) {
return false; return false;
} }
delay(3000);
delay(3000); // TODO: Verify delay timing here
return init(); return init();
} }
@ -513,7 +519,7 @@ public:
if (waitResponse() != 1) { if (waitResponse() != 1) {
return false; return false;
} }
sendAT(GF("+URAT="), urat); // Radio Access Technology (RAT) selection
sendAT(GF("+URAT="), urat); // Radio Access Technology (RAT) selection
if (waitResponse() != 1) { if (waitResponse() != 1) {
return false; return false;
} }


+ 2
- 1
src/TinyGsmClientXBee.h View File

@ -281,6 +281,7 @@ public:
*/ */
bool init(const char* pin = NULL) { bool init(const char* pin = NULL) {
DBG(GF("### TinyGSM Version:"), TINYGSM_VERSION);
if (resetPin >= 0) { if (resetPin >= 0) {
pinMode(resetPin, OUTPUT); pinMode(resetPin, OUTPUT);
@ -457,7 +458,7 @@ public:
exitCommand(); exitCommand();
return true;
return init();
} }
void setupPinSleep(bool maintainAssociation = false) { void setupPinSleep(bool maintainAssociation = false) {


+ 3
- 0
src/TinyGsmCommon.h View File

@ -9,6 +9,9 @@
#ifndef TinyGsmCommon_h #ifndef TinyGsmCommon_h
#define TinyGsmCommon_h #define TinyGsmCommon_h
// The current library version number
#define TINYGSM_VERSION "0.6.1"
#if defined(SPARK) || defined(PARTICLE) #if defined(SPARK) || defined(PARTICLE)
#include "Particle.h" #include "Particle.h"
#elif defined(ARDUINO) #elif defined(ARDUINO)


Loading…
Cancel
Save