• 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 Design
  3. Positioning the instances in Layout editor by using SKI...

Stats

  • Locked Locked
  • Replies 34
  • Subscribers 126
  • Views 32006
  • 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

Positioning the instances in Layout editor by using SKILL

RFStuff
RFStuff over 12 years ago

 Dear All,

I am trying to place copies of an instance/object ( say a simple via ) with 'x' distance separation in X-direction.

Is there any in-built feature already available in IC5141 ?

Otherwise, is there any solution ( SKILL script) already posted in the forum ? I searched but couldn't find so.

The code needs three functions:

1) Find the cordianate of the OBJECT/INSTANCE ( this I have already found in the Forum)

2) Copy the object. For this what is the SKILL function ?

3) Paste the desired distance separation ( For palcing wht is the simple SKILL function)

Couls anybody please tell regarding this.

Kind Regards,

 

 

  • Cancel
  • Andrew Beckett
    Andrew Beckett over 12 years ago

    I think you want something like this (which I just threw together). The idea is that you select the things you want to copy in the source window, and then run the command (I suggest putting this on a bindkey). It will prompt you to click in the destination window, and it will put all the selected objects in the same location with the same orientation in the destination window.

    Regards,

    Andrew.

    /* abCopyToOtherWin.il
    
    Author     A.D.Beckett
    Group      Custom IC (UK), Cadence Design Systems Ltd.
    Language   SKILL
    Date       Mar 06, 2013 
    Modified   
    By         
    
    Put the copy on a bindkey, say:
    
    hiSetBindKey("Layout" "<Key>F8" "abCopyToOtherWin()")
    
    Copies selected objects from the current window to the window you click in when prompted
    
    ***************************************************
    
    SCCS Info: @(#) abCopyToOtherWin.il 03/06/13.12:16:39 1.1
    
    */
    
    procedure(abCopyToOtherWinCB(srcWin _dont _points)
        let((destCv)
            ;----------------------------------------------------------------
            ; Since current window will be the destination window, this is correct
            ;----------------------------------------------------------------
            destCv=geGetWindowCellView()
            foreach(fig geGetSelSet(srcWin)
                ;------------------------------------------------------------
                ; Transformation is effectively null, since want the
                ; positions to be the same
                ;------------------------------------------------------------
                dbCopyFig(fig destCv list(0:0 "R0" 1))
            )
            t
        )
    )
    
    procedure(abCopyToOtherWin(@optional (srcWin hiGetCurrentWindow()))
        unless(windowp(srcWin) error("Must have a valid window to start from"))
        hiSetCurrentWindow(srcWin)
        enterMultiRep(
            ?prompts '("Point to the source window" "Point to the destination window")
            ?points list(0:0)
            ?doneProc "abCopyToOtherWinCB"
            ?dontDraw t
        )
    ) 
    

     

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • RFStuff
    RFStuff over 12 years ago

     Dear Andrew,

    Thanks a lot. This is exactly I was trying to achieve.

    But

    What is _dont _points in 1st function.

     

    The 2nd function I am not able to understand. What is enterMultiRep().  Looks like I was looking for somerhing like this type function.

    In another post, I have asked for help in interactive session. You have also mentioned there , I think this is what you were pointing to ?

     

    Kind Regards,

     

     

     

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

    There are a family of built-in functions typically used for digitizing points - these can also rubber-band the points being entered. These functions all begin with "enter" and the available functions are:

    enterArc, enterBox, enterCircle, enterDonut, enterEllipse, enterLine,
    enterMultiRep, enterNumber, enterPath, enterPoint, enterPoints,
    enterPolygon, enterScreenBox, enterSegment, enterString

    They're documented functions.

    Anyway, these have various callbacks which get triggered upon various events (e.g. when you add a point, when you delete a point, when you're done). In the case of the doneProc, it's called with three arguments, the windowId, whether it was "done", and the list of points. Since I don't care about the second two arguments (and I'm not using them in the callback), I used the convention of prefixing them with underscore. The reason for doing this is so that when I run SKILL Lint on the code, it doesn't mark me down for having arguments to my function which aren't used. Apart from that, it doesn't matter - the arguments have to be there, but just don't get used in my code.

    In your other post, it might be a matter of using one of these, or it might just be that you build a form and interact with the user that way.

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • RFStuff
    RFStuff over 12 years ago

     Dear Andrew,

    Thanks a lot .

    Kind Regards,

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • RFStuff
    RFStuff over 12 years ago

    Dear Andrew,

    I thought this I can achieve very easily. But I could not.

    i.e I want to copy the figure at a given offset and mirrored. This is very much useful for diferntial circuit design.

    Draw the one half of the circuit and copy it and mirrored at a given x or y offset.

    Could tell me how it can be done.

    Kind Regards,

     

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

    Maybe using CCSflip.il will do what you want - it's in this post.

    Then do:

    leSetRefPoint(geGetEditCellView() 100:30) ; i.e. specify the xy point to mirror about
    CCSflip(?orient "MY" ?relativeTo 'refPoint ?mode 'copy)

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • RFStuff
    RFStuff over 12 years ago

     Dear Andrew,

    Thanks a lot.

    But  I don't want to find the xy coordinate. It will be more time consuming.

    See, I have a object. Earlier I was just copying the object with (xPitch=x yPitch=0).

    Now I want the same but the object will be flipped i.e. the gap between the objects must be same as that of non-flipped case and there should not be any vertical movemnet of the new object. Same can be desire for yPitch case.

    Kind Regads,

     

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

    Your requirements don't make a great deal of sense to me. If everything is going to be shifted by a fixed pitch, they're not going to have a single line of symmetry, if flipped. And what would be the point about which they are flipped?

    Maybe you could use one of the other ?relativeTo options for CCSflip - such as the combined centre of all the shapes and then have a foreach loop over the resulting figures and do a dbMoveFig by a fixed translation (ie a transform of list(x:y "R0" 1)). Perhaps that is what you mean? This will flip all the shapes in place about the common centre, and then shift them by a fixed offset. 

    Regards,

    Andrew 

     

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • RFStuff
    RFStuff over 12 years ago

     

    Dear Andrew,

    You are right. It is indeed really simple as compared to so many options available in the script.

    However, only one half of the Diff-Pair is going to be shifted and flipped.

    Like:-

    Let's say left object is:- ABC ( left half of the Diff-Pair )

    If I simply shift in xdirection by +10 unit i.e. xPitch=1, yPitch=0, then I will get as below:-

    |ABC|----------------------------|ABC|

    |--------Spacing=10----------|

    What is desired is :-

    |ABC|----------------------------|CBA|

    |--------Spacing=10----------|

    ###################################################################

    When I got CCSflip.il  code, I did first as below:

    1:-- place(xPitrch=10  yPitch=0  Row=1 Column=2)   //This  places the object as below:-

     

    |ABC|----------------------------|ABC|

    |--------Spacing=10----------|

    2:-- In place(), it actually make the newly placed objects selectable using dbSelectFig().

    Here is only the right object ( 1st Row, 2nd Column)

    Then I did CCSflip(). Which basically flips the object around its center. So in principle it should have exactly same spacing i.e. Spacing=10

    But I ended up getting something like below:-

    |ABC|----------------------------|CBA|

    |------Spacing=9.9050------|

    So the spacing is not exactly 10um.

     What is the issue ?.

    I am still ( even at this stage after reading the manual and discussing with so many times ) , not able to understand why leSetRefPoint() is needed i.e. transformation is needed, even if you know the exact refpoint in the cell view. 

    Kind Regards,

     

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

    I suspect it didn't work for you because your shapes are not symmetrical, and so when it flipped around the centre, whichever point you are measuring to moved relative to the centre of the objects being flipped around.

    I took the shapes in the picture below, and did this:

    existingObjs=geGetSelSet()
    geDeselectAll()
    shiftTransform=list(60:0 "R0" 1)
    destCv=geGetEditCellView()
    foreach(obj existingObjs
      newObj=dbCopyFig(obj destCv shiftTransform)
      when(newObj geSelectFig(newObj))
    )
    CCSflip()

    And I get a nice symmetrical layout - but what the "pitch" means is rather dubious.

    Essentially I think you want to compute some point that  you want to be the symmetry line, and then use that as the reference point - either using the ?relativeTo 'refPoint approach, or a similar computation in your own code. If you look in CCSflip, you'll see it computes the overall transform relative to some "origin" - i.e the point about which you want to flip or rotate - by doing:

             ;-----------------------------------------------------------
             ; Combine the transform to do a shift to the origin,
             ; rotate/flip, and then shift back again
             ;-----------------------------------------------------------
             (setq transform
               (dbConcatTransform
                (dbConcatTransform
                 (list (mapcar 'minus origin) "R0")
                 (list 0:0 orient)
                 )
                (list origin "R0")
                ))

    Regards,

    Andrew.

    • halflayout.png
    • View
    • Hide
    • 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