From 33377df88312f7e74b3e8b80dfab1cc0525387ab Mon Sep 17 00:00:00 2001 From: Jan Petykiewicz Date: Sat, 7 Oct 2023 01:38:13 -0700 Subject: [PATCH] add notes about ports --- README.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/README.md b/README.md index 0ab5897..d346810 100644 --- a/README.md +++ b/README.md @@ -61,6 +61,14 @@ Each `Pattern` can contain `Ref`s pointing at other patterns, `Shape`s, and `Lab * 1 earth radii in nanometers (6e15) is still represented without approximation (53 bit mantissa -> 2^53 > 9e15) * Operations that would otherwise clip/round on are still represented approximately. * Memory usage is usually dominated by other Python overhead. +- `Pattern` objects also contain `Port` information, which can be used to "snap" together + multiple sub-components by matching up the requested port offsets and rotations. + * Port rotations are defined as counter-clockwise angles from the +x axis. + * Ports point into the interior of their associated device. + * Port rotations may be `None` in the case of non-oriented ports. + * Ports have a `ptype` string which is compared in order to catch mismatched connections at build time. + * Ports can be exported into/imported from `Label`s stored directly in the layout, + editable from standard tools (e.g. KLayout). A default format is provided. ## Glossary