I have been using the 74LS161 for some tinkering, and then switched to the CD4040 because it had 3 times as many counter stages in the same package size, and I don't need preset for my purpose.

Early on I was intrigued though by how much it is different. A 74LS161 increments on the rising edge of the clock input. Whereas the CD4040 increments on the falling edge of the clock, thus effectively making the clock itself another, the "zero-th" counter stage. This is a nice feature.

However, now I have a problem where the 74LS161 was really good for: the Ripple Carry Output, it's missing with the CD4040. I need something to trigger an S-R-latch, resetting it when the counter overflows. And I do not want to now hook up 12 lines to a 12-input NOR gate cobbled together from three chips that I might need for that. If I could just have that ripple carry output, which is exactly one clock pulse wide. Is there any way I could derive that?

I'm thinking of a falling edge of the last counter stage. How do I make the falling edge trigger an SR latch? Maybe instead of the SR latch I use a single edge triggered D-flip-flop, invert the last counter stage so that have a rising edge with which I can trigger the flip flop while holding D high. Then I could use an asynchronous reset and clear which most of them have, including the 74LS74 that I have on hand.

So is that the way to go or is there any other way of deriving a ripple carry like single pulse from a 4040 counter? Or a general technique to turn a binary counter into a Johnson counter?

  • \$\begingroup\$ What clock frequency do you want it to run at? \$\endgroup\$ Commented Aug 2, 2020 at 20:02
  • \$\begingroup\$ Hi again @BruceAbbott, I'm starting with 4 MHz and the SR latch was to serve as the gate of that main clock via a NAND gate to an active-low Write-Enable line. \$\endgroup\$ Commented Aug 2, 2020 at 22:42
  • \$\begingroup\$ @GuntherSchadow A falling edge can be used to trigger a 74121 or 74123 one-shot. I didn't read your details too much, yet. But you write something asking about that possibility. So there it is -- a way. If it helps any. \$\endgroup\$
    – jonk
    Commented Aug 3, 2020 at 3:41

1 Answer 1


You can use a 74xx73 J-K FF, which is negative edge triggered. There are hack-y ways of doing it with resistors & capacitors etc.

One of the fundamental differences between the 4040 and the 74xx161 is that the latter is a synchronous counter and the former is a ripple-carry counter. It can be a critical distinction in some applications. That's why there is a terminal count output on the '161 — to allow multiple 4-bit units to be cascaded into a wider synchronous counter. Otherwise you could just use the MS bit.

A Johnson counter could be made with a shift register. You require a lot of flip-flops to make a counter with 4096 states. 2048, to be specific.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.