Siemens 6AV6651-7KA01-3AA4 - S7-1200 + KTP400 Basic Starter Kit 6AV6651-7KA01-3AA4 Manual Do Utilizador

Códigos do produto
6AV6651-7KA01-3AA4
Página de 364
 
Programming made easy 
 
6.4 Easy to create data logs 
Easy Book 
Manual, 03/2014, A5E02486774-AF 
113
 
 
Table 6- 22  DataLogCreate and DataLogNewFile instructions 
LAD/FBD 
SCL 
Description 
 
"DataLogCreate_DB"( 
    req:=_bool_in_, 
    records:=_udint_in_, 
    format:=_uint_in_, 
    timestamp:=_uint_in_, 
    done=>_bool_out_, 
    busy=>_bool_out_, 
    error=>_bool_out_, 
    status=>_word_out_, 
    name:=_string_inout_, 
    ID:=_dword_inout_, 
    header:=_variant_inout_, 
    data:=_variant_inout_); 
DataLogCreate
1
 creates and initializes a 
data log file stored in the \DataLogs 
directory of the CPU. The data log file is 
created with a pre-determined fixed size.  
 
"DataLogNewFile_DB"( 
    req:=_bool_in_, 
    records=:_udint_in_, 
    done=>_bool_out_, 
    busy=>_bool_out_, 
    error=>_bool_out_, 
    status=>_word_out_, 
    name=:_DataLog_out_, 
    ID:=_dword_inout_); 
DataLogNewFile
1
 allows your program to 
create a new data log file based upon an 
existing data log file. A new data log will be 
created and implicitly opened based with 
the specified NAME. The header record will 
be duplicated from the original data log 
along with the original data log properties. 
The original data log file will be implicitly 
closed. 
 
1
  The DataLogCreate and DataLogNewFile operations extend over many program scan cycles. The actual time required 
for the log file creation depends on the record structure and number of records. Before the new data log can be used for 
other data log operations, your program logic must monitor the transition of the DONE bit to TRUE.