CONCAT_DATE_TOD block

Short summary

Name

CONCAT_DATE_TOD

→POU type

→function

Category

IEC-block, Time

Conform to →IEC-standard

images/s/b2ic8e/9012/1ca6q62/_/images/icons/emoticons/error.svg currently restricted
(IEC demands error handling, if the result of the block exceeds the range of values for the output data type. See " No check of invalid connections " for the behavior in logi.CAD 3. )

Graphical interface

images/download/thumbnails/414782766/CONCAT_DATE_TOD-version-1-modificationdate-1535104999069-api-v2.png

Available since

version 1.19.0 (for logi.CAD 3)

Functionality

The block concatenates (combines) a date and a time of day to a date with time of day (DATE_AND_TIME). Enter date and time at the corresponding inputs.

No check of invalid connections

For some blocks, invalid connections are not checked by logi.CAD 3. Therefore, enter code in your application to detect invalid connections (e.g. IF-statements in the ST-code).

See "IEC-blocks for the application" for information what the consequences of an invalid connection might be.

Inputs, return value


Identifier

→Data type

Description

Inputs:

IN1

DATE

date

IN2

TIME_OF_DAY

time

Return value:

DATE_AND_TIME


Input EN and output ENO are available when →calling the block. See "Execution control: EN, ENO" for information on input EN and output ENO.

See:

Example for usage within ST-editor

PROGRAM Test
VAR
result : DATE_AND_TIME;
END_VAR
result := CONCAT_DATE_TOD(D#2014-03-12, TOD#12:30:00); (* The variable 'result' evaluates to 'DT#2014-03-12-12:30:00'. *)
END_PROGRAM

When creating your application within the ST-editor, enter a call of a block by typing the text as requested by the syntax or use Content Assist.