how do I get rid of this evalstring() ?
CADForums.net Forum Index CADForums.net
Discussion of AutoCAD and other CAD software.
 
 FAQFAQ   MemberlistMemberlist     RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 
Google
 
Web cadforums.net
how do I get rid of this evalstring() ?

 
Post new topic   Reply to topic    CADForums.net Forum Index -> Cadence
Author Message
fogh
Guest





Posted: Fri Oct 01, 2004 1:07 pm    Post subject: how do I get rid of this evalstring() ? Reply with quote

Hi All,

How can I get rid of the evalstring in the following ? :

let(
(library CDFid termlist term devicelist device mappingstring)
library="somepdk"
devicelist='(
"nmos" "pmos" "rfnmos"
"npn" "lpnp" "vpnp"
"respoly" "reswood" "resceramic" "respaper" "resstone"
"capMIM" "capPIS" "varicap"
)
foreach(device devicelist
CDFid=cdfGetCellCDF(ddGetObj(library device))
termlist=CDFid->simInfo->spectre->termMapping->?

foreach(term termlist
mappingstring=strcat(":" lowerCase(term))
when(rexMatchp("^res" device)
if(":plus"==mappingstring mappingstring=":a")
if(":minus"==mappingstring mappingstring=":b")
);when resistor
when(rexMatchp("^CAP" device)
if(":plus"==mappingstring mappingstring=":a")
if(":minus"==mappingstring mappingstring=":k")
);when capa with polarity
mappingstring=sprintf(nil "(FUNCTION mappedRoot(%L))" mappingstring)
evalstring( strcat(
"CDFid->simInfo->spectre->termMapping->"
term
"=mappingstring"
))
);foreach term
);foreach device
);let

Back to top
S. Badel
Guest





Posted: Fri Oct 01, 2004 6:39 pm    Post subject: Re: how do I get rid of this evalstring() ? Reply with quote

this seems to work :

putprop( CDFid->simInfo->spectre->termMapping mappingString term )

cheers,

stéphane


fogh wrote:

Quote:
Hi All,

How can I get rid of the evalstring in the following ? :

let(
(library CDFid termlist term devicelist device mappingstring)
library="somepdk"
devicelist='(
"nmos" "pmos" "rfnmos"
"npn" "lpnp" "vpnp"
"respoly" "reswood" "resceramic" "respaper" "resstone"
"capMIM" "capPIS" "varicap"
)
foreach(device devicelist
CDFid=cdfGetCellCDF(ddGetObj(library device))
termlist=CDFid->simInfo->spectre->termMapping->?

foreach(term termlist
mappingstring=strcat(":" lowerCase(term))
when(rexMatchp("^res" device)
if(":plus"==mappingstring mappingstring=":a")
if(":minus"==mappingstring mappingstring=":b")
);when resistor
when(rexMatchp("^CAP" device)
if(":plus"==mappingstring mappingstring=":a")
if(":minus"==mappingstring mappingstring=":k")
);when capa with polarity
mappingstring=sprintf(nil "(FUNCTION mappedRoot(%L))"
mappingstring)
evalstring( strcat(
"CDFid->simInfo->spectre->termMapping->"
term
"=mappingstring"
))
);foreach term
);foreach device
);let
Back to top
fogh
Guest





Posted: Mon Oct 04, 2004 2:46 pm    Post subject: Re: how do I get rid of this evalstring() ? Reply with quote

Thanks Stephane, it works fine.

I guess I should have RTFM on this one: it is explicit from SKILL user manual , chapter on data structures, that I had to use putprop. I just made myself a new hardcopy.

S. Badel wrote:
Quote:
this seems to work :

putprop( CDFid->simInfo->spectre->termMapping mappingString term )

cheers,

stéphane


fogh wrote:

Hi All,

How can I get rid of the evalstring in the following ? :

let(
(library CDFid termlist term devicelist device mappingstring)
library="somepdk"
devicelist='(
"nmos" "pmos" "rfnmos"
"npn" "lpnp" "vpnp"
"respoly" "reswood" "resceramic" "respaper" "resstone"
"capMIM" "capPIS" "varicap"
)
foreach(device devicelist
CDFid=cdfGetCellCDF(ddGetObj(library device))
termlist=CDFid->simInfo->spectre->termMapping->?

foreach(term termlist
mappingstring=strcat(":" lowerCase(term))
when(rexMatchp("^res" device)
if(":plus"==mappingstring mappingstring=":a")
if(":minus"==mappingstring mappingstring=":b")
);when resistor
when(rexMatchp("^CAP" device)
if(":plus"==mappingstring mappingstring=":a")
if(":minus"==mappingstring mappingstring=":k")
);when capa with polarity
mappingstring=sprintf(nil "(FUNCTION mappedRoot(%L))"
mappingstring)
evalstring( strcat(
"CDFid->simInfo->spectre->termMapping->"
term
"=mappingstring"
))
);foreach term
);foreach device
);let


Back to top
 
Post new topic   Reply to topic    CADForums.net Forum Index -> Cadence All times are GMT
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum




Windows Server DSP VoIP Electronics New Topics
Powered by phpBB