.. _diodes: ********* Diodes ********* This starts Part II of our lab experiments which are directly related to the lecture material of Elec 2210. Again, it is mandatory for you to read the lab manual and complete the pre lab assignments. There will be "What to do in lab report" sections in the lab procedures. Observe those requirements so that you take necessary measurements needed for reporting. Objectives ============== The experiments in this laboratory exercise will provide an introduction to diodes. You will use the ELVIS II+ breadboarding system to build and test several DC and AC diode circuits. The objectives of this experiment include: #. Review basic principles of diodes from ELEC 2210 #. An understanding of diode rectifier circuits #. More experience with the ELVIS II+ breadboarding system and the oscilloscope #. Continue to develop professional lab skills and written communication skills. Required Soft Front Panels (SFPs) ================================= #. 2-wire I-V analyzer #. Function Generator #. Scope Required Components ==================== #. 330 :math:`\Omega` resistor #. 20 :math:`k\Omega` resistor #. 1N4733 zener diode :download:`datasheet <./datasheet/diodes/Zener_1n4733.pdf>`. #. 1N914 small signal diode x4 :download:`datasheet <./datasheet/diodes/1N914.pdf>`. #. Red LED x2 #. Green LED x2 #. Yellow LED x2 #. 1 :math:`\mu` F Capacitor #. 3.3 :math:`\mu` F Capacitor x2 #. 4558 op-amp (for bonus) :download:`datasheet <./datasheet/diodes/rc4558.pdf>`. #. 1 :math:`k\Omega` resistor (for bonus) Introduction ============ A thorough treatment of diodes can be found in Chapter 3 of the ELEC 2210 textbook, Microelectronics Circuit Design by R.C. Jaeger. Diode Basics ------------------- Diodes are circuit elements that allow current to pass in one direction, while blocking it in the other direction. They are used in rectifier circuits, which convert AC to DC, and in voltage regulation and voltage limiting circuits. An ideal diode has the following Shockley I-V characteristics: .. math:: :label: ivdiode I = I_{s} [ \exp \left( \frac{V_{f}}{\phi_{t}} \right) - 1 ], where Is is the saturation current, Vf is the forward voltage, and :math:`\phi_{t}` = kT/q is the thermal voltage. Consider two biases :math:`v_{f,1}` and :math:`v_{f,2}`, the current ratio relates to the voltage difference by: .. math:: :label: iratio \frac{I_2} {I_1} = \exp \left( \frac{V_{f,2} - V_{f,1}}{\phi_{t}} \right) For a current ratio of 10, the voltage difference is: .. math:: :label: slope V_{f,2} - V_{f,1}= \phi_{t} \ln(10) At 300K, :math:`\phi_t=25` mV, the voltage difference corresponding to 10x current difference is 60 mV theoretically for ideal diodes. Higher order physical effects degrade the I-V slope. As a result, it takes more than 60 mV voltage increase to increase the current by one decade, or 10x. From (1), we can see that the diode current increases exponentially as the diode voltage becomes more positive (forward bias), but the current is asymptotically limited to -IS when vD is negative (reverse bias). If the diode is forward biased substantially, Equation 1 can be simplified to a pure exponential, and then near room temperature we can deduce the *60 mV per decade rule*, which says that Vf increases approximately 60 mV for every factor of 10 increase in Id. In addition to the behavior described by (1), all diodes have a reverse breakdown voltage, VBR, at which significant reverse current will begin to flow. For many applications, it is desirable to have VBR be as large as possible. For other applications, such as voltage regulation, we require relatively low reverse breakdown voltages, such as 5 V or 9 V. For these applications, we use Zener diodes. The reverse characteristics of a typical Zener diode measured using ELVIS are shown in :num:`Figure #fig-zener-iv-curve`. .. _fig-zener-iv-curve: .. figure:: images/diode/zener-iv-curve.png :scale: 100 % :alt: zener diode iv curve :align: center Current-voltage characteristics of a typical zener diode. Real diodes have series resistance and junction capacitance which affect their behavior in circuits at higher currents and higher frequencies. Furthermore, IS is a strong function of temperature. These effects will not be considered in this lab experiment. Rectifier ------------ :num:`Figure #fig-series-circuit`. shows a half wave diode rectifier. Vout = I*R. When Vin is greater than zero, I is greater than zero and Vout is greater than zero. When Vin is less than zero, both I and Vout are approximately zero. .. _fig-series-circuit: .. figure:: images/diode/series-circuit.png :scale: 100 % :alt: series circuit with diode :align: center Half wave rectifier. Current will flow in only the forward direction through the diode, as long as the peak negative value of the voltage does not exceed the reverse breakdown voltage of the diode. In this case, Vout will never be negative, thus the AC voltage is said to be rectified. The resulting waveform will be only the top half of the input sine wave. However, to create what would be considered direct current, we will also need a capacitor. The filter capacitor is placed in parallel with the load resistance in a power supply. Its purpose is to filter out the voltage fluctuations in the rectified waveform. On most diodes, the p-type terminal is marked with a red band and the n-type terminal is colored black. The red end is called the anode and the black end is called the cathode. It is easiest to remember that current flows from the positive to the negative terminal, or from red to black. Because LEDs are often clear, a different system is used. The long lead of an LED is a the positive one. This system is also used to identify the polarity of other components. For example, the longest lead of a polarized capacitor is also positive. .. _filt-design-sec: Designing Filters for Rectifiers ----------------------------------- As we saw in the previous section, diode is a useful component to design rectifier circuits that convert alternating (or bipolar) signal into unipolar signal, that can then be filtered to obtain a constant level. Here we present design equations for the half-wave and full-wave bridge rectifier that you will build in the lab. For a half-wave rectifier, that has a sinusoidal input of period :math:`T`, peak voltage of :math:`V_p`, and diode-on voltage :math:`v_{on}`, then the peak-to-peak ripple voltage :math:`V_r` is given by -- .. _hwr-filter-eqn: .. math:: :label: hwr-filter V_r = \left(V_p-v_{on}\right) \times \left(1-e^{-\frac{T}{RC}}\right), where :math:`R` is the load resistance and :math:`C` is the capacitance of capacitor connected in parallel with the load resistance. For a full-wave rectifier, the peak-to-peak ripple voltage for the same sinusoidal input is smaller (why?) than the half-wave rectifier and is given by -- .. _fwr-filter-eqn: .. math:: :label: fwr-filter V_r = \left(V_p-2v_{on}\right) \times \left(1-e^{-\frac{T}{2RC}}\right). Using the ripple voltage :math:`V_r`, we can also find the **conduction time interval**, :math:`\Delta T`, which is basically the time duration for which any diode conducts in each period, for both the half-wave and full-wave rectifier using the following result: .. _filter-cond-time-eqn: .. math:: :label: cond-time-eqn \Delta T = \frac{T}{2\pi} \times \cos^{-1} \left( \frac{V_p-V_r}{V_p} \right) **Peak inverse voltage**, PIV, is defined as the maximum reverse voltage sustained by any diode during each period. PIV for half-wave rectifier is given by :math:`2V_p-v_{on}`, while for a full-wave (bridge) rectifier it is given by :math:`\frac{2V_p-2v_{on}}{2}=V_p-v_{on}`. Pre-Lab ======= #. Using the formulas from Equations :ref:`(4) `, :ref:`(5) `, and :ref:`(6) ` [*not the equations given in our class notes or text*], calculate the ripple voltage, conduction time interval, and peak inverse voltage for both a half-wave rectifier and a full-wave (bridge) rectifier with the following parameters: 100Hz, 10 volt peak-to-peak input, 20k :math:`\Omega` load resistance, 1 :math:`\mu` F filter capacitor, 0.6 volt diode turn on voltage. .. note:: The equations for ripple voltage developed in our lecture notes and text assume a very small ripple voltage, and near DC output. This can result in large errors, as you will find out when comparing hand calculation with simplified equations with simulation and measurement. So you are better off using the more accurate equations given for half-wave [Equations :ref:`(4) ` and :ref:`(6) `] and full-wave rectifiers [Equations :ref:`(5) ` and :ref:`(6) `]. #. Simulate the same two circuits in multisim using 1N914 diodes. Find the ripple voltage, conduction time interval, and peak inverse voltage. Take screenshots for prelab report. Compare the results of your simulations with your calculated values. A sample file is provided for each circuit, however the parameters must be changed. Note that the sample file contains two circuits. Either can be used. However, one of the circuits is connected to simulated versions of the instruments used throughout the rest of the lab. The sample files can be found :download:`here for half wave <./customprograms-auto-dev-name/diode/diode_sample_prelab.ms11>` and :download:`here for full wave bridge <./customprograms-auto-dev-name/diode/diode_sample_prelab2.ms11>`. .. note:: You need to change your scope channel input connections to measure a different voltage. In simulation, you can also use more scopes to display more voltages, as you see in the full wave sample file. You can also use the grapher and type in an expression to observe a different voltage, e.g. the reverse voltage across a particular diode. Lab Exercise ============ **There are three parts and a bonus. Have your GTA sign off on each part before proceeding to the next part.** LED Bridge ---------- One use of diodes is to prevent damage to components when power supply polarity is reversed. For example, consider the circuit shown in :num:`Figure #fig-led-bridge-rectifier`. When the power supply is connected normally, both the green and yellow LEDs light up, indicating that current is flowing through them. However, when the power supply polarity is reversed, the red LEDs will turn on. In both cases, the yellow LEDs will illuminate. .. _fig-led-bridge-rectifier: .. figure:: images/diode/led-bridge-rectifier-new.png :scale: 100 % :alt: led-bridge-rectifier :align: center LED bridge circuit. #. Construct the circuit shown in :num:`Figure #fig-led-bridge-rectifier`. In order to make the circuit easier to understand, use the pin holes instead of wires to connect the red and green LEDs to one another. #. Swap the +15v and ground wires. .. topic:: What to do in lab report Explain why the red and green LEDS never light up simultaneously. .. Diode I-V characteristics with Instrument Launcher. ----------------------------------------------------- #. Turn on both the ELVIS base and the power to the breadboard. #. Open the ELVIS instrument launcher via Start > Programs > National Instruments > NI ELVISmx for NI ELVIS & NI myDAQ > NI ELVISmx Instrument Launcher .. _fig-start-menu: .. figure:: images/diode/start-menu.png :scale: 100 % :alt: ELVIS start menu location :align: center Instrument Launcher location. #. Open the 2-wire current voltage analyzer soft front panel and carefully measure the forward characteristics of the 1N4733 diode, as follows. Connect the anode to the DUT+ terminal (pin 29 on the lower left terminal strip) and connect the cathode to the DUT- terminal. Set the stop voltage to .80 volts, set the increment to .01 volts, and use the low gain setting, as shown in :num:`Figure #fig-zener-iv-analyzer`. Set the current axis to logarithmic scale. .. _fig-zener-iv-analyzer: .. figure:: images/diode/1N4733-iv-analyzer.png :scale: 100 % :alt: 1N4733 iv analyzer :align: center Current-voltage analyzer settings for forward IV. #. Click run. Click the log icon to save the measured data for use in lab report. #. Repeat the above procedure and sweep from -5v to 0v with a .05v increment. Use a linear scale for both axes, as the logarithmic scale will not display negative values. What would you estimate is the reverse breakdown voltage of the zener diode? Does breakdown occur abruptly? Click the log icon to save the measured data for use in lab report. .. topic:: What to do in lab report Show all screen shots. Using the data file saved above, estimate the voltage difference between two points of 10x current difference in the linear region when the current axis uses log scale. Compare your result with the 60 mV per decade rule. For example, use approximate current values of 5 mA, .5 mA or .6 mA, .06 mA to test the rule. If you cannot find two current values in the linear region that are approximately a decade apart, linear interpolation will be required. Compare the corresponding voltage differences with 60 mV. A graph made using data from this measurement is shown in :num:`Figure #fig-slopeofdiodeiv` and illustrates a 72 mV/decade slope. Note that a log scale is used for the current axis to facilitate observation of the voltage swing required for a 10x change of current. .. _fig-slopeofdiodeiv: .. figure:: images/diode/slopeofdiodeiv.png :scale: 100 % :alt: 1N4733 iv analyzer :align: center How to find voltage difference required for 10x current change. Diode I-V characteristics with Custom LabVIEW Program. --------------------------------------------------------- ================================ Forward Characteristics ================================ #. Make circuit connections as shown in :num:`Figure #fig-zener-ivf-schem`. VPS+ is the positive variable power supply. .. _fig-zener-ivf-schem: .. figure:: images/diode/zener-diode-ivf-schem.png :scale: 100 % :alt: 1N4733 iv analyzer :align: center Zener diode schematic with connections on ELVIS for forward IV characteristics. #. Turn on both the ELVIS base and the power to the breadboard. #. Download the LabVIEW program :download:`here <./customprograms-auto-dev-name/diode/diode-idvd-tracer.vi>` for plotting forward IV characteristics of the 1N4733 diode. #. Set the Vd start voltage to 0V, and Vd stop to 1V. Set number of steps as 30. Click run. Right click on the plot to save the measured data for use in lab report. Take a screen shot. You should see a plot like one shown in :num:`Figure #fig-zener-diode-ivf`. .. _fig-zener-diode-ivf: .. figure:: images/diode/zener-diode-ivf.png :scale: 100 % :alt: 1N4733 iv analyzer :align: center Zener diode forward IV characteristics, with Vd start and stop settings. ================================ Reverse Characteristics ================================ #. We shall now plot the reverse characteristics of the zener diode. First turn off power to the breadboard. Make the connections as shown in :num:`Figure #fig-zener-ivr-schem`. It just entails swapping VPS+ with VPS- in the earlier circuit. .. _fig-zener-ivr-schem: .. figure:: images/diode/zener-diode-ivr-schem.png :scale: 100 % :alt: 1N4733 iv analyzer :align: center Zener diode schematic with connections on ELVIS for reverse IV characteristics. #. Download the LabVIEW program :download:`here <./customprograms-auto-dev-name/diode/diode-idvd-RB-tracer.vi>` for plotting reverse IV characteristics of the 1N4733 diode. #. Set the Vd start voltage to 0V, and Vd stop to -5V. Set number of steps as 30. Click run. Right click on the plot to save the measured data for use in lab report. Take a screen shot. You should see a plot like one shown in :num:`Figure #fig-zener-diode-ivr`. .. _fig-zener-diode-ivr: .. figure:: images/diode/zener-diode-ivr.png :scale: 100 % :alt: 1N4733 iv analyzer :align: center Zener diode reverse IV characteristics, with Vd start and stop settings. #. What would you estimate is the reverse breakdown voltage of the zener diode? Does breakdown occur abruptly? .. topic:: What to do in lab report Show all screen shots. Using the data file saved above, estimate the voltage difference between two points of 10x current difference in the linear region when the current axis uses log scale. Compare your result with the 60 mV per decade rule. For example, use approximate current values of 5 mA, .5 mA or .6 mA, .06 mA to test the rule. If you cannot find two current values in the linear region that are approximately a decade apart, linear interpolation will be required. Compare the corresponding voltage differences with 60 mV. A graph made using data from this measurement is shown in :num:`Figure #fig-slopeofdiodeiv` and illustrates a 72 mV/decade slope. Note that a log scale is used for the current axis to facilitate observation of the voltage swing required for a 10x change of current. .. _fig-slopeofdiodeiv: .. figure:: images/diode/slopeofdiodeiv.png :scale: 100 % :alt: 1N4733 iv analyzer :align: center How to find voltage difference required for 10x current change. .. Commented out... Half-wave rectifier and Operation Under High Reverse Voltage ----------------------------------------------------------------- Now, a circuit will be constructed that demonstrates a simple application of a diode, the half-wave rectifier. #. Build the circuit shown in :num:`Figure #fig-half-wave-rectifier`. Use the 1N4733 diode, a 1000 :math:`\Omega`, 1/4 Watt resistor, and the FGEN on the ELVIS. .. _fig-half-wave-rectifier: .. figure:: images/diode/half-wave-rectifier.png :scale: 100 % :alt: half wave rectifier :align: center Half-wave rectifier. #. Connect the ELVIS function generator (pin 33 on lower left terminal strip) to one of the analog inputs on the top left terminal strip. Because the analog inputs are differential and the ELVIS function generator is internally grounded, the negative analog input must be tied to ground, pin 49 or pin 53 on the lower left terminal strip. Adjust the FGEN to sine, 2 V peak (4 V peak-to-peak), 1 kHz. Make sure that the signal route on the function generator is set to \"Prototyping board,\" as shown in :num:`Figure #fig-fgen-settings`. Likewise, make sure that the scope input is set to use the one of the analog inputs and not the BNC jack on the side of the ELVIS. Use the second oscilloscope channel to display and measure the voltage across the resistor. Be sure both AI- terminals are connected to the function generator ground. You should observe a half-wave rectified voltage across the resistor. Sketch your observation. Note the RMS value of the voltage. .. _fig-fgen-settings: .. figure:: images/diode/fgen-settings.png :scale: 100 % :alt: function generator settings :align: center Function Generator Settings. .. _fig-scope-settings: .. figure:: images/diode/scope-settings.png :scale: 100 % :alt: function generator settings :align: center Oscilloscope Settings. #. Use the cursor to estimate the MAXIMUM value of the voltage. Explain this value, considering KVL and the forward voltage drop you observed in Part (2). #. Increase the amplitude of the FGEN to its maximum value. Save a screenshot and explain what you observe on the oscilloscope. It will help to take a moment to measure the FGEN output on the scope, and note that the peak negative output exceeds the Zener voltage of the diode. .. _fig-fig-10: .. figure:: images/diode/fig-10.png :scale: 100 % :alt: turn on voltage fig 10 :align: center Diode and resistor exchanged. #. Now reverse the diode so that the cathode is connected to the function generator, as shown in :num:`Figure #fig-fig-10`. Set the FGEN voltage to its maximum, and switch the FGEN to a square wave. Use the scope to observe the diode voltage. Measure the most negative voltage and the most positive voltage. Explain your observations. .. topic:: What to do in lab report Show all screen shots. Explain your results, particularly what happens when the peak negative output exceeds breakdown voltage. .. Commented out Filtered half-wave rectifier ------------------------------- Next, a circuit similar to the one in :num:`Figure #fig-half-wave-rectifier` will be constructed. A filter capacitor is added, and different diode and resistor will be used. Be sure that the diode polarity is correct, as described in the prelab. The function generator will be set to 10 volts peak-to-peak at 100Hz. #. Construct the circuit shown in :num:`Figure #fig-filtered-half-wave-rectifier`. Use a 1N914 diode. .. _fig-filtered-half-wave-rectifier: .. figure:: images/diode/filtered-half-wave-rectifier.png :scale: 100 % :alt: filtered half wave rectifier schematic :align: center Filtered half-wave rectifier. #. Set the function generator to produce a 10 volt peak-to-peak sine wave at 100Hz. Check function generator output with the oscilloscope. #. Use the oscilloscope to measure the voltage across the resistor. Save a screenshot of the output. Find the measured ripple voltage and conduction time interval. You can enable the cursors on the scope screen to ease measurements. Compare with calculated and simulated results. Try a larger capacitor such as 3.3 :math:`\mu` F or 10 :math:`\mu` F. How does the output look different? Why? .. topic:: What to do in lab report Show all screen shots. Address all the questions above. Compare the ripple voltage and conduction time invervals from theoretical calculation, SPICE simulation and measurement. Bridge rectifier ------------------- #. Construct the circuit shown below in :num:`Figure #fig-bridge-rectifier` using 1N914 diodes. To realize the 7.6 :math:`\mu` F capacitance, connect two 3.3 :math:`\mu` F and one 1 :math:`\mu` F capacitor together in parallel. 20k :math:`\Omega` is a standard resistor. .. _fig-bridge-rectifier: .. figure:: images/diode/bridge-rectifier-new.png :scale: 100 % :alt: bridge rectifier schematic :align: center Bridge Rectifier Schematic. #. Set the function generator to 10 volts peak-to-peak to produce 5V peak. As the function generator is grounded, we must use a make a differential measurement of the voltage across the output. **Make sure that the AI 1- terminal is not grounded.** Instead connect the AI 1+ and AI 1- terminals to opposite sides of the resistor. #. Save a screenshot of the capacitor voltage similar to the one in :num:`Figure #fig-bridge-rectifier-output`. Measure the ripple voltage and conduction time interval for comparison with prelab calculation and simulation. .. _fig-bridge-rectifier-output: .. figure:: images/diode/bridge-rectifier-output.png :scale: 100 % :alt: bridge rectifier output :align: center Bridge rectifier output. #. Now remove one of the 3.3 :math:`\mu` F capacitors, resulting in a total capacitance of 4.3 :math:`\mu` F. How does the output change? Save a screenshot. #. Now move the AI 1+ and AI 1- inputs to measure the voltage across D2. Use the scope cursors to find the point when the inverse voltage across the diode D2 reaches its peak. A screenshot of the voltage across D1 is shown in :num:`Figure #fig-d1-voltage`. .. _fig-d1-voltage: .. figure:: images/diode/bridge-diode-voltage.png :scale: 100 % :alt: Diode D1 voltage :align: center Diode D1 voltage. .. topic:: What to do in lab report Show all screen shots. Is the measurement consistent with theory and simulation? During what time interval is D2 on? Compare theory, simulation and measurement for R=20k :math:`\Omega`, and C=7.6 :math:`\mu` F. Superdiode Rectifier (10 Bonus Points) --------------------------------------- The previous diode based rectifier circuits suffer from diode voltage loss. While this is no big deal for power adaptors, for low voltage rectifying applications, this voltage loss can be too large. We can remove this diode voltage loss using a so-called super diode shown below. #. Using the rc4558 op-amp available in the lab, construct the circuit shown in :num:`Figure #fig-active-rectifier`. .. _fig-active-rectifier: .. figure:: images/diode/active-rectifier.png :scale: 50 % :alt: active-rectifier :align: center Active rectifier. You may not have used an op-amp before, that is okay. You need to supply power, actually two powers, one positive, and the other negative. On the ELVIS, just use the +15V and -15V power supplies. The rc4558 has two sets of inputs and outputs, or two channels. We will just use one set. When Vin > 0, op-amp output Vout is positive, D1 turns on, allowing a current to flow through R1. The impedances at the "+" and "-" inputs of the op-amp are so high that their currents can be neglected for practical purposes. The op-amp has high enough gain so that the + and - inputs have about the same voltage levels. This way, the output voltage of the rectifier is the *same* as the input voltage during the positive half cycle. When Vin < 0, Vout < 0, D1 turns off, the rectifier output is zero. The combination of the op-amp and the diode configured in this fashion is referred to as "super-diode." #. Measure the input and output of the rectifier with the scope. This schematic did not indicate where to take the output. It should be taken from the "-" input of the op-amp, which is connected to the load R. Take a screenshot. #. Add a capacitor to filter out the high frequency components. .. topic:: What to do in lab report Show one screen shot. Describe an advantage of this circuit over the recitifer circuits built previously.