Mitsubishi — 5.6 Descriptions of the Applied Instructions

AH500 Motion Control Module Manual  S 1 : Binary floating-point number 1; S 2 : Binary floating-point number 2; D : Explanation Comparison result (D occupies three consecutive devices.)  The instruction is used to compare the binary floating-point value in S 1 with that in S 2 . The comparison result is stored in D .  If S 1 is a floating-point number, the instruction will be used to compare the floating-point number with the binary floating-point value in S 2 . If S 2 is a floating-point number, the instruction will be used to compare the binary floating-point value in S 1 with the floating-point number.  F represents a floating-point number.

There is a decimal point in a floating-point number.  If the operand D is M10, M10, M11, and M12 will be occupied automatically.  When X0.0 is ON, the instruction DECMP is executed, and M10, M11, or Example M12 is ON. When X0.0 is OFF, the execution of the instruction DECMP stops, and the states of M10, M11, and M12 remain unchanged .  If users want to get the result that the value in (D1, D0) ≧ the value in (D101, D100), they have to connect M10 and M11 in series. If users want to get the result that the value in (D1, D0) ≦ the value in (D101, D100), they have to connect M11 and M12 in series.

If users want to get the result that the value in (D1, D0)≠the value in (D101, D100), they have to connect M10, M11, and M12 in series.  If users want to reset M10, M11, or M12, they can use the instruction RST or ZRST. X0.0 M10 If the value in (D1, D0)>the value in (D101, D100), M10 will be ON. M11 If the value in (D1, D0)=the value in (D101, D100), M11 will be ON. M12 If the value in (D1, D0) Additional remark  Please refer to section 5.3 for more information about performing operations on floating-point numbers.

5-78 API Instruction code Operand Function Comparing binary 110 D ECMP P S , S , D 1 2 floating-point numbers Device Xn.n Yn.n M S K 16# F KnM KnS D W T C V Z S 1    S 2    D    Pulse instruction 16 -bit instruction 32-bit instruction (9 steps )  –  DECMP D0 D100 M10