Basic local machine to machine interactions
In this recipe, we are going to demonstrate Basic local machine to machine interactions. To do that, we will build a simple project that demonstrates machine to machine interaction between two ESP8266 boards. This will enable you to create simple networks using your ESP8266 boards, with no Internet connection.
Getting ready
You will need the following hardware components for this project:
Two ESP8266 boards
Two USB cables
220 Ω resistor
LED
Momentary Push button
10 kΩ resistor
Connect a Push button and a 10 kΩ pull up resistor to the GPIO2 pin. The Push button will be used as an input. This ESP8266 board will be configured as the client. The setup is shown in the following figure:
For the second ESP8266, connect an LED to the GPIO2 pin via a 220 Ω current limiting resistor. This ESP8266 is going to be configured as the server. The server setup will look like this:
How to do it…
To successfully transfer data between the two ESP8266 boards, set up one of the...