Patent ID: 7930575

Claim:
A microcontroller comprising: a CPU; a power supply unit arranged between the CPU and a power supply device for supplying power to the CPU; a power supply control unit for controlling the CPU and the power supply unit; an information holding unit for holding information evacuated from the CPU, the information being necessary in proceeding with a program; and a clock generator; wherein: the power supply control unit outputs a shutdown request signal to the CPU in response to an occurrence of a power shutdown factor, the CPU, upon receiving the shutdown request signal, executes a power shutdown microprogram, evacuates the information necessary in proceeding with the program to the information holding unit, and outputs an evacuation completed signal to the power supply control unit after evacuation is completed, the power supply control unit, upon receiving the evacuation completed signal, outputs a power shutdown control signal to the power supply unit, the power supply unit shuts down power supply to the CPU upon receiving the power shutdown control signal from the power supply control unit, the power supply control unit, upon receiving the evacuation completed signal, outputs a clock stop control signal to the clock generator, the power supply control unit outputs a power supply control signal to the power supply unit in response to an occurrence of a power supply restoration factor, the power supply unit, upon receiving the power supply control signal, starts to supply power to the CPU, the power supply control unit outputs a restoration request signal to the CPU and outputs a clock supply control signal to the clock generator when a supplied power supply voltage is stabilized, the clock generator, upon receiving the clock supply control signal, restarts to supply an operation clock, and the CPU, upon receiving the restoration request signal, executes a power supply restoration microprogram, restores the information necessary in proceeding with the program and evacuated in the information holding unit in time of power shutdown, and then branches a process to an address indicated by a program counter to continue program execution from a shutdown state.