Pages

Sunday, November 7, 2010

Opamp Configurations - Schmitt Trigger

This opamp configuration is derived from the simple comparator circuit: set up a reference at the non inverting and use the inverting as signal input. There is one main difference: this circuit uses feedback to move the reference point when the signal passes it.

The feedback goes from output to the non inverting input via a resistor.

This circuit's initial conditions are somewhat random, depending on noise when turned on and other similar things. For simplicity, we'll assume that the output starts full positive.

At turn on, the output is at positive, and the reference es set up using a voltage divider. With the output initially at positive, you can think of it as in parallel with the top resistor of the divider for practical purposes. If both resistors are equal, then the equivalent resistor is half the value; you can further simplify things at this point by making both top and feedback resistors twice the value of the second divider resistor, setting the reference at 0v (assuming the second resistor is connected to the negative rail).

The reference is now set at 0v, with the input starting lower than that, the output remains positive. When the input goes just a bit higher than the reference, the output will swing to full negative by action of the high internal gain.

With the output now negative, the output resistor is now virtually connected to the negative rail, so the parallel combination is now on the lower resistor. Using the parallel resistor formula, you can get the equivalent resistor.
    Rt = R1R2/(R1+R2)
With R2 twice that of R1, we get
    Rt = 2R^2/(3R) => Rt = 2R/3
With these values now we can calculate the voltage at the reference
    Vref = (Vcc+Vee)Rt / (2R + Rt)
where 2R is the top resistor of twice the value of the original lower resistor. Substituting Rt.
    Vref = ((Vcc+Vee)2R/3) / (2R + 2R/3)
Some algebraic manupulation.
    Vref = (Vcc+Vee)2R / 3(2R + 2R/3)
    Vref = (Vcc+Vee)2R / (6R + 2R)
    Vref = (Vcc+Vee)2R / 8R
    Vref = (1/4)(Vcc+Vee)
This Vref is by measuring from the non inverting terminal to Vee, we need to change this to be from the non inverting to ground; we know that ground is at the half position between  Vcc and Vee, so the 1/4 is actually 1/2 of Vee.

As you can see, Vref as moved towards the negative supply, so if any noise at the point where the signal crosses the initial reference drives it momentarily down, the output will not swing again at that point because the new reference is lower than what a typical noise will make the signal move.

When the signal goes down all the way to 1/2 of Vee, then the output will swing to positive, driving the reference voltage up along with it, so the switching action only occurs once even if the signal wiggles near the transition point.

This property is called hysteresis, and is useful in many applications where noise becomes a problem, specially in digital systems where excessive switching from noise can mess up the logic.

Opamp Configurations - Window comparator

The simple comparator circuit has one inherent problem: it can only tell us if one of the input voltages is higher than the other.

But what if you needed a circuit that tells us if a signal is within a range of values? you would need a circuit that tells you if the signal is higher than a minimum and if it also is lower than the maximum. The problem itself hints at the solution.

For a window comparator, we need one simple comparator set up just like the previous circuit: use the non inverting as reference and the inverting input as the signal entry. This comparator will set the maximum; if the signal goes higher than the reference the output will go negative, signaling an out of range (if we consider positive to be in range).

Another comparator is set by switching the reference and signal inputs, connecting the reference to the inverting input and the signal to the non inverting. If the signal is lower than the reference, the output will go negative, again indicating an out of range; this comparator sets the minimum.

When both opamp outputs go positive, it means that the signal is below the maximum and above the minimum, in other words, the signal is within the window of voltages you have defined.

There's one thing to consider with this configuration, when the signal is out of range, one of the opamps will go full negative (virtual connection to negative supply) and the other will be full positive (virtual connection to positive supply). This causes a short circuit condition that needs to be avoided as it could cause damage to the circuit or the supplies.

One way to protect from this cnndition is use diodes configured as the logic AND gate. This simply means to connect two diodes at the opamp outputs, connect both their anodes together and to the positive supply via a high value resistor.

What this does is that only when both opamps are at full positive (diodes' conduction blocked, basically disconnecting the opamps from the rest of the circuit) will the output be positive, held by the high value resistor.

When either opamp goes negative, the diode connected to it will be forward biased, basically connecting the output to ground; the other opamp is blocked from connecting to the output by the reverse biased diode (positive opamp output connected to cathode, negative to anode) and no short circuit condition occurs.

Opamp Configurations - Comparator circuit

One of the main reasons for using opamps as active devices in circuits is that their internal gain is so high, that even if we reduce it to a tiny fraction, it will still be enough for practical purposes. This particular configuration depends on the very high gain of the opamp to swing the output to one of the extremes; the sign of which tells us which input is more positive than the other.

By connecting the non inverting input to a voltage source, we are setting the reference point of the comparator. Remember that since there's no feedback, and because internally the opamp is just a very high gain difference amplifier, the output will be the non inverting input voltage minus the inverting input voltage, multiplied by the internal gain (in the 100k's).

This means that a difference of just millivolts will drive the output into saturation; if the difference is positive it will swing to full positive, limited by the supply. If the difference is negative, it will swing to full negative, again limited only by the supply.

On most amplifier circuits it is not advisable to drive the opamp into saturation because it clips the signal from going any further on both ends, but in this case we are not so much interested in the signal itself but on the relationship between the signal and a reference, so this circuit serves its purpose.

Opamp Configurations - Differentiator

The inverse function to integration is differentiation, in other words finding the derivative, which the opamp can also perform. The derivative is defined as the rate at which the function changes.

By using an input capacitor instead of a resistor, we can accomplish the same thing. If you remember, a capacitor stores charges in its plates, when one of them starts accumulating charges, the same charges will be pushed out from the other plate, as if current was flowing through the capacitor despite the intrinsic insulating layer.

The capacitor's charges start building up and creating a voltage across itself in opposition to the charging voltage, thus slowing down the incoming charges, slowing down the charging process in general. When enough charges have accumulated, the charges inside the capacitor completely push away the charges coming from the source, no more charges enter the capacitor, and because of this no more charges are pushed out on the other side of the capacitor, so no more apparent flow of current across the capacitor.

When used as input for a signal, if the signal does not change (like a DC input), the capacitor will have an initial apparent current through it as the voltage across it builds up due to incoming charges, and since the input of the amplifier tries to not draw any current, it will create a voltage at its output so that the current through the feedback resistor is the same as the apparent current through the capacitor.

Since the capacitor charges very quickly due to the voltage applied to it and the fact that there's no current limiting component like a resistor, the apparent current through the capacitor falls very quickly as the voltage across it in opposition rises as quickly; the falling current is also causes the opamp to drive the output voltage less, since there's less current to compensate for.

Applying a DC input to the differentiator thus creates a spike in input as well as in output as the capacitor's initial charge is developed, and then goes back to 0v as there's no more apparent current to compensate for; Similar to the operation of finding a constant's derivative, which is always 0.

The fact that there's an initial spike can be mathematically modeled as a period in which there's a function that rises at a very high rate (which actually happens, the voltage doesn't just jump from 0v to the DC input voltage, it rises very rapidly towards it), so its rate of change is very high for a brief period of time; hence the spike.

As the input voltage stabilizes, its rate of change slows down very rapidly as well, going towards zero when fully stabilized; this is reflected in the opamp's output by the fact that as the voltage stabilizes, the output spike goes down very rapidly towards zero and stays there.

Now instead of applying a constant input, you can replace it with a constantly changing input.

If the input is increasing at a constant rate, there will be a constant apparent flow of current through the capacitor, since the voltage buildup across the capacitor is compensated by the increase in input signal. Since there's a constant apparent flow of current through the capacitor, the opamp compensated by setting the output voltage at a level that will make the feedback resistor draw the same amount of current, so that the opamp input does not draw it.

Since the amount of apparent current is constant, a constant output voltage is enough to keep the feedback resistor drawing the current, and the opamp keeps a constant output at the output.

This mode is very similar to using a resistor with constant dc as the input.

The same is true for a constantly decreasing input voltage; the output will just be of reversed polarity. To compare with the mathematical definition of the derivative of a linear variable, the derivative will be a constant.

This can be expanded to other functions, one of the most widely used being the sine function. Since the mathematical derivative of the sin(x) function is cos(x), which is a shifted version of sin(x) by 90 degrees, when you input a sine input at the differentiator amplifier, the output will be the same function shifted 90 degrees, in essence, a cosine function.

Opamp Configurations - Integrator

If you replace the feedback resistor with a capacitor, you get an integrating amplifier.

In math, an integration operation is basically the area under a curve. If we have a voltage vs time graph, and the voltage remains constant, the integral of that will be the voltage times the time it stays at that level. As you can see, the longer the time the voltage remains constant, the higher the integral will be.

Back to our integrator, as the input voltage is applied to the inverting input via an input resistor that creates an input current. The Opamp will try to compensate the current by creating a voltage across the feedback element enough to make a current flow equal to that at the input to conform to the current rule: the inputs draw virtually no current.

In the simple inverting amplifier, the feedback resistor developed a constant current at a constant voltage at the output with respect to the inverting input, tied to ground. This time however, the feedback element is a capacitor; an element that can store charge, charge that eventually develops a voltage across it as it gets more and more charged.

If we apply a constant voltage at the input, a current flows through the input resistor. This current the opamp tries to compensate by creating a voltage at the capacitor to induce a current equal to that of the input. If the capacitor is initially completely discharged, the voltage across it is 0v, and its "resistance" is infinite since it is effectively insulating both sides so no current flows.

The gain is initially infinite, since Rfb/Rin tends to infinity by action of Rfb being infinity. This makes the output voltage go down quickly in a small amount of time (remember that the opamp is acting in an inverting configuration). As the capacitor starts charging, the charges entering the out plate of the capacitor push the charges on the other side, effectively creating a current across the capacitor, enough to counteract the input current.

As the charges build up inside the capacitor, a voltage develops across it in opposition of the output voltage, making it seem as if less voltage is applied to it, slowing down the amount of charges getting into the capacitor.

Less new charges going into the capacitor causes less charges being pushed out at the other plate. The Opamp tries to compensate by further lowering the voltage.

As you can see, the charges keep building up and the opamp is always trying to compensate by lowering the output voltage. At one point, the opamp will not be able to lower the output voltage, at which point it is said to be saturated.

The rate of charge of the capacitor depends on the current that is applied to it, and the current depends on the voltage and resistor at the input by ohms law I = V/R. The higher the voltage, the faster the capacitor charges and the output going lower, and the lower the input resistor the more current flows, charging the capacitor faster and resulting in the same faster lower output.

This action is the same as in the integration operation: the higher the value of the graph the higher the integral will be in the same amount of time.

Also if the input goes negative, the capacitor starts discharging and the output will go higher to compensate. If at any point the input goes to 0, the current through the input resistor will be zero, and the opamp will compensate by setting the output voltage at the same level as the capacitor voltage, in order to stop it from being charged or discharged.

Similar to what happens in an integration: if the graph crosses 0 and stays there, the integral will be the sum of areas up until that point and stay there for as long as the graph stays at zero. Also, if the graph goes lower than 0 then the integral will go lower because the area will be negative relative to 0.

Opamp Configurations - Summing Amplifier

Let's go back to the inverting amplifier. In its original form, we had one input resistance, one feedback resistance and one input voltage; but what happens if we have two or more inputs?

The math goes like this:
    Vrin1 = Vin1 - Vinv
The inverting terminal is at the same potential as the non inverting, which is tied to ground, so:
    Vrin1 = Vin1
Then separate Vrin into current times voltage, according to ohm's law:
    IinRin1 = Vin1 => Iin1 = Vin1/Rin1
But then again, we have more than one input, so for any Nth input, we have
    IinRinNth = VinNth => IinNth = VinNth/RinNth
And the voltage at the feedback resistor, same as before
    Vfb = Vinv - Vout
Separate by ohm's law
    IfbRfb = Vinv - Vout
    Ifb = (Vinv - Vout)/Rfb
Since the inputs try to draw no current, the current through the feedback resistor must be equal to the sum of the currents through each input resistor, by kirchoff's laws.
    Ifb = Iin1 + Iin2 + ... + IinNth
In terms of the voltages and resistances
    (Vinv - Vout)/Rfb = Vin1/Rin1 + Vin2/Rin2 + ... + VinNth/RinNth
Let's simplify to just two inputs, this can be expanded to more if needed; the equation holds true for more inputs.
    (Vinv - Vout)/Rfb = Vin1/Rin1 + Vin2/Rin2
Since we are interested in the output voltage, the equation is solved for it
    Vinv - Vout = (Vin1/Rin1 + Vin2/Rin2) Rfb
    - Vout = (Vin1/Rin1 + Vin2/Rin2) Rfb - Vinv
    (-1)(- Vout) = [-1][(Vin1/Rin1 + Vin2/Rin2) Rfb - Vinv]
    Vout = -(Vin1/Rin1 + Vin2/Rin2) Rfb + Vinv
    Vout = Vinv - (Vin1/Rin1 + Vin2/Rin2) Rfb
The voltage at the inverting input will be the same as the voltage at the non inverting, which is tied to ground, so this becomes
    Vout = - (Vin1/Rin1 + Vin2/Rin2) Rfb
If we assume equal resistors
    Vout = - (Vin1/R + Vin2/R) R
    Vout = - (Vin1 + Vin2) (R/R)
    Vout = - (Vin1 + Vin2) (1)
    Vout = - (Vin1 + Vin2)
Notice how the output is the inverse of the sum of the voltages. This happens because we are using an inverting amplifier base, so as expected the output is inverted. Also note that the ratio of input and feedback resistors also set the gain by multiplying the sum by the ratio of resistances; if all input resistances are the same the gain is controlled by the feedback resistor.

Another variation of this circuit is using different input resistors for each input voltage, thus creating a weighted sum, useful in some very simple digital to analog conversion circuits.

Opamp Configurations - Difference Amplifier

Difference Amplifier

So far you've learned about how to make an opamp add an inverted (negative) voltage to a reference, and to add a positive voltage by setting the reference.

Since the opamp has two inputs, one inverting and one non inverting, it should be possible to use both at the same time to add them to one another, and since one will be inverted, the effect will be a difference of voltages.

This one is a bit trickier to derive equations for, since, as you already know, the voltage that will be applied to the non inverting input will also appear at the inverting input via the opamp trying to compensate.

Since we are using resistor ratios in the voltage divider to set the voltage at the non inverting input, the voltage at the inverting one will be in terms of those resistors as well, otherwise the equations are derived the same as for the inverting amplifier.

Lets start with the inverting amplifier equations
    Vrin = Vin - Vinv
    IinRin = Vin - Vinv => Iin = (Vin - Vinv)/Rin
Same as last time, except Vinv is non zero, set by the voltage divider. Applying the current rule:
    Iin = Ifb, Ifb is the feedback current.
    Ifb = (Vinv - Vout)/Rfb
Vinv is not tied to ground, so it can't be simplified more at this point. We also have
    Iin = Ifb => (Vin - Vinv)/Rin = (Vinv - Vout)/Rfb
Expressed in terms of Vout, this becomes
    (Vin - Vinv) (Rfb/Rin) = Vinv - Vout
    (Vin - Vinv) (Rfb/Rin) - Vinv = - Vout
Multiply both sides by -1
    (-1)[(Vin - Vinv) (Rfb/Rin) - Vinv] = (-1)(- Vout)
    - (Vin - Vinv) (Rfb/Rin) + Vinv = Vout
    Vinv - (Vin - Vinv) (Rfb/Rin) = Vout
Now, since Vinv is in terms of the non inverting voltage, we have
    Vninv = Vin2 R2 / (R1+R2)
And
    Vinv  = Vninv => Vinv = Vin2 R2 / (R1+R2)
So we can rewrite our Vout equation now in terms of both input voltages
    Vinv - (Vin - Vinv) (Rfb/Rin) = Vout
    [Vin2 R2 / (R1+R2)] - (Vin - [Vin2 R2 / (R1+R2)]) [Rfb/Rin] = Vout
This seems complicated enough as it is, so from here we are going to simplify by making some assumptions. Lets make all resistors equal.
    R = R1 = R2 = Rfb = Rin
The equation then becomes
    [Vin2 R/2R] - (Vin - [Vin2 R/2R] [R/R] = Vout
    Vin2 (1/2) - (Vin - [Vin2 (1/2)] [ 1/1 ] = Vout
    Vin2 (1/2) - (Vin - [Vin2 (1/2)] = Vout
    Vin2 (1/2) - (Vin - [Vin2 (1/2)] = Vout
    Vin2 (1/2) - Vin + Vin2 (1/2) = Vout
    Vin2 - Vin = Vout
As you can see, with our assumption of equal resistors, the output will be equal to the difference of voltages applied, the applied at the non inverting minus the one applied at the inverting. In practice if you use the same ratios of resistors, the relation holds. You could also use equal ratios (not precisely 1:1) to set the gain; if you use different ratios you will get a weighted difference.

Opamp Configurations - The non inverting amplifier

For a non inverting action, a simple way to obtain it is to keep the feedback loop in place and connecting the terminal where the input used to be connected, to ground, while feeding the input signal to the non inverting input.

This makes the opamp create an output voltage so that the current flowing through the feedback resistor network will be the necessary to develop a voltage at the inverting input that is the same as the non inverting input.

Since we know that the inputs draw virtually no current, then the voltage at the inverting terminal will be defined by the voltage divider created with by the feedback network.
    Vinv = VoutR2 / (R1 + R2)
Since Vinv, the inverting input, is at the same potential as the non inverting input, then
    Vin = VoutR2/(R1+R2)
The gain is the ratio of output voltage to input voltage
    gain = Vout/Vin
A rewrite of the Vin equation gives you
    Vin/Vout = R2/(R1+R2)
This las equation is the inverse of what we need, so lets get it straight
    Vin = Vout R2/(R1+R2)
    Vin (R1+R2) = Vout R2
    (R1+R2) = R2 (Vout/Vin)
    (R1+R2)/R2 = Vout/Vin
That's an equation for gain, which can be further simplified by separating the terms
    (R1/R2) + (R2/R2) = Vout/Vin
    (R1/R2) + 1 = Vout/Vin
As you can see, the gain is similar to the inverting amplifier, set by the ratio of the feedback resistors. In this case however, the gain will always be higher than 1. You can think of it as if the amplifier is adding the amplified signal to the non inverting reference voltage, which in fact is the same as the inverting, just that in this case the reference is not ground (0v).

Opamp Configurations - Inverting amplifier

As you leaned in the intro to opamps, when under negative feedback, the voltage difference across its inputs will be close to 0v. This is achieved via compensation from the opamp output and the feedback loop.

In the simplest way to achieve it is a configuration known as the inverting amplifier. In this configuration, the non inverting input is tied directly to ground, and a feedback loop is made using a resistor connected between inverting input and output.

Another resistor is used to connect the signal source to the amplifier, since the inverting input will be at the same potential by action of the feedback loop, it would be connected to ground and no signal would get to the opamp to get amplified.

The voltage in through the resistor will cause a current going in the direction of the inverting input. Since one of the properties of the op amp is that its inputs draw virtually no current, or at least it will try not to draw current by pulling the output voltage towards a more negative value, in order to create a voltage across the feedback resistor that will draw the same amount of current as what's trying to go through the input resistor.

The math behind this action:

    Vrin = Vin - Vinv
The inverting terminal is at the same potential as the non inverting, which is tied to ground, so:
    Vrin = Vin
Then separate Vrin into current times voltage, according to ohm's law:
    IinRin = Vin => Iin = Vin/Rin
Now you get an equation for the current in. Since the input will not draw current, we have that
    Iin = Ifb, Ifb is the feedback current.
    Ifb = (Vinv - Vout)/Rfb
Again, Vinv is tied to ground similar to the non inverting, so
    Ifb = (0 - Vout)/Rfb => -Vout/Rfb
We equal both currents to get an equation in terms of only voltages and resistors
    Iin = Ifb => Vin/Rin = -Vout/Rfb
The variable of interest is Vout, so rewrite it in terms of Vout
    (Vin/Rin)Rfb = -Vout => -Vin(Rfb/Rin) = Vout

From this last equation you can see that the output voltage will be an inverted version of Vin multiplied by the ratio of the input resistor and the feedback resistor; increasing the input resistor gives less gain, while increasing the feedback resistor increases gain.

The Operational Amplifier OpAmp

The operational amplifier is perhaps the most versatile of amplifier circuits, used many different applications as a gain component due to high stability, gain and input impedance, as well as the fact that very little external components are needed for operation.

Internally, the OpAmp is based around a transistorized differential amplifier; two transistors connected to the same emitter resistor, where one of the inputs is inverted and added to the other to essentially subtract one from the other, the difference amplified by a certain factor and fed as the output.

The basic opamp is a simple differential amplifier. Most commercially available opamps have extra internal circuitry to compensate for temperature change, different voltage source values and compensation to get an exact 0v when both inputs are disconnected.

There are two characteristics that make opamps so versatile: The voltage difference across its inputs will be very close to 0v, and its inputs draw virtually no current. This characteristics are only valid only under Negative Feedback.

Negative Feedback

Opamps have a very high intrinsic gain, something in the order of 150,000 and higher; this is called the open loop gain. This gain is not very useful by itself since it is very unstable; it changes with temperature, supply voltage and also requires extremely small signals to work within a useful range of voltages without clipping the incoming signal.

A method deviced from the conception of the opamp is the use of a feedback loop to limit the gain of the op amp to lower than 100, but that the gain will only depend on external components instead of the built in properties of the device.

The feedback is connected in a way such that any increase in the feedback signal will lower the output, similar to adding a negative, hence it's name.

The MOSFET: Metal Oxide Semiconductor Field Effect Transistor

Sometimes, even that small amount of current is too much, so a new FET design came into being. The Insulated Gate FET (IGFET) is another type of field effect transistor. This time, the P material is completely dumped and replaced by a metal contact. The metal does not come in direct contact with the N material, instead it is insulated by a thin layer of Silicon Dioxide (In other words, glass).

This configuration of materials gives this type of transistor its more common name: Metal-Oxide-Semiconductor FET, or MOSFET for short.

The internal working of the MOSFET is somewhat different from that of the junction FET in action, not in principle, and there are two modes of operating a MOSFET called Depletion mode and Enhancement mode.

In depletion mode, when a gate voltage is applied the metal contact acts as a capacitor and start charging positively. This charge draws electrons to the other side of the oxide insulator, which recombine with the holes of the P material, resulting in a zone of neutral net charge.

This region acts in exactly the same way as the depletion zone of the reverse biased diode, which in effect is a neutral net charge zone inside the semiconductor. As you can see, the net effect is the same, as the gate voltage is increased, more electrons are drawn to towards the gate and neutralize the holes; and also as the voltage at the gate decreases, the electrons are free to move again, the channel widens and more current flows.

In enhancement mode, a layer of N material is built inside the P bar, in a structure similar to the bipolar transistor. This intrinsic layer creates two depletion regions inside the bar, insulating the from each other so no current can flow.

In P channel enhancement mode MOSFETs, the applied voltage is negative, opposite of how it was in depletion mode. When a negative voltage is applied to the gate, it pushes electrons away from that region, leaving only the holes.

In the area where the gate meets either depletion zone, the result is a net positive charge in the material, as if in that zone the material was the same P type material. The free electrons of the intrinsic N type layer are pushed away from the gate, also leaving a zone of free holes that act as P type material.

As you can see, in this mode a channel is created near the gate that connects both ends of the P material, pushing the N middle layer away, allowing current to flow through it. When the voltage is removed, the free electrons again fill the holes and the depletion zones return to their normal neutral net charge state, insulating the layers and preventing current flow.

CMOS: Complementary MOSFET

Let's do a quick review of MOSFET operation.

An P type MOSFET in depletion mode, apply a positive voltage enough to create a wide neutral zone and it turns off by the action of holes at the base drawing electrons to it.

An N type MOSFET in depletion mode, connected to ground, a reservoir of electrons, and they start to push electrons on the other side of the gate away, as if connected to a negative voltage, creating a zone where the material loses its negative charge via the lost electrons, and it turns off.

As you can see, only one of the types of MOSFET is active in a certain configuration: Positive turns the P type OFF and the N type ON, and ground will turn P type ON and the N type OFF.

This interesting characteristic is employed in the making of digital circuits, that work with ON (1) and OFF (0) values only, and the fact that ON is represented by an almost direct connection to a positive rail and 0 is an almost direct connection to the ground rail.

A very simple circuit demonstrates it, called an inverter. Imagine one P type MOSFET's source connected to positive and sink to the source of a N type MOSFET. Also, the sink of the N type is connected to ground.

Both MOSFETs share the same base connection, and the output will be taken at the P sink/N source connection.

When we connect the base to the positive rail, the P type MOSFET will turn off, insulating the output from the positive rail its source is connected to, but the N type MOSFET will be fully on, effectively connecting the output to the ground rail. An ON (1) input gives an OFF (0) output, in other words, the input is inverted.

On the other hand, if we connect the shared base connection to ground, the P type transistor will be fully ON, connecting the output to the positive rail, and the N type will be fully OFF, insulating it from the ground rail. An OFF (0) input gives an ON (1) output, again, the input is inverted.

Many more combinations of this two complementary MOSFETs are possible, creating any kind of digital circuit you can imagine, like all of the microprocessors used to build computers and cell phones.

Field Effect Transistors

The field effect transistor is a component that uses only one junction instead of two as in bipolar transistors. Even though it is only one junction that also functions like a diode, the actual layout of the materials make it have some properties that allow a single junction device function like a transistor.

The layout of the FET is a bar of semiconductor material that has a ring of an oppositely doped semiconductor material around it. This Transistor is called the junction field effect transistor or JFET.

There are two types of JFET, called N-channel and P-channel. The name comes from the type of material that makes up the bar of material, for example the N-channel is a bar of N material with a ring of P material around it.

The explanations here are given for P-channel JFETs, as with bipolar transistors, just reverse polarities for N-channel JFETs.

Similar to the Bipolar transistors, FETs have three terminals, Source, Gate and Sink that correspond in function to the Collector, Base and Emitter of the BJT, respectively

Junction FET operation (JFET)

Junction FETs work with the diode junction in reverse bias, that is, a more positive voltage is applied to the cathode instead of the anode, the cathode being the gate terminal.

When a gate voltage is applied, the junction depletion region widens by action of the reverse bias of the PN junction. With enough voltage applied, the depletion region widens enough as to completely divide the P material bar, effectively preventing current from flowing. When the gate voltage is lowered, the depletion region shrinks again and current can flow again.

Even in the absence of a control voltage at the gate, the transistor is able to conduct current through its P material body, and works like a semiconductor resistor. When a gate voltage is present, it effectively increases the resistance of the JFET's body, thus controlling the amount of current flowing through it.

Since the PN junction of the JFET is in reverse bias mode, very little current flows (only leakage current caused by heat), so it is useful in applications where loading of a previous stage can affect its behavior or there's a need to limit the amount of consumed current, as in low power applications.

Capacitive Coupling: Isolating AC from DC

In order to connect an alternating signal into the transistor amplifier in a way that the circuitry that generates the signal doesn't interfere with the operation of the amplifier, and also that the biasing and operation of the transistor amplifier doesn't change the way the circuitry of the source signal operates, we need a way to isolate them from each other.

Since the only component of interest that needs to be shared by both circuits is the alternating signal (AC signal), we need to use a component that will let the ac component pass while blocking the any DC of the bias circuitry or the signal generator.

As you learned in a previous lesson, a capacitor is a component that can store energy in the form of an electric field created by lumping charges close to each other but still isolated. Current cannot directly cross the insulating layer inside the capacitor, effectively blocking any direct current flow.

But something interesting happens when a capacitor is affected by an alternating current. On the positive half of an AC wave, one side of the capacitor is filled with an inrush of electrons, while on the other side, electrons are pushed out to be replaced with holes, until the capacitor is fully charged and no more charges move.

For the moment when the capacitor is charging, the amount of electrons entering one plate of the capacitor is the same as the electrons being pushed out from the other side, almost as if the electrons had just crossed the insulating layer.

When the polarity is reversed the effect happens once again, the electrons are now drawn towards the voltage source, leaving holes in the plate of the capacitor. These holes draw the electrons that were previously pushed away, into the plate of the capacitor. The net effect is again as if the electrons crossed the insulating layer to get to the voltage source.

In practice, it is not the actual crossing of the electrons that is of use, but the movement of them on both sides of the capacitor that can be used as a current in the circuit.

Summarizing, the capacitor blocks any current that tries to directly cross the insulating layer, but it can't stop the electrons from being drawn to or away from the plates, effectively letting alternating voltages get through.

This effect is used to isolate the DC component from both sides while allowing the ac to flow, and is called capacitive coupling.