• 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. Selection Problem SKILL messing with rectangle placemen...

Stats

  • Locked Locked
  • Replies 12
  • Subscribers 144
  • Views 18738
  • 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

Selection Problem SKILL messing with rectangle placement

ARB9
ARB9 over 6 years ago

I am gonna start off by saying that I am pretty new to SKILL. My Code is at the Bottom if you want to look at that. I'm having on odd problem with my SKILL Code. When it first places an Instance, you can move everything around independently. But, after you double click on an instance and it goes from the view with the red outline to the one with the white, things start going funky. First off, the only Pcell I can move is the one I initalliy double clicked to change the view. Second, if I move that one, any instance that is the same PCell moves with it. See Image where I move a corner cell and the other 3 move along with it.

                

If this was all that happened, it would be annoying but I could get around it. But, if I try to place a rectangle into the layout with SKILL using

rect3 = rodCreateRect(
?name "rect3"
?cvId geGetEditCellView()
?layer "Met5"
?bBox list(466:387 496:600)
)

it places 4 rectangles, each tied to one of the corners. I'm pretty sure this is based on the last thing I placed using the code since, when I tested it using PANALOG_S as the last thing I place, I ended with many rectangles. How can I make it only place one rectangle?

One last thing, if y'all are willing to help me with this as well. When I'm in the view with the red outline, the one where an instance if first placed, I am having trouble placing rectangles in any layer other than background. Can you do that with SKILL? I know that if the layout is in the other view, the one with white outlines, that I can make the rectangles place using that bit of code above. How can you change the view using SKILL? Thank Y'all again. And before you say anything about which pads I have where, I know that it is nonsensical. I am just trying to figure out the code so this is a test run.

procedure(placePadFrame1( @optional no_pads )

(setq no_pads 6.0)

(if (null no_pads) then

(setq no_pads (enterNumber ?prompts '("Please enter the number of pads on a side"))))

(setq xpointh 593)

(setq ypointh 300)

(setq xpointv 503)

(setq ypointv 849)

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PBREAK_T" "layout") nil (list xpointv+(40*-1) ypointh-223) "R0")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PANALOG_S" "layout") nil (list xpointv+(40*0) ypointh-223) "R0")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PAVDD_S" "layout") nil (list xpointv+(40*1) ypointh-223) "R0")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PAVDD_T" "layout") nil (list xpointv+(40*2) ypointh-223) "R0")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PANALOG_S" "layout") nil (list xpointv+(40*3) ypointh-223) "R0")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PAVDD_T" "layout") nil (list xpointv+(40*4) ypointh-223) "R0")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PANALOG_S" "layout") nil (list xpointv+no_pads*40+346 ypointv+(40*0)-386) "R90")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PAVDD_T" "layout") nil (list xpointv+no_pads*40+346 ypointv+(40*1)-386) "R90")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PBREAK_T" "layout") nil (list xpointv+no_pads*40+346 ypointv+(40*2)-386) "R90")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PANALOG_S" "layout") nil (list xpointv+no_pads*40+346 ypointv+(40*3)-386) "R90")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PAVDD_T" "layout") nil (list xpointv+no_pads*40+346 ypointv+(40*4)-386) "R90")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PANALOG_S" "layout") nil (list xpointv+no_pads*40+346 ypointv+(40*5)-386) "R90")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PANALOG_S" "layout") nil (list xpointv+(40*0) ypointv+no_pads*40) "R180")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PAVDD_T" "layout") nil (list xpointv+(40*1) ypointv+no_pads*40) "R180")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PANALOG_S" "layout") nil (list xpointv+(40*2) ypointv+no_pads*40) "R180")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PAVDD_T" "layout") nil (list xpointv+(40*3) ypointv+no_pads*40) "R180")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PANALOG_S" "layout") nil (list xpointv+(40*4) ypointv+no_pads*40) "R180")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PAVDD_T" "layout") nil (list xpointv+(40*5) ypointv+no_pads*40) "R180")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PANALOG_S" "layout") nil (list xpointv-426 ypointh-70+(40*1)+233) "R270")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PBREAK_T" "layout") nil (list xpointv-426 ypointh-70+(40*2)+233) "R270")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PANALOG_S" "layout") nil (list xpointv-426 ypointh-70+(40*3)+233) "R270")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PAVDD_T" "layout") nil (list xpointv-426 ypointh-70+(40*4)+233) "R270")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PANALOG_S" "layout") nil (list xpointv-426 ypointh-70+(40*5)+233) "R270")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PAVDD_T" "layout") nil (list xpointv-426 ypointh-70+(40*6)+233) "R270")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PCORNER_T" "layout") nil (list xpointv-426 ypointh+no_pads*40+549) "R270")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PCORNER_T" "layout") nil (list xpointv+no_pads*40+346 ypointh+no_pads*40+549) "R180")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PCORNER_T" "layout") nil (list xpointv+no_pads*40+346 ypointh-223) "R90")

(dbCreateInst (getEditRep) (dbOpenCellViewByType "Pad_Library" "PCORNER_T" "layout") nil (list xpointv-426 ypointh-223) "R0")

)

  • Cancel
  • MalcolmWhite
    MalcolmWhite over 6 years ago

    I'm just curious why you used the ROD function, you *can* use dbCreateRect() to make your rectangles and they are not inter-related to each other - it just becomes object "rect"  ,then you have to increment your placement coordinates and create the next rectangle.  

    • Cancel
    • Vote Up +1 Vote Down
    • Cancel
  • ARB9
    ARB9 over 6 years ago in reply to MalcolmWhite

    Gotcha, when I made this code, I was researching ways to do it and the way I saw to use dbCreateRect() was not working for me. Then I found the ROD function which worked a bit better but had this problem. Yesterday, I was able to figure out/find how you use dbCreateRect() and it's working much better. Thank you! I am still wondering about why the corners move together so if you could help me figure that out, I would really appreciate it!

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

    I have no idea why you are seeing the symptoms you are (or were) seeing. I see no reason why this would be related to using rodCreateRect rather than dbCreateRect, since all that does is use a higher level function. Yes, you can set up persistent alignments between objects using rod functions, but you're not doing this here. I also don't see why your code would (or even could) cause everything to move together - to be honest, your description didn't make sense to me.

    There's an awful lot of information missing in the original question - the code doesn't even use rodCreateRect, so I've no idea what you're actually doing here...

    Andrew.

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

    Ok, let me start from the beginning. I am making this code to make pad frames. My jumping off point was this site I found:

    https://sites.google.com/a/mst.edu/eech106-eda/2013spring_cpe411/45nm-lab-1--pad-frames

    I just expanded the amount of pads per side while using much of this code at first. Even at this point, everything was moving together so this has been a question to me for a while now.

    It was after this that I went onto creating rectangles. I did end up using dbCreateRect which works much better then using the ROD function did so now I am just trying to figure out that original problem with the Pads moving together. I am 100% certain that the rectangles, whether they are added or not, have no effect on this weird symptom. If you have no idea what causes it, I can try to work around it. And if you have any more questions, I would be happy to answer them

    Thanks for you help!

    Adam

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • MalcolmWhite
    MalcolmWhite over 6 years ago in reply to ARB9

    Hi Adam - just wondering - what cadence version are you using ? also, would you be able to cut and paste some more information about "the way you saw to use dbCreateRect() " , perhaps the code snippet you saw and copied ?create rectangle is a pretty basic function, so just wondering how what you saw was not working for you.  Thanks. Also , I'm just curious that in your original post you talk about  " But, after you double click on an instance and it goes from the view with the red outline to the one with the white" I'm not sure what you are doing , it sounds like you are traversing heirarchy in your layout cell. ( like using Descend Edit ) but I am not sure.  thanks, just wondering.  

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • ARB9
    ARB9 over 6 years ago in reply to MalcolmWhite

    The version is 6.1.8.

    The snippet of code I found was from this link:

    community.cadence.com/.../script-skill-drawing-a-path-or-rectangle-in-layout-s-view

    The code didn't like the "M1" so I ended up using:
    rect1 = dbCreateRect(
    cv
    list(level type)
    list( x1:y1
    x2:y2 )
    where I put just a number for level type (in my case, I am putting 6).

    Yes! Sorry, I didn't know the exact terminology but traversing hierarchy sounds right. How do I do that with SKILL?
    Not knowing terminology makes looking things up difficult
    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • MalcolmWhite
    MalcolmWhite over 6 years ago in reply to ARB9

    Hi Adam, ok , cadence 6.x - that's good - you're using tools based in OA so that's pretty modern cadence.  

    Few thoughts if I may.

    1. I can see what happened when you originally tried to draw a rectangle and that didn't work.  I am glad that you have posted a question in fhe forums before you proceed much farther with this .  The reason being that you have to be careful when you read the postings of other people when they post software snippet solutions.  Let me tell you I have never worked anywhere with cadence where two sites have the same names - so what happens is the code snippet you read used the term "M1" which is commonly understood to be the first metal drawing layer in anyones layout design.  I have seen a number of different ways to refer to this - M1, met1, MET1, METAL1, m1  those are probably the top 5.  I read your other posted code snippet and you made reference to "Met5" when you posted a snippet about your ROD create rectangle so that suggested to me you have a different naming convention - what the code snippet requires to work is the name you use in your code must match the technology naming convention that you are running cadence under.   So when you used "6" cadence interpretor kinda barfed and said I have no idea what this layer is so I cannot continue with this code. What is interesting to me is I have never seen a note in cadence help pages which references that you must use the naming convention that matches what tech file you are using.  ( however I am certainly open to knowing where that is found since HELP is a REALLY large set of pages ... )

    2. referencing the above thought - you'll find SKILL is REALLY picky about syntax.  that's one of the harder things to learn for a newbie.  if something about your code isn't understood,  - even really small things like a missing parenthesis -Most of the time,  your code just wont run.  the beauty of this is the other option is it does run and totally does something different than you want / expect . and you can UNDO the last operation.  The case to be careful of - you kick off a code - the screen just kinda sits there - it LOOKS like it IS doing SOMETHING , the screen cursor forms a hourglass which just spins... DON"T let that run - hit control C immediately. you have probably just created THOUSANDS of objects .

    3. sorry - this is just a personal style thing- I write the function call to create a rectangle from left to right , ( I find it more readable ) , as in 

    rect1 = dbCreateRect(cv list(level type) list( x1:y1 x2:y2 ) ) <- don't forget the closing parenthesis.

    4. traversing heirarchy in SKILL is a lot more difficult subject , get used to using the commands from the pulldown menu under the "Edit " pulldown which is proabably 3rd from the left ( order being "Launch" "File " "Edit " )  Edit =>Heirarchy  =>Descend Edit / Descend Read / Return   those 3 get you up and down in layout - you probably have a bindkey attached by default which is probably some combination of the X key you can see that from your CIW window under the "Options" pulldown menu - then "Bindkeys " then select the "Layout " type.

    5. if you are having problems writing a code snippet - the wonderful thing about skill is you CAN debug things a line at a time by cut/paste your line into the CIW window.  and then you can see what happens.  if your line has some problem in it the line won't result in a successful response . or the CIW window will try to respond with the reason your code line snippet was unable to process , what syntax was wrong, or some such other error messages.

    Good luck to you !  Ask questions - it's a difficult thing to learn especially syntax.

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

    Whilst I may be a little biased (having been using SKILL for something like 28 years), I don't think it's that hard to learn and the syntax is not really any worse than any other programming language. Most programming languages are fairly insistent on correct syntax. 

    I would always suggest you start off by reading the SKILL Language User Guide in the documentation as this talks through the principles of the language and how things are structured, as well as core language features. There is then a lot of documentation for the specific application programming interfaces you need to get things done, as well as a wealth of code out there - either in these forums or on support.cadence.com

    There's nothing in the code you pointed to or posted which could possibly cause the instances to be linked together (this can be done by attaching one object to another, creating a parent-child relationship, or by using the rodAlign function to create a persistent alignment between objects). The only thing I can think of is that you have an instance of the pad frame you've created, and it's that you've select and have moved. This is a wild guess though - none of what you are saying makes sense. A single rodCreateRect or dbCreateRect with the arguments you've given cannot be creating 4 rectangles - that's just impossible. 

    I'm guessing you're at a University - if so, I suggest you talk to your supervisor. If you're at a commercial company, speak to a colleague as it sounds as if you're unsure about basic use of the layout tool - if you don't have an idea about that, then automating creation of layout is likely to be a bigger challenge still.

    We love to help in these forums, but you really do need some basic knowledge as otherwise even describing what you're aiming to do is going to be a challenge.

    Regards,

    Andrew.

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

    Hi Andrew - the only thing I can think of that caused his situation as he describes is the snip : " But, after you double click on an instance and it goes from the view with the red outline to the one with the white " and I think what he's talking about would make sense if what he has in his environment is somehow with a double mouse click he activated "Descend Edit" and when he was in a subcell he started moving around parts of that which reflects on each case the instance is placed at top level .

    In my case not having formal software background , I've felt the learning curve towards correct syntax was a pretty decent obstacle.  When I was able to create code which worked the first time I executed it,  I thought that was a enjoyable personable experience.

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

    So I noticed something interesting. When I try to edit the instance in my view, it edits the master instead. So of course this would cause other instances with the same master to change. I just need to find how to not do this.

    By the way, I am at university and they have computers with Virtuoso on them in a few labs so I am trying to self teach it as well as SKILL. It is, admittedly, a bigger undertaking then I anticipated and I don't really have other people to ask questions to. That's why I am going right to here with most of my questions

    Adam

    • 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