X-Git-Url: https://gerrit.simantics.org/r/gitweb?p=simantics%2Fplatform.git;a=blobdiff_plain;f=bundles%2Forg.simantics.history%2Fsrc-isv%2Ftrend_collector.mediawiki;h=d4dc797a9006e7e89e90c26f000175add377b586;hp=8137cbff5990bc3bb5213ec26059cc2073a88003;hb=0ae2b770234dfc3cbb18bd38f324125cf0faca07;hpb=24e2b34260f219f0d1644ca7a138894980e25b14 diff --git a/bundles/org.simantics.history/src-isv/trend_collector.mediawiki b/bundles/org.simantics.history/src-isv/trend_collector.mediawiki index 8137cbff5..d4dc797a9 100644 --- a/bundles/org.simantics.history/src-isv/trend_collector.mediawiki +++ b/bundles/org.simantics.history/src-isv/trend_collector.mediawiki @@ -1,94 +1,94 @@ -=History and Collector in Charts and Trends= -There is a specified way how trend manages the items in the history. -The "id"-field of an history item has the following format: "subscriptionId-variableId-formatId". -Therefore the files are named in the same notation (appended with the different extensions ".data", ".txt", ".index"). - -The trend's history item format has the following record: - { - id : String, - variableId : String, // Simantics RVI - format : Datatype, - deadband : Double, // NaN = No deadband - interval : Double, - gain : Double, - bias : Double, - enabled : Boolean, - groupId : String, // Subscription Id - groupItemId : String, // Subscription Item Id - formatId : String // One of: "all", "100ms", "1s", "10s", "60s", or "minmax" - } - - -Each datasource variable is sampled into 5-6 separated files with different interval. -The sampling formats are named. Some formats may be omited if subscription configuration suggests so. For example, if "subscription interval = 250ms" then, the files "all" and "100ms" are omited. -{| border="1" cellpadding="3" cellspacing="0" align="center" -|- style="background-color: #f9f9f9;" -|'''SamplingFormat-Id''' -|'''Description''' -|- -|"all" -|All datasource samples are stored here. -|- -|"100ms" -|Samples are written with (atleast) 100ms interval. -|- -|"1s" -|Samples are written with (atleast) 1000ms interval. -|- -|"10s" -|Samples are written with (atleast) 10000ms interval. -|- -|"60s" -|Samples are written with (atleast) 60000ms interval. -|- -|"minmax" -|File contains only one sample and it has fields { time, value, endTime, min, max }. Not used for with binary variable. -|} - -The file format for analog variables is the following: -{| border="1" cellpadding="3" cellspacing="0" align="center" -|- style="background-color: #f9f9f9;" -|'''SamplingFormat-Id''' -|'''Sample RecordType''' -|- -|"all" -|{ time:Double, endTime:Double, value:Double, quality:Byte } -|- -|"100ms" -|{ time:Double, endTime:Double, value:Double, min:Double, max:Double, avg:Double, quality:Byte } -|- -|"1s" -|{ time:Double, endTime:Double, value:Double, min:Double, max:Double, avg:Double, quality:Byte } -|- -|"10s" -|{ time:Double, endTime:Double, value:Double, min:Double, max:Double, avg:Double, quality:Byte } -|- -|"60s" -|{ time:Double, endTime:Double, value:Double, min:Double, max:Double, avg:Double, quality:Byte } -|- -|"minmax" -|{ time:Double, endTime:Double, value:Double, min:Double, max:Double } -|} - -The file format for binary variables is the following: -{| border="1" cellpadding="3" cellspacing="0" align="center" -|- style="background-color: #f9f9f9;" -|'''SamplingFormat-Id''' -|'''Sample RecordType''' -|- -|"all" -|{ time:Double, endTime:Double, value:Byte, quality:Byte } -|- -|"100ms" -|{ time:Double, endTime:Double, value:Byte, max:Byte, quality:Byte } -|- -|"1s" -|{ time:Double, endTime:Double, value:Byte, max:Byte, quality:Byte } -|- -|"10s" -|{ time:Double, endTime:Double, value:Byte, max:Byte, quality:Byte } -|- -|"60s" -|{ time:Double, endTime:Double, value:Byte, max:Byte, quality:Byte } -|} - +=History and Collector in Charts and Trends= +There is a specified way how trend manages the items in the history. +The "id"-field of an history item has the following format: "subscriptionId-variableId-formatId". +Therefore the files are named in the same notation (appended with the different extensions ".data", ".txt", ".index"). + +The trend's history item format has the following record: + { + id : String, + variableId : String, // Simantics RVI + format : Datatype, + deadband : Double, // NaN = No deadband + interval : Double, + gain : Double, + bias : Double, + enabled : Boolean, + groupId : String, // Subscription Id + groupItemId : String, // Subscription Item Id + formatId : String // One of: "all", "100ms", "1s", "10s", "60s", or "minmax" + } + + +Each datasource variable is sampled into 5-6 separated files with different interval. +The sampling formats are named. Some formats may be omited if subscription configuration suggests so. For example, if "subscription interval = 250ms" then, the files "all" and "100ms" are omited. +{| border="1" cellpadding="3" cellspacing="0" align="center" +|- style="background-color: #f9f9f9;" +|'''SamplingFormat-Id''' +|'''Description''' +|- +|"all" +|All datasource samples are stored here. +|- +|"100ms" +|Samples are written with (atleast) 100ms interval. +|- +|"1s" +|Samples are written with (atleast) 1000ms interval. +|- +|"10s" +|Samples are written with (atleast) 10000ms interval. +|- +|"60s" +|Samples are written with (atleast) 60000ms interval. +|- +|"minmax" +|File contains only one sample and it has fields { time, value, endTime, min, max }. Not used for with binary variable. +|} + +The file format for analog variables is the following: +{| border="1" cellpadding="3" cellspacing="0" align="center" +|- style="background-color: #f9f9f9;" +|'''SamplingFormat-Id''' +|'''Sample RecordType''' +|- +|"all" +|{ time:Double, endTime:Double, value:Double, quality:Byte } +|- +|"100ms" +|{ time:Double, endTime:Double, value:Double, min:Double, max:Double, avg:Double, quality:Byte } +|- +|"1s" +|{ time:Double, endTime:Double, value:Double, min:Double, max:Double, avg:Double, quality:Byte } +|- +|"10s" +|{ time:Double, endTime:Double, value:Double, min:Double, max:Double, avg:Double, quality:Byte } +|- +|"60s" +|{ time:Double, endTime:Double, value:Double, min:Double, max:Double, avg:Double, quality:Byte } +|- +|"minmax" +|{ time:Double, endTime:Double, value:Double, min:Double, max:Double } +|} + +The file format for binary variables is the following: +{| border="1" cellpadding="3" cellspacing="0" align="center" +|- style="background-color: #f9f9f9;" +|'''SamplingFormat-Id''' +|'''Sample RecordType''' +|- +|"all" +|{ time:Double, endTime:Double, value:Byte, quality:Byte } +|- +|"100ms" +|{ time:Double, endTime:Double, value:Byte, max:Byte, quality:Byte } +|- +|"1s" +|{ time:Double, endTime:Double, value:Byte, max:Byte, quality:Byte } +|- +|"10s" +|{ time:Double, endTime:Double, value:Byte, max:Byte, quality:Byte } +|- +|"60s" +|{ time:Double, endTime:Double, value:Byte, max:Byte, quality:Byte } +|} +