The Designer's Guide Community
Forum
Welcome, Guest. Please Login or Register. Please follow the Forum guidelines.
Jul 19th, 2024, 4:26pm
Pages: 1
Send Topic Print
HSPICE behavioral VCO? (Read 2515 times)
joel
Community Member
***
Offline



Posts: 43

HSPICE behavioral VCO?
Dec 12th, 2007, 2:36pm
 
Can anyone tell me how to create a behavioral VCO in HSPICE?
The manual clearly describes the voltage-controlled-voltage-source syntax for this:

Evco out 0 VOL='sin( TwoPI * freq * v(control) * TIME)'

and then goes on to say that it doesn't work if v(control) is time-varying.
The manual is correct that it doesn't work...

Thanks in advance for any advice!  /jd
Back to top
 
 
View Profile   IP Logged
Eugene
Senior Member
****
Offline



Posts: 262

Re: HSPICE behavioral VCO?
Reply #1 - Dec 12th, 2007, 8:15pm
 
Many years ago, before we had VerilogA, we wrote macro models. There was a paper in one of the power electronics journals back then that described a motor model that used a VCO to convert a voltage representing instantaneous shaft angular velocity into instantaneous shaft position. The motivation for computing position was to insert a detent torque. Anyway, you could vary the frequency of that VCO model. The VCO model consisted  of two ideal integrators in a simple feedback loop. Each integrator was preceded by a multiplier that multiplied the output of the other integrator with the desired frequency. You have to introduce a sign inversion in the loop too. If you write out the equations, you see the differential equation that defines sine and cos functions. In short, you can create a simple VCO out of two integrators.  The pre-VerilogA integrators were constructed from controlled current sources and capacitors. The multipliers were made from non-linear polynomial controlled sources.

One thing to watch out for is numerical decay of the oscillations. One solution to that problem is to use a Van der  Pol oscillator, perhaps followed by a filter if you want a nice sinusoid. Another solution is to leak a small amount of current onto one of the caps through a resistor.

Back to top
 
 
View Profile   IP Logged
Pages: 1
Send Topic Print
Copyright 2002-2024 Designer’s Guide Consulting, Inc. Designer’s Guide® is a registered trademark of Designer’s Guide Consulting, Inc. All rights reserved. Send comments or questions to editor@designers-guide.org. Consider submitting a paper or model.