Home Forums Nazca Specify gds layer number, and draw objects on the different gds layer numbers Reply To: Specify gds layer number, and draw objects on the different gds layer numbers

#6564
Xaveer
Moderator

Dear Cameron,

To start with the second question: what you see is the effect of the way “cross sections” are implemented.

This is done to have a single structure write all relevant layers, typically of a waveguide.

In demofab this is done for (in your example) the “Shallow” cross section. You can find the cross sections by calling nd.show_xsections().

You can see which layers are part of the cross sections by calling nd.show_xsection_layer_map(), which shows indeed that there are two layers: “Shallow” and “ShallowTrench” that get drawn, where the second is 8 microns wider than the first. The first is as wide as the specified width of the waveguide.

How to work with cross sections is explained in tutorial https://nazca-design.org/xsections_and_layers/ and https://nazca-design.org/implement-a-cross-section/

To make use of this, a post-processing step may be needed in order to subtract one structure from the other. This is efficiently done in KLayout. See my answer to this post for some explanation: https://nazca-design.org/forums/topic/creating-priority-rule-for-overlapping-layers-in-specific-regions/

The answer to your first question is related: you can specify an absolute or relative “grow” in x and y to achieve what you want. This example will use an absolute grow.

import nazca as nd

nd.add_layer(name="Main", layer=(1, 0), accuracy=0.001)
nd.add_layer(name="Grow1", layer=(2, 0), accuracy=0.1)
nd.add_layer(name="Grow2", layer=(3, 0), accuracy=0.1)

nd.add_layer2xsection("Myxs", layer="Main")
nd.add_layer2xsection("Myxs", layer="Grow1", growx=2, growy=2)
nd.add_layer2xsection("Myxs", layer="Grow2", growx=4, growy=4)

nd.strt(xs='Myxs', width=10, length=20).put()

nd.export_gds()

Xaveer