Switch to desktop version  
Historical Logging & Memory Optimised - Printable Version

+- Ewon Technical Forum (https://techforum.ewon.biz)
+-- Forum: Development (https://techforum.ewon.biz/forum-50.html)
+--- Forum: BASIC Script (https://techforum.ewon.biz/forum-52.html)
+--- Thread: Historical Logging & Memory Optimised (/thread-1172.html)



Historical Logging & Memory Optimised - DOne - 11-02-2020

[font=medium-content-sans-serif-font, -apple-system, BlinkMacSystemFont,]Hello everyone,
[/font]

[font=medium-content-sans-serif-font, -apple-system, BlinkMacSystemFont,]I have an eWon Flexy 205 where 15 tags are historically recorded with a recording interval of 2sec (0.5Hz). 
They have each an incremental log file icr_XXXXX.txt which are sent to an FTP server every day at midnight.

In which memory of the eWon are these files stored?

What is the optimal choice of memory organization:
- record size at 29MB and 6MB for the /usr directory?
- record size at 21MB and 14MB for the /usr directory?
- record size at 16MB and 19MB for /usr ?

I also wanted to know if it was possible to record the tags only for 24H, send the data, then reset the file and start again?
Even if I use the EBD which allows me to get the data since the last 24H:

"[$dtHL $ftT $st_d1 $and_m0 $tnXXX]"

The file icr_XXXXXX.txt takes up space unnecessarily and should therefore be overwritten by new data in the next 24 hours.

Tank you so much for you answers and advices
[/font]

[font=medium-content-sans-serif-font, -apple-system, BlinkMacSystemFont,]John[/font]


RE: Historical Logging & Memory Optimised - simon - 12-02-2020

John,

All historical data are stored in the "recording size" memory (6, 14 or 19 MB). It is a binary file. The txt files (per tag) you see is just a representation of the data you can get (with an EBD).
The FIFO mechanism is handled by the system automatically. So no need to erase the datalogging after having sent it.
However, if you really want to erase it, you can do it with the BASIC command ERASE "#ircall"

Simon


RE: Historical Logging & Memory Optimised - DOne - 12-02-2020

Thank you very much for your answer!

The memory space actually occupied by all the historical data is identified by the size of the binary file (ircall.bin) ?
If the use of ewon is limited to data historization, a size of 19 is preferable ?

If several tag groups are defined at different logging intervals and space is missing at the level of one tag, the FIFO mechanism is applied only at this tag or can damage the records of other tags ?


RE: Historical Logging & Memory Optimised - simon - 14-02-2020

Hi,

Yes, you can then use the highest memory config (19 MB = 1.000.000 records)

The memory is managed globally, regardless which tags is stored (like a flat file).
So when the buffer "circularizes", records from different tags are erased.

Simon


RE: Historical Logging & Memory Optimised - Corinna - 28-05-2020

Can I simply delete the ircall.bin to start from 0 recording history data?
Can I delete the irc - historical logs also?


RE: Historical Logging & Memory Optimised - simon - 28-05-2020

Hi,

Yes, by using
ERASE "#ircall"


RE: Historical Logging & Memory Optimised - Corinna - 02-06-2020

(28-05-2020, 03:32 PM)simon Wrote: Hi,

Yes, by using
ERASE "#ircall"

In the BASIC IDE ? Only this expression?
How can I test if it worked?


RE: Historical Logging & Memory Optimised - simon - 02-06-2020

You can read the historical logging from your Ewon (using File Transfer --> irc_x files), execute the command and then read the data file again.


RE: Historical Logging & Memory Optimised - Corinna - 02-06-2020

It did not work when I add it at the bottom of the script, but it works when I put it at the beginning of the Script.

Do the irc_x files not disappear from File transfer then?


RE: Historical Logging & Memory Optimised - simon - 04-06-2020

No, it does not disappear from File Transfer.
The File Transfer just shows you what is available. After the Erase "#ircall", the file will be simply empty.

Simon