Date_Time_Long Data Type; Variant Data Type - Siemens S7-1200 Programming Manualline

Step 7 tia portal, background and system description
Hide thumbs Also See for S7-1200:
Table of Contents

Advertisement

2 S7-1200/1500 Innovations
2.8 New data types for S7-1200/1500
Table 2-9: Floating-point decimal data types
Type
Real
LReal
2.8.2

Date_Time_Long data type

Table 2-10: Structure of DTL (Date_Time_Long)
Year
DTL always reads the current system time. Access to the individual values is
through the symbolic names (e.g. My_Timestamp.Hour)
Advantages
All partial areas (e.g. Year, Month, ...) can be addressed symbolically.
Recommendation
Use the new DTL data type instead of LDT and address symbolically (e.g.
My_Timestamp.Hour).
Note
You will find further information in the following entries:
In STEP 7 (TIA Portal), how can you input, read out and edit the date and time
for the CPU modules of S7-300/S7-400/S7-1200/S7-1500?
http://support.automation.siemens.com/WW/view/en/58387452
Which functions are available in STEP 7 V5.5 and in TIA Portal for processing
the data types DT and DTL?
http://support.automation.siemens.com/WW/view/en/63900230
2.8.3

VARIANT data type

A parameter of the VARIANT type is a pointer that can point to tags of different
data types. In contrast to the ANY pointer the VARIANT is a pointer with type test.
The target structure and source structure are checked at runtime and have to be
identical.
VARIANT is used, for example, as input for communication blocks (TSEND_C).
Programming Guideline for S7-1200/1500
V1.2, Entry ID: 81318674
Size
32 bit (1 bit signs, 8 bit exponent, 23 bit mantissa),
accurate to 7 decimal places
64 bit (1 bit signs, 11 bit exponent, 52 bit
accurate to 15 decimal places
mantissa),
Month
Day
Weekday
-3.40e+38 .. 3.40e+38
-1.79e+308 .. 1.79e+308
Hour
Minute
Second
Value range
Nanosecond
18

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

S7-1500

Table of Contents