Data Types Supported By The S7-1200 - Siemens SIMATIC S7-1200 Getting Started

Hide thumbs Also See for SIMATIC S7-1200:
Table of Contents
1.1.4

Data types supported by the S7-1200

The data type specifies not only the size of a data element, but also the structure of the bits
within the data.
Data type
Bool (Boolean)
Byte
(byte)
Word
(word)
DWord
(double word)
Char
(character)
SInt
(short integer)
USInt
(unsigned short integer)
Int
(integer)
UInt
(unsigned integer)
DInt
(double integer)
UDInt
(unsigned double integer)
Real
(real or floating point)
LReal
(long real)
Time
(time)
String
(character string)
DTL
1
(date and time long)
The DTL data type is a structure of 12 bytes that saves information on date and time in a predefined structure. You can
1
define a DTL in either the Temp memory of the block or in a DB.
Getting started with S7-1200
Getting Started, 11/2009, A5E02486791-01
Size
Range
1 bit
0 to 1
8 bits
16#00 to 16#FF
(1 byte)
16 bits
16#0000 to 16#FFFF
(2 bytes)
32 bits
16#00000000 to 16#FFFFFFFF
(4 bytes)
8 bits
16#00 to 16#FF
(1 byte)
8 bits
-128 to 127
(1 byte)
8 bits
0 to 255
(1 byte)
16 bits
-32,768 to 32,767
(2 bytes)
16 bits
0 to 65,535
(2 bytes)
32 bits
-2,147,483,648 to 2,147,483,647
(4 bytes)
32 bits
0 to 4,294,967,295
(4 bytes)
32 bits
+/-1.18 x 10
(4 bytes)
64 bits
+/-2.23 x 10
(8 bytes)
32 bits
T#-24d_20h_31m_23s_648ms to
(4 bytes)
T#24d_20h_31m_23s_647ms
Stored as: -2,147,483,648 ms
to +2,147,483,647 ms
Variable
0 to 254 byte-size characters
12 bytes
Minimum:
DTL#1970-01-01-00:00:00.0
Maximum:
DTL#2554-12-31-23:59:59.999 999 999
1.1 Basic information about how the CPU works
to +/-3.40 x 10
-38
38
to +/-1.79 x 10
-308
308
Quick review
Constant Entry Examples
TRUE, FALSE, 0, 1
16#12, 16#AB
16#ABCD, 16#0001
16#02468ACE
'A', 't', '@'
123, -123
123
123, -123
123
123, -123
123
123.456, -3.4, -1.2E+12,
3.4E-3
12345.123456789
-1.2E+40
T#5m_30s
5#-2d
T#1d_2h_15m_30x_45ms
'ABC'
DTL#2008-12-16-
20:30:20.250
11

Hide quick links:

Table of Contents
loading

Table of Contents