WiFi ESP8266 Serial TTL Module

Rated 5.00 out of 5 based on 1 customer rating
(1 customer review)

65.00EGP

Description

Advantage of this module:
1 low prices, basically only earn a small profit, hoping that the move can bring more rapid development of the animal
2 powerful internal LWIP protocol
3 supports three modes: AP, STA, AP+STA coexistence mode
4 improve the simple and efficient AT instruction, so that you develop more simple.
Warm tip: WiFi ESP8266 library file is compiled based on the IDE 1.0.5 Arduino version, such as the case of compiler, please try other versions.
Open the library in the uartWIFI.h file, because our RBoard Mini uses the same chip as UNO, so you want to remove the definition of UNO file in the H notes, write off MEGA.
UNO #define
MEGA //#define
Then the _DBG_RXPIN_ and _DBG_TXPIN_ pins are defined to D9 and D10.
_DBG_RXPIN_ #define 9 //A0
_DBG_TXPIN_ #define 10 //A1
Then save the uartWIFI.h file.
Burning code:
Code:
SSID //type “Itead_1 (Public)” your own SSID name #define
PASSWORD 0//type “27955416” your own WIFI password #define
UartWIFI.h “#include”
<SoftwareSerial.h> #include
WiFi WIFI;
Int chlID //client; ID extern (0-4)
Setup void ()
{
PinMode (4, OUTPUT);
PinMode (5, OUTPUT);
PinMode (6, OUTPUT);
PinMode (7, OUTPUT);
Wifi.begin ();
B bool = wifi.Initialize (STA, SSID, PASSWORD);
If (b!)
{
DebugSerial.println (“error Init”);
}
Delay (8000); sure the module can have enough time to get an IP address //make
Ipstring String = wifi.showIP ();
DebugSerial.println (ipstring); the IP address of module //show
Delay (2000);
Wifi.confMux (1);
Delay (100);
If (wifi.confServer (18080))
DebugSerial.println (“is set up Server”);
}
Loop void ()
{
Buf[100] char;
ILen int = wifi.ReceiveMessage (buf);
If (iLen > 0)
{
If (StrCmp (buf, “CH0ON”) = = 0)
{
DigitalWrite (4, HIGH);
DebugSerial.println (“CH0ON”);
}
If (StrCmp (buf, “CH0OFF”) = = 0)
{
DigitalWrite (4, LOW);
DebugSerial.println (“CH0OFF”);
}
/ * the following three channels can be directly used for channel 4 Rboard D5 D6 D7, Rboard buy address: Spm=a1z10.3.w4002-2605688463.12.EMkeTJ&amp;id=39334222369
If (StrCmp (buf, “CH1ON”) = = 0)
{
DigitalWrite (5, HIGH);
DebugSerial.println (“CH1ON”);
}
If (StrCmp (buf, “CH1OFF”) = = 0)
{
DigitalWrite (5, LOW);
DebugSerial.println (“CH1OFF”);
}
If (StrCmp (buf, “CH2ON”) = = 0)
{
DigitalWrite (6, HIGH);
DebugSerial.println (“CH2ON”);
}
If (StrCmp (buf, “CH2OFF”) = = 0)
{
DigitalWrite (6, LOW);
DebugSerial.println (“CH2OFF”);
}
If (StrCmp (buf, “CH3ON”) = = 0)
{
DigitalWrite (7, HIGH);
DebugSerial.println (“CH3ON”);
}
If (StrCmp (buf, “CH3OFF”) = = 0)
{
DigitalWrite (7, LOW);
DebugSerial.println (“CH3OFF”);
}
* /
}
}
Paste the code into the Arduino IDE, modify your router WIFI name and password in the SSID and PASSWORD in the macro definition.
SSID //type “Itead_1 (Public)” your own SSID name #define
PASSWORD //type “27955416” your own WIFI password #define
Board type selection “UNO Arduino”, click on the compiler, burn, OK!
Next we also need to use FocA to read the serial port information, view WiFi status.

1 review for WiFi ESP8266 Serial TTL Module

  1. Rated 5 out of 5

    abdelghafar

    السلام عليكم
    ارجو عرض مثال بسيط طريقة اعداد وتوصيل وبرمجة الشريحة
    وشكرا جزيلا

Add a review

Your email address will not be published. Required fields are marked *