Page 1 of 1

how to pass values from esp32 to html like web server

Posted: Fri Aug 30, 2019 5:54 pm
by megatronixs
Hi all,

I'm new to the forum.
I started first with Arduino Uno board and after hearing about the ESP32 I wanted to give it a try.
I found the web server example here below:
https://randomnerdtutorials.com/esp32-d ... duino-ide/

and wanted to modify it to include the RTC DS3231 module value as well in the html page. Wanted to get the date and time below the temperature and humidity.

I have been looking around in google to find some examples how to do this, but no luck.
Maybe some one can explain me how I can pass values from the RTC to the html page like the temperature and humidity.

Thank you in advance.

Re: how to pass values from esp32 to html like web server

Posted: Sun Sep 01, 2019 3:27 am
by RoverDog
Hey,
You probably want to get a web server going 1st: https://randomnerdtutorials.com/esp32-w ... duino-ide/

Once you have that working, there are various ways to display content, you can move onto something like AJAX which will help you gather real time data from the ESP32 back to your browser using some JavaScript.

First you need a good understanding of what you want to achieve : https://javascript.info/xmlhttprequest

So you can read one value at a time using XMLHttpRequest or the newer version https://developer.mozilla.org/en-US/doc ... sing_Fetch or you can pass multiple values back via the XML data format.

Do some googling on the above and let us know if you came right... ;)

Re: how to pass values from esp32 to html like web server

Posted: Mon Sep 02, 2019 3:27 am
by RoverDog

Re: how to pass values from esp32 to html like web server

Posted: Sun Sep 15, 2019 6:39 am
by megatronixs
HI all,

Sorry for my late reply.
I had not time yet to look at it, but will do for sure and post back once I get it working.

Greetings.