using send_P for webpage in Progrgam memory
Posted: Tue Aug 09, 2022 4:30 am
I am doing a webserver using the code at: https://circuitdigest.com/microcontroller-projects/ajax-with-esp8266-dynamic-web-page-update-without-reloading
The esp8266 keeps resetting and that seems to be an issue with storage in Program memory causing a corruption to the main code.
I read the post at https://www.esp8266.com/viewtopic.php?p=48388 But there it uses server.send(...) as my code from the example is doing.
As I understand it, I need to use:
rather than:
I'm getting an error saying that send_P expects 4 arguments.
Can anyone advise how to correctly send a page from prog memory?
thanks
Russell
The esp8266 keeps resetting and that seems to be an issue with storage in Program memory causing a corruption to the main code.
I read the post at https://www.esp8266.com/viewtopic.php?p=48388 But there it uses server.send(...) as my code from the example is doing.
As I understand it, I need to use:
Code: Select all
server.send_P(200, "text/html", s );
rather than:
Code: Select all
server.send(200, "text/html", s );
I'm getting an error saying that send_P expects 4 arguments.
Can anyone advise how to correctly send a page from prog memory?
thanks
Russell