3
\$\begingroup\$

I'm building a signal generator for my electronics project, and to generate the triangle wave, we're required to use a relaxation oscillator (we can add other circuits around it to improve the quality, but the minimum is to use the relaxation oscillator).

\$R\$ is a pot (\$8\Omega\$ to \$51k\Omega \$),

\$R_1 = 1k\Omega\$,

\$R_2 =23k\Omega\$

\$C\$ is selected using a dip switch depending on the desired frequenecy range:

  • \$6.8\mu F \$ for 18Hz to 1.1kHz
  • \$0.1\mu F \$ for 1.2Hz to 61kHz
  • \$27 nF \$ for 4.5kHz to 200kHz

Op-amp : Data sheet

Supply voltage : \$\pm 15 \ V \$

2x Electrolytic decoupling capacitors : \$100\mu F \$

At low frequencies, the oscillator produces a very nice triangle wave, but at higher frequencies, there's noise that appears at the peaks.

enter image description here

Anyone know what could be causing this, and what I could add to clean it up?

We're not allowed any dedicated ICs, except for Op-amps.

\$\endgroup\$
10
  • \$\begingroup\$ What are your values for the resistors and capacitor ? \$\endgroup\$ – Dan Khan Mar 7 '20 at 18:26
  • \$\begingroup\$ What op-amp part number it is? Please put a link to a datasheet of exact same part. Also, that circuit output should be a square wave anyway, not a triangle wave, unless the slew rate of the op-amp limits the output to the slopes of a triangle wave. \$\endgroup\$ – Justme Mar 7 '20 at 18:34
  • \$\begingroup\$ That's not noise. It's a glitch. \$\endgroup\$ – JRE Mar 7 '20 at 18:37
  • \$\begingroup\$ What opamp are you using, and what supply voltages? \$\endgroup\$ – JRE Mar 7 '20 at 18:38
  • \$\begingroup\$ @JRE I updated my question with the opamp and supply voltages \$\endgroup\$ – Liam F-A Mar 7 '20 at 18:41
4
\$\begingroup\$

Looks like you've run into a limitation of low power opamps.

This article mentions the effect you are seeing, and says that it has to do with the inability of the opamp to deliver the current needed at the peaks of the triangle wave.

From the article, I see three ways you can reduce or fix the glitches:

  1. Use the circuit suggested in the article. That has a schmitt trigger helping the opamp. That's out of the question since you are only allowed to use opamps.
  2. Use larger resistors and smaller capacitors to get the same frequency at lower loading of the opamp. This has the disadvantage of being noisier and more susceptible to picking interference from other noise sources.
  3. Use an opamp that is less "low power."

Point (2) is the easiest to try out. If you have a selection of different models of opamps, then you may find one that you can plop in to take the place of your LM6171.

I expect the real solution will be a combination of (2) and (3) and a restriction on the maximum frequency you can use the circuit at. That is, you make your circuit and specify "can be used at frequencies up to \$F\$ with no more than X% distortion."

\$\endgroup\$
3
  • \$\begingroup\$ If WideUnity-Gain-BandwidthProduct:100MHz is not enough to do 0.2MHz there is an error in your fundamentals and his test methods with crosstalk and probe inductance and pot inductance. \$\endgroup\$ – Tony Stewart EE75 Mar 7 '20 at 20:12
  • \$\begingroup\$ The OP just clarified that the plot is the cap voltage. \$\endgroup\$ – Mattman944 Mar 7 '20 at 20:39
  • \$\begingroup\$ That's the only point it could be . The crosstalk from output is 100 MHz > 200mVpp From the damping factor you can estimate the reactive resistive ratio. I would add 100 Ohms in series with Pot, Change Hysteresis to 10% and guard output or use @JRE's dual OA & comparator method or anything with better isolation and lower triangle impedance \$\endgroup\$ – Tony Stewart EE75 Mar 8 '20 at 0:04
2
\$\begingroup\$

That is switching "noise" from the op-amp output swinging from rail to rail. It is probably there at all oscillator frequencies, but at lower frequencies the scope sampling rate will miss it.

Did you build this on a solderless breadboard? If yes, it will be difficult to get clean signals. Edit: Since you are forced to use a solderless breadboard, a lot of your effort will be overcoming the limitations of these boards.

Did you use enough decoupling capacitors? Both bulk electrolytic and high frequency ceramic. Edit: See figure 58 in the datasheet. Put the caps as close to the op-amp as possible.

Where is your scope ground lead? Try different locations. Close to the cap ground should be the best.

\$\endgroup\$
3
  • \$\begingroup\$ The thing is, my square wave is very clean. Also we're required to build the circuit on a breadboard. We're also being graded on the quality of our signal, so I'm assuming that the professor knows that it is possible to reach the required frequencies with only a breadboard. And currently there are 2 electrolytic capacitors going from V+ to ground and V- to ground (100uF) \$\endgroup\$ – Liam F-A Mar 7 '20 at 18:49
  • \$\begingroup\$ The square wave switching is causing the glitch on the triangle wave. Myself and others have listed several things to look at. Trigger on the peak and look at a low frequency triangle wave at the same scope horizontal scale. I will bet that the glitch is there. \$\endgroup\$ – Mattman944 Mar 8 '20 at 0:50
  • \$\begingroup\$ @LiamF-A -- try paralleling the electrolytics with 100nF or so ceramics \$\endgroup\$ – ThreePhaseEel Mar 8 '20 at 2:30
1
\$\begingroup\$

I think the twitch at the peaks of your triangle wave are caused by the stray capacitance between the many rows of contacts and wires all over the place in a solderless breadboard.

Does the squarewave output also have twitches?

\$\endgroup\$
4
  • \$\begingroup\$ The square wave is very nice \$\endgroup\$ – Liam F-A Mar 7 '20 at 18:34
  • \$\begingroup\$ It is the coupling of 100MHz BW to the triangle signal at fault with your layout and test methods like ground inductance of probe. \$\endgroup\$ – Tony Stewart EE75 Mar 7 '20 at 20:14
  • \$\begingroup\$ Guru is correct. There is always some crosstalk at high speed unless you control impedance for source , destination and probe (REMEMBER THIS). dV/dt=3600V/us if C=10pF and Ic=36mA * Z(f) for probe & signal impedance = > 200mV @ 100MHz but you have 27nF with some ESR so then it is mutual inductive coupling \$\endgroup\$ – Tony Stewart EE75 Mar 7 '20 at 23:47
  • \$\begingroup\$ I could add a lot more detail but due to lack of design details and questions, I'll only add this to Audioguru's correct answer tinyurl.com/tttsb7p ESL ~ 1nH/mm \$\endgroup\$ – Tony Stewart EE75 Mar 7 '20 at 23:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.