Jack Hansdampf / ESP8266WebserverF103

Dependents:   ATCmdParserTest_V1_0_F103

Revision:
14:d17cfd8131b1
Parent:
13:ed5c59ed4ae5
Child:
15:e710f0431920
--- a/ESP8266Webserver.h	Mon Jun 07 18:32:57 2021 +0000
+++ b/ESP8266Webserver.h	Thu Jun 10 07:32:53 2021 +0000
@@ -1,8 +1,9 @@
 
 #include "mbed.h"
 #include "string"
+#include "Einstellungen.h"
 
-#define   ESP8266_DEFAULT_BAUD_RATE   115200
+
 
 class ESP8266Webserver
 {   
@@ -21,12 +22,13 @@
     ATCmdParser *_parser;
     int Aufrufe=0;
     bool gefunden;
+    string ipad=ip;
     
 
     public:
     char suchergebnis[20];
     
-    ESP8266Webserver(int Port=80,PinName tx=PB_10, PinName rx=PB_11, bool pDebug=false);
+    ESP8266Webserver();
     int on(const char* handlestring,Callback< void()> func);
     int begin(void);
     int handleClient(void);
@@ -35,4 +37,16 @@
     const char* gibWert(const char* suchstring);
     string gibWertString(string suchstring);
     void debugOn(bool pD);
+    
+    void connect_wifi(string cmd, int t);                 //This function is for connecting ESP8266 with wifi network by using AT commands
+
+  
+    void WIFIsetup(string pSSID, string pPW);
+
+
+    void wifi_init();                                //This function contains AT commands that passes to connect_wifi()
+
+
+    bool check4IP(int t1);                                     //A function to check ip of ESP8266
+
 };
\ No newline at end of file