I am looking for a project, basic code, to have an ESP32 on an existing network receive data from a few ESP8266 clients sending T sensor data and serve up a webpage of the data on the ESP32. Sockets preferred to get regular updates, but open to suggestions.
I dont care if example code for includes some specific T sensor code, I will sub what I need
for that.
I have tried quite a few different web examples, many would not compile, fixed some
errors, but never got to the goal . Not a network guy, read a ton of stuff, and its a pile
of feathers swirling around in my raisin side brain pan.
I would need code for both ESP8266 basic > ESP32 aggregator.
Data rates just T and Humidity, every 5 minutes or so, total of 4-5 ESP8266's
sending the data. To be viewed on a web page on local network as served
by ESP32 on attached to local network. ESP32 not in STA mode as the web page
viewed over remote access, eg. property is remote, running its own network.
That way remote access is not broken moving local net to an ESP32 generated
net.
You have many options like mentioned already here. Having one client or four doesn't really change anything.
Pick some quality tutorial and choose communication method.
you have several options for example UDP, TCP or HTTP and I suggest you read my general summary in a first step:
As you mentioned that your ESP32 should run a webserver anyway I would chose HTTP as protocol and set up a HTTP Client on the ESP8266. You just need to transmit the data as key value pairs from the client to the server and extract the transmitted data with some simple functions of the HTTP Server.
here I have example sketches with should work together as Client -> Server.