Abstract:
The present disclosure relates to a semiconductor device and a method of operating the semiconductor device. The semiconductor device includes a ROM for storing a program algorithm, an erase algorithm, a reading algorithm, and a reset algorithm and outputting ROM data corresponding to a selected algorithm, a program counter for outputting a ROM address to the ROM so as to sequentially operate the selected algorithm, an internal circuit for performing an operation corresponding to the selected algorithm in response to a plurality of internal circuit control signals in response to the ROM data, and a reset circuit for stopping progress of a running algorithm by initializing the program counter in response to a reset command input from an outside, and performing the reset algorithm.

Description:
CROSS-REFERENCE TO RELATED APPLICATION 
       [0001]    This application is based on and claims priority from Korean Patent Application No.10-2011-0110582, filed on Oct. 27, 2011, with the Korean Intellectual Property Office, the disclosure of which is incorporated herein in its entirety by reference. 
       BACKGROUND 
       [0002]    The present invention relates generally to a semiconductor device and a method of operating the same, and more particularly to a semiconductor device capable of preventing over-spec when inputting a reset command and a method of operating the same. 
         [0003]    A semiconductor device includes a microcontroller for controlling operations of circuits included therein. 
         [0004]    The microcontroller controls the operations of the internal circuits in response to an operation command input to the semiconductor device. When the semiconductor device performs the operation in response to an external command, the semiconductor device may receive a reset command instructing the stop of the operation and the return to an initial state from a user. In this case, when the microcontroller executes the reset command amid a running operation, the semiconductor device may be in an abnormal state due to a resulting operation error. 
         [0005]    In order to prevent the abnormal state, the semiconductor device may identify whether the reset command is input during a running operation by way of a reset check code. 
         [0006]    For example, when the reset command is input from the outside during a running program operation by the external command, the program operation up to a reset check code is performed, and an initialization operation is performed thereafter. The reset check code determines whether or not a reset command is provided. 
         [0007]    A plurality of reset check codes exists for a program operation, a reading operation, and an erase operation, but positions of the reset check codes may be different. 
         [0008]    Accordingly, when the reset command is input from the outside, a time tRST at which the reset command is input and the time when an operation such as the program operation, the reading operation, or the erase operation, is finally completed, is not always synchronized, thereby generating over-spec in the device. 
       SUMMARY 
       [0009]    The present disclosure provides a semiconductor device having the same reset time regardless of the state of a running operation by resetting a program counter within a microcontroller and performing a reset check code of an algorithm stored in a ROM when a reset command is input from the outside, and a method of operating the same. 
         [0010]    An embodiment of the present invention provides a semiconductor device including: a ROM for storing a program algorithm, an erase algorithm, a reading algorithm, and a reset algorithm and outputting ROM data corresponding to a selected algorithm; a program counter for outputting a ROM address to the ROM so as to sequentially operate the selected algorithm; an internal circuit to perform an operation corresponding to the selected algorithm in response to a plurality of internal circuit control signals in response to the ROM data; and a reset circuit to stop progress of a running algorithm by initializing the program counter in response to a reset command input from an outside and performing the reset algorithm. 
         [0011]    Another embodiment of the present invention provides a semiconductor device including: a microcontroller to output a plurality of internal circuit control signals in response to commands input from an outside; an internal circuit to perform a program operation, an erase operation, or a reading operation in response to the plurality of internal circuit control signals; and a reset circuit to control the microcontroller so as to stop a running algorithm and to perform a reset algorithm when a reset command is input from the outside. 
         [0012]    Another embodiment of the present invention provides a method of operating a semiconductor device, including: performing one algorithm among a program algorithm, a reading algorithm, and an erase algorithm in response to an operation command input from an outside; initializing a program counter to move to a first line syntax of the one algorithm when a reset command is input from the outside; determining whether a reset signal is input through a reset check code recorded in the first line syntax; and performing a reset algorithm when it is determined that the reset signal is input. 
         [0013]    In response to the various embodiments of the present invention, when the reset command is input from the outside, the reset check code of the algorithm stored in the ROM is performed by resetting the program counter within the microcontroller, thereby having the same reset time regardless of the state of a running operation, thereby preventing over-spec of the semiconductor device in the reset operation. 
         [0014]    One reset check code may be stored in the algorithm within the ROM, so that the efficiency of the semiconductor device may be improved as the multiple sub routines for performing the reset operation may be unified into one sub routine. 
         [0015]    The foregoing summary is illustrative only and is not intended to be in any way limiting. In addition to the illustrative aspects, embodiments, and features described above, further aspects, embodiments, and features will become apparent by reference to the drawings and the following detailed description. 
     
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
         [0016]      FIG. 1  is a block diagram illustrating a semiconductor device in response to an embodiment of the present invention. 
           [0017]      FIG. 2  is a block diagram illustrating a microcontroller illustrated in  FIG. 1  in detail. 
           [0018]      FIG. 3  is a waveform diagram of signals for illustrating an operation of a microcontroller illustrated in  FIG. 2 . 
           [0019]      FIG. 4  is a flowchart illustrating an operation of a semiconductor device in response to an embodiment of the present invention. 
       
    
    
     DETAILED DESCRIPTION 
       [0020]    Hereinafter, an embodiment of the present invention will be described with reference to the accompanying drawings in detail. However, the present invention is not limited to an embodiment disclosed below and may be implemented in various forms. The embodiment is provided only for illustrative purposes and for full understanding of the scope of the present invention by those skilled in the art. 
         [0021]      FIG. 1  is a block diagram illustrating a semiconductor device in response to an embodiment of the present invention. 
         [0022]    Referring to  FIG. 1 , the semiconductor device includes a memory cell array  110 , a page buffer unit  120 , a Y encoder  130 , a voltage supplier  140 , an X decoder  150 , and a microcontroller  160 . 
         [0023]    The memory cell array  110  includes a plurality of memory cells in which data may be stored. 
         [0024]    The page buffer unit  120  includes a plurality of page buffers connected with a plurality of bit lines of the memory cell array  110 . Each of the page buffers temporarily stores program data transmitted through the Y decoder  130 , controls the potential of a corresponding bit line in a program operation in response to page buffer control signals PB_SIG, senses the potential of the corresponding bit line in a reading operation, temporarily stores the read data, and then outputs the stored data to the Y decoder  130 . 
         [0025]    The Y decoder  130  transmits program data input through a data line to a page buffer corresponding to a column address in the program operation in response to Y decoder control signals YDEC_SIG, and outputs the read data transmitted from the page buffer to the data line in the reading operation. 
         [0026]    The voltage supplier  140  generates operation voltages (e.g., a program voltage, a reading voltage, and a pass voltage) necessary for each operation in response to voltage supplier control signals HG_SIG. 
         [0027]    The X decoder  150  transmits the operation voltages generated in the voltage supplier  140  to word lines WL&lt;n:0&gt; of the memory cell array  110  in response to X decoder control signals XDEC_SIG. 
         [0028]    The memory cell array  110 , the page buffer unit  120 , the Y decoder  130 , the voltage supplier  140 , and the X decoder  150  are circuits to perform internal operations in the semiconductor device, and they may be defined as internal circuits. 
         [0029]    The microcontroller  160  generates and outputs the page buffer control signals PB_SIG, the Y decoder control signals YDEC_SIG, the voltage supplier control signals HG_SIG, and the X decoder control signals XDEC_SIG in response to a command input from the outside. When the reset command is input from the outside, the algorithm is re-performed from the first line in which a reset syntax is stored in a ROM by initializing a program counter included in the microcontroller  160 , so that a running operation is stopped to perform the reset operation. 
         [0030]      FIG. 2  is a block diagram illustrating the microcontroller illustrated in  FIG. 1  in detail. 
         [0031]    Referring to  FIG. 2 , the microcontroller  160  includes a command input unit  161 , a program counter  162 , a ROM  163 , a reset signal generator  164 , a command decoder  165 , an output register  166 , and a glue logic  167 . 
         [0032]    The command input unit  161  generates a command signal in response to a command input from the outside and outputs the generated command signal to the ROM  163 . When a reset command 0xFF is input from the outside, the command input unit  161  outputs a reset enable signal CI_RESEN to the reset signal generator  164 . 
         [0033]    The program counter  162  outputs a ROM address ROMADD&lt;11:0&gt; sequentially increasing in the program operation, the reading operation, or the erase operation of the semiconductor device in response to a state signal PH 1 . The program counter  162  is initialized in response to a program counter reset signal PC_RESET and outputs an initial ROM address ROMADD&lt;0&gt;. 
         [0034]    The ROM  163  stores the algorithm corresponding to the program operation, the reading operation, and the erase operation of the semiconductor device, and a reset check code is recorded in the first line syntax of each algorithm. The ROM  163  executes the algorithm corresponding to the program operation, the reading operation or the erase operation in response to the command signal output from the command input unit  161 , and sequentially outputs ROM data ROMDATA&lt;23:0&gt; corresponding to a syntax of each algorithm in response to the ROM address ROMADD&lt;11:0&gt; output from the program counter  162 . 
         [0035]    The reset signal generator  164  outputs the program counter reset signal PC_RESET in response to the reset enable signal CI_RESEN. The reset signal generator  164  is initialized in response to a circuit initialization signal LOGRST, and inactivates the program counter reset signal PC_RESET regardless of the reset enable signal CI_RESEN in response to a test signal CNFPCRESETDIS. 
         [0036]    The command decoder  165  outputs a plurality of control signals CS by decoding the ROM data ROMDATA&lt;23:0&gt; received from the ROM  163 . 
         [0037]    The output register  166  temporarily stores the plurality of control signals CS and then sequentially outputs the stored control signals CS to the glue logic  167 . 
         [0038]    Referring to  FIG. 1 , the glue logic  167  generates and outputs the page buffer control signals PB_SIG, the Y decoder control signals YDEC_SIG, the voltage supplier control signals HG_SIG, and the X decoder control signals XDEC_SIG by using the plurality of control signals CS received from the output register  166 . 
         [0039]      FIG. 3  is a waveform diagram of signals for illustrating an operation of a microcontroller illustrated in  FIG. 2 . 
         [0040]      FIG. 4  is a flowchart illustrating an operation of a semiconductor device in response to an embodiment of the present invention. 
         [0041]    The operation of the semiconductor device in response to an embodiment of the present invention will be described with reference to  FIGS. 1 to 4 . 
         [0042]    A case in which a reset command is input during a running program operation will be described below. 
         [0043]    Specifically, an operation of the semiconductor device for performing the program operation before the input of the reset command will be first described below. 
         [0044]    In the program operation, when a program command is input from the outside, a program algorithm stored in the ROM  163  is executed, so that ROM data ROMDATA&lt;23:0&gt; is sequentially output in response to ROM address ROMADD&lt;11:0&gt;. 
         [0045]    The glue logic  167  generates and outputs the page buffer control signals PB_SIG, the Y decoder control signals YDEC_SIG, the voltage supplier control signals HG_SIG, and the X decoder control signals XDEC_SIG corresponding to the program operation in response to the control signals CS in response to the ROM data ROMDATA&lt;23:0&gt;. 
         [0046]    The internal circuits of the memory cell array  110 , the page buffer unit  120 , the Y decoder  130 , the voltage supplier  140 , and the X decoder  150  perform the program operation for programming data in the memory cell array  110  in response to the page buffer control signals PB_SIG, the Y decoder control signals YDEC_SIG, the voltage supplier control signals HG_SIG, and the X decoder control signals XDEC_SIG. 
         [0047]    The step S 410  for inputting a reset command is described below. 
         [0048]    When a reset command 0XFF is input from the outside, the command input unit  161  outputs a reset enable signal CI_RESEN at a high voltage level. The reset signal generator  164  outputs a program counter reset signal PC_RESET at a corresponding high voltage level for a predetermined time in response to the reset enable signal CI_RESEN at the high voltage level. 
         [0049]    The step S 420  for resetting the program counter is described below. 
         [0050]    The program counter  162  is initialized in response to the program counter reset signal PC_RESET and outputs an initial ROM address ROMADD&lt;0&gt;. 
         [0051]    The step S 430  for moving to the first line syntax of the algorithm is described below. 
         [0052]    The ROM  163  moves to a reset check code recorded in the first line syntax of a running algorithm in response to the initial ROM address ROMADD&lt;0&gt; output from the program counter  162 . 
         [0053]    The step S 440  for checking the reset is described below. 
         [0054]    A reset check operation corresponding to the reset check code stored in the first line syntax of the algorithm stored in the ROM  163  is performed. 
         [0055]    The step S 450  for determining the reset is described below. 
         [0056]    It is determined whether the reset command is input from the outside by the performance of the reset check operation corresponding to the reset check code. 
         [0057]    The step S 460  for processing the algorithm is described below. 
         [0058]    When it is determined that the reset command is not input from the outside by the performance of the reset check operation corresponding to the reset check code, the running program algorithm is sequentially re-performed from the beginning. 
         [0059]    The step S 470  for moving to a reset sub routine is described below. 
         [0060]    When it is determined that the reset command is input from the outside by the performance of the reset check operation corresponding to the reset check code, the ROM moves to the reset sub routine in which the ROM data for the reset operation is stored. 
         [0061]    8) The step S 480  for performing the reset operation is described below. 
         [0062]    After moving to the reset sub routine, the ROM outputs the ROM data ROMDATA&lt;23:0&gt; for the reset operation. The glue logic sequentially turns off the page buffer control signals PB_SIG, the Y decoder control signals YDEC_SIG, the voltage supplier control signals HG_SIG, and the X decoder control signals XDEC_SIG corresponding to the program operation in response to control signals CS in response to the ROM data ROMDATA&lt;23:0&gt;, to terminate the currently running program operation. 
         [0063]    As described above, in response to the present invention, when the reset command is input from the outside during the internal operation, the reset check code is re-performed from the first line syntax of the algorithm by initializing the program counter, thereby having the same reset time regardless of the state of a currently running operation. Accordingly over-spec of the semiconductor device in the reset operation may be prevented. 
         [0064]    One reset check code may be stored in each algorithm stored in the ROM, so that the efficiency of the semiconductor device may be improved as the multiple sub routines for performing the reset operation may be unified into one sub routine. 
         [0065]    From the foregoing, it will be appreciated that various embodiments of the present disclosure have been described herein for purposes of illustration, and that various modifications may be made without departing from the scope and spirit of the present disclosure. Accordingly, the various embodiments disclosed herein are not intended to be limiting, with the true scope and spirit being indicated by the following claims.