From 90dde6861bb6923ef339ca303936dc61788a46fa Mon Sep 17 00:00:00 2001 From: Sara Damiano Date: Wed, 15 Apr 2020 08:48:31 -0400 Subject: [PATCH] Fix get battery voltage, fixes #369 Signed-off-by: Sara Damiano --- src/TinyGsmBattery.tpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/TinyGsmBattery.tpp b/src/TinyGsmBattery.tpp index 36596e7..a662682 100644 --- a/src/TinyGsmBattery.tpp +++ b/src/TinyGsmBattery.tpp @@ -55,7 +55,7 @@ class TinyGsmBattery { thisModem().streamSkipUntil(','); // Skip battery charge status thisModem().streamSkipUntil(','); // Skip battery charge level // return voltage in mV - uint16_t res = thisModem().streamGetIntBefore(','); + uint16_t res = thisModem().streamGetIntBefore('\n'); // Wait for final OK thisModem().waitResponse(); return res;