Simulation of crystal oscillator circuit a Simscape does not converge

조회 수: 14 (최근 30일)
Jan Kappen
Jan Kappen 2025년 3월 6일
답변: Steve Miller 2025년 3월 24일
Hi all,
I'm trying to simulate the effect of load capacitors on a oscillator circuit using the Crystal Simscape block. This is in fact a simple Pierce oscillator, see e.g. https://www.elprocus.com/pierce-oscillator-working-and-its-applications/
I'm following Guidelines for oscillator design on https://www.st.com/resource/en/application_note/cd00221665-oscillator-design-guide-for-stm8afals-stm32-mcus-and-mpus-stmicroelectronics.pdf to parametrize the passives and added an initial voltage to the crystal to (hopefully) start the oscillation.
Unfortunately, the model does not run at all:
Error:An error occurred during simulation and the simulation was terminated
Caused by:
['crystal_model_simplified/Solver Configuration']: Transient initialization at time 7.414431651271723e-06, solving for consistent states and modes, failed to converge.
Nonlinear solver: failed to converge, residual norm too large.
Here is the set of components with unconverged equations:
'crystal_model_simplified/Inverter'
Equation location is:
'ee.ic.logic.logic_1ip_eqn'(no line number info)
'crystal_model_simplified/Crystal'
Equation location is:
'foundation.electrical.elements.inductor' (line 34)
Equation location is:
'foundation.electrical.elements.inductor' (line 34)
'crystal_model_simplified/Inverter'
Equation location is:
'foundation.electrical.elements.capacitor' (line 36)
The model is attached.
Do you have ideas what's going wrong?
Thanks!
  댓글 수: 1
Jan Kappen
Jan Kappen 2025년 3월 6일
편집: Jan Kappen 2025년 3월 7일
For some reasons the links and images in my post have gone. Trying to fix that.
Edit: fixed.

댓글을 달려면 로그인하십시오.

답변 (1개)

Steve Miller
Steve Miller 2025년 3월 24일
While I can't say for sure what is going wrong, if I set Rf to 1e9 the simulation runs to completion and the value on the Scope looks unchanged. Perhaps look at the quantities you care about and see if that modification is acceptable.

카테고리

Help CenterFile Exchange에서 Electrical Sensors에 대해 자세히 알아보기

제품


릴리스

R2024b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by