Ewon Technical Forum

Full Version: Export Block Descriptor - Exported File Discrepancies
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I have an EWON with a BASIC script setup to FTP files back to my server. The function is as follows and runs on a ONDATE timer.

Code:
FUNCTION FtpHourlyInit()
fileName$ = ewonName$ + "_eWON_Hourly_" + @GetDateTime$() + ".csv"
exportRequirements$ = "[$dtHT $ftT $st_m60 $et_s0 $in60]"
PUTFTP fileName$, exportRequirements$
//PRINT "FTP Hourly Sent"
ENDFN

Code:
ONDATE 1, "*/10 * * * *", "@FtpHourlyInit()" //Execute every 10 minutes

The generated file that uses the above function is differing slightly each time it is being ran.

E.g. The above script generates a file every 10 mins. I've have attached two files generated from the EWON (Converted to .txt)

[attachment=1577]
[attachment=1578]

If you look at the values, you'll see that they differ even though the timestamp is the same. This is also different from the Historical Logging file.

Can you please explain how the export block descriptor works from a timestamp perspective as the generated files timestamps also differ from the Historical logging files of each tag.

I need to ensure the data is consistent across all files as this is paramount for our energy consumption data.

Thanks in advance.
Hi,

I think it is linked to the option $in60 which is rebuilding the table to have a fix interval of 60 sec.
It seems all records are shifted of 1 min in the second file.

How often are these tags recorded ?
(08-03-2023, 12:13 PM)simon Wrote: [ -> ]Hi,

I think it is linked to the option $in60 which is rebuilding the table to have a fix interval of 60 sec.
It seems all records are shifted of 1 min in the second file.

How often are these tags recorded ?

Hi Simon,

Thank you for the quick response.

Yes they're all off by 1 minute and each of the tags are logging at 1 minute also. 

What do you suggest?
Can you try without $in ??
Or you absolutely want round timestamps ?
(08-03-2023, 04:52 PM)simon Wrote: [ -> ]Can you try without $in ??
Or you absolutely want round timestamps ?

I'll try this and test it for a couple of days and let you know the outcome. Thanks again.