Appendix I: Numbering Systems; Introduction; Binary Numbering System - Automation Direct DL05 User Manual

Micro plc
Hide thumbs Also See for DL05:
Table of Contents

Advertisement

Appendix I: Numbering Systems

Introduction

1
As almost anyone who uses a computer is somewhat aware, the actual operations of a
computer are done with a binary number system. Traditionally, the two possible states for a
2
binary system are represented by the digits for "zero" (0) and "one" (1) although "off" and
"on" or sometimes "no" and yes" are closer to what is actually involved. Most of the time a
typical PC user has no need to think about this aspect of computers, but every now and then
3
one gets confronted with the underlying nature of the binary system.
A PLC user should be more aware of the binary system specifically the PLC programmer.
4
This appendix will provide an explanation of the numbering systems most commonly used
by a PLC.
E

Binary Numbering System

6
Computers, including PLCs, use the Base 2 numbering system, which is called Binary and
often called Decimal. Like in a computer there are only two valid digits a PLC relies on, zero
and one, or off and on respectively. You would think that it would be hard to have a
7
numbering system built on Base 2 with only two possible values, but the secret is by encoding
using several digits.
H
Each digit in the base 2 system when referenced by a computer is called a bit. When four bits
are grouped together, they form what is known as a nibble. Eight bits or two nibbles would
I
be a byte. Sixteen bits or two bytes would be a word (Table 1). Thirty-two bits or two words
is a double word.
10
11
12
Binary is not "natural" for us to use since we grow up using the base 10 system. Base 10 uses
13
the numbers 0-9, as we are all well aware. From now on, the different bases will be shown as a
subscripted number following the number. Example; 10 decimal would be 10
14
Table 2 shows how base 2 numbers relate to their decimal equivalents.
A nibble of 1001
A
11010101
4
+ 1
10
B
C
D
I–2
DL05 Micro PLC User Manual, 6th Edition, Rev. A
Nibble
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
would be equal to a decimal number 9 (1*2
2
would be equal to 213 (1*2
2
).
10
Bit #
15
14
13
15
14
13
Power
2
2
2
2
Decimal
Bit Value
Max Value
Word
Byte
Byte
Nibble
Nibble
Table 1
7
6
4
+ 1*2
+1*2
Binary/Decimal Bit Pattern
12
11
10
9
8
7
12
11
10
9
8
2
2
2
2
2
65535
10
Table 2
Nibble
10
3
0
+ 1*2
or 8
+ 1
10
2
0
+ 1*2
+1*2
or 128
+ 64
10
6
5
4
3
2
7
6
5
4
3
2
2
2
2
2
2
.
). A byte of
10
+ 16
+
10
10
1
0
1
0
2
2

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the DL05 and is the answer not in the manual?

Subscribe to Our Youtube Channel

Table of Contents