Today I did the lab on NAND gates. For those who don't know, the idea behind a NAND gate is that you have two inputs and one output. If both the inputs are receiving +5 volts, the output is grounded (i.e. 0 volts.) Otherwise, the output is at +5 volts.
I plug in the "test circuit", which is about as trivial as it gets. You've got a chip. You connect it to voltage and ground. You set something up to measure the voltage, and you set something up to control the inputs.
With both inputs grounded it outputting 4.997 volts, which is well within tolerance. I went to connect one of the inputs to +5vdc, and brushed a wire.
I brushed the wire again.
Clickclick. Click. Click.
4.995 - no, wait. Click. 0.54mV.
I don't know how standard this is, but our digital multimeter (which is actually quite nice) clicks when it changes voltage modes. I imagine it's pretty standard. But it does mean that it clicks whenever going from 5v to 0v.
I sigh with resignation, and plug the resistor in entirely. Click. Click click click. Click. 0.40mV.
It *should* be 5v.
Click click. Click. 4.985V.
I write it down, accompanied by the cheerful clicking of the multimeter changing its mind.
The next resistor doesn't go any better. Neither, for that matter, does it work any better with both of them plugged in. It randomly changes its mind - in fact, at this point, it randomly changes its mind even with both terminals grounded.
Next, I have to write the truth table for another NAND gate on the same chip. It's about as productive. At this point, I'm down to poking the circuit with my finger repeatedly, then writing down the first realistic value it gives me.
The second section involves making more complex circuits. For example, an OR gate, which requires the use of three NAND gates. I laugh. Like I'm going to find three working NAND gates in the entire lab. I still test the two remaining gates on my chip, just to make sure.
The third is just as useful as the first two. The fourth, however, actually works . . . well, for some definitions of "works". With one input at +5vdc, it outputs +3vdc . . . which is sort of like answering a yes/no question with "Yno." Or possibly "Nes."
It's still an improvement.
For entertainment value, I set up an OR gate, using the "good" gate and two of the crappy ones. It works too, after a fashion. With both inputs grounded, I get +1vdc out - since the threshold is around 1.4vdc, that's technically a 0. With one input connected, I get +3vdc, and with both, I get +5vdc. (Well, occasionally I do - remember, these numbers involve a lot of circuit-poking.)
I look at the remaining parts of the lab. They don't want the real voltages. They just want 1's and 0's.
I write down what they expect, and turn it in.
Ain't school great.