Hi Mathias -
What's the best way for:
1. automatically selecting and loading a default layer properties (lyp) file, when opening a GDS file in klayout.
2. automatically selecting a lyp file (one out of several) based on environment variable or other settings? (this feature would be very useful when multiple technologies are used within the same organization).
3. Automatically applying setting that I normally manually have to apply in "Layers" toolbar/menu, after new GDS file is opened:
(a) Clean up layer entries
(b) Add other layer entries
(c) Sort by -> name
Thanks a lot!
simg
Comments
Hi simg,
KLayout has the concept of a "technology setup" which allows associating a layout with some "technology". A "technology" is basically a set of settings for specific purposes. For example, the net tracer requires a connectivity stack which tells it which layers represent conducting material and which layers are connecting (via) layers. This setup is clearly technology dependent. Hence a technology stands for specifying additional information based on the GDS layer numbers.
Among the various settings you can also specify layer properties with a technology. Details about using technologies can be found here: http://klayout.de/doc/about/technology_manager.html.
Once you have set up a technology, you can tell KLayout to use a specific technology for some file:
Here "TECHNAME" is the name of the technology you want to use.
If you use that approach, the answers to 3.) will be:
Matthias
with regard to "automatically detecting a technology":
As long as there is some kind of digital power grid in the gds file and via's have not been flattened, I found the following heuristic to work very well:
Look for struct that have one rectangles of the same size on two different layer and another layer with only squares of equal spacing, which are covered by the "metal" rectangle. The layer with the squares would be a via layer. Ignore struct with less then 4 squares, there are too many struct from ram/rom generators or analog design that would otherwise trigger.
With this list of possible via containing 2 metal rectangles and 4+ via squares one can work out the order of the metal stack by linking up the metal layers.
The lowest via Layer sometimes has two different lower metal layers, that's usually contact going down to poly or well.
By the size of the via squares, one can easily detect which metal stack the gds file contains. And in a lot of technologies contact are smaller then via1.
This heuristic doesn't depend on any metal or via layer number ordering, which wouldn't work especially on upper metal layers on some technologies.
Let's call "automatic technology detection" yet another feature request.
Or a challenge for anybody with coding skills and time on their hands.
I'm lacking the latter ..
Best Regards
Stefan