Technical data
Memory usage and application examples
3.2 Memory usage for data logging
Structure and Use of the CPU Memory
Function Manual, 01/2013, A5E03461664-01
25
3.2 Memory usage for data logging
3.2.1 Overview of data logging
Your controller program can store process values in Data Logs using the "Data Logging"
instructions. The Data Logs are saved in csv format in the "\datalogs" directory of the
SIMATIC memory card. The data records are organized in a circular Data Log of a
predefined size.
The "Data Logging" instructions are used in your program to create, open and write
Data Logs and to close Data Logs. You decide which tags are to be logged by creating a
data block that defines a single Data Log data record. Your data block is used as temporary
storage for a new Data Log data record. New actual values for the tags must be transferred
into the data block during runtime by means of user program instructions. Once all tag
values have been updated, you can execute the "DataLogWrite" instruction to transfer data
from the data block to the Data Log.
You manage your Data Logs with the integrated Web server. On the standard "File browser"
Web page, you can download or delete Data Logs. Once you have transferred a Data Log to
your PC, you can analyze the data using a standard spreadsheet program such as Microsoft
Excel.
The following figure shows the basic sequence for creating Data Logs:
7DJV
0HPRU\
FDUG
:HEVHUYHU
'DWDORJJLQJ
LQVWUXFWLRQV
?GDWDORJV
&38
'%
FVY
'RZQORDG
Figure 3-3 Basic procedure for creating Data Logs










