The Designer's Guide Community
Forum
Welcome, Guest. Please Login or Register. Please follow the Forum guidelines.
May 21st, 2024, 9:19am
Pages: 1
Send Topic Print
lost Events in asynchr. comparator w AMS/spectre (Read 5984 times)
boe
Community Fellow
*****
Offline



Posts: 615

lost Events in asynchr. comparator w AMS/spectre
Jun 07th, 2007, 7:34am
 
I wrote an asynchr. comparator similar to the one in http://www.designers-guide.org/Books/dg-vams/ch4/listing14.tar.gz; Code fragment:
 logic CompOut;
 electrical VCompIn;
 parameter real Vhyst = 3.75e-3;
 parameter real tpd = 25e-9;
 always @(cross(VCompIn - Vhyst/2, +1, 1n, Vhyst/10.0))
     CompOut  <= #(tpd/1n) 1;

 always @(cross(VCompIn + Vhyst/2, -1, 1n, Vhyst/10.0))
     CompOut <= #(tpd/1n) 0;

I ran this with ncsim (AMS/spectre). The problem I have is that I loose events. First I get the warning

> Warning from spectre at time = 34.7478 ms during transient analysis `tran'.
>     Analog events may be missing and simulation results may not be correct
>         since time step was too big to catch the details in device/AHDL models.
>         Use bound_step() or tighten simulation tolerance options to limit the
>         time step.

At 70.2917608ms I clearly see a missing event which is not passed on to the digital simulator.
The signal VCompIn goes to -1 V and remains there for ca. 8 us, but CompOut remains at "1" all the time!

I can see no reason for the simulator not to catch the event - is my code poor or is this a simulator bug?
Back to top
 

lostEvent.png
View Profile   IP Logged
Ken Kundert
Global Moderator
*****
Offline



Posts: 2384
Silicon Valley
Re: lost Events in asynchr. comparator w AMS/spect
Reply #1 - Jun 7th, 2007, 10:25am
 
Boe,
    Your model looks good to me. I can see no reason why the simulator should skip the event. It is very odd that the simulator recognizes that it is missing the event and admits it rather than just handling the event properly. The suggestion to use bound_step() (or equivalently the maxstep transient analysis parameter) might be a work around to the problem, but this seems like a simulator problem that really should be fixed by Cadence. I suggest you bundle up an example and send it off to them so they can fix it.

-Ken
Back to top
 
 
View Profile WWW   IP Logged
boe
Community Fellow
*****
Offline



Posts: 615

Re: lost Events in asynchr. comparator w AMS/spect
Reply #2 - Jun 7th, 2007, 11:10am
 
Ken Kundert wrote on Jun 7th, 2007, 10:25am:
Boe,
    Your model looks good to me. I can see no reason why the simulator should skip the event. It is very odd that the simulator recognizes that it is missing the event and admits it rather than just handling the event properly. The suggestion to use bound_step() (or equivalently the maxstep transient analysis parameter) might be a work around to the problem, but this seems like a simulator problem that really should be fixed by Cadence. I suggest you bundle up an example and send it off to them so they can fix it.

-Ken


Ken,

First of all: Thanks you very much for your advice.
The suggestion to use bound_step() does not help very much though, because I do not know how to do a better prediction of critical transitions efficiently with less information than the simulator: The comparator is asynchronuous and switches very often -- and only very few transitions cause problems...

BOE
Back to top
 
 
View Profile   IP Logged
sheldon
Community Fellow
*****
Offline



Posts: 751

Re: lost Events in asynchr. comparator w AMS/spect
Reply #3 - Jun 12th, 2007, 5:49am
 
Boe,

  You did not mention the simulation conditions you used. Sometimes tightening
the simulation conditions help to resolve these types of issues. For example, using
the moderate error preset with relref=pointlocal.

                                                              Best Regards,

                                                                Sheldon
Back to top
 
 
View Profile   IP Logged
boe
Community Fellow
*****
Offline



Posts: 615

Re: lost Events in asynchr. comparator w AMS/spect
Reply #4 - Jun 12th, 2007, 8:20am
 
Sheldon,
I used the following parameters:
   reltol = 10e-06
   abstol(I) = 100 fA
   abstol(V) = 1 uV
   errpreset = conservative
   method = gear2only
   relref = alllocal

Regards,
BOE
Back to top
 
 
View Profile   IP Logged
boe
Community Fellow
*****
Offline



Posts: 615

Re: lost Events in asynchr. comparator w AMS/spect
Reply #5 - Jul 3rd, 2007, 7:38am
 
Hi all,
Lasr week, we got an answer from Cadence: the problem does no longer show up in versions IUS 5.70.s016/IUS 5.83.s006.

I attach the input of the "cross" of the testcase we sent to Cadence, run with IUS 5.70.s012 (red) and with IUS 5.70.s017 (blue): The critical time is 1.9637556 ms to 1.963756 ms. The s012 uses only 1 step in this range; thus, the s012 has no time step in the tolerance band of the cross event. This seems to be the reason that the event is lost.
Apparently, Cadence changed the simulator time step control between s012 and s016, so that the problem does no longer occur.

BOE
Back to top
 

Vinp_ius57s12-s17.png
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.