# Digital Electronics Questions

1. Jan 10, 2014

### whoareyou

I've recently started a digital electronics course with a lab component (so far not at all related to the lectures). Unfortunately, there are no prerequisites for the course and I guess they somehow expect us to know a whole lot about circuits, but I'm completely confused.

I"ll just ask two questions now and maybe if I don't understand some other things we can clear those up as well.

1. How do circuits like these make sense? I thought you needed a closed loop to have current flow ....

2. This is an example of an "active high" circuit. "When a switch is closed, the signal will be connected to power. When a switch is open, the signal will be connected to ground through the resistor." Does this mean that when the switch is open, there is actually current flowing through the wires?

I feel really stupid :(.

2. Jan 10, 2014

### Staff: Mentor

-1- The + and - symbols imply that there is a voltage source connected to those ends. The power supply (or battery) is what completes the circuit to allow current to flow.

-2- Usually such a switch is used to drive the input of logic gates high and low. That takes a small current to drive those inputs low or high, so yes, that current is either supplied by the power supply when the switch is closed, or by the pulldown resistor when the switch is open. When the switch is closed, the power supply provides both the pullup current for the logic gate, and drives a current through the pulldown resistor.

If that's not clear, post some follow-up questions.

3. Jan 10, 2014

### whoareyou

Ooops, wrong circuit! This one (there aren't any closed loops):

Also, "current is either supplied by the power supply [...] or by the pulldown resistor" --> I though resistors limited current. They also provide a current? I tried searching around the web and there are a lot of sources that say something about being in a floated state so that the input pin is sometimes how and sometimes low and that the resistor is in place to ensure it is low.

4. Jan 10, 2014

### Staff: Mentor

-1- Sure there are. Draw the Vcc voltage supply and its ground connection.

-2- The input to logic gates has a small leakage current that needs to be sourced or sinked to pull the input high or low. That leakage current can be supplied by a "hard" power supply voltage (like 5V or ground), or by a pullup/pulldown resistor. If the input leakage current for a CMOS gate is 10uA, and you use a 1 kOhm pullup/pulldown resistor, what will the input voltage be to the gate for a high and low input?

5. Jan 16, 2014

### whoareyou

I'm still not understanding the pull-up/pull-down resistor stuff. Why use resistors anyways? Why can't I just attach a wire in place of the resistor?

6. Jan 17, 2014

### CWatters

Some circuit symbols (like Vcc and Gnd) are shorthand. If you replace them with a voltage source you will see the circuit loops.

Resistors are used to pull the inputs to a defined logic level (0V/Gnd in your circuit) when there is nothing else connected to them. For example when the switches are open (off).

You can't use a wire instead because when the switches are made (on) the wire would connect VCC directly to 0V/Gnd via the switch. Very large current would flow because the resistance of the wire is very low.

7. Jan 22, 2014

### Staff: Mentor

Hi whoareyou.

There is a frequent confusion with terminology here, among people new to electronics. If you have a farming background, then you are accustomed to associating an open door or gate with free passage of animals, and a closed gate as allowing no passage through it. However, electrical switches are not farm gates. When an electrical switch allows current to flow through it, we say that switch is closed. Yes, really! And when the switch prevents the passage of current, we say the switch is open.

The origin of this lies with switch internals. When it is required to block electron flow, the circuit between the switch's terminals needs to be an open circuit, i.e., not be a continuous path of copper conductor within that switch. When flow of current is to be allowed, the switch's two terminals need to be joined as by a continuous path of copper conductor so as to close or complete the circuit.

All perfectly logical!

Now, having deftly cleared away the confusion between farm gates and electrical switches, we can turn our spotlight onto the topic of logic gates, and ask "should we draw a comparison between farm gates and logic gates?"

8. Jan 22, 2014

### ViperSRT3g

Not to tread on anyone's toes or anything. But in digital logic, a 1 is on and a 0 is off.

In the case of this circuit, the 1 would be the full voltage from the power supply. The 0 would be a decrease in voltage by way of a resistor. This results in constant flow of electricity, but at varying voltages to represent the 1, or 0.