The Designer's Guide Community Forum
https://designers-guide.org/forum/YaBB.pl
Design Languages >> Verilog-AMS >> idtmod in wreal VAMS
https://designers-guide.org/forum/YaBB.pl?num=1538125309

Message started by deba on Sep 28th, 2018, 2:01am

Title: idtmod in wreal VAMS
Post by deba on Sep 28th, 2018, 2:01am

Hi,

I am trying to model the VCO in VAMS wreal. There are no electrical signals only digital and wreal signals.

Is it possible to use idtmod(modulo 2*pi integrator) the same way as used in verilog-A.

Thanks

Title: Re: idtmod in wreal VAMS
Post by Ken Kundert on Sep 30th, 2018, 11:55pm

One would not use idtmod to write an event driven VCO. The idtmod operator is implemented in the continuous kernel, which would slow the simulation. It is pretty easy to write a event driven VCO model without it. Just do something like the following:

Code:
module vco (out, in);
parameter real kvco = 1e9;
output out;
input in;
wreal in;
reg out = 0;
real freq, half_period = 100e-12;

always #half_period begin
   freq = kvco * in;
   half_period = 0.5/freq;
   out = ~out;
end
endmodule

Title: Re: idtmod in wreal VAMS
Post by deba on Oct 1st, 2018, 12:46am

Hi Ken,

Thanks for your reply. I am using a similar approach.  A follow up question.

The same event driven can be used instead of idtmod for modelling VCO. Does modelling the VCO in VAMS electrical idtmod more accurate than the event driven VCO model? Event driven the resolution is limited to 1 fs. Using idtmod what level of resolution can be achieved?

I have to model a very low jitter PLL.(<200 fs).

Thanks

The Designer's Guide Community Forum » Powered by YaBB 2.2.2!
YaBB © 2000-2008. All Rights Reserved.