Markers and ports · 1 of 4
Markers
A marker names one or more points of a cell — its ports, a reference point, the position of a light source — without drawing anything on the chip:
cell Taper {
...
marker {
input { at t.start with type = "waveguide", direction = "input", width = 3um }
output { at t.end with type = "waveguide", direction = "output", width = 500nm }
}
}Each entry has a name, which shares the cell's names with its shapes and instances: a marker input and a shape input cannot live in the same cell. at gives the position — any point or anchor, even of a shape defined further down — and with attaches attributes, as many as needed. A few attribute names have a meaning:
| Attribute | Meaning |
|---|---|
kind | "port", the default, or anything else, such as "light_source"; only ports take part in connections |
type | the kind of port: "waveguide", "pad", … |
direction | "input" or "output" |
width | the width of the port |
In GDSII, markers are text labels on the marker layer (255/0 unless the layer table says otherwise), and the preview shows them as labels. From outside the cell, a marker is read through an instance: wg.marker.output[0] is the position of the output port of the instance wg.
Exercise
Give Waveguide two ports: input at the left end and output at the right end of core, both with type = "waveguide", the matching direction and width = width.