DVP-ES3 Series Programming Manual Symbol S : Source value D : Device where the conversion result is stored Explanation _6 1. This instruction converts the signed decimal ASCII code in S into a signed decimal binary number, and stores the conversion result in D . 2. For 16-bit instructions, the operand S occupies three word devices, and the decimal ASCII code in S must be between -32768 to 32767. If the value in S is a string and does not include the ending character 16#00, the conversion can be up to 5 digits (excluding the sign). b15 b8 b7 b0 b15 b0 S + 0 1234 D S + 1 S + 2 3. If the first character is “ ” (a space), the sign is a positive sign.
If the first character is “-”, the sign is a negative sign. Take the string “2345” for example. b15 b8 b7 b0 b15 b0 S + 0 -2345 D S + 1 S + 2 6-636 API Instruction code Operand Function 2103 D DABIN P S, D Converting a signed decimal ASCII code into a signed decimal binary number Device X Y M S T C HC D FR SM SR E K 16# “$” F S D BOOL WORD DWORD LWORD UINT INT DINT LINT REAL LREAL TMR CNT STRING Data type S D Pulse instruction 16-bit instruction 32-bit instruction ES3 ES3 ES3 “ 2 “ “ 1 “ “ 4 “ “ 3 “ 16#00 16#00 “ 2 “ “ - “ “ 4 “ “ 3 “ 16#00 “ 5 “