• 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 disable/enable a device in schematic pcell while...

Stats

  • Locked Locked
  • Replies 4
  • Subscribers 143
  • Views 4576
  • 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 disable/enable a device in schematic pcell while netlisting

kalikrishna
kalikrishna over 6 years ago

Hi,

I've created a schematic parameterized cell (Pcell) in which I've 3 types of capacitors (MOS, MIM and MOM caps). When I insatiate this cell in a top cell, I want to have a switch for each of these caps, so that I can disable/enable them in the top cell based on my requirement. Let's say in one case, I want to netlist MOS and MIM only. And in another case, I want to netlist MIM and MOM. 

I came to know that there is an option called nlAction. If I add this as netset, CDL export is ignoring the particular cap while netlisting. This is working fine for the current schematic. But I want this to be parameterized, so that I can toggle net listing of each cap from top cell. 

Could someone help me with this. 

Thanks,

Prasad

  • Cancel
  • Andrew Beckett
    Andrew Beckett over 6 years ago

    Hi Prasad,

    If you have a PCell, please share the PCell SKILL code - all you should have to do in your code is add the nlAction=ignore to each instance or not based on the parameter for the PCell.

    However, from reading what you said, I suspect  you haven't got a PCell at all, but a normal schematic that just happens to pass parameters through the hierarchy. You are also talking about netsets which is a specific type of property for setting inherited connection parameters, so you have some rather strange terminology being used here (so that's why I suspect you didn't mean PCell, and  you didn't mean netset).

    If you are expecting to have a normal schematic, and then be able to pass a parameter which selects which to pass nlAction=ignore to, then you can't do that, You could instead create a config, and then in the tree view select the two instances you don't want to netlist and set these to "bind to open".

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • kalikrishna
    kalikrishna over 6 years ago in reply to Andrew Beckett

    Hi Andrew, 

    Thanks for your reply. Yes, I've created a normal schematic and passing variables through hierarchy using CDF parameters (I'm referring this as a PCell, as I'm able to pass variables).

    I've never created a PCell using SKILL code. Currently I've a PCell layout which I've created through PCell interactive window in layout. I'm able to control the usage of particular Cap by using "Conditional Inclusion". I need something similar in schematic as well. 

    If it can't be done with a normal schematic, could you please help me with the PCell SKILL code. I can modify the SKILL code based on my requirement. 

    Thanks,

    Prasad

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 6 years ago in reply to kalikrishna

    Hi Prasad,

    OK, so you don't have a PCell for the schematic (it's best not to use this terminology for a schematic where you are passing variables using pPar, as that is not what is normally referred to as a "PCell"). A PCell is something where you specify parameters on the instance, and a variant layout, schematic or symbol is built by calling some code (when you use the layout pcell editor, this is a primitive tool for building SKILL PCells). There is a more advanced capability called "Cadence PCell Designer" but I doubt whether you have that product.

    For schematic PCells, search in this forum for "pcDefinePCell schematic" and you'll find a few examples (albeit with issues, but with explanations on how to fix the issues).

    Here's an example of a series connected resistor schematic pcell:

    /* respcell.il
    
    Author     A.D.Beckett
    Group      Custom IC (UK), Cadence Design Systems Ltd.
    Language   SKILL
    Date       Apr 07, 2014 
    Modified   
    By         
    
    Example of a series resistor pcell.
    
    Original version only contained connectivity - this one contains "graphics"
    too so that if you descend into the schematic you can probe nets.
    
    ***************************************************
    
    SCCS Info: @(#) respcell.il 04/07/14.11:02:22 1.2
    
    */
     
    procedure(abCreateResPcell(libName cellName) 
      let( (pcellId)
        unless( ddGetObj(libName)
          error("Couldn't open library %L" libName)
        )
    
        pcellId =  pcDefinePCell(
          list( ddGetObj(libName) cellName "schematic" "schematic" )
    
          ;------------------------------------------------------------------
          ; Default Parameters
          ;------------------------------------------------------------------
          (
    	(ns "1")
          )
          let(( pcCV masterCv instName instId netP netM numInsts y (resHeight 0.375)
    	(wireLen 0.125) pinMaster pinFig wire lastCoord)
    
    	pcCV = pcCellView
    
    	;------------------------------------------------------------------
    	; open master cellviews
    	;------------------------------------------------------------------
    	masterCv = dbOpenCellViewByType( "analogLib" "res" "symbol" nil "r" )
    	pinMaster=dbOpenCellViewByType("basic" "iopin" "symbol")
    
    	numInsts=atoi(ns)
    	when(numInsts<1 numInsts=1)
    
    	;----------------------------------------------------------------
    	; Create nets and terminals
    	;----------------------------------------------------------------
    	netP=dbMakeNet(pcCV "PLUS")
    	netM=dbMakeNet(pcCV "MINUS")
    	dbCreateTerm(netP "PLUS" "inputOutput")
    	dbCreateTerm(netM "MINUS" "inputOutput")
    	y=0
    	pinFig=dbCreateInst(pcCV pinMaster "" 0:y "R0")
    	dbCreatePin(netP pinFig)
    	lastCoord=0:y
    	for(inst 1 numInsts
    	  ;--------------------------------------------------------------
    	  ; Create the nets connected to either side
    	  ;--------------------------------------------------------------
    	  if(inst==1 then
    	    netP=dbMakeNet(pcCV "PLUS")
    	  else 
    	    netP=dbMakeNet(pcCV sprintf(nil "net%d" inst-1))
    	  ) ; if
    	  if(inst==numInsts then
    	    netM=dbMakeNet(pcCV "MINUS")
    	  else 
    	    netM=dbMakeNet(pcCV sprintf(nil "net%d" inst))
    	  )
    	  sprintf(instName "R%d" inst)
    	  y=y-wireLen
    	  instId = dbCreateInst( pcCV masterCv instName (0:y) "R0" )
    	  dbCreateProp(instId "r" "string" "pPar(\"r\")/pPar(\"ns\")")
    	  ;--------------------------------------------------------------
    	  ; Connect up the instance
    	  ;--------------------------------------------------------------
    	  dbCreateInstTerm(netP instId dbFindTermByName(masterCv "PLUS"))
    	  dbCreateInstTerm(netM instId dbFindTermByName(masterCv "MINUS"))
    	  wire=dbCreateLine(pcCV list("wire" "drawing") list(lastCoord 0:y))
    	  dbAddFigToNet(wire netP)
    	  y=y-resHeight
    	  lastCoord=0:y
    	)
    	y=y-wireLen
    	pinFig=dbCreateInst(pcCV pinMaster "" 0:y "R0")
    	dbCreatePin(netM pinFig)
    	wire=dbCreateLine(pcCV list("wire" "drawing") list(lastCoord 0:y))
    	dbAddFigToNet(wire netM)
    
    	dbSetConnCurrent(pcCV)
    
    	dbClose( masterCv )
    	;; Always return true
    	t
          ) ; ** let **
        )
        ; not sure if below is really necessary
        dbSave(pcellId)
        dbClose( pcellId ) 
      ) ; ** let **
    )
    

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • kalikrishna
    kalikrishna over 5 years ago in reply to Andrew Beckett

    Hi Andrew,

    Thank you so much for the Example script to create a schematic Pcell. It really helped me to create a PCELL for capacitors

    Regards,

    Prasad

    • 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