The following steps can be used to interpret a decimal
number from a binary value.
1) Search from least to most significant bit for 1s.
2) Write down the decimal representation of each column
containing a 1.
3) Add the column values.
In the following example, the fourth and fifth columns from the
right contain a 1. The decimal value of the fourth column from
the right is 8, and the decimal value of the fifth column from
the right is 16. The decimal equivalent of this binary number is
24. The sum of all the weighted columns that contain a 1 is the
decimal number that the PLC has stored.
No comments:
Post a Comment