Abstract:
An inventive presettable synchronous predecoded counter which provides predecoding and counting in a single circuit, with an inventive dual-input flip-flop included in the design. This predecoded counter is used advantageously to sequentially access elements in a semiconductor memory array. This invention offers small size and simple design.

Description:
FIELD OF THE INVENTION 
     This invention generally relates to counting and decoding circuitry used in a semiconductor memory chip, and more particularly relates to a predecoded counter combination, such as might be used in a sequential access memory (SAM). 
     BACKGROUND OF THE INVENTION 
     Semiconductor memories are commonly randomly accessible. This means that a user must provide an address for each element accessed in a memory array. Some memories, such as SAMs, are sequentially accessed. This means that a clock pulse is provided to the SAM, and elements within a predetermined block within the array are sequentially accessed, one element per pulse. This is used with advantage in devices such as dual-port and triple-port RAMs (random access memories), which have both sequential and random access ports. 
     A well known way to accomplish sequential access is illustrated in FIG. 1. Clock 10 pulses counter 11, which increments by calculating its next output by using feedback from its present output. Counter 11 outputs an address to predecoder 12, which outputs the address predecoded to decode stage 13, which then presents the address fully decoded to array 14. Predecoder 12 and decode stage 13 work together to efficiently access an element in array 14 which corresponds to the address output of counter 10. As clock 10 pulses, counter 11 counts, and elements in array 14 are sequentially accessed. Often counter 11 is presettable, allowing the sequential access to begin at a predetermined element within array 14. 
     It would be advantageous to combine a counter and a predecoder into a single stage, thus reducing design complexity and size. 
     It would also be advantageous if the predecoded counter was presettable, allowing sequential access to begin at any predetermined element within a memory array. 
     It would further be advantageous if the predecoded counter were synchronous. The outputs of the predecoded counter would then change simultaneously, thus avoiding spurious activation of one or more outputs. 
     SUMMARY OF THE INVENTION 
     An inventive predecoded counter provides a counter and predecoder in one circuit. Included in this device is an inventive dual-input flip-flop. This combination offers the advantages of simpler design, fewer circuit elements, and smaller circuit size. 
     The inventive predecoded counter also is synchronous, having no ripple on its outputs, eliminating a logic level within an attached decode stage. 
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS 
     FIG. 1 is a block diagram showing prior art counter in use. 
     FIG. 2 is a block diagram showing the inventive predecoded counter in use. 
     FIG. 3 is a state diagram of the inventive predecoded counter. 
     FIG. 4 is a state diagram of a prior art counter and predecoder. 
     FIG. 5 details an inventive one-of-four predecoded counter. 
     FIG. 6 is a chart illustrating the operation of a dual-input flip-flop used in the predecoded counter. 
     FIG. 7 is a timing diagram illustrating operation of the predecoded counter. 
     FIG. 8 shows cascaded predecoded counters accessing a memory array having 256 elements. 
     FIG. 9 is a chart illustrating operation of cascaded predecoded counters 15C and 15D, shown in FIG. 8. 
    
    
     DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENT 
     A predecoded counter is provided according to the invention. FIG. 3 shows sequential states of a preferred predecoded counter. Predecode and count are performed simultaneously. For comparison, FIG. 4 shows sequential states of an ordinary shave-and-a-haircut (two bit) counter. The states are outputted to a predecoder, whose outputs are also shown. 
     The preferred embodiment of a one-of-four predecoded counter 15 is detailed in FIG. 5. It includes: two dual-input master-slave D-type flip-flops 50 and 50&#39; with data inputs D0, D1, D0&#39;, and D1&#39;, presetting inputs S*, R*, S*&#39;, and R*&#39;, separate clock inputs CLKM and CLKS*, and flip-flop outputs Q, Q*, Q&#39;, and Q*&#39;; and predecoder 51 with predecoded outputs P0 (least significant), P1, P2, and P3 (most significant). All of these elements are connected as shown in FIG. 5, so that the flip-flops 50 and 50&#39; synchronously output directly to predecoder 51, and feedback is taken from predecoded outputs P0, P1, P2, and P3 in order to generate a next state. These elements preferably share a common semiconductor substrate. 
     The operation of flip-flop 50 within a predecoded counter such as 15 is now summarized. The master stage is transparent when input CLKM is low, and latches on CLKM rising edge. The slave stage is transparent when CLKS* is high, and latches on CLKS* falling edge. Because of the predecoded counter 15 feedback from outputs P0-P2 to inputs D0, D1, D0&#39;, D1&#39;, flip-flops 50 and 50&#39; are not allowed to have both the master stage and the slave stage transparent at one time. To latch a new value into flip-flop 50, CLKM and CLKS* are simultaneously (or almost simultaneously) brought low and then high (see FIG. 6, lines 1-3). When at least one of D0 and D1 are high (lines 2 and 3), a high output is latchable at Q. When both D0 and D1 are low (line 1), a low output is latchable at Q. When flip-flop 50 is used in the preferred embodiment, D0 and D1 are never high at the same time because only one output of predecoder 51 is high at one time. To preset flip-flop 50, one of S* and R* is brought low while CLKS* is low (lines 4 and 5). R* and S* are both high for normal operation (lines 1-3), but when S* goes low (line 5) Q asynchronously goes high, and when R* goes low (line 4) Q asynchronously goes low (R* and S* low at the same time is a disallowed state). Q* is always the inverse of Q. 
     Sequential states of the preferred embodiment are shown in FIG. 7. At time T1 in this figure, the embodiment is initialized to select P0. CLK is a signal placed on CLKM and CLKS* simultaneously, for purposes of illustration. At each positive CLK edge through times T2-T5 the embodiment is shown predecodably counting through P1, P2, P3, and P0, respectively. 
     At time T6, the embodiment is preset to select P2 by bringing S* and R*&#39; low. S* and R&#39;* return high at time T7 but outputs P0-P3 remain latched. At time T8, predecoded counting resumes, beginning at selected state P2. 
     FIG. 8 details the preferred embodiment used in a memory system. One-of-four predecoded counters 15A-15D are synchronously cascaded, each predecoded counter 15 outputting to different levels in decode stage 13, which selects one of 256 elements in array 14, as shown. Decode stage 13 is a tree decoder having four branching levels. CLOCK clocks the master stage of predecoded counter 15D and slave stages of predecoded counters 15A-15D. Counters 15A-15D are cascaded using logic devices 80-83 connected as shown so that a given predecoded counter (for example, 15A) will not increment until the most significant (P3) outputs of all of the lesser significant predecoded counters (for example, 15B-15D) are high and CLOCK undergoes a positive transition. 
     For clarity, in FIG. 9, pertinent signals of cascaded predecoded counters 15D and 15C and NAND gate 81 are shown in action. Predecoded counter 15D is shown incrementing normally (as was seen in FIG. 7). Inputting P3 of predecoded counter 15D and inverted CLOCK to the NAND gate 81, which clocks CLKM of predecoded counter 15C, causes 15C to increment only when P3 of predecoded counter 15D is high and CLOCK undergoes a positive transition (shown at time T of FIG. 9). 
     Clearly, although not shown in FIG. 9, predecoded counter 15B will not increment unless P3 of both 15C and 15D are high and CLOCK undergoes a positive transition, as evidenced by the three-input gate 82. Similarly, predecoded counter 15A will not increment unless P3 of all three of 15B, 15C, and 15D are high and CLOCK undergoes a positive transition, as evidenced by the four-input gate 83. 
     Predecoded counters 15A-15D in this configuration can increment only on a rising edge of CLOCK. If all of predecoded counters 15A-15D are ready to increment at the same time, they all will increment on the same rising edge of CLOCK. This means that, although predecoded counters 15A-15D are cascaded, there is no ripple effect on their outputs. This is a necessity: rippling inputs to decode stage 13 can be quite a problem, as multiple decoder branches (not shown) may be activated during the ripple. Further, a rippling counter is actually slower. 
     Predecoded counter 15A is preset by using one or more signals in CLKP to cause circuit 84A to latch A6 and A7, passing A7 to S*, A7* to R*, A6 to S*&#39;, and A6* to R*&#39;. When predecoded counter 15A is not being preset, circuit 84A inputs high levels to S*, R*, S*&#39;, and R*&#39;. Predecoded counters 15B, 15C, and 15D are similarly preset by circuits 84B, 84C, and 84D, respectively. 
     Referring again to FIG. 5, the choice of NOR gates in predecoder 51 and master stages of flip-flops 50 and 50&#39;, and NAND gates in slave stages of flip-flops 50 and 50&#39; is deliberate. Decode stage 13, for which this embodiment was designed, happens to require active-high selection signals from predecoder 51. Using NORs in predecoder 51 connected as shown in FIG. 5 provides only one of P0-P3 high (active) at one time. Flip-flop 50 and 50&#39;  slave stages drive predecoder 51 and have NANDs as output devices to avoid momentary false selections among P0-P3. 
     Latches like the slave stages within flip-flops 50 and 50&#39; have outputs that do not toggle instantaneously: one output will change before the other. The outputs of a NAND latch (such as the slave stage in flip-flop 50, for example) will both momentarily be high during a toggle. Similarly, the outputs of a NOR latch will both momentarily be low during a toggle. NOR predecoder 51 is immune to the momentary simultaneous lows of NAND slave stages of flip-flops 50 and 50&#39;, and thus avoids false selection among outputs P0-P3. Similarly, had decode stage 13 required active-low selection signals, predecoder 51 would have comprised NAND gates and the slave stages of flip-flops 50 and 50&#39; would have comprised NOR gates to avoid false selection among outputs P0-P3. 
     In flip-flops 50 and 50&#39; the master stages comprise NOR gates and the slave stages comprise NAND gates simply to make CLKM and CLKS* have opposing active states. This means CLKM and CLKS* can be clocked in parallel and flip-flop 50 always has a latched stage. Having at least one stage latched at any one time gives flip-flop 50 stability: if both the master stage and the slave stage is transparent at one time, an infinite loop would result as feedback from outputs P0-P2 drive inputs D0, D1, D0&#39;, and D1&#39;, thus changing outputs P0-P2. 
     Although individual circuit elements are described above, the invention is preferably embodied in an integrated semiconductor circuit. The claims should be interpreted accordingly.