how do I get rid of this evalstring() ?

Discussion in 'Cadence' started by fogh, Oct 1, 2004.

  1. fogh

    fogh Guest

    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
     
    fogh, Oct 1, 2004
    #1
  2. fogh

    S. Badel Guest

    this seems to work :

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

    cheers,

    stéphane
     
    S. Badel, Oct 1, 2004
    #2
  3. fogh

    fogh Guest

    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.
     
    fogh, Oct 4, 2004
    #3
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.