Remote I/O Sensor bus with AT&T flow and M2X cloud

Dependencies:   DHT11 FXOS8700CQ MODSERIAL mbed

Fork of Avnet_ATT_Cellular_IOT by Avnet

Revision:
80:d635c0eddd6e
Parent:
79:ff3014b3637e
--- a/wnc_control.cpp	Mon Aug 15 22:40:14 2016 +0000
+++ b/wnc_control.cpp	Tue Aug 16 13:55:59 2016 +0000
@@ -385,7 +385,7 @@
      
   if (cmdRes == -3) {
      WNC_MDM_ERR = WNC_EXTERR;
-     pc.printf("[[WNC_MDM_ERR = WNC_EXTERR]] \r\n");
+     PRINTF("[[WNC_MDM_ERR = WNC_EXTERR]] \r\n");
   }
 
  if (cmdRes == 0)
@@ -565,7 +565,7 @@
   if (send_wnc_cmd(str.c_str(), &pRespStr, 60000) == 0)
   {
     size_t pos_start = pRespStr->find(":\"") + 2;
-    size_t pos_end = pRespStr->rfind("\"") - 1;
+    size_t pos_end = pRespStr->find("\"", pos_start) - 1;
     if ((pos_start !=  string::npos) && (pos_end != string::npos))
     {
         if (pos_end > pos_start)