ESP8266 Webserver Project

Moderator: Sprite_tm

User avatar
By Luck Hermsen
#92193 Hi all,
I'm using ESP8266WebServer in my project (using Arduino IDE) and for some reason all HTTP requests are being logged to serial, which is a problem as I need the serial to communicate with my car.

Serial output looks like this:
Code: Select all10:43:01.576 -> New client
10:43:01.576 -> request: GET /getConsole HTTP/1.1
10:43:01.622 -> method: GET url: /getConsole search:
10:43:01.669 -> headerName: Host
10:43:01.669 -> headerValue: 192.168.0.238
10:43:01.715 -> headerName: Connection
10:43:01.715 -> headerValue: keep-alive
10:43:01.762 -> headerName: User-Agent
10:43:01.808 -> headerValue: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/92.0.4515.159 Safari/537.36
10:43:01.948 -> headerName: Accept
10:43:01.948 -> headerValue: */*
10:43:01.994 -> headerName: Referer
10:43:01.994 -> headerValue: http://192.168.0.238/
10:43:02.041 -> headerName: Accept-Encoding
10:43:02.087 -> headerValue: gzip, deflate
10:43:02.134 -> headerName: Accept-Language
10:43:02.134 -> headerValue: en-NL,en;q=0.9,nl-NL;q=0.8,nl;q=0.7,en-US;q=0.6,de-DE;q=0.5,de;q=0.4
10:43:02.227 -> args:
10:43:02.227 -> args count: 0
10:43:02.273 -> args:
10:43:02.273 -> args count: 0
10:43:02.273 -> Request: /getConsole
10:43:02.320 -> Arguments:
10:43:02.320 -> final list of key/value pairs:


Does anyone know how to disable this?
All help much appreciated!
User avatar
By Luck Hermsen
#92211 Turns out the ESPTemplateProcessor was logging it's data to Serial.
Took a look in the Library and was able to disable to logging by calling the function differently.

First I called it like this:
Code: Select allESPTemplateProcessor(server).send(String("/index2.html"), indexProcessor);


Now like this:
Code: Select allESPTemplateProcessor(server).send(String("/index2.html"), indexProcessor, '%',true); 


The 'True' at the end sets SuppressSerial.