Noise on NAND gate output?

Go To Last Post
29 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hey guys, i have a simpe NAND gate chip. its a quad NAND gate HCF4011BE. I have been trying to learn how to use this thing and for interest sake i connected a logic analyzer to the output of the gate. what is strange is the output pin has noise on it when the OUTPUT is low (when the two inputs are high). I have added a pull down resistor on the output pin but the noise is there regardless if i use the resistor or not. What could be the problem? 

 

I cannot upload images for some reason? it just says "uploading" forever. else i would have uploaded a circuit diagram and a screen shot of the logic analyzer

Attachment(s): 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Noise. How MUCH noise? What KIND of noise? Is it in the microvolt range, or the millivolt range? What are the frequency characteristics? What is connected to the inputs? What is its power supply? Has the local shaman driveway the devils?

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

oh i see the one picture did add. here is a picture of the logic analyzer showing the noise

Attachment(s): 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You said it is a QUAD nand gate. You only show two inputs. You have probably left the other two floating... don't do that.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

The inputs are just simple 5v signals driven from an LM7805. its the most basic circuit ever. i just wanted to see how a NAND gate works so i connected 5v to both inputs and measured the output. The multimeter shows 0v but the logic analyzer shows switching from high to low when both inputs are high. the output goes high for 0.125us then low for long. see zoomed image of spikes

Attachment(s): 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

it is a quad NAND gate yes. i thought it just means its 4 separate gates? here is the pinout of the gate i am using. It does not show that one gate will effect the next?

Attachment(s): 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

 

 

 

 

OK. First of all, the CD 4011 contains qty (4) two input NAND gates. It is not a quad input NAND gate... that is a gate with 4 inputs. I wanted to illustrate to you how very important it is to be clear about what you are working with.

 

NAND means 'NOT AND'. With and AND gate, ALL inputs must be 'true' (5 volts) for the output to be true (5 volts).

 

NOT AND means that both inputs must be true for the output to be false (0 volts).

 

So by the multimeters guess, the output is correct. The logic analyzer says different. So the questions becomes 'which is wrong?'... the chip the multimeter, the logic analyzer... or the power supply?

 

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Looking at the diagrams, it is obvious that the inputs are NOT just connected tied to +5. What is driving them?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanx and sorry for the confusion it is my first time working with these gates. i think it might be the power supply that is noisy. But it is the ground line that is noisy, is this possible? i connected one of the logic analyzers pins to ground and it shows that it jumps from ground to VCC every few milliseconds or so. 

 

Is there another way i can test to see if it is the ground that is noisy? i do not have an oscilloscope 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Did you have a good ground connection between the LA and power supply ground?

 

Make sure that you have all of the other inputs tied to something - either Vcc or ground. The gates are independent but not absolutely so.

 

Connect a logic analyzer input to Vcc, referenced, of course, to ground.  Does the LA show that it is steady?

 

Jim

 

Until Black Lives Matter, we do not have "All Lives Matter"!

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I connected the logic analyzer to Vcc and referenced to ground. It shows stable but when i connect the logic analyzer to ground and reference ground i see the noise. is this normal? the inputs of the logic analyzer and grounds are ties to ground and i see noise? how can this be if they are all tied to the same reference point?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I got it working now. i unplugged everything and plugged it back in and now there is no noise. i think it might be the usb cable that is faulty i am not sure

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Do you have a 100nF cap close to the supply pins of the chip?

John Samperi

Ampertronics Pty. Ltd.

www.ampertronics.com.au

* Electronic Design * Custom Products * Contract Assembly

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

calvingloster wrote:

I got it working now. i unplugged everything and plugged it back in and now there is no noise. i think it might be the usb cable that is faulty i am not sure

 

Great.

A good 'sanity check' when starting with designs & equipment  like Logic Analyzers, is to connect spare channels to Vcc and GND, and confirm that they are stable.

Also, look at the numbers, - your LA reports a strangely long period of many seconds between pulses.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

it seams like the noise is gone but the output of the NAND gate is bouncing now? if that is even possible?

Attachment(s): 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Here is a zoomed image of the bouncing. i have tried putting a 100nf capacitor on the chips close to vcc and it still bounces. i actually put a 330nf cap cause i did not have a 100nf

Attachment(s): 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

In your 'bouncing' picture, the input is changing and the output is reflecting that change.
I think we need a picture of youre setup - i think there are some fundamental problems. You say 'simple', but you are not seeing the underlying complexity - for example, the 7805. Used properly it does what you'd expect, used wrongly, it likes to oscillate. The datasheet tells you how to use it properly. There's other physical phenomena at play as well - capacitance and inductance. You can't see it, but it is there.

I would use the USB as a source of voltage. Means everthing is powered from the same source.

Last Edited: Sat. Sep 5, 2015 - 10:46 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I assume the NAND gate is also connected to V+ and Ground?

 

JC

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

calvingloster wrote:

Here is a zoomed image of the bouncing. i have tried putting a 100nf capacitor on the chips close to vcc and it still bounces. i actually put a 330nf cap cause i did not have a 100nf

The earlier plot had a different input signal ?

 

What you show is certainly possible from a slow edge, noisy input. (which can be a floating  pin)

 

Multiple transitions result,  until the input level is clear of the threshold.

You need to double check Vcc.Gnd connections and check for any floating pins.

What are you using as a drive signal ?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Without a picture of your test setup trying to determine the source of the noise in the circuit will prove to be a guessing game. Are you using a prototyping breadboard like this:

 

 

I can only guess at this point that you have some hardware issue.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Yes I am using a breadboard. The input signals are coming from simply connecting a wire to 5v by hand. Then to ground, then to 5v then to ground. I am doing it manual specifically to create bouncing on the inputs. I thought that the NAND gate can be used to eliminate bouncing. Or is it a latch that does that?

Last Edited: Sun. Sep 6, 2015 - 06:47 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

calvingloster wrote:

Yes I am using a breadboard. The input signals are coming from simply connecting a wire to 5v by hand. Then to ground, then to 5v then to ground.

 

ouch.

 

calvingloster wrote:

I am doing it manual specifically to create bouncing on the inputs.

 

Then you have nicely succeeded  :)

 

calvingloster wrote:

I thought that the NAND gate can be used to eliminate bouncing. Or is it a latch that does that?

The fact you are unsure, suggests you already know the answer :)

Do you see any mention in the NAND data sheets of de-bounce ?

 

You can build a S-R latch with 2 NAND gates, plenty of Google-will-find examples of how to do that

.

That does not 'debounce' so much as provide two trigger signals, so bounce becomes a non-issue if they avoid overlap.

The first trigger edge ( =\_ ) will activate the latch as either !SET or !RESET, and any following pulses are repeating SET or REST so have no discernible effect on the output.

You will usually need a Pull-up resistor on each of !S & !R, and momentary buttons for !S & !R to GND

 

Check to see what happens if you apply both !S & !R, at the same time.

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

http://www.eng.utah.edu/~cs5780/...

 

Has plenty to say on the subject. Seems a 4011 isn't a good choice. A 4093 might be a better one.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

If the 4011 had an inherent bounce problem then it would not have been around for 40 years.  The bounce must be due to the inputs, the power supply or the measuring method.

 

An analogue scope would help but if the only tool is a LA then you need to look at the inputs to see if the tool sees them bouncing.  If it doesn't then connect LA inputs onto pins 7 and 14 of the 4011 - on the pins not anywhere else - and see what they are doing when the output bounces.  Don't forget that CMOS effectively only draws current on a transition and the power to the 4011 is likely to be ringing during the transition if you have poor HF decoupling.

 

A picture of your actual setup with 4011, decoupling capacitor, voltage feeds etc. would help.  Try feeding the power direct to the 4011 pins 7 and 14, run short wire from pin 14 to short strip for pull up resistors and avoid the use of power rails on the breadboard.

 

Davi

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Note that the input is floating when he connects the input, manually, between V+ and Gnd, and back and forth.

It is, therefore easy for the input to bounce, especially with the wire being held by one's fingers.

I think this was Who-Me's point, above.

 

JC

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Ok, I should have read all the posts and realised the subject was totally misleading. 

 

David

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

To add images inline in your messages (not as annoying attachments that must be opened separately) start by clicking this icon on the message editor toolbar:

 

 

In the dialog that appears just just [Upload...] and use the file selector that appears to select the .png/.gif/.jpg/.bmp/... that you want to use. When it is uploaded click [Next]. In the second dialog you can optionally specify "ALT TEXT" and "TITLE TEXT" but almost no one ever does. So just click [Save] and that is it you should get results as follows. These are all your preceding pictures. I have actually set ALT/TITLE on each to the filename so if you hover the mouse over them you should see the filenames (they are in the same order as your attachments above):

 

circuit_0.png

 

NAND Gate NOISE_0.png

 

zoomed on noise.png

 

NAND gate chip pinout.png

 

bouncing output.png

 

noise.png

 

Oh and one further thing - once a picture is inline in the editor you can double-click it and set a new viewing width/height. As your pictures were very large and this is just an example of how to put them inline I have used that that to make them a more sensible 800 pixels wide (450 high). One thing to note about that - if you do ever change the width/height in this way such changes are lost if you then edit the post (so I won't be editing this one even if I spot a typo after I post it!).

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

clawson wrote:

To add images inline in your messages (not as annoying attachments that must be opened separately) start by clicking this icon on the message editor toolbar:

 

 

In the dialog that appears just just [Upload...] and use the file selector that appears to select the .png/.gif/.jpg/.bmp/... that you want to use. When it is uploaded click [Next]. In the second dialog you can optionally specify "ALT TEXT" and "TITLE TEXT" but almost no one ever does. So just click [Save] and that is it you should get results as follows. These are all your preceding pictures. I have actually set ALT/TITLE on each to the filename so if you hover the mouse over them you should see the filenames (they are in the same order as your attachments above):

 

circuit_0.png

 

NAND Gate NOISE_0.png

 

zoomed on noise.png

 

NAND gate chip pinout.png

 

bouncing output.png

 

noise.png

 

Oh and one further thing - once a picture is inline in the editor you can double-click it and set a new viewing width/height. As your pictures were very large and this is just an example of how to put them inline I have used that that to make them a more sensible 800 pixels wide (450 high). One thing to note about that - if you do ever change the width/height in this way such changes are lost if you then edit the post (so I won't be editing this one even if I spot a typo after I post it!).

 

 

 

 

Thanx BUDY! not everyone has fast internet. down hear in south africa fast internet is very scars so i must do with what i have and post attachments. 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You quoted my post? Why?

 

so i must do with what i have and post attachments.

But it makes no difference - the time for you to upload is the same.