Double Precision Integer Type (Dint) Real Number Type (Real) Conversion - Mitsubishi Electric MELSEC Q Series Programming Manual

Structured text
Hide thumbs Also See for MELSEC Q Series:
Table of Contents

Advertisement

6 IEC FUNCTIONS
6.1.6 Double precision integer type (DINT) real number type (REAL) conversion DINT_TO_REAL
Double precision integer type (DINT) data is converted into real number type (REAL) data.
Function definition
Function definition
6 - 8
REAL DINT_TO_REAL ( DINT S1 );
Argument
Argument Name
IN/OUT
S1
IN
Return value
Return Value
REAL
Conversion result (real number data)
Example of use
Argument Type
DINT
r_data1 :=
DINT_TO_REAL(di_data1);
BOOL DINT_TO_REAL_E( BOOL EN, DINT S1, REAL D1 );
Argument
Argument Name
IN/OUT
EN
IN
S1
IN
D1
OUT
Return value
Return Value
BOOL
Execution condition
Example of use
(*
When execution condition X0 turns ON, the double precision integer type
(*
(DINT) data in dData is converted into real number type (REAL) data, and the
(*
result is stored into Result.
M0 := DINT_TO _REAL_E ( X0, dData, Result ) ;
Data to be converted (BIN 32-bit data)
ST Program
Conversion Result
LD
DFLT
Execution condition (Function is executed only when the result is TRUE)
Data to be converted (BIN 32-bit data)
Conversion result (real number data)
DINT_TO_REAL_E
Description
Description
Used Instruction
SM400
LD,DFLT
di_data1
r_data1
Description
Description
*)
*)
*)
6 - 8

Advertisement

Table of Contents
loading

This manual is also suitable for:

Melsec l series

Table of Contents