{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}


ass2_w_2011 - ECE 100 Lab 2 DSL Low-pass Active Filter...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ECE 100 Lab 2 DSL Low-pass Active Filter Design Winter 2011 The objective of this assignment is to design, simulate, build and test the low pass filter that is needed to separate the digital DSL signal from the voice signal on a telephone line. The specifications for this filter are sketched below. 1. Approximation: The basic objective is (always) to realize the circuit as economically as possible. The cost of a circuit depends on the “order” because the higher the order the more components you need. So the first step in any filter design, is to find the lowest order rational function of s that will meet the spec. In this case it is easy to see by eye that we will need a stop band that falls at least as fast as 40dB/decade, so we start by checking to see if a second order filter will work. We start with a Butterworth for convenience. (a) The “Butterworth” |H(f)|2 = 1 / (1 + (f/f0)4). To see if the transfer function meets the spec we choose f0 so the transfer function just hits the passband edge. This is the lowest possible value of f0. Then we check to see if |H(f)|2 clears the stopband edge. Find this value of f0 analytically. Calculate the resulting |H(f)|2 at 32 Khz and 180 Khz. Does the filter meet the spec? (b) You will find that the maximally flat transfer function does meet the spec (as you can see in the figure), but it is a very tight fit. This leaves little room for component errors. We could increase the order from n = 2 to n = 3, but this will increase the cost by, roughly, 50%. So we consider allowing |H(f)|2 in the passband to “ripple” from –1dB at dc, up to 0dB, then down to –1dB at 4 KHz. Thus |H(f)|2 will have a peak 1dB greater than the dc value. This peak is |H(fPK)|2 / |H(0)|2 = 1/(4ζ2(1 - ζ2)), as was found in Lab 1. It is not easy to solve this expression for the necessary ζ but it is easy to calculate and plot. Use Matlab to plot |H(fPK)|2 in dB vs ζ in the range 0.1 < ζ < 0.7 and find the value of ζ that will provide a 1dB peak (i.e. |H(fPK)|2 = 1/0.7943). Make a hard copy. (c) Now we have the necessary ζ we can correct the dc gain and get |H(f)|2 = 0.7943/((1 - (f/f0)2)2 + (2ζ f/f0)2). All that remains is to choose the resonant frequency f0 so |H(f)|2 = –1dB at 4 KHz. It is not easy to invert this equation for f0 either. Take a guess at f0, say f0 = 5000 Hz, and plot |H(f)|2 in dB vs f over the range 1000 < f < 10000. Find the frequency at which |H(f)|2 drops to –1dB, say this value is X. We therefore need to scale f0 by the factor 4000/X, i.e. f0 = 5000*4000/X. Find the required f0 and plot |H(f)|2 in dB vs f for 200 < f < 1Mhz on a semilogx plot. The resulting function will drop faster in the transition band and will meet the spec with more clearance than the Butterworth approximation. There is no need to save a copy of this plot. (d) Finally we need to adjust f0 upwards a bit so |H(f)|2 clears the passband edge and the stopband edge by the same factor. What is your final value of f0? Save a copy of this graph to show that it meets the spec. 2. Realization/Simulation: This filter can be realized with a passive RLC circuit or an active RC circuit. The most attractive topology for an active RC lowpass filter is the Sallen-Key form shown below. However the Sallen-Key circuit has a dc gain of unity, so we’ll need to modify it slightly. The circuit components are not ideal and we will have to simulate the realization to make sure that non-ideal effects don’t interfere with the design. (a) The most important “non-ideal” opamp effect for this circuit is the output resistance of the opamp itself. This is typically about 50 Ω. At the highest frequencies you can assume that the capacitors are short circuits and the opamp gain is zero. Show that under these conditions |H| →ROUT/R. Given this approximation we might expect to use resistors a bit smaller than 100K. (b) Analyze the Sallen-Key circuit as shown below. Put the transfer function in normalized form. With this circuit any transfer second-order transfer function can be realized with equal resistors (but not with equal capacitors). So for simplicity we usually set R1 = R2. Assume that the resistors are R1 = R2 = 100K. Calculate the component values needed to obtain the necessary values of f0 and ζ. Finally we can correct the dc gain, setting it to –1dB, by converting R2 into a potential divider with a dc gain of –1dB and an Thevenin resistance of 100K. Do this too. (c) Simulate the circuit using the uA741 macromodel and confirm that it meets the spec. If you cut all the resistors exactly in half and double all the capacitors, it won’t change the theoretical transfer function, but it will increase the effect of the output resistance. Try it. Does the transfer function still meet the spec? Find the lowest resistance for which the simulation still meets the spec. Make a hard copy to take to the lab. Save the simulated |H(f)|2 as an ascii text file, so you can compare it with your theory and measurements using Matlab. To do this select the trace name (under the plot), then choose copy from the edit menu. Open notepad and paste the data in. You will see a header line and frequency followed by an amplitudes in dB. Save this with a name.txt in a convenient place. Create a Matlab script that will plot your theoretical |H(f)|2, then read and plot your simulated |H(f)|2, and then read a table of observations and over-plot them as distinct symbols (i.e. not connected by a line). If you want to be really fancy have it plot the specs too, as in the first figure in these instructions. 3. Measurement: When you go into your scheduled lab period have hard copies of two plots (from part 1e and part 2) for the TA to check. Have your plotting script ready so you can compare your measurements with the simulations immediately. We will use the uA741 which has the same pinout as the LF411 shown below. Build and test the active circuit. Here we have lots of 1% resistors in stock so you should be able to get pretty close to the three resistors you need. You can always use a larger than minimum resistor to make the choice easier. However we don’t have nearly as wide a range of capacitors, you will probably have to put two capacitors in parallel to approximate C1 and the same for C2. Put probes on both the input and the output and trigger the scope from the input probe. This will allow you to measure low-level signals at the output without losing the trigger. Measure the transfer function at the spec frequencies: dc, fPEAK, 4 Khz, 32 Khz, 180 Khz, and 1 Mhz. At high frequencies the output voltage will be weak and noisy. You can’t use the scope’s peak-to-peak measurement with noisy data because it will give you the sum of the signal and noise. You will have to work to get the noise down: (1) use a good strong signal, between 10 and 20 v p-p; (2) use the probe in X1 mode (remember to change the channel setting to match the probe; (3) use trace averaging; (4) reduce the channel bandwidth. With all these features you should be able to reach –60dB. In this circuit you can use X1 mode on the probe. This is often not possible because you need a high impedance probe. But in this circuit the probe is connected to the low impedance output of an opamp, so the probe impedance is not a problem. Explore the remainder of the frequency range up to the generator limit and make sure there are no unexpected “features.” Since this is an active circuit you have to make sure that the signal does not drive the opamp into a nonlinear operating condition. So long as the output voltage still looks like a sine wave you are probably OK. A good way to confirm that the system is being tested in a linear range is to change the input voltage by a factor of two and re-measure |H(f)|2, if it is the same you are OK. If they differ then reduce the input voltage another factor of two and try again. Put your measurements in an ascii file so you can read them into Matlab and plot them on top of the simulation. Put your measurements on your simulated transfer function. When you are finished show the TA and ask him/her to sign your plot. This is the final proof of performance. Report: Your report should contain a short discussion of the prelab with the requested plots. It should include a diagram of the measured circuits with the actual components used. The most important part of the report is the diagram showing that the measured transfer function meets the spec. ...
View Full Document

{[ snackBarMessage ]}

Ask a homework question - tutors are online