To explain, I used finder (I use Mac stuff, sorry if anyone is offended) to find Upgrade-Insecure-Requests:, it was not found. I can't seem to trace where the stuff is coming from. I guess the answer is to look at every single .cpp file associated with ESP8266Wifi
I only posted here because I thought there was a general form of DEBUG 0 or something that worked for wifi messages.
sevenoutpinball:
That's the problem, I can't find them.
To explain, I used finder (I use Mac stuff, sorry if anyone is offended) to find Upgrade-Insecure-Requests:, it was not found. I can't seem to trace where the stuff is coming from. I guess the answer is to look at every single .cpp file associated with ESP8266Wifi
I only posted here because I thought there was a general form of DEBUG 0 or something that worked for wifi messages.
first check the Serial.prints and writes in the sketch
sevenoutpinball:
That's the problem, I can't find them.
To explain, I used finder (I use Mac stuff, sorry if anyone is offended) to find Upgrade-Insecure-Requests:, it was not found. I can't seem to trace where the stuff is coming from. I guess the answer is to look at every single .cpp file associated with ESP8266Wifi
I only posted here because I thought there was a general form of DEBUG 0 or something that worked for wifi messages.
I've been using that library for two years in dozens of projects and never seen this. Apparently neither has anyone else here. It MUST be in your code.
Sent by the browser to the esp software and then written to the serial monitor. I spent an hour going thru all the include things can didn't find much in the way of .........
Hey wait, maybe it's this thing that is doing it... the Serial.write line!!!!!!!!!
void CheckServer() {
yield();
WiFiClient client = server.available(); // Listen for incoming clients
if (client) { // If a new client connects,
String currentLine = ""; // make a String to hold incoming data from the client
while (client.connected()) { // loop while the client's connected
if (client.available()) { // if there's bytes to read from the client,
char c = client.read(); // read a byte, then
Serial.write(c); // print it out the serial monitor
header += c;
if (c == '\n') { // if the byte is a newline character
// if the current line is blank, you got two newline characters in a row.
// that's the end of the client HTTP request, so send a response:
if (currentLine.length() == 0) {
client.println(prepareHtmlPage());
break;
} else { // if you got a newline, then clear currentLine
currentLine = "";
}
} else if (c != '\r') { // if you got anything else but a carriage return character,
currentLine += c; // add it to the end of the currentLine
}
performRequest(currentLine);
}
}
header = ""; // Clear the header variable
client.stop(); // Close the connection
yield();
// Serial.println("Client disconnected.");
}
}
I told you so. 4 times.
it is exactly what I expected
char c = client.read();
Serial.write(c);
the comment
// print it out the serial monitor
is new or was there all the time?
I am glad that you found where it was coming from, but the hunt could have been over at least 20 posts ago if you had followed the advice to post your code
The whole thing? See I never know how much and in this case was sure it wasn't anything I had made, because I had taken all the serial prints and made and put them in an html table so I could look at them without having the device connected to a computer. This is what can happen when you get code off websites without rally knowing all the html commands etc. I just want it to work!