Library to use a wifly module: RN 131 C/G

Dependents:   RN-XV_simple_server

Files at this revision

API Documentation at this revision

Comitter:
samux
Date:
Mon Aug 15 16:05:21 2011 +0000
Parent:
8:d72bfdccb5d8
Child:
10:d3e3e925f62f
Commit message:

Changed in this revision

Wifly.cpp Show annotated file Show diff for this revision Revisions of this file
Wifly.h Show annotated file Show diff for this revision Revisions of this file
--- a/Wifly.cpp	Mon Aug 15 12:52:49 2011 +0000
+++ b/Wifly.cpp	Mon Aug 15 16:05:21 2011 +0000
@@ -272,12 +272,10 @@
 
 bool Wifly::CmdMode() 
 {
-    int i = 0;
-    while(!Send("$$$", "CMD"))
+    if(!Send("$$$", "CMD"))
     {
         printf("Wifly::CmdMode: cannot enter in cmd mode\r\n");
-        i++;
-        if ( i == 4 ) return false;
+        return false;
     }
     return true;
 }
--- a/Wifly.h	Mon Aug 15 12:52:49 2011 +0000
+++ b/Wifly.h	Mon Aug 15 16:05:21 2011 +0000
@@ -120,7 +120,7 @@
         bool CreateAdhocNetwork();
         
         /**
-        * Receive a string from the wifi module by serial port
+        * Receive a string to the wifi module by serial port
         *
         *@param str string to be read
         */