![](/media/cache/group/default_image.jpg.50x50_q85.jpg)
Example program for the LWIPInterface
Dependencies: LWIPInterface NetworkSocketAPI mbed-rtos mbed
Fork of HelloESP8266Interface by
Example for the NetworkSocketAPI. Attempts to get the device's public facing IP address from ifcfg.me.
Diff: main.cpp
- Branch:
- api-changes
- Revision:
- 32:28a909a3748e
- Parent:
- 30:f80540b6e2db
- Child:
- 33:b80621db4a68
--- a/main.cpp Tue Feb 23 00:01:04 2016 -0600 +++ b/main.cpp Tue Feb 23 01:35:24 2016 -0600 @@ -18,7 +18,7 @@ #include "ESP8266Interface.h" #include "TCPSocket.h" -DigitalOut myled(LED1); +DigitalOut myled(LED_GREEN); void flash(){ myled = !myled; } ESP8266Interface wifi(D1, D0); @@ -30,7 +30,7 @@ t.attach(flash, 0.4f); printf("NetworkSocketAPI Example\r\n"); - wifi.connect("WifiDemo", ""); + wifi.connect("Sniffer", "Sandcastle"); const char *ip = wifi.getIPAddress(); const char *mac = wifi.getMACAddress();