V
vlsidesign
Guest
In Cadence Virtuoso I first select a pad inst and a pin (I do it in XL
mode). My current script works then is called by a bindkey, it then
centers the pin on top of the padinst. But sometimes I forget to
de-select everything, and it then moves all the pins, etc. So I wanted
to do a quick check and if I have more than two things selected it will
abort the script. The "IF" statement is supposed to do that check, and
then I have a foreach to handle calculating center of padinstance and
then moving the pin, here is the IF portion:
cv= GeGetEditCellView()
twoObjects=geGetSelSet(cv)
numObjects=geGetSelSetCount()
if( numObjects != 2 then
println( "Incorrect number of objects selected" )
;;;;;;;exit program but not Cadence Virtuoso session
);end if
Do I need to embed the "foreach" into the "else" portion of the "if"
statement or can I give a function like 'exit' to exit the script. When
I tried to use the exit function, it then exits my Cadence VIrtuoso
session. ANy help is appreciated or pointing in the right direction is
appreciated. Thanks.
mode). My current script works then is called by a bindkey, it then
centers the pin on top of the padinst. But sometimes I forget to
de-select everything, and it then moves all the pins, etc. So I wanted
to do a quick check and if I have more than two things selected it will
abort the script. The "IF" statement is supposed to do that check, and
then I have a foreach to handle calculating center of padinstance and
then moving the pin, here is the IF portion:
cv= GeGetEditCellView()
twoObjects=geGetSelSet(cv)
numObjects=geGetSelSetCount()
if( numObjects != 2 then
println( "Incorrect number of objects selected" )
;;;;;;;exit program but not Cadence Virtuoso session
);end if
Do I need to embed the "foreach" into the "else" portion of the "if"
statement or can I give a function like 'exit' to exit the script. When
I tried to use the exit function, it then exits my Cadence VIrtuoso
session. ANy help is appreciated or pointing in the right direction is
appreciated. Thanks.