FX Series Programmable Controllers Devices in Detail 4
4-44
c) ABCD conversion
Usin
the ori
inal bit pattern as a base but addin
the followin
BCD headers allows the
conversion of the binar
data into a BCD format.
Binary Coded Decimal value= ERROR!!!!!
It will be noticed that this will produce an ERROR. The conversion will not be correct.
This is because BCD numbers can onl
have values from 0 to 9, but the second block of
4 bit devices from the left would have a value of 14. Hence, the error.
The conversion process is ver
similar to that of hexadecimal except for the mentioned
limit on values of 0 to 9. If the other blocks were converted
ust as an example the
followin
values would be found;
Extreme Left Hand Block= ((1
×
8) + (1
×
1)) = 9
Second Ri
ht Hand Block= ((1
×
4) + (1
×
2) + (1
×
1)) = 7
Extreme Ri
ht Hand Block= ((1
×
4) + (1
×
1)) = 5
BCD data is read from left to ri
ht as a normal number would be read. Therefore, in this
example the “9” would actuall
represent “9000”. The second ri
ht hand block is actuall
“70” not “7”. The units are provided b
the extreme ri
ht hand block, i.e. 5. The hundreds
“100’s” would have been provided b
the second left hand block (which is in error).
It is also important to note that there is no si
n with BCD converted data. The maximum
number allowable for a sin
le data word is “9999” and the minimum is “0000”.
Word Data Summary
In each of the previous cases the ori
inal bit pattern had a further meanin
. To recap the three
new readin
s and the ori
inal bit pattern,
Decimal : -24971
Hexadecimal : 9E75
BCD : Error (9?75)
Each meanin
is radicall
different from the next
et the
are all different wa
s of describin
the same thin
. The
are in fact all equal to each other!
1 0 0 1 1 1 1 0 0 1 1 1 0 1 0 1
8421842184218421
1 0 0 1 1 1 1 0 0 1 1 1 0 1 0 1
1 0 0 1 1 1 1 0 0 1 1 1 0 1 0 1