triangular wave using lt spice help

Thread Starter

syaf921

Joined Dec 21, 2012
18
I need it to oscillates at 20kHz. How i can get that?
And why Vcc need to be -10v? I have changed the value but the output is different.
Also why in the transient section of the edit simulation command, i need to check the "skip initial operating point solution".

This is the cct.
 

Attachments

Last edited:

MikeML

Joined Oct 2, 2009
5,444
Try this:
08.gif

I cleaned up your drafting so I could follow what you were trying to do. This will only work as simulated if you buy some modern, CMOS, rail-to-rail opamps, because its frequency depends on the square output reaching the rails.

To get it to oscillate, I had to create a slight initial perturbation with the statement .ic V(tri)=1mV. Dont use UIC, ever! Here is what the LTSpice Help file says about UIC.

uic.gif
 

Attachments

Last edited:

Alec_t

Joined Sep 17, 2013
14,335
You just needed to change R1 to 2k2 to get 20kHz.
Vcc was -10V because you had the V1 +ve terminal grounded.
Here's a redrawn version with V1 and V2 moved, so that the schematic is less cluttered.
 

Attachments

crutschow

Joined Mar 14, 2008
34,470
Here's Alec's circuit further modified to operate from a single supply by using a pseudo-ground at 1/2 the supply voltage to the op amp inputs that were previously grounded.

Note that you need to use .uic or "Start external supply at 0V" to start the oscillations. Otherwise the circuit does a DC analysis when puts the circuit into a quasi-stable state with no oscillation and there is not the normal real circuit noise to initiate the oscillation.
Alternately you can perturb the circuit with an initial .ic command as Mike suggested, to start the oscillation.

TriangleMod2.gif
 

Attachments

MikeML

Joined Oct 2, 2009
5,444
How did u get R1=2.2k, can you show me the calculation?
I didn't. I changed all the resistors to more reasonable values (considering the currents that real opamps can source and sink).

There are four things to consider. The peak to peak value of the square wave, the trip point(s) of the Schmitt Trigger, the value of R1 and C1.
 

MikeML

Joined Oct 2, 2009
5,444
I copy the LTSpice screen image to clipboard using Alt-PrtScn, paste it to IrfanView, crop the excess, and save it to a .gif Then I post the .gif here.
 

Alec_t

Joined Sep 17, 2013
14,335
How did u get R1=2.2k, can you show me the calculation?
I didn't calculate it. I just tried it in the sim. That's what sims are for ;). Just play with values and let LTS do the calculations.
I use the same method as Mike (albeit with a different graphics program) to post sim results here.
 
Top