Implementation of the CellularInterface for u-blox C027 and C030 (non-N2xx flavour) modems that uses the IP stack on-board the cellular modem, hence not requiring LWIP (and so less RAM) and allowing any AT command exchanges to be carried out at the same time as data transfers (since the modem remains in AT mode all the time). This library may be used from mbed 5.5 onwards. If you need to use SMS, USSD or access the modem file system at the same time as using the CellularInterface then use ublox-at-cellular-interface-ext instead.

Dependents:   example-ublox-cellular-interface example-ublox-cellular-interface_r410M example-ublox-mbed-client example-ublox-cellular-interface ... more

Revision:
23:9098a541452b
Parent:
22:63b1a3c02fb8
Parent:
21:2a500a881a5a
Child:
27:3d709ee8c3e1
--- a/TESTS/unit_tests/default/main.cpp	Mon May 13 13:30:24 2019 +0500
+++ b/TESTS/unit_tests/default/main.cpp	Mon May 20 07:46:43 2019 +0000
@@ -402,9 +402,6 @@
 {
     char ntp_values[48] = { 0 };
     time_t timestamp = 0;
-    struct tm *localTime;
-    char timeString[25];
-    time_t TIME1970 = 2208988800U;
     int len;
     bool comms_done = false;
 
@@ -422,6 +419,8 @@
 
     tr_debug("UDP: %d byte(s) returned by NTP server.", len);
     if (len >= 43) {
+    	struct tm *localTime;
+    	time_t TIME1970 = 2208988800U;
         timestamp |= ((int) *(ntp_values + 40)) << 24;
         timestamp |= ((int) *(ntp_values + 41)) << 16;
         timestamp |= ((int) *(ntp_values + 42)) << 8;
@@ -431,6 +430,7 @@
         tr_debug("srand() called");
         localTime = localtime(&timestamp);
         if (localTime) {
+        	char timeString[25];
             if (strftime(timeString, sizeof(timeString), "%a %b %d %H:%M:%S %Y", localTime) > 0) {
                 printf("NTP timestamp is %s.\n", timeString);
             }