Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

74hct4020 question

Status
Not open for further replies.

jack0987

Member
I have a 74hct4020 that I am clocking. I connected a led to Q0 as a test. If I have my hands close to the circuit it does not seem to light the led.

Do I need to ground unused outputs?

Anyway, in general how does one work with it?

What if I want to connect a led to each output?

thanks
 
Speaking only for myself, schematic, Schematic, SCHEMATIC.

ak
 
I don't think you need to ground the outputs, but you will probably want to ground the "MR" reset pin and add a 0.1uF decoupling capacitor across the power and ground pins if you haven't already. If the reset is left floating, it could be reacting to ambient electric fields and could behave as you describe.

I'm not sure what you mean by "work with it" exactly... is there something specific that you want it to do? It should count up in binary for each clock pulse. If you are already sending a clock signal, then it sounds like you pretty much have the gist of it already.

The maximum rated supply current at Vcc is 50mA, so you would probably want to buffer the outputs if you plan to run an LED from each output.
 
I don't think you need to ground the outputs, but you will probably want to ground the "MR" reset pin and add a 0.1uF decoupling capacitor across the power and ground pins if you haven't already. If the reset is left floating, it could be reacting to ambient electric fields and could behave as you describe.

The maximum rated supply current at Vcc is 50mA, so you would probably want to buffer the outputs if you plan to run an LED from each output.

Thanks. The capacitor did not help but grounding the reset pin seems to have done the trick.

Is there a particular driver IC that I might use and I'll look in parts box to see if I have one or two on hand.
 
Thanks. The capacitor did not help but grounding the reset pin seems to have done the trick.

Is there a particular driver IC that I might use and I'll look in parts box to see if I have one or two on hand.

Hmm, that's what I figured. Your description sounded like a pretty textbook case of a floating CMOS input. The decoupling cap is not always strictly necessary, but is generally considered good practice.

There are LOTS of buffer/driver ICs that would be able to drive an LED. I don't really have any specific recommendation off the top of my head...

If you can't find anything on hand and really want to test, you might be able to use some discrete transistors to drive the LEDs (along with some current limiting resistors, of course), but that might be a bit cumbersome to wire up for 14 separate inputs.

I mean, if it's just to test and you don't need the LEDs to be super-bright, you could always limit the current to the LEDs so that the combined current wouldn't exceed the rating of the IC. Some 10k or 4.7k resistors in series with each LED would probably work just fine.
 
The ULN2003/2004 is a great general purpose driver for experimenting. 7 drivers in a package, base resistors built in, a single ground pin, and rated for 50 V and 0.5 A. 8 in a ULN2803/04.

ak
 
I don't think you need to ground the outputs
I don't think you would ever want to ground an output, input maybe, but never an output. Of course I know you were thinking input :)
 
Last edited:
I don't think you would ever want to ground an output, input maybe, but never an output. Of coarse I know you were thinking input :)

Oh, I guess I meant more in the sense of "not floating" rather than "shorted to ground." That would be a bad idea. The RF engineer in me wants to put termination loads on everything lol.
 
Do I need to ground unused outputs?[]/quote]
You have a lot to learn. You never ever short the output of anything. Unused inputs must be grounded.

What if I want to connect a led to each output?
Look at the Texas Instruments datasheet where they show the maximum allowed output current is 25mA. They also show graphs of output current vs voltage and if you directly connect a 2V to 3.5V LED to an output then its current will be much higher than is allowed. So you must limit the current with a series resistor or something. The maximum allowed current in the supply pins is 50mA so if 5 outputs are active then each must be limited to 10mA or less.
 
Unused inputs must be grounded.

Not always. It depends on how the input affects the output driver (if you care about power consumption). In some cases grounding the input as opposed to pulling it high may consume more power. So, it would be more accurate to say "Unused inputs should not be left floating". Pulling high or low depends on the part being used. Of course you cant go wrong pulling low :)
 
Speaking only for myself, schematic, Schematic, SCHEMATIC.

ak

LOL. I am looking to do something like this, only in TTL as I am only using a 5VDC power supply, have a lot of those type of parts on hand, and the TTL is, IMHO, kind of bomb proof for a little guy like me.

SCHEMATIC: https://ronj.eu5.org/rt.html

In the above circuit, I would also like to replace the 4001 stuff with a 555 one shot.
 
There are LOTS of buffer/driver ICs that would be able to drive an LED. I don't really have any specific recommendation off the top of my head...

If you can't find anything on hand and really want to test, you might be able to use some discrete transistors to drive the LEDs (along with some current limiting resistors, of course), but that might be a bit cumbersome to wire up for 14 separate inputs.

I have lots of 7490s on hand and (still looking) and I think a few 7 segment driver ICs as well to replace the 744020. This would work quite nicely for me.

What do you think?

EDIT: I do have some 7447s but now think I'll just stay with the binary. Still looking for a binary driver of sorts.
 
Last edited:
The ULN2003/2004 is a great general purpose driver for experimenting. 7 drivers in a package, base resistors built in, a single ground pin, and rated for 50 V and 0.5 A. 8 in a ULN2803/04.

ak

Thanks. This is not a part I will have on hand. Is there something similar you can think of I might use without base resistors built in?
 
OptoSw.jpg
Perhaps the OP meant one of these (commonly known as a photo-interrupter or opto-switch)? If mounted upside-down at the top of the slot then some filtering of smaller coins can be achieved (tut tut @ naughty people). Also, although the clock input should be normally low, the coin will create a high-low-high pulse, which is enough to clock the 4020, as long as it is fast enough... the sensor is normally a long way down the coin tube so that the coin is travelling quite fast by then - that also stops lolly-stick triggering (tut tut again!).
 
I have lots of 7490s on hand and (still looking) and I think a few 7 segment driver ICs as well to replace the 744020. This would work quite nicely for me.
I don't think there is a TTL part 744020. AFAIK there is no TTL part with an on-board oscillator and counter-divider. You can build the oscillator out of two TTL inverters or inverting gates and drive a string of 7490s with it.

For output drivers, a small-signal NPN transistor with a 4.7K base resistor will work. 2N4401, 3904, 2222, etc.

ak
 
Last edited:
Just FYI. The ULN2003 is an awesome, cheap driver chip (and very common). But it's ok 7/8s as awesome as the ULN2803. The same part with an addition channel. For some reason, itdoesn't seem as well known.
 
View attachment 105058
Perhaps the OP meant one of these (commonly known as a photo-interrupter or opto-switch)? If mounted upside-down at the top of the slot then some filtering of smaller coins can be achieved (tut tut @ naughty people). Also, although the clock input should be normally low, the coin will create a high-low-high pulse, which is enough to clock the 4020, as long as it is fast enough... the sensor is normally a long way down the coin tube so that the coin is travelling quite fast by then - that also stops lolly-stick triggering (tut tut again!).

I do not understand. What I am doing has nothing to do with coins. Did I misstate something?
 
Just FYI. The ULN2003 is an awesome, cheap driver chip (and very common). But it's ok 7/8s as awesome as the ULN2803. The same part with an addition channel. For some reason, itdoesn't seem as well known.

Thanks. I will look into this.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top