My embedded CPU has a poor implementation for the async Web server, in that it uses heap space to recreate a valid json file that is to be replied back when a request for a graph is made.
The graph has to have up to 2 years of data, and can be about 2Mb. There is enough SDRAM to hold it, but not enough microcontroller RAM (the CPU allocates regular RAM at 2x-3x the size of the string passed).
Assuming the library creator is unable to optimize this, my only solution is to break up the 2 years of graph into 24 month JSON strings – and send them individually.
I am using JQuery. Is there a best way you can see how this should be implemented, and can the data be passed to the chart elements one month at a time, or should the entire array be concatenated before sending to the chart.
Thanks
-
This topic was modified 2 years ago by salasidis.
-
This topic was modified 2 years ago by salasidis.