sandbox / Mbed OS simple-mbed-client-example

Dependencies:   simple-mbed-client

Fork of simple-mbed-client-example by Jan Jongboom

Revision:
12:31e60c8bb7f6
Parent:
11:341c9f62028b
Child:
13:d4da5e6aa952
--- a/main.cpp	Thu Mar 03 19:26:28 2016 +0000
+++ b/main.cpp	Mon Mar 07 22:11:37 2016 +0000
@@ -26,7 +26,7 @@
 #include "mbed.h"
 #include "rtos.h"
 
-#include "ESP8266Interface.h"
+#include "LWIPInterface.h"
 #include "mbed-client-classic/m2mnetwork.h"
 
 
@@ -299,8 +299,8 @@
 // Instantiate the class which implements
 // LWM2M Client API
 MbedClient mbed_client;
-ESP8266Interface esp(D1, D0);
-M2MNetwork network(&esp);
+LWIPInterface lwip;
+M2MNetwork network(&lwip);
 
 // Set up Hardware interrupt button.
 InterruptIn obs_button(SW2);
@@ -338,10 +338,10 @@
 
     // This sets up the network interface configuration which will be used
     // by LWM2M Client API to communicate with mbed Device server.
-    esp.connect("Sniffer", "Sandcastle");
+    lwip.connect();
 
     //lwipv4_socket_init();
-    output.printf("IP address %s\r\n", esp.getIPAddress());
+    output.printf("IP address %s\r\n", lwip.getIPAddress());
 
     // On press of SW3 button on K64F board, example application
     // will call unregister API towards mbed Device Server