Maker Pro
Maker Pro

Trapezoidal Wave Generator Circuit

KrisBlueNZ

Sadly passed away in 2015
Nov 28, 2011
8,393
Joined
Nov 28, 2011
Messages
8,393
How have you connected the voltage divider at the output?

You can't draw any significant current out of the output. You need to buffer it first, maybe using an op-amp.

What are the characteristics of the thing you want to drive with the trapezoidal wave? What do you want to use it for?
 

OddOne

Feb 26, 2013
42
Joined
Feb 26, 2013
Messages
42
From the output to a resistor which is connected to a potmeter. I want to use an op-amp after the voltage divider. For now it's important that I can change the maximum and minimum voltage of the trapazoidal signal.
 

KrisBlueNZ

Sadly passed away in 2015
Nov 28, 2011
8,393
Joined
Nov 28, 2011
Messages
8,393
What range of adjustment do you want for the top and bottom of the trapezoidal wave?

What do you want to use this signal for? What do you intend to drive with it?
 

OddOne

Feb 26, 2013
42
Joined
Feb 26, 2013
Messages
42
The range is 0 - 10 V.

At the moment I just want to make it visible on the oscilloscoop.
 

Harald Kapp

Moderator
Moderator
Nov 17, 2011
13,700
Joined
Nov 17, 2011
Messages
13,700
Split the task in three parts:
1) use a potentiometer to attenuate the signal variably
2) use an OpAmp connected as "non-inverting summing amplifier" (see this application note) to add a variable offset to the signal.
The combination of offset and attenuated signal will allow you to both adjust the lower and the upper level of the signal.
3) use an OpAmp connected as unity gain buffer (use the non-inverting amplifier circuit from above reference and remove R1) to add signal strength for driving a load.
 

OddOne

Feb 26, 2013
42
Joined
Feb 26, 2013
Messages
42
I can change the output voltage with the voltage divider, and change the rise and falling edges. But not when both parts of the circuit are connected.
 

Harald Kapp

Moderator
Moderator
Nov 17, 2011
13,700
Joined
Nov 17, 2011
Messages
13,700
Showing us your circuit diagram would greatly help.
 

KrisBlueNZ

Sadly passed away in 2015
Nov 28, 2011
8,393
Joined
Nov 28, 2011
Messages
8,393
You need to use a buffer between the output and the voltage divider.

An emitter follower (Wikipedia it) would be enough, or you could use an op-amp.

After that you'll have to feed it to an amplifier with an adjustable gain and an adjustable DC offset, as Harald suggested. This would normally be based on an op-amp.
If you want the maximum output swing to be 0V~10V with a +12V power supply, you may need an op-amp with "rail-to-rail" outputs.

After that, you may need more buffering. This all depends on what you want to drive with your trapezoidal waveform. I've asked this twice already; it seems to be some kind of Official Secret.

There should be no problem getting the trapezoidal waveform at the output to show up on an oscilloscope. You should get that working before you worry about changing it.
 

OddOne

Feb 26, 2013
42
Joined
Feb 26, 2013
Messages
42
Thanks it works, but not perfectly yet. I was thinking about changing the zenerdiodes to ~10V zenerdiodes so I can extend the range(?) to 8V pk-pk, because don't have the signal anymore if it's lower than ~4V. I think that with the ~10V zeneriodes I don't have the signal anymore if it's lower than ~2V, but it's still better.

Also, which signals are the input for the non-inverting summing amplifier? And how can I get the formula, because the formula isn't available in the application note?
 

Harald Kapp

Moderator
Moderator
Nov 17, 2011
13,700
Joined
Nov 17, 2011
Messages
13,700
Why, the input signals are the signals you want to sum, what else?
The equations are there, right next to the schematics.
 

OddOne

Feb 26, 2013
42
Joined
Feb 26, 2013
Messages
42
Ah I see, I think I understand it now. Apparently my screen doesn't show the equations. Is it possible to make a screenshot?

Edit: Does this make sense?

Vout = ( (R1 + R2) / R1 ) * Vin

and Vin = E1 + E2

E1 ≈ 5V signal from the amplifier after the divider.
E2 ≈ 5V with potmeter to change the offset voltage.
 
Last edited:

OddOne

Feb 26, 2013
42
Joined
Feb 26, 2013
Messages
42
Is it possible to change the duty cycle of an astable multivibrator without changing the frequency? I already have two potmeters at the bases of the two npn transistors. It changes the duty cycles, but it also changes the frequency.
 

Harald Kapp

Moderator
Moderator
Nov 17, 2011
13,700
Joined
Nov 17, 2011
Messages
13,700
Is it possible to change the duty cycle of an astable multivibrator without changing the frequency
Yes, if you keep the sum of the two resistors that determine the charge rate of the capacitors constant, but vary their ratio.
See this schematic circuit:
attachment.php

To the left is the standard circuit. To the right R1 and R2 are replaced by the potentiometer R5 and a protection resistor R6. R6 is there to avoid having the base of either Q3 or Q4 connected to Vcc in case the potentiometer is at the left or right end.
Make R6 =1kOhm, make R5=(R1+R2). You may need to tweak the circuit for the frequency you want b y adjsuting C3 and C4 or adding a fixed resistor parallel to R5.
 

Attachments

  • bla.gif
    bla.gif
    8.3 KB · Views: 434

KrisBlueNZ

Sadly passed away in 2015
Nov 28, 2011
8,393
Joined
Nov 28, 2011
Messages
8,393
The best way to do that is to generate a fixed frequency using an astable multivibrator or any type of oscillator, and feed it into an adjustable monostable. The monostable period, as a percentage of the oscillator period, determines the duty cycle percentage. The frequency will not vary as the duty cycle is varied.

Edit: You can modify the astable multivibrator as suggested by Harald but the frequency will vary somewhat as you change the duty cycle. Whether this is workable or not depends on how much frequency variation you can accept.
 

OddOne

Feb 26, 2013
42
Joined
Feb 26, 2013
Messages
42
Thank you Harald. I've also tried that, but it changed the frequency too. I didn't knew if this was possible, because the formula for the frequency of the astable multivibrator and the formula for the duty cycle both contain the same resistors.
 

OddOne

Feb 26, 2013
42
Joined
Feb 26, 2013
Messages
42
The explanation of KrisBlueNZ really helped me to understand this circuit, but some parts of the circuit I don't fully understand. The circuit works great with an input voltage of 12V, but I want to change the input voltage to 9V. So to test I changed the resistors at the voltage divider of the PNP transistor to have more gain. The signal was finally visible at the output, but it was a triangular wave instead of a square wave.
I'm pretty sure it has something to do with the amplification at the NPN and PNP transistors.

Does anyone know what I could try?
 

KrisBlueNZ

Sadly passed away in 2015
Nov 28, 2011
8,393
Joined
Nov 28, 2011
Messages
8,393
There are actually three factors that affect the shape of the output waveform:

1. The frequency generated by the astable multivibrator at the left side of the diagram;

2. The rate of voltage change across C, which is determined by the value of C and the currents drawn/provided by the current source and current sink transistors;

3. The clipping voltages, which are determined by the supply voltage and the two zeners, ZD1 and ZD2.

Changing any of these three parameters will affect the output waveform.

Assuming that the voltage across C changes quickly enough that the zeners can clip the waveform, the peak-to-peak output voltage is roughly ZD1_voltage + ZD2_voltage - VCC_voltage. So with ZD1=ZD2=8.2V and VCC=12V the output voltage is about 4.4V peak to peak.

With a 9V supply, you may not be able to get such a large output signal. If you use ZD1=ZD2=5.6V you will get an output waveform that's about 2.2V peak to peak.

You also have to ensure that the change in voltage across C for each half cycle is large enough that the zeners will actually have some effect. If not, you will see a triangle wave with a lower amplitude than the peak-to-peak amplitude determined by the zeners.

To make this happen, reduce the frequency of the astable multivibrator, and/or increase the current sourced and sunk (sinked?) by the current source/sink transistors by reducing the values of the two 25k trimpots in their emitter circuits.
 
Last edited:

duke37

Jan 9, 2011
5,364
Joined
Jan 9, 2011
Messages
5,364
The cross coupled bistable should be limited to about 6V supply so that the reverse e/b voltage is not exeeded.

The circuit refered to in #28 runs on 12V but a diode is placed in series with the base of the first transistor to protect it.
 

KrisBlueNZ

Sadly passed away in 2015
Nov 28, 2011
8,393
Joined
Nov 28, 2011
Messages
8,393
I was assuming that OddOne was talking about the circuit he linked to in post #1, which I duplicated in post #16.
 
Top