KLayout Design Tips: Difference between revisions
(link to QNFCF Youtube videos on Cells) |
(→How to draw Text: minor update) |
||
(5 intermediate revisions by the same user not shown) | |||
Line 16: | Line 16: | ||
===How to draw circles=== |
===How to draw circles=== |
||
*You have to draw a square, and then apply the function '''''Edit > Selection > Convert to PCell'' > Basic.CIRCLE'''. |
*You have to draw a square, and then apply the function '''''Edit > Selection > Convert to PCell'' > Basic.CIRCLE'''. (A P-Cell is a Cell with parameters - like a programmer's "function" with "arguments" of sorts.) |
||
*Sometimes these P-Cells don't convert properly at the photomask vendor, so make sure to run '''''Edit > Selection > Convert to Static Cell''''' or '''''Edit > Layout > Convert All Cells to Static''''' before sending to the vendor/machine, which converts to a regular polygon in a Cell. (You lose editing capabilities of the P-Cell when you do this.) |
|||
**Another way is to convert a square to a polygon directly with '''''Edit>Selection>Round Corners''''' function with '''''Outer Corner Radius''''' = the desired circle radius (radius is not changeable afterards in this method, but computation may be faster for a large number of objects). |
**Another way is to convert a square to a polygon directly with '''''Edit>Selection>Round Corners''''' function with '''''Outer Corner Radius''''' = the desired circle radius (radius is not changeable afterards in this method, but computation may be faster for a large number of objects). |
||
**Klayout doesn't natively support circles because the GDS file format does not have a "circle" primitive built-in, so instead it creates a polygon. Make sure you include enough polygon points, eg. 32. See the [https://www.klayout.de/forum/discussion/142/making-circles forum help pages] on this for more info. |
**Klayout doesn't natively support circles because the GDS file format does not have a "circle" primitive built-in, so instead it creates a polygon. Make sure you include enough polygon points, eg. 32. See the [https://www.klayout.de/forum/discussion/142/making-circles forum help pages] on this for more info. |
||
===How to draw Text=== |
|||
A common mistake is to use the “Text” tool to draw text that you want to get printed on the mask plate. |
|||
'''Only Polygons''' will get printed on the final mask plate. To print text, you have to convert the Text tool objects into polygons as so: |
|||
*Use the '''Text''' Tool to place some text. These text objects are useful for comments/labels on a layout that won’t get printed. |
|||
*select the text object |
|||
*Use the function '''Edit > Selection > Convert to PCell''' |
|||
*by default the PCell “'''BASIC.TEXT'''” should be selected. |
|||
*Select the object again if needed, and view the object’s Properties ('''Edit > Properties''') |
|||
*Here you can adjust the Size via the “''Magnification''” parameter, the text string, and other useful properties. |
|||
Note that the default font has enclosed spaces, which is sometimes non-optimal for lift-off processes. See this hint for [https://www.klayout.de/forum/discussion/comment/6919/#Comment_6919 '''installing a Vented Font.'''] |
|||
===Cells & Instances of Cells=== |
===Cells & Instances of Cells=== |
||
It is highly recommended that you understand and use the concept of "Cells" in your design. This is critical for direct-write machines ([https://wiki.nanotech.ucsb.edu/wiki/E-Beam_Lithography_System_(JEOL_JBX-6300FS) EBL], [https://wiki.nanotech.ucsb.edu/wiki/Maskless_Aligner_(Heidelberg_MLA150) MLA], Mask-writing vendors), and if used properly, helps tremendously with programming the Stepper lithography machines. This functionality also circumvents many problems with enormous file sizes (due to huge numbers of identical polygons), by "pointing" to the same polygon only defined once in the file. Links to documentation below: |
It is highly recommended that you understand and use the concept of "'''Cells'''" & "'''Instances'''" in your design. This is critical for direct-write machines ([https://wiki.nanotech.ucsb.edu/wiki/E-Beam_Lithography_System_(JEOL_JBX-6300FS) EBL], [https://wiki.nanotech.ucsb.edu/wiki/Maskless_Aligner_(Heidelberg_MLA150) MLA], Mask-writing vendors), and if used properly, helps tremendously with programming the Stepper lithography machines. This functionality also circumvents many problems with enormous file sizes (due to huge numbers of identical polygons), by "pointing" to the same polygon only defined once in the file. Links to documentation below: |
||
*Create a new cell, and instancing that cell: [https://www.klayout.de/doc-qt4/manual/create_instance.html KLayout Docs : Creating a Cell instance] |
*Create a new cell, and instancing that cell: [https://www.klayout.de/doc-qt4/manual/create_instance.html KLayout Docs : Creating a Cell instance] |
||
Line 28: | Line 43: | ||
===File Types=== |
===File Types=== |
||
OASIS files tend to be much smaller than GDS files, and they also save the Layer Names (not just Layer Number). |
OASIS format is the successor to the GDS format, and is the preferred format, except that some software (eg. Heidelberg) doesn't yet accept it. All Photomask vendors accept OASIS format. OASIS files tend to be much smaller than GDS files, and they also save the Layer Names (not just Layer Number). All Photomask manufacturers accept this file type. KLayout can convert between OASIS and GDS without issue (except that GDS loses the layer names). See [https://www.klayout.de/forum/discussion/2152/oasis-the-successor-to-gds/p1?new=1 this article] for more info. |
||
GDS files are considered "standard", but are somewhat antiquated, |
GDS files are considered "standard", but are somewhat antiquated, lose the text names of layers between saves and can be 1000x larger file size than OASIS. The Heidelberg software ([[Maskless Aligner (Heidelberg MLA150)|MLA150]]) only accepts GDS as the preferred format, not OASIS. |
||
Alternatively, in KLayout the function '''File > Save Session''' will save the entire view including layer styles and window/zoom locations will be saved. You can share this file, as the entire design file is embedded within it, but it may not be as robust between KLayout versions. |
Alternatively, in KLayout the function '''File > Save Session''' will save the entire view including layer styles and window/zoom locations will be saved. You can share this file, as the entire design file is embedded within it, but it may not be as robust between KLayout versions. |
||
DXF files coming from AutoCAD often are missing the "units", and may erroneously map millimeters to meters, causing your design to be 1000x too large. You can fix this in '''''File > Reader Options > DXF''''', or simply instance the entire design into a new Cell with Magnification set to correct the scaling error. Also, AutoCAD allows for non-closed polygons, which are invalid shapes (even though the start/end points lie on top of each other, the shape is not technically "closed" unless you use polyline-edit "''PEDIT''" and intentionally Close them). The DXF Reader has some options to catch/fix these. |
DXF files coming from AutoCAD often are missing the "units", and may erroneously map millimeters to meters, causing your design to be scaled 1000x too large. You can fix this in '''''File > Reader Options > DXF''''', or simply instance the entire design into a new Cell with Magnification set to correct the scaling error. Also, AutoCAD allows for non-closed polygons, which are invalid shapes (even though the start/end points lie on top of each other, the shape is not technically "closed" unless you use polyline-edit "''PEDIT''" and intentionally Close them). The DXF Reader has some options to catch/fix these. |
||
===Non-Orthogonal Arrays=== |
===Non-Orthogonal Arrays=== |
||
Arrays created with diagonal instancing (non-orthogonal arrays) can be incompatible with photomask vendor's mask writing software. |
Arrays created with diagonal instancing (non-orthogonal arrays) can be incompatible with photomask vendor's mask writing software. |
||
Line 42: | Line 57: | ||
If you do need to use a non-orthogonal array, make sure to use '''''Selection > Resolve Arrays''''' before submitting your design to the manufacturer/machine. |
If you do need to use a non-orthogonal array, make sure to use '''''Selection > Resolve Arrays''''' before submitting your design to the manufacturer/machine. |
||
=== |
===Handling very large files=== |
||
If you will be generating millions of identical shapes (eg. repeating array of circles), the file size can quickly become enormous due to all the stored polygon points. You can reduce the number of polygon points stored by: |
If you will be generating millions of identical shapes (eg. repeating array of circles), the file size can quickly become enormous due to all the stored polygon points. You can reduce the number of polygon points stored by: |
||
# |
#Reduce the number of points in each shape/circle if possible. Gentle corners will be rounded by the lithography resolution. |
||
# |
#Use Cell instancing so that only one, or a few, polygons are defined, and that same polygon is then only referenced as a repeating Cell instance. (See above for tutorials). |
||
# |
#The OAS file type generates much smaller files, and most photomask vendors can accept this. Photomask vendors are used to handling large files. |
||
# |
#Photomask vendors are able to take multiple files and insert them into the final reticle – you just need to provide a clear schematic showing the exact insertion coordinates for each file (with respect to the origin of each file). They can also do some boolean operations (for a fee). |
||
''[[Demis D. John]], updated 2022-09'' |
Latest revision as of 15:57, 1 May 2024
Turn on Editing Mode
By default, KLayout might open as a "viewer" only, without draw-mode capbilities (no square/polygon/text buttons in the toolbar) and only ruler/zoom tools. Enable Editing mode as so:
- Preferences > Editing mode > [√] Use Editing Mode by default, and restart the software.
Turn on the display of the Origin (0,0)
- Preferences > Display > Background > Axis = change from the default "invisible", eg. "Lines".
Minimum Step-Size / Database Unit
- The default minimum unit of 0.001 µm (1nm) is usually fine. Don't change this after drawing - all polygons will be scaled accordingly. If you need finer resolution: Before starting your design, set the Layout Properties > Database Unit to something smaller, eg. 0.0001 µm.
How to draw circles
- You have to draw a square, and then apply the function Edit > Selection > Convert to PCell > Basic.CIRCLE. (A P-Cell is a Cell with parameters - like a programmer's "function" with "arguments" of sorts.)
- Sometimes these P-Cells don't convert properly at the photomask vendor, so make sure to run Edit > Selection > Convert to Static Cell or Edit > Layout > Convert All Cells to Static before sending to the vendor/machine, which converts to a regular polygon in a Cell. (You lose editing capabilities of the P-Cell when you do this.)
- Another way is to convert a square to a polygon directly with Edit>Selection>Round Corners function with Outer Corner Radius = the desired circle radius (radius is not changeable afterards in this method, but computation may be faster for a large number of objects).
- Klayout doesn't natively support circles because the GDS file format does not have a "circle" primitive built-in, so instead it creates a polygon. Make sure you include enough polygon points, eg. 32. See the forum help pages on this for more info.
How to draw Text
A common mistake is to use the “Text” tool to draw text that you want to get printed on the mask plate.
Only Polygons will get printed on the final mask plate. To print text, you have to convert the Text tool objects into polygons as so:
- Use the Text Tool to place some text. These text objects are useful for comments/labels on a layout that won’t get printed.
- select the text object
- Use the function Edit > Selection > Convert to PCell
- by default the PCell “BASIC.TEXT” should be selected.
- Select the object again if needed, and view the object’s Properties (Edit > Properties)
- Here you can adjust the Size via the “Magnification” parameter, the text string, and other useful properties.
Note that the default font has enclosed spaces, which is sometimes non-optimal for lift-off processes. See this hint for installing a Vented Font.
Cells & Instances of Cells
It is highly recommended that you understand and use the concept of "Cells" & "Instances" in your design. This is critical for direct-write machines (EBL, MLA, Mask-writing vendors), and if used properly, helps tremendously with programming the Stepper lithography machines. This functionality also circumvents many problems with enormous file sizes (due to huge numbers of identical polygons), by "pointing" to the same polygon only defined once in the file. Links to documentation below:
- Create a new cell, and instancing that cell: KLayout Docs : Creating a Cell instance
- Viewing only some levels of the Cell heirarchy, to prevent drawing all objects: KLayout Docs: Viewing Cell Heirarchy
- Video Tutorials: QNFCF: KLayout Cell Hierarchy Part 1 & QNFCF: KLayout Cell Hierarchy Part 2
File Types
OASIS format is the successor to the GDS format, and is the preferred format, except that some software (eg. Heidelberg) doesn't yet accept it. All Photomask vendors accept OASIS format. OASIS files tend to be much smaller than GDS files, and they also save the Layer Names (not just Layer Number). All Photomask manufacturers accept this file type. KLayout can convert between OASIS and GDS without issue (except that GDS loses the layer names). See this article for more info.
GDS files are considered "standard", but are somewhat antiquated, lose the text names of layers between saves and can be 1000x larger file size than OASIS. The Heidelberg software (MLA150) only accepts GDS as the preferred format, not OASIS.
Alternatively, in KLayout the function File > Save Session will save the entire view including layer styles and window/zoom locations will be saved. You can share this file, as the entire design file is embedded within it, but it may not be as robust between KLayout versions.
DXF files coming from AutoCAD often are missing the "units", and may erroneously map millimeters to meters, causing your design to be scaled 1000x too large. You can fix this in File > Reader Options > DXF, or simply instance the entire design into a new Cell with Magnification set to correct the scaling error. Also, AutoCAD allows for non-closed polygons, which are invalid shapes (even though the start/end points lie on top of each other, the shape is not technically "closed" unless you use polyline-edit "PEDIT" and intentionally Close them). The DXF Reader has some options to catch/fix these.
Non-Orthogonal Arrays
Arrays created with diagonal instancing (non-orthogonal arrays) can be incompatible with photomask vendor's mask writing software.
We recommend you avoid the grey X and Y fields shown below when creating arrays, as shown here:
If you do need to use a non-orthogonal array, make sure to use Selection > Resolve Arrays before submitting your design to the manufacturer/machine.
Handling very large files
If you will be generating millions of identical shapes (eg. repeating array of circles), the file size can quickly become enormous due to all the stored polygon points. You can reduce the number of polygon points stored by:
- Reduce the number of points in each shape/circle if possible. Gentle corners will be rounded by the lithography resolution.
- Use Cell instancing so that only one, or a few, polygons are defined, and that same polygon is then only referenced as a repeating Cell instance. (See above for tutorials).
- The OAS file type generates much smaller files, and most photomask vendors can accept this. Photomask vendors are used to handling large files.
- Photomask vendors are able to take multiple files and insert them into the final reticle – you just need to provide a clear schematic showing the exact insertion coordinates for each file (with respect to the origin of each file). They can also do some boolean operations (for a fee).
Demis D. John, updated 2022-09