I have two arduinos one is Arduino Mega while other is Arduino UNO and I want to send data from UNO to Mega and vice versa over wifi using two ESP8266 wifi modules without use of any router in between, so what is the simplest procedure I can use to do this? Moreover how can I do this with a router in between?
1 Answer
The simplest solution is to turn on Access Point Mode on one of Wifi modules. and the other one has to be set to Station Mode in order to connect to the first one.
In case you want to add a router, just set both ESP8266 modules to Station Mode and connect them to the router.
Also, I would recommend replacing the Original Firware (AT firmware) of ESP8266 with NodeMCU Firmware. It uses lua language to write programs directly to ESP8266 which means that you can even make 2 ESP8266 modules talk with each other without even using Arduino.
-
can i use Arduino to Flash NodeMCU to ESP8266 or I have to buy usb to ttl adapter like thing? Commented Nov 14, 2015 at 0:57
-
No you don't need a USB to TTL. Use your arduino, just connect RX pins together and TX pins together (RX<------>RX and TX<------->TX).– IkbelCommented Nov 14, 2015 at 1:14
-
You first need to upload a blink sketch to ensure that Serial interface isn't used by Arduino. then you can flash NodeMCU.– IkbelCommented Nov 14, 2015 at 1:15