• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Custom IC SKILL
  3. How to Call multi pcells one time?

Stats

  • Locked Locked
  • Replies 5
  • Subscribers 143
  • Views 13689
  • Members are here 0
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

How to Call multi pcells one time?

nidon
nidon over 13 years ago

Dear Sir.

I  want to write a skill script to call mulit pcells in layout, and I used dbCreateParamInstByMasterName(cv "libname" "nmos" ....).But it's just call one pcell one time,and if i want to call mulit pcells one time ,it means I have to write a lots of  dbCreateParamInstByMasterName....Can you help me to solve this problem?

 

Thanks a lot.

  • Cancel
  • Sarvani
    Sarvani over 13 years ago

     hi nidon,

                  I didn't understand your question. As per my guess you need cells in layout are same as schematic cells. When you open layout in XL mode then there is an option called 'Gen From Source' in design menu. I hope this will helps you.

     

     

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • nidon
    nidon over 13 years ago

    Hi,Sarvani,

        I means that i want to use the skill to call the instance in the layout, and I use the command dbCreateParamInstByMasterName(cv "libname" "mn18" ....),then the mn18 is invoked in the layout.But now ,i want to call mulit instances,such as,mn18,mn33,mp18,mp33....

    Do I have to wirte the command dbCreateParamInstByMasterName(cv "libname" "mn18" ....),dbCreateParamInstByMasterName(cv "libname" "mn33" ....)....?Is there any simple ways to do above?

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 13 years ago

    That's what loops were invented for. For example:

    foreach(tranName list("mn18" "mn33" "mp18" "mp33")
      dbCreateParamInstByMasterName(cv "libName" tranName ...)
    )

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • skillUser
    skillUser over 13 years ago

     Hi Nidon,

    One easy way to do this is to create a loop construct around the dbCreateParamInst... statement, perhaps like the following:

    
    params = list(list( ... ))  ;; device parameters, assuming they are all the same
    ;; initialise the instance counts to zero
    ninstNum = pinstNum = 0
    ;; the x stepping distance is 1 micron, the y separation is 2
    xstep = 1
    ystep = 2
    foreach(masterName list("mn18" "mn33" "mp18" "mp33")
      dbCreateParamInstByMasterName(cv "libname" masterName "layout"
        ;; name the instance, increment the count
        if(rexMatchp("p" masterName) then
          sprintf(nil "P%d" pinstNum++) 
        else
          sprintf(nil "N%d" ninstNum++) 
        ); if
        ;; adjust the position based on device type and instance count
        if(rexMatchp("p" masterName) then
          xstep * pinstNum : ystep
        else
          xstep * ninstNum : 0
        ); if
        "R0"
        1
        params
      )
    ); foreach
    

    The above is not tested, I just wrote it out to show an example of what you might do in order to parameterize the code.  The trick is to try to re-use code where possible, but if there are too many exceptions then it is easier just to write out the code, even if it seems a little repetetive.

    Hope this helps!

    Lawrence.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • nidon
    nidon over 13 years ago

    Thanks for you all kindly help,it's seems work out~lol;

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information