Chapter 12 - Fundamentals of Linear Simulation
This chapter illustrates the simulation and measurement of linear circuits by analyzing transient, AC, noise, and Fast Fourier Transform (FFT) responses of a non-inverting amplifier. Measurements included in this analysis are signal voltages, current in the wire, device current, frequency response, and FFT.
12.1 Prerequisites
- Chapter 1 of this workbook, Getting Started with MPLAB® Mindi™ Analog Simulator
- Review the MCP6001 Amplifier Datasheet
12.2 Non-Inverting Amplifier
Open the schematic file NonInvertingAmp_MCP6001.wxsch. The circuit shown in the figure below is driven by a 2 kHz, 200 mVpp sinusoidal signal source with a DC offset of 1.5 V.
Select 'Enable DC' and 'Enable AC' at the top right corner of the dialog.
12.3 Transient Analysis
Next, set the simulator for performing a transient analysis.
Measurement probes must be placed at the input and output nodes to view the simulation results. Select Probe > Place Fixed Voltage Probe and place probes at nodes Vsignal and at AmpOut. See the figure below for placement of probes Vsignal and AmpOut.
Click on the graph, check the Vsignal and AmpOut boxes shown below and select Measure > A More Functions > Peak-to-Peak. This computes the peak-to-peak voltage of the transient signals Vsignal and AmpOut.
The output is not 400.00 mVpp as this is a real op-amp with a 1 MHz GBWP. The response of the amplifier at 2 kHz will be 54 dB and this results in an error. This is because the typical Open-Loop gain listed in the datasheet at low frequencies is 112 dB but falls off with frequency. See the accompanying figure in the MCP6001 datasheet.
The error due to finite open-loop gain is 1/(Avol*β) where 1/β is the feedback gain and is equal to 2, the open-loop gain of MCP6001 is 25.11K. Therefore, the gain error is 0.079 mV. To achieve 400 mVpp, change the op-amp to a high gain bandwidth amplifier such as the MCP6021 or MCP6291, which has 10 times the GBWP of MCP6001.
12.4 AC Analysis
To run the AC response of the circuit, we need to add the Bode Plot tool to the circuit.
Double-click on the AmpOut probe and select 'AC Sweep'.
Set the start frequency to 1 Hz and the stop frequency to 2 MHz with 500 points/decade. Select Simulator > Run Schematic. The resulting output is shown in the figure below.
The AC stimulus is 1 Vrms and the resulting gain is 6 dB (due to a gain of 2). The graph shows the gain cross-over frequency at 510 kHz. This is the frequency at which the gain plot in dB units crosses the 0 dB level.
12.5 Noise Analysis
Intrinsic and thermal noise contributions degrade the signal-to-noise ratio of signals. This is an important attribute to consider when an amplified signal is converted to a digital format by an Analog-to-Digital Converter (ADC). Therefore, understanding noise contributions to the output signal is an essential factor in selecting an ADC for signal conversion. This section illustrates the simulation and measurement of amplifier noise contribution.
There are three sources of noise: amplifier voltage noise, amplifier current noise (converted to voltage by the equivalent source resistance), and thermal noise (arising from the gain resistors). Voltage noise en and current noise ei are provided in the datasheets. The resistor noise is given by the formula er = √4KbTR where Kb is the Boltzmann constant, R is the resistance, and T is the temperature in kelvins.
In the 'Noise' parameters section, list the Output node as AmpOut. Select Simulator > Run Schematic.
Run a second noise analysis with the Output node set to AmpFilter. View the noise plot by selecting Probe AC/Noise > Plot Output Noise. The output from this analysis is displayed in the figure below with a green trace.
12.6 Fast Fourier Transform (FFT) Analysis
Fast Fourier Transforms help us observe the effect of signal components across the amplifier's bandwidth of interest and determine the noise floor of the amplifier. To run an FFT analysis, we first need to run a transient analysis and then apply the FFT Probe to the output node of interest. To get an accurate output, the transient analysis needs to be computed at user-specified time-step intervals.
Set up the transient analysis for FFT. Select Simulator > Choose Analysis and set Analysis Mode to 'Transient'. Uncheck 'Default' for the '.PRINT' step. Enter 500n (500 nS) for the time step interval. Enable 'Output at .PRINT step'. Run transient analysis. Select Simulator > Run Schematic.
Select Probe > Fourier > Probe Voltage Custom and place the probe tool at the AmpFilter node. Then edit the resulting FFT setup menu as shown in the dialog below. After editing select Ok.
An FFT output will be rendered in a separate graph as shown in the figure below. Using the signal measurement cursors, we can show that the signal frequency does appear at 2 kHz and the noise floor is well below the signal.
12.7 Measurement of Current in Wires and Device
We can measure the current at any wire in the circuit by using Probe > Current in Wire on the circuit. Run Transient analysis first. Then select Probe > Current in Wire and place the probe at the output of the Amplifier. The resulting output is shown in the figure below.
Next, we use Probe > Current in Device Pin to measure the current in the Amplifier itself. Select this probe and place it at the positive supply connection of the amplifier. The Amplifier quiescent current will be plotted in a graph and will look like the plot in the figure above. This shows that the supply current used by the amplifier during its signal amplification operation is a maximum of 1.6 mA.