摘要 |
PURPOSE:To detect the fault of a pull-up resistor together with the abnormality of a key switch and to prevent the instable operation or malfunction of a computer by providing standby time between rise time from Low to Hi and rise time delayed when disconnecting the pull-up resistor, and reading an input voltage after the lapse of the standby time. CONSTITUTION:By the input operation of an input part, the standby time for reading the voltage is set within a range between the rise time of a signal inputted to an I/O port from Low to Hi and the rise time when disconnecting the pull-up resistor. An input state is set after outputting a Low signal from the I/O port, an input level is read after the lapse of the standby time and when the level is Low, the abnormality of a pull-up resistor 4 or a key switch 3 is decided. Thus, not only the abnormality in the input part such as the key switch 3 or the like but also the fault of the pull-up resistor 4 in the input part can be detected and without changing a hardware, the malfunction and the instable operation can be easily prevented only by a software. |