Another illustration how to wire the ESP8266 as server and client mode, therefore there is no need to use a router or smart phones to interact/communicate to the ESP8266, this is direct communication between 2 ESP module as server and client mode, ones the code is loaded the ESP8266 coded as server the client ESP8266 will automatically connect to the ESP8266 Server Access Point. As you can see the diagram on the ESP8266 client the push button is attach to pin D2 map on Arduino as GPIO pin 4 when button is pressed it will send a command to the server as value of 1 then the server will turn the D2/GPIO 4 to HIGH then LED light will turn on.
USB TTL UART / (Flashing/Programming the ESP8266 Module)
Push Button
Resistors
LED
Jumper Wire / DuPont Wire
Solder Less Bread Board
AA Battery
Wiring Guide
Programming / Flashing the ESP8266 12/12E
You need to install Arduino 1.6.8 from the Arduino website. available for Windows, Mac OS, and Linux (32 and 64 bit).
Open Arduino IDE and open the Preferences window then add {http://arduino.esp8266.com/stable/package_esp8266com_index.json} without bracket into Additional Board Manager URLs field. Note you can add multiple url separating them with commas. > http://arduino.esp8266.com/stable/package_esp8266com_index.json
Soy Daniel de Valencia (España) . Me gustaría hablarte de un pequeño proyecto que tengo en mente. Como conectar entre si dos esp8266-01
Uno como cliente con entrada gpio2 de un sensor de lluvia, que manda orden ( cuando llueve) durante 20 segundos al otro esp8266-01 como servidor,
con salida por gpio2 a un relé, que hace que baje la persiana de una ventana.
La idea es meter el esp8266-01 (servidor) dentro de la caja empotrada de los pulsadores de subir/bajar la persiana.
La cuestión es que lo quiero hacer inalámbricamente.
Es posible hacer el proyecto?
He mirado mucho por internet y no he visto nada, podríais echarme una mano
Mi problema es, que de programación, NO tengo nada de idea. ¿Tu podrías desarrollar el código (sketch)que hiciera funcionar mi proyecto?
Muchas Gracias por la atención, espero tu ayuda. Un abrazo.
We use cookie to provide you the best possible experience, this site uses cookies and by continuing to use the site you agree that we can save them on your device. Cookies are small text files which are placed on your computer and which remember your preference / some details of your visit. Our cookies don’t collect any personal information. For information, please read our Privacy Statement and Cookie Policy , which also explains how to disable this option in your browser. Cookie SettingsACCEPT
Privacy & Cookies Policy
Privacy Overview
This website uses cookies to improve your experience while you navigate through the website. Out of these cookies, the cookies that are categorized as necessary are stored on your browser as they are as essential for the working of basic functionalit...
Necessary cookies are absolutely essential for the website to function properly. This category only includes cookies that ensures basic functionalities and security features of the website. These cookies do not store any personal information.
Any cookies that may not be particularly necessary for the website to function and is used specifically to collect user personal data via analytics, ads, other embedded contents are termed as non-necessary cookies. It is mandatory to procure user consent prior to running these cookies on your website.
Hi sir,
I am tring to use your code but its seems at the server side it say’s
‘val’ was not decleared in this scope.
How to fix this. Thank you.
Hi! Please check your code there is no variable ‘val’ declared in server code.
‘digtalRead’ was not declared in this scope
Hi! Kelio.. the code above has been fix. actually it suppose to be digitalRead not digtalRead. :)
The schematic diagram has been updated. Thank you very much for your concern.. :)
need to be:
if (req.indexOf(“/led/0”) != -1) val=0;
if (req.indexOf(“/led/1”) != -1) val=1;
Soy Daniel de Valencia (España) . Me gustaría hablarte de un pequeño proyecto que tengo en mente. Como conectar entre si dos esp8266-01
Uno como cliente con entrada gpio2 de un sensor de lluvia, que manda orden ( cuando llueve) durante 20 segundos al otro esp8266-01 como servidor,
con salida por gpio2 a un relé, que hace que baje la persiana de una ventana.
La idea es meter el esp8266-01 (servidor) dentro de la caja empotrada de los pulsadores de subir/bajar la persiana.
La cuestión es que lo quiero hacer inalámbricamente.
Es posible hacer el proyecto?
He mirado mucho por internet y no he visto nada, podríais echarme una mano
Mi problema es, que de programación, NO tengo nada de idea. ¿Tu podrías desarrollar el código (sketch)que hiciera funcionar mi proyecto?
Muchas Gracias por la atención, espero tu ayuda. Un abrazo.
dazallu@hotmail.com
i have the val not declared in scope problem please help
which value is not declared? most provably that issue is come from the declared variables, see true it that all variables are properly utilize/ :D
Pingback:Point to Point / Server & Client Setup on ESP8266 & MCP9808 Temp Sensor | 14core.com