• 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. getting the dbID for an instance in the layout

Stats

  • Locked Locked
  • Replies 9
  • Subscribers 143
  • Views 18657
  • 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

getting the dbID for an instance in the layout

Inas Mohammed
Inas Mohammed over 8 years ago

Hello,

I need to get the dbID for certain transistor in order to do some operations on it after that.

The idea is that i need to check for a transistor in a pattern, if this transistor is at lower left of upper right do some commands.

so i need to get value of x which then will be used as follows.

when(row=0 && col==0  lowerleft=x)

when(row=Rows-1 && col=Cols-1 upperright=x)

I thought about like trying to create instances again on the old one with the same names in these places using dbCreateInst just to have the ID, then use it.

But it doesn't work

So can you help me with this issue please.

thanks

  • Cancel
  • Andrew Beckett
    Andrew Beckett over 8 years ago

    This is a very fuzzy description of what you're trying to do. Are  you trying to look at a set of instances and see if they appear to be an array of some sort? That's not entirely trivial to figure out, but maybe some heuristics could do it. Anyway, presumably you'd start by looking at cv~>instances to find all the instances in the cellView and see where they are, or you might start from cv~>instHeaders, to see what component it is, and then from that look at ~>instances to find all the instances of that type. For each  you can look at the ~>xy or ~>bBox to find the position.

    From your description, I'm really not sure what you're trying to do (and I suspect  you're not sure either); maybe if you explained it more clearly, somebody could give you some pointers in the right direction?

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Inas Mohammed
    Inas Mohammed over 8 years ago
    I have generated a pattern.
    Then i need to check in this pattern for the lower left and upper right corners instances to do some operations on them.
    The 1st step in this operation is the "when" statements mentioned above, in which it tells when you are at the lower left corner so this device will be assigned to a variable called "lower left" and the same applied for the case of the upper right instance.
    My question is how to do this assignment.

    I hope i clarified my question. Tell me please if there is another something missed
    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 8 years ago

    How are you generating this pattern? Manually or via SKILL? If via SKILL, then  you can collect the instance ids as you create them (the return value of dbCreateInst).

    Your requirement is still very unclear. If you didn't create the "pattern" using SKILL, how do you know which set of instances you're dealing with? 

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Inas Mohammed
    Inas Mohammed over 8 years ago
    yes i generated the pattern via skill script. And i mention above that i tried to use the "dbCreateInst" but i didn't know how to use it for this purpose which is getting the IDs. I found an instance created instead which is not what i want.
    What i was doing is like the following with an inner loop for filling the columns of the row mentioned in an outer loop:
    masterID=dbOpenCellViewByType(lib cellname cellview)
    x=dbCreateInst(cellView masterID name 1 list(x y) "R0")

    name--> is a variable mention earlier in the code.

    But the lines i wrote didn't work correctly. I need to know how can i use this function to return the IDs of the instances.
    Can you give me an example for this usage of this function, please?
    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 8 years ago

    This still makes absolutely no sense. If you've generated the pattern (presumably the instances), don't you have the instance IDs then? Or are you saying that you know the instance names - in which case you could use dbFindAnyInstByName(cv name) to find the instance id of the named instance? Calling dbCreateInst if you already have the instances in existence makes no sense - it would try to create a new instance in the layout, and if the instance name already exists, it will fail because you can't have two instances with the same name.

    I'm still no clearer as to what you're doing. Maybe you should just talk to customer support so that you can actually show them rather than not being able to describe your problem well enough here (given that I'm answering this in a few minutes during my working day, I really don't have the time to go back and forth to tell you how to describe your problem in clearer language, or to magically guess what you're trying to do; sorry if that sounds harsh).

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Inas Mohammed
    Inas Mohammed over 8 years ago
    Ok i can explain it in another way and you can reply in your free time if you don't mind. Or if other people can share their ideas with us please.
    Simply you have an already generated pattern via skill script, the script doesn't have the dbCreateInst function used inside. In such a case i need to get the ID of a certain instance in this pattern.
    What function(s) that can track the instances ID and give them back as returns.
    For example:
    I'm in a certain row in the pattern, and i'm filling the columns of this row i need to keep track of the instances ID according to its position in which row and column.
    This is a general idea i need to know about.

    Thanks for your patience
    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 8 years ago

    If you have some idea of the coordinate where the instance is placed, you could use dbInstQuery to find out which instances are in a bounding box (could be a list of the same point twice). Maybe that's what you want?

    It's still a very imprecise question - I don't have a good sense of what information your code has access to about the location, number of rows and columns, spacing etc of the "pattern". Anyway, maybe somebody else has more patience than me or is better at guesswork than me.

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • dmay
    dmay over 8 years ago
    I too am confused about what is being done here. It seems to me that you should be recording this information when you create the instances. You said that you are creating the pattern with a skill script. I interpret that to mean that you have a skill script that places the instances using dbCreateInst. If that is true, then, like Andrew said, you would have the instance id after you create each inst (x = dbCreateInst...). If so, then you could change the instance name to contain information about where the instance is in the pattern:
    x~>name = "Inst_1_3"
    sprintf(instName "Inst_%d_%d" row col)
    lowerLeft = dbFindAnyInstByName(geGetEditCellView instName)

    Or you could put properties on the instance:
    x~>R =1
    x~>C = 1
    lowerLeft = setof(x geGetEditCellView()~>instances x~>R==0 && x~>C==0)

    Or you could create a table that contains your information:
    myTable = makeTable("myTable" nil)
    myTable["lowerleft"] = x ; Where x is the return value from dbCreateInst.
    or
    myTable[0:0] = x

    If you are looking at a cellview that already has the instances in it, then I think you have to do what Andrew suggested in his first response.

    Derek
    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Inas Mohammed
    Inas Mohammed over 8 years ago

    Thank you so much for your detailed reply :-)

    • 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