Safe data types
The following data types
are used in the safe blocks
.
Each of the following safe data types is a directly →derived data type
. Its base type is an elementary data type according to
"Supported data types (in ST)".
Name |
Base type |
SAFEBOOL |
BOOL |
SAFEBYTE |
BYTE |
SAFEDATE |
DATE |
SAFEDINT |
DINT |
SAFEDT |
DATE_AND_TIME |
SAFEDWORD |
DWORD |
SAFEINT |
INT |
SAFELINT |
LINT |
SAFELREAL |
LREAL |
SAFELWORD |
LWORD |
SAFEREAL |
REAL |
SAFESINT |
SINT |
SAFETIME |
TIME |
SAFETOD |
TIME_OF_DAY |
SAFEUDINT |
UDINT |
SAFEUINT |
UINT |
SAFEULINT |
ULINT |
SAFEUSINT |
USINT |
SAFEWORD |
WORD |
Observe:
If you connect the input/output of a block for safe logic to one of these safe data types , the background color of this block might be changed to a shade of yellow. Details: See " Highlighting safe logic in the FBD-editor".
Due to the implicit conversion of logi.CAD 3 you do not have to enter additional code in your application, if you want to convert a safe data type to its base type. Example: The safe data type SAFEINT can be converted implicitly to its base type INT.
If you want to convert a base type to the corresponding safe data type, you must call the respective safe convert function in the application. Example: Call the TO_SAFEINT block for a conversion from INT to SAFEINT.