V.06 11/3

Dependencies:   FT6206 SDFileSystem SPI_TFT_ILI9341 TFT_fonts

Fork of ATT_AWS_IoT_demo by attiot

Revision:
23:b9ff83dc965f
Parent:
18:6370da1de572
Child:
28:54d9a550adf1
--- a/AWS_openssl/aws_iot_src/protocol/mqtt/aws_iot_embedded_client_wrapper/platform_mbed_os/openssl/network.cpp	Wed Dec 07 21:19:07 2016 +0000
+++ b/AWS_openssl/aws_iot_src/protocol/mqtt/aws_iot_embedded_client_wrapper/platform_mbed_os/openssl/network.cpp	Thu Dec 15 18:05:09 2016 +0000
@@ -22,6 +22,7 @@
 
 // Expose serial for WNC boot
 extern MODSERIAL pc;
+extern char iccidName[21];
 
 // Network socket
 WNCTCPSocketConnection* _tcpsocket;
@@ -30,6 +31,7 @@
 {
     INFO("Booting WNC modem...");
     int rc = -1;
+    string str;
     WNCInterface eth_iface;
     
     INFO("...Using Avnet Shield and AT&T wireless LTE");
@@ -42,6 +44,11 @@
     
     eth_iface.connect();
     INFO("...IP Address: %s ", eth_iface.getIPAddress());
+    
+    // Get SIM card number (ICCID)
+    eth_iface.getICCID(&str);
+    strcpy(iccidName, str.c_str());
+    INFO("...ICCID: %s", iccidName);
     return rc;
 }
 
@@ -103,7 +110,8 @@
 
 int net_modem_boot()
 {
-    // Do nothing   
+    // Do nothing
+    return 0;  
 }
 
 void mbedtls_net_init( mbedtls_net_context *ctx )