Reading a continous flow of data from a webserver

HI, I have a home automation system that give s on a webpage a continuous flow of data (every second) in JSON format for a dozen of measured parameters.

I would need to read them and copy in the corresponding variables.

So globally three steps:

  1. Logging to server ( Digest authentication) - solved I think

  2. reading String from Webpage Every second - NO IDEA HOW TO DO it and found no tutorials/examples

  3. Parsing JSON and extracting data (easiest part I think)

Can anyone help with some links/opinion?

There is a meta tag for refresh; that would probably an easy way. See HTML meta http-equiv Attribute

A refresh every second is a lot; are the server and the browser in te same network? Or is it going to be via the internet (in which case I suspect that you can forget it).

Hi,
Thanks for the answer.
The server and teh client are on the same subnet a few (30) feets between. It is an SSE server so it is transmitting continously. I do not need to refresh teh webpage it just print. I was needing to get the data in a small microcontroller ( Arduino, ESP and alike) and if possibly in a zigbee network in order to control some home automation .
I think I solved the problem by using GetStreamPtr with an ESP8266.
It seems to work fine.

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.