![](https://csdnimg.cn/release/download_crawler_static/87247332/bg3.jpg)
This design is the use of MSC-51 microcontroller to design
the four-digit calculator, using C programming language to
achieve calculator functions. 4X4 external keyboard, the
keyboard scan to finish by the number of control values and
make the drive circuit to the cathode results in a total of
seven-segment digital tube display properly, and has cleared
at any time to complete key calculation and display clear.
Calculator to complete an integer from 0 to 9999 plus / minus
/ multiply / divide.
Implementation of the process is as follows:
Power is displayed 0, waiting type value, when the input
numbers, will come out through the digital display, the input
+,-,*,/ operator, the calculator in the internal implementation
of the numerical conversion and storage, and wait for the
re-enter the value, when Type the value in the type of value
will be displayed by an equal sign will be displayed in the
digital control operation results.
Key words: SCM calculator keyboard scan C language。
前言
计算器:一般是指“电子计算器”,该文是由日文传入中国。
计算器是能进行数字运算的手持的机器,拥有电子集成芯片,
结构简单,功能较弱,但由于它使用方便,价格低廉,因而