Convert the decimal number 75.4 into BCD code: 7-"011,5-"0 1, 4-"0 100, then spell it into 842 1BCD code. If BCD code1000010101is converted into decimal number:1000-"8,010/kloc-.
Note: The numbers represented by the same 8-bit binary code are different when considered as binary numbers and binary coded decimal numbers.
Extended data
Look at the source and use of the data. BCD codes are generally used for input and output. For example, the data of dip switch is BCD code, and the decoding chip displaying elevator floor is BCD code.
842 1 BCD code is the most basic and commonly used BCD code. It is similar to four-bit natural binary code, and the weight of each bit is 8, 4, 2, 1, so it is called authorized BCD code. Different from the four-bit natural binary code, it only selects the first 10 group of codes in the four-bit binary code, that is, 0000~ 100 1 respectively represents its corresponding decimal number, and the other six groups of codes are not used.
BCD code is input in hexadecimal format, and its highest bit (symbol bit is16 # f (2 #11). The lower 3 digits of BCD code can only be 0~9. If it is 16#A~ 16#F, an error will occur. The preset value PV of the counter is BCD code from 0 to 999, and a constant in C# format (C# 1 ~ C # 999) can be used as the preset value of the counter.