Example program to connect to the internet via Ublox Cellular Shield and post MEMS sensor readings to M2X.

Dependencies:   C027_Support M2XStreamClient Nucleo_Sensor_Shield jsonlite mbed-rtos mbed

Fork of Cellular_m2x-demo-all by u-blox

Revision:
10:ba926a8f1fe6
Parent:
9:08fdd1036e93
Child:
13:b04452198625
--- a/main.cpp	Sun Sep 07 01:42:11 2014 +0000
+++ b/main.cpp	Sat Sep 13 16:06:06 2014 +0000
@@ -84,7 +84,7 @@
         }
     }
     
-    if (tmr.read_ms() > 10000) {
+    if (tmr.read_ms() > 1000) {
         tmr.reset();
         tmr.start();
         int response;
@@ -92,8 +92,8 @@
         MDMParser::NetStatus status;
         if (mdm.checkNetStatus(&status)) {
             sprintf(buf, "%d", status.rssi);
-            response = m2xClient.post(feedId, "rssi", buf);
-            printf("Post response code: %d\r\n", response);
+            response = m2xClient.put(feedId, "rssi", buf);
+            printf("Put response code: %d\r\n", response);
             if (response == -1) while (true) ;
         }
 //#define READING