htgghg

Fork of WizFi310Interface_Legacy by WIZnet

Files at this revision

API Documentation at this revision

Comitter:
ajeet3004
Date:
Mon Sep 18 02:50:44 2017 +0000
Parent:
1:e08ea0ee2788
Commit message:
Changed the Library

Changed in this revision

WizFi310/WizFi310.h Show annotated file Show diff for this revision Revisions of this file
WizFi310/WizFi310_at.cpp Show annotated file Show diff for this revision Revisions of this file
WizFi310/WizFi310_sock.cpp Show annotated file Show diff for this revision Revisions of this file
WizFi310Interface.cpp Show annotated file Show diff for this revision Revisions of this file
WizFi310Interface.h Show annotated file Show diff for this revision Revisions of this file
diff -r e08ea0ee2788 -r a4890cc8be69 WizFi310/WizFi310.h
--- a/WizFi310/WizFi310.h	Tue May 02 00:31:36 2017 +0000
+++ b/WizFi310/WizFi310.h	Mon Sep 18 02:50:44 2017 +0000
@@ -149,6 +149,7 @@
     int cmdCLOSE    ( int cid );
     int cmdFDNS     (const char *host);
     int cmdSMGMT    ( int cid );
+    int cmdTEST     ();
 
 
     static WizFi310 * getInstance() {
diff -r e08ea0ee2788 -r a4890cc8be69 WizFi310/WizFi310_at.cpp
--- a/WizFi310/WizFi310_at.cpp	Tue May 02 00:31:36 2017 +0000
+++ b/WizFi310/WizFi310_at.cpp	Mon Sep 18 02:50:44 2017 +0000
@@ -99,6 +99,10 @@
 
     return resp;
 }
+int WizFi310::cmdTEST()
+{
+  return sendCommand("AT");
+}
 
 int WizFi310::cmdMECHO(bool flg)
 {
@@ -166,7 +170,7 @@
 int WizFi310::cmdWANT(AntennaMode mode)
 {
     char cmd[CFG_CMD_SIZE];
-    sprintf(cmd, "AT+WANT=%d",mode);
+    sprintf(cmd, "AT+WANT=%d",mode); 
     
     return sendCommand(cmd);
 }
diff -r e08ea0ee2788 -r a4890cc8be69 WizFi310/WizFi310_sock.cpp
--- a/WizFi310/WizFi310_sock.cpp	Tue May 02 00:31:36 2017 +0000
+++ b/WizFi310/WizFi310_sock.cpp	Mon Sep 18 02:50:44 2017 +0000
@@ -238,6 +238,7 @@
     return -1;
 }
 
+
 int WizFi310::getRemote(int cid, char **ip, int *port)
 {
     if (!isConnected(cid))  return -1;
diff -r e08ea0ee2788 -r a4890cc8be69 WizFi310Interface.cpp
--- a/WizFi310Interface.cpp	Tue May 02 00:31:36 2017 +0000
+++ b/WizFi310Interface.cpp	Mon Sep 18 02:50:44 2017 +0000
@@ -63,6 +63,10 @@
 {
 	return cmdWLEAVE();
 }
+int WizFi310Interface::test()
+{
+	return cmdAT();
+}
 
 char* WizFi310Interface::getMACAddress()
 {
diff -r e08ea0ee2788 -r a4890cc8be69 WizFi310Interface.h
--- a/WizFi310Interface.h	Tue May 02 00:31:36 2017 +0000
+++ b/WizFi310Interface.h	Mon Sep 18 02:50:44 2017 +0000
@@ -37,6 +37,7 @@
     int init(const char* ip, const char* mask, const char* gateway, const char* name = NULL);
     int connect(Security sec, const char* ssid, const char* phrase, WiFiMode mode = WM_STATION);
     int disconnect();
+    int test();
     char* getMACAddress();
     char* getIPAddress();
     char* getGateway();