Delta AH500 Programming Manual page 632

Hide thumbs Also See for AH500:
Table of Contents

Advertisement

AH 5 00 Pr ogr am m ing Ma n ua l
If the data in S~S+3 is -123.45, the calculation is as follows.
b15
b8
S
16#31(1)
S+1
16#
33(3)
S+2
16#
34(4)
S+3
16#
00
If there is 16#20 or 16#30 between the sign character and the first value which is not 0 in the
string, 16#20 or 16#30 is ignored when the string is converted into the binary number.
- 123.45
Ignor ed
Sign
If 16#2E, which represents the decimal point, is ignored, the string in S should be within the
range between -32768 and 32767. For example, if the string is "1235.3", users have to check
whether "12353" is within the range.
3.
D$VAL:
The operand S occupies seven word devices at most.
The number of characters contained in the string in S should be within the range between 2
and 13.
If there is a decimal point in the string in S, 16#2E should be stored between the first character
after the sign character and the last character.
b15
b8
b7
F irst ASCII code
S
T hi rd AS CII c ode
Second A SCII code
S+ 1
F our th ASCII code
F ifth ASCII code
S+ 2
Six th ASCII code
Seventh AS CII c ode
S+ 3
Ninth ASCII code
Eighth AS CII c ode
S+ 4
Elevnth A SCII code
S+ 5
S+ 6
16#00
6 - 4 6 4
b0
b7
16#
2D( -)
16#
32(2)
16#
2E(.)
16#
35(5)
8
2
-12345
0.0012
Ignored
b0
Sign
T enth A SCII code
T welfth AS CII c ode
.
-
4
5
1
2
3
Number of characters
Number of dec imal places
Binary number
Number of characters
7
Number of dec imal pl ac es
4
Binar y number
12
(D1+1,D1)
Number of characters
... .... .... .... .... ..... .... .... .... .... ..... .... .
(D2+1,D2)
Binary number
D1
7
2
D1 +1
- 12345
D2
(D1+3,D1+2)
Number of dec imal plac es

Advertisement

Table of Contents
loading

Table of Contents