![background image](http://html1.mh-extra.com/html/omron/cvm1d/cvm1d_operation-manual_742532036.webp)
30
Signed binary data can have either a positive and negative value. The sign is
indicated by the status of bit 15. If bit 15 is OFF, the number is positive and if bit 15
is ON, the number is negative. Positive signed binary values range from 0
($0000) to 32,767 ($7FFF), and negative signed binary values range from
–32,768 ($8000) to –1 ($FFFF).
Bit number
Contents
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
15
14
13
12
11
10
09
08
07
06
05
04
03
02
01
00
Digit value
16
3
16
2
16
1
16
0
Sign indicator
Eight-digit positive values range from 0 ($0000 0000) to 2,147,483,647 ($7FFF
FFFF), and eight-digit negative values range from –2,147,483,648 ($8000
0000) to –1 ($FFFF FFFF).
Positive signed binary data is identical to unsigned binary data (up to 32,767)
and can be converted using BIN(100). The following procedure converts nega-
tive decimal values between –32,768 and –1 to signed binary. In this example
–12345 is converted to CFC7.
Bit number
Contents
0
0
1
1
0
0
0
0
0
0
1
1
1
0
0
1
15
14
13
12
11
10
09
08
07
06
05
04
03
02
01
00
1. First take the absolute value (12345) and convert to unsigned binary:
Bit number
Contents
1
1
0
0
1
1
1
1
1
1
0
0
0
1
1
0
15
14
13
12
11
10
09
08
07
06
05
04
03
02
01
00
2. Next take the complement:
Bit number
Contents
1
1
0
0
1
1
1
1
1
1
0
0
0
1
1
1
15
14
13
12
11
10
09
08
07
06
05
04
03
02
01
00
3. Finally add one:
Reverse the procedure to convert negative signed binary data to decimal.
Signed Binary
Converting Decimal to
Signed Binary
Data Area Structure
Section 3-2
Summary of Contents for CVM1D
Page 462: ...SYSMAC CVM1D Duplex System Programmable Controllers Operation Manual Revised August 2001...
Page 463: ...iv...
Page 465: ...vi...