Websocket example

Dependencies:   C027 UbloxUSBModem WebSocketClient mbed

Fork of VodafoneUSBModemWebsocketTest by Donatien Garnier

Revision:
10:495e03a3fc8f
Parent:
8:05a5c32037c2
Child:
11:c329ae939cd5
--- a/main.cpp	Wed Nov 06 10:35:38 2013 +0000
+++ b/main.cpp	Wed Nov 06 10:48:00 2013 +0000
@@ -5,8 +5,11 @@
 
 #include "Websocket.h"
 
+C027 c027;
+
 void test(void const*)
 {
+    c027.mdmPower(true);
     UbloxUSBGSMModem modem; // for LISA-C use the UbloxUSBCDMAModem instead
     Websocket ws("ws://sockets.mbed.org:443/ws/demo/rw");
     char recv[128];
@@ -38,6 +41,7 @@
     }
 
     modem.disconnect();
+    c027.mdmPower(false);
 
     while(1) {
     }
@@ -47,7 +51,7 @@
 int main()
 {
     Thread testTask(test, NULL, osPriorityNormal, 1024 * 4);
-    DigitalOut led(A0); // Connect a LED to A0 if you like to see some blinking
+    DigitalOut led(LED); // on rev A you should reasign the signal to A0
     while(1) {
         led=!led;
         Thread::wait(1000);