Home > Community > Forums > Custom IC SKILL > Opening Pcell while hierarchically browsing a Master Layout

Email

* Required Fields

Recipients email * (separate multiple addresses with commas)

Your name *

Your email *

Message *

Contact Us

* Required Fields
First Name *

Last Name *

Email *

Company / Institution *

Comments: *

 Opening Pcell while hierarchically browsing a Master Layout 

Last post Wed, Jun 12 2013 11:59 PM by Abhishek Iyer. 4 replies.
Started by Abhishek Iyer 12 Jun 2013 01:29 AM. Topic has 4 replies and 707 views
Page 1 of 1 (5 items)
Sort Posts:
  • Wed, Jun 12 2013 1:29 AM

    • Abhishek Iyer
    • Not Ranked
    • Joined on Tue, Nov 6 2012
    • Bangalore, Karnataka
    • Posts 2
    • Points 55
    Opening Pcell while hierarchically browsing a Master Layout Reply

    Hi,

    I have a master layout and with various levels of heirarchy. My aim is to find and draw boxes around shapes belonging to a particular layer.

    The problem comes in when I come across an instance which is a pcell while I am traversing through the hierarchy.

    If I try to openthe instance using dbOpenCellViewByType(), it obviously opens with the default parameters and the purpose is lost.

    I intend to do some processing on pcell layout with the instantiated parameters "without flatenning" the layout.

    Regards,

    Abhishek

    • Post Points: 50
  • Wed, Jun 12 2013 7:11 AM

    • dmay
    • Top 25 Contributor
    • Joined on Thu, Jul 17 2008
    • Allen, TX
    • Posts 396
    • Points 7,460
    Re: Opening Pcell while hierarchically browsing a Master Layout Reply

    If you have the instance id while traversing the hierarchy, then you can access the pcell submaster using:

    instId~>master

    Any shapes you find in this master will need to be transformed to the current level of hierarchy. If shpId is the id of a shape in the master, you can do this:

    ll = dbTransformPoint(car(shpId~>bBox) inst~>transform)
    ur = dbTransformPoint(cadr(shpId~>bBox) inst~>transform)
    newBox = list(ll ur)
    or
    newBox = mapcar('(lambda (x) dbTransformPoint(x inst~>transform)) shpId~>bBox)

    Derek

    • Post Points: 5
  • Wed, Jun 12 2013 7:19 AM

    • marcelpreda
    • Top 200 Contributor
    • Joined on Tue, Jan 19 2010
    • Bucharest, Romania
    • Posts 44
    • Points 715
    Re: Opening Pcell while hierarchically browsing a Master Layout Reply

     Hi Abhishek,

    You can not open the pcell, add the new shape and then to save it.

     You have to  create a new inst eventaually withthe parameters changed.

    E.g. the code bellow will create a new pcell of tipe libname/cellname/layout on the x:y coordinates, no rotation withparamaters W and L

    masterId = dbOpenCellViewByType("libname" "cellName" "layout");
    isntId = dbCreateParamInst( cv() masterId "my_inst_name" list(x y) "R0" list( list("W" "float" 0.5) list("L" "float" 0.6)))

    Have a look on  dbCreateParamInst()

    Eventually you can try  dbCreateParamInstByMasterName("libname" "cellName" "layout" ...)

    BR,

    Marcel

    • Post Points: 5
  • Wed, Jun 12 2013 8:25 AM

    • theopaone
    • Top 50 Contributor
    • Joined on Tue, Feb 12 2013
    • Cedar Park, TX
    • Posts 136
    • Points 2,050
    Re: Opening Pcell while hierarchically browsing a Master Layout Reply

     Do you intend that the new shape be put at the top level of the hierarchy?

     Pcell instances create a virtual memory master that reflects the results of the execution of the pcell code based on the parameter values. For each set of parameter values, there is one instance master (instHeader). An instHeader may point to multiple masters.

    You should not modify the VM instance master of the pcell. It can corrupt the VM master as well as the cached master.

     Like Derek said,  you would have to find the shape in the master and then draw a shape at the top level for each instance using that instance's transform. (I would use dbTransformBBox but I'm lazy)

     For shapes nested in deeper levels of hierarchy, you would need to find the instance path and concat the transforms. See dbGetTrueOverlaps and dbConcatTransform for more information on this.

    Ted

    • Post Points: 20
  • Wed, Jun 12 2013 11:59 PM

    • Abhishek Iyer
    • Not Ranked
    • Joined on Tue, Nov 6 2012
    • Bangalore, Karnataka
    • Posts 2
    • Points 55
    Re: Opening Pcell while hierarchically browsing a Master Layout Reply

     Thanks for all the replies
    inst~>master is what i was looking for....obviously some transformations has to be done before puting a rect around BBox of a shape

    Will figure it out using your replies earlier.

    Thanks for all the pointers

     Regards
    Abhishek

    • Post Points: 5
Page 1 of 1 (5 items)
Sort Posts:
Started by Abhishek Iyer at 12 Jun 2013 01:29 AM. Topic has 4 replies.