Autosave: 2024-07-04 07:00:04

This commit is contained in:
thomasabishop 2024-07-04 07:00:04 +01:00
parent 311f02b13a
commit 5867417c4a
4 changed files with 47 additions and 83 deletions

Binary file not shown.

View file

@ -29,4 +29,4 @@ The contact holes on the outer edges of the breadboard, designated by numbers
You will typically use the positive bus strip on one side for the voltage source You will typically use the positive bus strip on one side for the voltage source
and the negative bus strip on the other side for the ground outlet. and the negative bus strip on the other side for the ground outlet.
## Related notes

View file

@ -17,11 +17,20 @@ pairs.
To create a breakable circuit we would connect a signal-in cable to the top left To create a breakable circuit we would connect a signal-in cable to the top left
at row 23 and a signal-out cable to the bottom-right at row 25. at row 23 and a signal-out cable to the bottom-right at row 25.
![Push button legs diagram](../img/push-button-legs.png)
_The correct use of a push button where the button breaks the circuit_
![](../img/correct_push_button.jpg)
To override the switch functionality and just have the button work as a To override the switch functionality and just have the button work as a
connector we would connect the signal-in to the row 23 input and the row 23 connector we would connect the signal-in to the row 23 input and the row 23
output. output.
![Push button legs diagram](../img/push-button-legs.png) _The push button being used as simple connector which does not break the
circuit:_
![](../img/incorrect_push_button.jpg)
## Related notes ## Related notes

View file

@ -7,103 +7,58 @@ tags:
# Transistors # Transistors
In the discussion of A digital circuit requires that electrical phenomena be treated as discrete
[digital circuits](Digital_circuits.md) rather than continuous values.
we noted that a digital circuit requires that electrical phenomena be treated as
discrete rather than continuous values. Although a given voltage at a point in
the circuit can vary widely, in order to represent the binary states of 'on' and
'off' we need it to remain fixed within certain narrow parameters.
Typi>understanding the concept and then with transistors which are what are
actually used in computers.
## Implementing binary logic with mechanical switches Although a given voltage at a point in the circuit can vary widely, in order to
represent the binary states of 'on' and 'off' we need it to remain fixed within
certain narrow parameters. This is achieved with transistors.
An electrical switch is inherently binary. When the switch is on, it acts like a Transistors are an electrical component that is capable of controlling the flow
simple copper wire through which current flows freely. When the switch is off, of current in the manner of a switch where the 'off' and 'on' states are
it acts like an open circuit and no current can flow. represented by [voltage](Voltage.md) values within set parameters.
We can combine switches in a circuit to create analogs to logic gates.
![](/img/switch-and-gate.png)
In the example above a simple AND gate is implemented with switches. Each switch
is a conjunct and the current only flows if both switches are on, closing the
circuit.
![](/img/switch-or-gate.png)
In the example above is a circuit implementing an OR gate. The current flows
just if one of the switches are on or if both of the switches are on but not if
both switches are off.
## Transistors
In real digital circuits, mechanical switches would be totally impractical. The
number of switches required is too numerous and we need to be able to connect
and interconnect the output of many circuits together. The output of one circuit
needs to be fed into another and there is no way to do this with switches.
Thus instead of switches, modern digital circuits use transistors, a special
electrical component that controls the flow of current in the manner of a switch
where the 'off' and 'on' states are represented by
[voltage](Voltage.md) values within
set parameters.
There are different types of transistors but the simplest for the purposes of There are different types of transistors but the simplest for the purposes of
explanation are **bipolar junction transistors**. explanation are **bipolar junction transistors**.
![](/img/transistor-diag.svg) ![BJT transistor terminals](../img/bjt-terminals.jpg)
A transistor works as follows: applying a small amount of current at the base The pins:
allows a larger current to flow from the collector to the emitter. Relating this
back to switches, applying current to the base is like turning the switch on.
Removing this current is like turning the switch off.
The diagrams below show a transistor being used in a circuit to create 'on' and - C: collector
'off' switch states alongside a switch based circuit. - B: base
- E: emitter
![](/img/transistor-off.png) Applying a small amount of current at the base allows a larger current to flow
from the collector to the emitter. Applying current to the base is like turning
the switch on. Removing this current is like turning the switch off.
![](/img/transistor-on.png) This happens because of how current and voltage interact in a transistor. The
small base current controls the larger collector-emitter current through a
process called current amplification.
- $V^{in}$ is the voltage that electrically controls the switch-as-transistor This happens because of how voltage works. Voltage is the potential difference
- $V^{out}$ is the voltage we want to control: it will be high when the between two terminals in a circuit. A high voltage increases the flow of current
transistor is in the 'on' state and low otherwise whereas low voltage restricts or reduces it.
- $V^{cc}$ stands for "common collector" and is the positive supply voltage
appliced to the collector terminal is "on".
When the voltage at the base is low (in the diagram it is grounded to ensure It follows from this that when the voltage at the base is high, a current flows
this) no current flows from the c We recall that voltage is the potential from the collector to the emitter and the transistor is "on". Whereas when the
difference between two points or terminals in a circuit. High voltage increases voltage at the base is low no current flows from the collector to the emitter
the flow of current, low voltage restricts or reduces it. and the transistor is "off".
When the voltage at the base is high a current flows from the collector to the
emitter and the transistor is "on".
When the voltage at the base is low (in the diagram it is grounded to ensure
this) no current flows from the collector to the emitter and the transistor is
"off".
## Transistors and logic gates ## Transistors and logic gates
With the basic element of the transistor established, we can combine transistors We can combine transistors to create logic gates. A logic gate is a combination
to create logic gates. A logic gate is a combination/sequence of transistors of transistors arranged such that the logical function is embodied by the
where the logical function is represented by the characteristic input and output characteristic input and output voltages to the transistor.
voltages.
For example to create an For example to create an [AND](Logic_gates.md#and-gate) gate we would have two
[AND](Logic_gates.md#and-gate) gate voltage inputs going into two transistors that are connected in sequence. The
we would have two voltage inputs going into two transistors that are connected two transistors create a continuous line going from the collector of one to the
in sequence. The two transistors create a continuous line going from the emitter of the other. If either voltage input is low then the voltage of the
collector of one to the emitter of the other. If either voltage input is low combined line is low (equivalent to the circuit being broken) and there is no
then the voltage of the combined line is low (equivalent to the circuit being current flowing.
broken) and there is no current flowing.
![](/img/and-transistor.png) ![](/img/and-transistor.png)
Below, an // Add example of OR gate created with transistors
[OR](Logic_gates.md#or-gate) has been
constructed with transistors. If a voltage is applied to the base of either
transistor, the current reaches the V-out terminal.
![](/img/or-transistor.svg)