EEVblog Electronics Community Forum
Electronics => Projects, Designs, and Technical Stuff => Topic started by: MD1071 on November 06, 2024, 11:23:23 pm
-
hey all,
I'm trying to simulate the equivalent circuit of a crystal oscillator. Its a simple RLC circuit with a shunt capacitor. I first did a .ac frequency sweep and saw the expected resonance peaks and at the correct frequency. However when I did a .tran measurement by using a sine wave with the resonant frequency, I get a phase shift of zero!
*note--> sorry just noticed the different labels. V(n002) is the node above the right most capacitor in both the circuits
V(n001) is the node right after the 150k resistor
the .ac plots show that phase shift at 50.948KHz should be ~-84 deg --> this is phase difference between n001 and n002 or the top shunt capacitor
doing .tran I see the phase difference as 0. I've tried timesteps as small as 0.01u but still see zero phase shift. if I use a smaller value of shunt capacitor from 2.0789p to something < 0.1p then I can see some non-zero phase shift
So far I think it might be an issue with initial conditions on my transient simulation. but I'm not sure
I attahced a screenshot below of the outputs. also attached the .asc file for both the .ac and .tran simulations
-
Are the motional inductance and resistance values real? These look rather large for a ~51k crystal.
Q is very large, you will have no luck with a transient analysis. Doing an AC sweep is the way to go. Below is what I got after getting the total phase shift to 180° by raising R2=220k and C4=68p and loading the output with 10 MOhm.
For comparison a single transistor 32.75kHz Pierce crystal oscillator is shown. Loop gain and phase shift is included. Crystal dissipation is kept below 1uW with the help of a diode limiter.
-
I would recommend you to use the "new" .FRA analysis when using transistors/opamps or any active components.
It makes gain and phase graph but differently to the .AC, as the .AC analysis first decompose the schematics into a simplified model ("small signal" model without active parts).
.FRA uses original schematics unmodified.
PS: OP - plz do label the wires with "names" so we may see what/where you are measuring - see below..