Cells and instances · 1 of 4
Instances
A cell is a reusable piece of layout. Placing a cell inside another cell creates an instance of it: the same geometry, drawn again somewhere else. In the GDSII output an instance is only a reference, so a cell placed a thousand times is still stored once.
cell Pad {
layer metal {
shape rect with 80um, 80um as body
place body at self.origin
}
}
cell Pair {
place Pad at (0, 0)
place Pad at (100um, 0)
}Cells are placed outside layer blocks: directly in the cell, as above, or in a place { } block. Inside such a block the word place can be left out, which keeps long lists short:
place {
Pad at (0, 0)
Pad at (100um, 0)
}Like a shape, a cell is placed by its origin here: Pad means Pad.origin. The next chapter shows the other anchors a cell can have. as names an instance — Pad at (0, 0) as left — so that other placements can refer to it.
A cell that no other cell places is a top cell. The preview shows the largest one.
Exercise
Fill PadRow with three pads at x = 0, 100 µm and 200 µm (y = 0), placed in a place { } block.