Connect to SSID, get ip by dhcp, ping google.com, display statistics

Dependencies:   NVIC_set_all_priorities cc3000_hostdriver_mbedsocket mbed

Revision:
1:1ef047ffeef4
Parent:
0:26d9788555b6
Child:
3:f38499c4000e
--- a/main.h	Sat Sep 14 05:13:00 2013 +0000
+++ b/main.h	Sun Sep 15 14:41:26 2013 +0000
@@ -16,43 +16,20 @@
 #ifndef MAIN_H
 #define MAIN_H
 
-#ifndef FALSE
-#define FALSE 0
-#endif
-
-#ifndef TRUE
-#define TRUE 1
-#endif
-
-#define SMART_CONFIG_SET 0x55
-#define TCPIP_PORT 15000
-
-#define USE_DHCP      1
-#define USE_STATIC_IP 2
-
+/* use this defines in AP_SECURITY */
 #define NONE 0
 #define WEP  1
 #define WPA  2
 #define WPA2 3
 
-// Modify the following settings as necessary for your Wi-Fi Network setup:
-#define IP_ALLOC_METHOD USE_DHCP        // for DHCP assigned IP address
-//#define IP_ALLOC_METHOD USE_STATIC_IP // for static IP address
+// use smart config
+#define USE_SMART_CONFIG 0
 
-// Default SSID Settings
-#define AP_KEY       "87654321"
+ // Default SSID Settings
+#define AP_KEY       "test"
 #define AP_SECURITY     WPA2            // WPA2 must be enabled for use with iPhone or Android phone hotspot!
 #define SSID           "test"
-//#define AP_SECURITY    NONE          // no security but will connect quicker!
-#define STATIC_IP_OCT1 192
-#define STATIC_IP_OCT2 168
-#define STATIC_IP_OCT3 0
-#define STATIC_IP_OCT4 103
-
-#define STATIC_GW_OCT4 1             // Static Gateway address  = STATIC_IP_OCT1.STATIC_IP_OCT2.STATIC_IP_OCT3.STATIC_GW_OCT4
-
-#define REQ_BUFFER_SIZE 400
-
+/* Board specific */
 #define WIGO_BOARD 1
 
 #if (WIGO_BOARD == 1)