Configure

Configuring the algorithm.

Syntax

Definition:

METHOD Configure : BOOL
VAR_INPUT
    sConfigId : STRING;
    sDataKey : STRING;
    tInterval : LTIME;
    bIncludeTimestamps : BOOL;
    nBufferSize : UDINT;
    bBufferOnEvent : BOOL;
END_VAR

Configure 1: Inputs

Name

Type

Description

sConfigId

STRING

Indicates the name of the report. The name must correspond to the name of the configuration file at the Reporting Server.

sDataKey

STRING

The data key should be unique within a report. The data object can be uniquely assigned to the report via the data key.

tInterval

LTIME

Time interval at which the data should be sent to the Reporting Server.

bIncludeTimestamps

BOOL

Inserts a column with the timestamps.

nBufferSize

UDINT

Indicates the size of the buffered data. If the buffer size is equal to one, a key-value structure is built. If the buffer size is greater than one, the data is presented in a table.

bBufferOnEvent

BOOL

Indicates how the data is to be collected and buffered.
If the parameter is True, the data of the inputs is buffered at each edge signal at the input. As soon as the Buffer Count output has the same value as the Buffer Size parameter, the data is sent to the TcReportingServer.
If the parameter is False, the data of the inputs are buffered in the buffer at each cycle. Once the buffer size is reached, the new data replaces the previous data. If there is an edge signal at the input, the data is sent to the TcReportingServer.

Configure 2: Return value

Name

Type

Description

Configure

BOOL

Returns TRUE if successful.