Data conversion instructions Chapter 12
Rockwell Automation Publication 2080-RM001D-EN-E - February 2015 287
ANY_TO_REAL converts a value to a Real value.
Arguments
Parameter Parameter Type Data Type Description
EN Input BOOL Function enable.
When Enable = TRUE, execute the conversion to the Real computation.
When Enable = FALSE, there is no computation.
Applies only to LD programs.
i1 Input BOOL - SINT - USINT - BYTE - INT -
UINT - WORD - DINT - UDINT -
DWORD - LINT - ULINT - LWORD -
LREAL - TIME - DATE - STRING
Any value other than Real.
o1 Output REAL A real value.
ENO Output BOOL Enable out.
Applies only to LD programs.
ANY_TO_REAL operator ST language example
(* ST Equivalence: *)
bres := ANY_TO_REAL (true);
tres := ANY_TO_REAL (t#1s46ms);
ares := ANY_TO_REAL (198);