Fix a typo in temperature for SARA R4

This commit is contained in:
Sara Damiano
2019-08-26 18:58:56 -04:00
parent f0dd33ffe3
commit 4697285932
2 changed files with 7 additions and 10 deletions

View File

@@ -525,7 +525,7 @@ TINY_GSM_MODEM_GET_GPRS_IP_CONNECTED()
streamSkipUntil(','); // Skip units (C/F)
int16_t res = stream.readStringUntil('\n').toInt();
float temp = -9999;
if (res != 655355) {
if (res != 65535) {
temp = ((float)res)/10;
}
return temp;

View File

@@ -104,12 +104,9 @@ void setup() {
SerialMon.begin(115200);
delay(10);
// !!!!!!!!!!!
// Set your reset, enable, power pins here
pinMode(20, OUTPUT);
digitalWrite(20, HIGH);
pinMode(23, OUTPUT);
digitalWrite(23, HIGH);
// !!!!!!!!!!!
SerialMon.println("Wait...");
@@ -139,7 +136,7 @@ void loop() {
SerialMon.println(F(" [OK]"));
String modemInfo = modem.getModemInfo();
SerialMon.print("Modem: ");
SerialMon.print("Modem Info: ");
SerialMon.println(modemInfo);
#if TINY_GSM_USE_GPRS