Fix ublox battery percent

This commit is contained in:
Sara Damiano
2019-05-24 23:47:49 -04:00
parent 5f8c1c5784
commit db6bb0e6c0
4 changed files with 6 additions and 4 deletions

View File

@@ -501,8 +501,10 @@ TINY_GSM_MODEM_GET_GPRS_IP_CONNECTED()
}
int res = stream.readStringUntil(',').toInt();
int8_t percent = res*20; // return is 0-5
// Wait for final OK
waitResponse();
return res;
return percent;
}
uint8_t getBattChargeState() TINY_GSM_ATTR_NOT_AVAILABLE;

View File

@@ -10,7 +10,7 @@
#define TinyGsmCommon_h
// The current library version number
#define TINYGSM_VERSION "0.7.8"
#define TINYGSM_VERSION "0.7.9"
#if defined(SPARK) || defined(PARTICLE)
#include "Particle.h"