In IC6, I have a bindkey which change via level (via1 to via2) . Main part of the code is:; Current selected viaviaToBeChanged=car(geGetSelSet()); new via identifiernewVia=dbOpenCellViewByType( technName viaName "layout" nil "r")if( newVia then viaToBeChanged~>master=newVia)Do you know how doing the same thing in IC6 ?Thanks in advanceEric
I've not really played with this, but I think that you can find the via definition using something like techFindViaDefByName() and then use that as one of the arguments to the dbCreateVia() function. In IC 6.1.x vias are objects in the database, whereas in IC51 ad earlier vias are instances, so they do need to be treated differently in IC61x.
Hope this helps.
In reply to skillUser:
There are two types of vias in IC6, customVias which have cellViews and stdVias which do not have cellViews. My current tech file only has stdVias so I cannot include anything about customVias.
As Lawrence implied, with IC6, if you want to put in a new via in place of the old, not modify the parameters on an existing one, you have to replace the via by creating a new via instanceusing dbCreateVia and delete the old.
In reply to Austin CAD Guy:
Thanks for your replies.
OK for creating a new via which is stdVia. dbCreateVia has some argmuments. There is no problem for me to get l_point and t_orient from the original via. But I don't know how to get l_paramList. Is there a function to get those parameters ?
In reply to Eric L14:
The non default parameter values are stored on the via header for that instance:
The default parameter values have to be extracted from the viaDef
Thanks for your help. It works fine
Based on what you mentioned the differenct between IC6.1.x vias are objects and IC51 are instance. In this case, is a script in IC51 use 'leIsContact' to check if the via being selected and exist, what should I use accordingly in IC6.1.x?
In reply to kpai:
there is a function dbIsCellViewStdViaMaster() that may help, but there may be another way to approach the problem. In IC61x you can access the vias from the cellview database object, as well as the viaHeaders and viaMasters (and viaVariants) - perhaps you can come from one of these and check to see if the object in question matches?
In IC5141 vias were just instances, and it determined which instances were vias based on them being defined in the tech file as a via. So the leIsContact function could be passed an instance, and then it checked to see if it was one of the registered vias.
In IC61 (because it's OpenAccess), vias are separate objects. So it's very easy to tell if a via is a via:
inst~>objType=="stdVia" || inst~>objType=="customVia"
member(inst~>objType '("stdVia" "customVia"))
take your pick!
Thanks Lawrence and Andrew for your prompt reply!
I can find out my via is "stdVia". Now, how can I found out this particular "stdVia" with it's col and row number?
You can see there's a viaDefName attribute, an overrideParams attribute (which is an assoc list of things like cutRows, cutColumns). The original (default) parameters are at inst~>viaHeader~>viaDef~>params - but they're just a simple list. So, for example:
"cutWidth" "cutHeight" "cutRows" "cutColumns"
"layer2Enc" "layer1Offset" "layer2Offset"
mapcar('list paramNames inst~>viaHeader~>viaDef~>params)
(("cutLayer" "Via1") ("cutWidth" 0.14) ("cutHeight" 0.14) ("cutRows" 1) ("cutColumns" 1) ("cutSpacing" (0.2 0.2) ) ("layer1Enc" (0.06 0.06) ) ("layer2Enc" (0.06 0.06) ) ("layer1Offset" (0.0 0.0) ) ("layer2Offset" (0.0 0.0) ) ("originOffset" (0.0 0.0) ) ("imp1Enc" nil) ("imp2Enc" nil))
So if you had this:
default=mapcar('list paramNames inst~>viaHeader~>viaDef~>params)override=inst~>viaHeader~>overrideParams
cadr(assoc("cutRows" override)) => 2cadr(assoc("cutRows" default)) => 1
Hope that helps!
Thanks Andrew! It works like a charm now.
In reply to Andrew Beckett:
Is there anyway to change the existing via rows or column, by using viadefs parameter
In reply to Gurup:
No. You can't do that (it doesn't make sense either).
You can change the rows and columns of an existing via instance by using:
or you could use dbReplaceProp() or dbReplacePropList() to change them in one go.
You'll find that you'll get a different viaHeader if you do this - it will bind that via to a different header.
Thanks Andrew,I will try this.
can you tell me what is difference between the objects and instances.
Not sure I entirely understand the question, because it's like asking for the difference between fruit and apples.
In both CDB and OpenAccess, various things are represented as "objects" in the database. For example, there are objects to represent shapes (e.g. rectangles, polygons, paths, ellipses etc), objects to represent instances, objects to represent nets, terminals, and so on and so on. Instances are a type of object. In CDB there was no specific object type for vias; vias were just instances. In OpenAccess however, instances are one type of object, and vias are another type - so there is now a specific object type for vias, thus separating them from ordinary instances (e.g. instances of devices, instances of other cellViews and so on).
Hopefully that answers your question?