Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

AVEVA™ InTouch HMI

Use DDE items to show historical data

  • Last UpdatedJun 25, 2024
  • 3 minute read

The HistData program includes a set of DDE items that specify how historical data is extracted from log files. These items are part of the HistData internal database. You assign a value to each item.

The following table summarizes HistData items defined in the HistData program.

Item

Data Type

Descriptions

DATADIR

Message

Path of the folder containing historical log files.

DBDIR

Message

Path of the folder containing the contents of the InTouch Tagname Dictionary.

STARTDATE

Message

Start date to extract data from the log file. The format of the start date is MM/DD/YY.

STARTTIME

Message

Start time to extract data from log files. The format of the start time is HH:MM:SS using a 24-hour clock.

DURATION

Message

Length of the data collection interval from log files. DURATION can be expressed as:

  • Weeks (w)

  • Days (d)

  • Hours (h)

  • Minutes (m)

  • Seconds (s)

    Fractional DURATION periods can be specified. For example, DURATION=0.5m is equivalent to 30 seconds. To request a single sample, set DURATION to 0.

INTERVAL

Message

Length of time between data collection intervals. INTERVAL can be expressed in weeks, days, hours, minutes, and seconds. The units of time of an INTERVAL period are the same as a DURATION period.

Fractional intervals can be specified. For example, INTERVAL=0.25d represents 6 hours.

The maximum period for DURATION or INTERVAL is six weeks. The maximum six week period applies to any time value assigned to DURATION or INTERVAL. For example, 42 is the maximum number of days of an DURATION or INTERVAL period.

FILENAME

Message

Name and folder location of the file containing data extracted from the historical log file.

WRITEFILE

Integer

Flag that indicates the status of HistData write operation to the output file. When set to 1, HistData writes the requested data to the file specified by the FILENAME Item Name. When the file update is complete, WRITEFILE automatically resets to 0.

ERROR

Message

String containing a description of the last error that occurred while extracting data from log files. When STATUS is set to 1, the ERROR string is set to None. When STATUS is set to 0, the ERROR string contains an error message.

TAGS1, TAGS2,...

Message

String containing the name of one or more tags whose data is extracted from the log files.

The TAGS string can be 131 characters in WindowViewer and 255 characters in Excel.

The string can be appended for longer requests by adding tag items named Tagsn, where n represents an incrementing integer.

If a tag needs additional tag text, place a plus (+) at the end of the string.

For example:

TAGS="$Date,ProdLevel,ProdTemp,+"
TAGS1="ReactLevel,Temp,GasLevel,+"
TAGS2="MotorStatus"

Duplicate tags are not allowed and the maximum length of each tag’s string is 512 bytes.

PRINTTAGNAMES

Discrete

Flag that indicates whether the names of tags are placed above the associated column of values. When set to 1, tag names are printed. When set to 0, tag names are not printed.

DATA

Message

This item holds the requested data in the HistData program in comma separated values format. It is used by other applications to ADVISE or REQUEST data by DDE.

STATUS

Discrete

Status of the most current HistData operation.

A value of 1 indicates HistData successfully extracted historical data from the log file. A value of 0 indicates that an error occurred.

SENDDATA

Integer

Flag that indicates the status of the HistData update operation. When set to 1, HistData updates the DATA item with the requested data. When the update is complete, SENDDATA automatically resets to 0.

If you receive an error message indicating too much data was requested using SENDDATA, shorten the DURATION period or reduce the number of requested tags. Duplicate tags are not allowed and the maximum length of each tag’s string is 512 bytes.

TitleResults for “How to create a CRG?”Also Available in