3. Instructions
472
CS/CJ/NSJ Series Instructions Reference Manual (W474)
FIX/FIXL
Applicable Program Areas
Operands
z Operand Specifications
Flags
Instruction Mnemonic Variations
Function
code
Function
FLOATING TO 16-BIT FIX @FIX 450
Converts a 32-bit floating-point value to 16-bit
signed binary data and places the result in the
specified result word.
FLOATING TO 32-BIT FIXL @FIXL 451
Converts a 32-bit floating-point value to 32-bit
signed binary data and places the result in the
specified result words.
Symbol
FIX FIXL
Area
Function block
definitions
Block program areas Step program areas Subroutines Interrupt tasks
SFC action or
transition programs
Usage OK OK OK OK OK OK
Operand Description
Data type Size
FIX FIXL FIX FIXL
S First source word REAL REAL 2 2
R First result word INT DINT 1 2
Area
Word addresses
Indirect DM/EM
addresses
Con-
stants
Registers
TK CF
Pulse
bits
TR
bits
CIO WR HR AR T C DM EM
@DM
@EM
*DM
*EM
DR IR
Indirect
using IR
S
OK OK OK OK OK OK OK OK OK OK
OK ---
--- OK --- --- --- ---
R --- OK
Name Label Operation
Error Flag ER • FIX
ON if the integer portion of S+1 and S is not within the range of -32,768 to 32,767.
•FIXL
ON if the integer portion of S+1 and S is not within the range of -2,147,483,648 to 2,147,483,647.
• ON if the data in S+1 and S is not a number (NaN).
• OFF in all other cases.
Equals Flag = • ON if the result is 0000.
• OFF in all other cases.
Negative Flag N • ON if bit 15 of the result is ON.
• OFF in all other cases.
S: First source word
R: Result word
FIX(450)
S
R
S: First source word
R: First result word
FIXL(451)
S
R