How I make confirmation on the server with the ESP8266WiFi.h
Posted: Tue Dec 06, 2016 5:53 pm
I have two esp8266. One as an AP and the other as a client to make a Wi-Fi connection with the ESP8266WiFi.h library. From the client press a button to light a led on the server. How do I send from the server a reception response so that the client also lights a led as a signal that the server has responded to the signal. From the client I send the command to the server with Serial.println ("ON");
MQTClient.println ("ON");
And on the server I read with
String Message = MQTClient.readStringUntil ('\ r');
To proceed to turn on the led. Then I would like to send a signal to the customer to have a LED on the server LED on.
I have used server.print () on the server and on the client I read with
String Message = MQTClient.readStringUntil ('\ r'); But does nothing.
I'm sorry for English but I'm not native English and I appreciate any kind of help.
MQTClient.println ("ON");
And on the server I read with
String Message = MQTClient.readStringUntil ('\ r');
To proceed to turn on the led. Then I would like to send a signal to the customer to have a LED on the server LED on.
I have used server.print () on the server and on the client I read with
String Message = MQTClient.readStringUntil ('\ r'); But does nothing.
I'm sorry for English but I'm not native English and I appreciate any kind of help.