With Instructables you can share what you make with the world, and tap into an ever-growing community of creative experts.
WiFi / Internet Controlled Relays using ESP8266 - Quick, 30 minutes IoT project
do you mind pointene me in the right direction?
FLASHİNG WİTH WASS . GİVE PLESE DİTEKT WORKED FLASH. YOU SENN ALWAYS GİFTHUB WOOD.GİFTHUB İS BİG BİG WOOOD .
Hİ HOW CAN İ FİND İN THİS LİNK FW. ????All information on NodeMCU is here : https://github.com/nodemcu/nodemcu-firmwareHERE İS WOOD.
Hello, I have used AT Command which is sequence given below:ATAT+CWMODE=2AT+CWSAP="IndiaAP","1234test",5,3AT+RSTAT+CIPMUX=1AT+CIPSTART=1,"UDP","192.168.4.100",80AT+CIPSERVER=1,80AT+CIPSTO=3600AT+CIPSEND=1,512345Use 300ms Delay for avoid busy -------AT+CIPSEND=1,512345-----------------------------------------My problem is that how to reduce 300ms delay between send two data packets.Please anyone can help me...
Thanks for the quick reply! It turns out I had a bad jumper wire connection or two that was either effecting the TX/RX and/or power stability. A complete rework of my benchtop configuration solved the enigma. Thanks again for the quick reply and the project!
Hello thanks again for your willingness to share your expertise. My next problem is I can't get the webpage to start. The only changes I've made to the init.lua file is as you instructable (e.g. IP, SSID, p/w). I'm working in the same room as the WiFi router (2.4 ghz, 802 1.1, WPA/WPA2 PSK). I even reformatted/reloaded .lua on the ESP01. Any suggestions?
If you have flashed the nodemcu firmware successfully, you need to disconnect GND and GPIO0 otherwise the module will stay in bootloader mode and you will not be able to use it normally. You can only flash in this mode. Other things should be fine. You should at least get a startup message from nodemcu when the module starts.
Hello - Thanks for the Project! It's exactly what I need to save some coin over using a more expensive alternative. Your Instructable rocks! Unfortunately I'm getting: "ERROR: Communication with MCU not yet established" in the ESPlorer v0.2.0-rc3 IDE. I was able to flash the NodeMCU firmware at a 9600bps on the first try! And I believe my power config at 3.3V to ESP-01 with only a shared GND to CP210x is good. CP210x is powered by PC. My LM2595 step-down is powered by a AC/DC wall plug at 5.5vdc/500ma.I've pulled the GND to GPIO0 jumper. COM3 port says it's opened and I've mirrored the baud rate in my Win7 OS. My CP210x has latest driver. My port setting are: 9600bps, 8db, No: Pairty, 1sb, No: Flow Ctrl. I cycled through each baud rate option hoping for a miracle to no avail. Finally, I did try two different ESP-01s in hopes the one antenna may have been defective and still can't get any communication. Please help? Thanks again!
So my switches are opposite of what they should be. I ought to be able to figure that part out on my own.However there is no indicator to tell if you turned things on or what state they are in when you load the page. Would there be a way to put an indicator that shows whether it's off or on?thanks
Now,both relays working.I think the problem was de ESP-01 module and i will check well later.I have notice that when i press relay 2 button,the blue comunication led on ESP-12-E module goes on.Is this normal?.As i said before to Vaidyasp,i need four relays for my project,and also i need access outside of my wifi network.I do not know nothing about programming,so please,can you help me with this?.I will appreciate it.Thank you so much.
Thanks for reply.At this moment i am trying with another module,a ESP-12-E.For my project ,i need four relays,and the ESP-01,has only two gpios.If this module works,i will need help with the lua script and the access outside my wifi network.I am electronic technician,but i am rookie in programming,no matter what languaje.Thank you very much.
Hi again.I have changed the wires for relay 1 and 2,and both relays works fine.If i check gpio0 when i push button 1,gpio0 goes down 0v and activate relay,but when i push button 2,gpio2 remain high,and relay is not activated.I have re-checked,conections in esp module,breadboard,power supply,and all seems ok.I had thought ,the problem was the pull-up resistor,but gpio0 have another one,and wors fine.I realy do not where the problem can be.Init.lua?.Thanks a lot. - Jose LuisG35
The file is fine and working, It may be problem of programming. Try re-uploading the code using upload button in esplorer. You may also check your module's io pin working with some other code. - vaidyasp
Upload the file directly. When you uplaod through esplorere editor it sends the file line by line and tries to execute it on ESP8266. Some long lines or some lines with complex html may not work. Upload the complete file using upload button in left bottom row.
Can you check if your relay works -> give VCC to relay input pin.Secondly check if your esp module gives output. Check the pin with reference to GND.
Its already in description. http://robokits.co.in/download/init.zip
Hello,thanks for project.For me everything is ok,except,that only one relay works.I can see de buttons on web page,but only relay one work.When i push button 2 on,nothing happen.I have pull-up resistors for rst,chpd,gpio0 and gpio2.Without resistors,nothing works.I have check de conections,power supply,esp module,etc, and everything seems fine.Also i have no problem to access the web page from my destok pc,but i cannot,from my phone,ipod,or my tablet.All my devices are in the same network.Can you help me with this?.Thank you in advance,and sorry for my english.
guys please I'm just newbie here. Where do I find the code for this? Thank you
Awesome project! I made it but i have one little problem when I go to webpage it shows only header "Robokits IOT Server" i dont have buttons but i know that this thing works when i type http://192.168.0.87/?pin=ON1....What I have done wrong? Sorry for my English...
Hope this helps...
Should this circuit not have a transistor with resistors doing the switching? Eg: the recommended way? Similar to the Arduino to drive a DC relay: http://playground.arduino.cc/uploads/Learning/relays.pdf
Hi Robokits!Nice easy work, good understanable, I made it, works well.Pls give an answer: why does not work it with iPhone?Does it need a meta Tag?
If anyone interested, iPhone superusers could combine SIRI with assistant+,activator and simple curl command to voice control ESP-01. Or, Simple springboard icon flicks triggering curl commands (e.g. curl -X POST 192.168.x.x/?pin=ON2 >/dev/null )
I can't set my esp8266 on station mode I don't know why... I followed step by step this tutorial :( can you help me?tnx
Hello My Friend, It's a great tutorial, i searched many times but I don't figured out how to replace that second relay by a push button, my intention is to when the button is pressed, the relay is turned (if ON, turn OFF and if OFF turn ON) and on the web page show state and turn the relay too or by mqtt...
Tried for seven hours to get this working without success. I managed to get the ESP8266 to connect as per the video but no web page. I have two devices and programmed both the same one connected to network the other did not. If I change station to station AP on the one that does not connect it creats a hot spot but still no web page. I have used Notpad++ to edit can anyone help
Hey, followed the tutorial precisley, the website show up at my desired ip the voltages are correct. But when i try to switch the relays on or off nothing seem to happen? any suggestions on this? firmware is flashed and the init.lua is on the esp8266Greetings Tibor
after updating firmware its not responding at commands. what i want to do now please tell me.
Mine works great however after 2 days it no longer serves up the webpage. I have to recycle the power to the esp8266 and it all good.My power supply is rock solid and my wifi router is never turned off or ever needs rebooting. Do you know why this happens? I have checked in my router setup for anything about expiring ip leases etc but nothing was there to help. Only way to fix it seems to be adding something to cycle the power every day or so.
Hello!I have a problem. Wants to relay 1 after turning work 30sec and shutdown. Will it be good:if(_GET.pin == "ON1")then gpio.write(Relay1, gpio.HIGH); wait(30); gpio.write(Relay1, gpio.LOW); elseif(_GET.pin == "OFF1")then gpio.write(Relay1, gpio.LOW);
hello there.This is a great project and very close to what I'm looking for. Perhaps you someone here can help me...I want to use an esp8266 to send a signal to a second esp8266 to open or close the relays. Everything in this instruct able stays the same, but how do I add another esp8266 in here to send control signals?Thanks for any help!
Nice project, next I'd like to see you using MQTT to connect it to DIoTY.co. Like this you no longer need a static IP or DNS service to update your dynamic IP address. Using DIoTY gives you the additional advantage of getting a mobile app (android and iOS) to control both relays... and all for free...
Join 2 million + to receive instant DIY inspiration in your inbox.
Download our apps!
© 2016 Autodesk, Inc.