Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Conditional statement in HSPICE

Status
Not open for further replies.

msandhu

Newbie level 1
Joined
Dec 14, 2009
Messages
1
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Location
AZ/US
Activity points
1,291
Does anyone know how i can use .if statement with .measure in HSPICE ex:
.measure tran vol1 find v(outp,gnd!) at=3900n
.if (vol1>2)
.measure tran var1 param='slewrate_fallper20rise'
.else
.measure tran var1 param='slewrate_fallper20fall'
.endif
Now from above i get arithmetic evaluation error, i cant compare measured (vol1--getting measured from .measure statement from top) values (i.e. .measure statement is evaluated while simulation is going on whereas .if is checked before simulation starts).
I tried it with GnuCap simulator and it works (I guess eval command can have if statement which can compare two measureed values), ex:
.measure var1=eval({ if(vol2>vol1,slewrate_fallper20rise,slewrate_fallper20fall) })
Any help will be appreciated.
Thanx
 

May be **broken link removed** will help you?
 
Last edited by a moderator:

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top