10 Application Instructions API 202-313 API 203 Operands: S 1 : Source value S 2 : Parameter D : Destination device Explanations: 1. See the specifications of each model for the range of operands. 2. Flags: M1162 (decimal integer or binary floating point); M1162 = On -> Binary floating point 3. Settings of S 2 for 16-bit instruction: S 2 occupies 4 consecutive devices in 16-bit instruction. 4. Settings of S 2 for 32-bit instruction: S 2 occupies 8 consecutive devices in 32-bit instruction. 5. Operation equation in the instruction: D = [( S 1 – min. source value) Ч (max. destination value – min. destination value)] ч (max. source value – min. source value) + min. destination value 6.
The operational relation between source value and destination value is as stated below: y = kx + b y= Destination value ( D ) k= Slope = (max. destination value – min. destination value) ч (max. source value – min. source value) x= Source value ( S 1 ) b= Offset = Min. destination value – Min. source value Ч slope DVP-PLC Application Manual 10-3 Mnemonic Operands Function D SCLP P Parameter Proportional Value Calculation Type OP Bit Devices Word Devices Program Steps X Y M S K H KnX KnY KnM KnS T C D E F SCLP, SCLPP: 7 steps DSCLP, DSCLPP:
13 steps S 1 * * * S 2 * D * PULSE 16-bit 32-bit EH3 EH3 EH3 ES EX SS SA SX SC EH SV ES EX SS SA SX SC EH SV ES EX SS SA SX SC EH SV SV2 SV2 SV2 PULSE 16-bit 32-bit EH3 SV2 EH3 EH3 ES EX SS SA SX SC EH SV ES EX SS SA SX SC EH SV ES EX SS SA SX SC EH SV SV2 SV2 Device No. Parameter Range S 2 Maximum source value -32,768 ~ 32,767 S + 1 2 Minimum source value -32,768 ~ 32,767 S + 2 2 Maximum destination value -32,768 ~ 32,767 S + 3 2 Minimum destination value -32,768 ~ 32,767 Device No.
Parameter Range Integer Floating point S , S + 1 2 2 Maximum source value -2,147,483,648 ~ 2,147,483,647 Range of 32-bit floating point S + 2, 3 2 Minimum source value S + 4, 5 2 Maximum destination value S + 6, 7 2 Minimum destination value