### Constraints

| Constraint type           | Argument type                                                                                                         | Description                                                                                                                                                                                                                                                                                                                                                                                                                                             |
|---------------------------|-----------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `annular_width`           | min/max                                                                                                               | Checks the width of annular rings on vias.<br>                                                                                                                                                                                                                                                                                                                                                                                                          |
| `assertion`               | "&lt;expression>"                                                                                                     | Checks the given expression.<br>                                                                                                                                                                                                                                                                                                                                                                                                                        |
| `bridged_mask`            |                                                                                                                       | Checks for solder mask bridges between copper items.  This constraint does not take a min/opt/max value.  In combination with a severity clause, this constraint can be used to allow or disallow solder mask bridging in various conditions.<br>                                                                                                                                                                                                       |
| `clearance`               | min                                                                                                                   | Specifies the **electrical** clearance between copper objects of different nets.  (See `physical_clearance` if you wish to specify clearance between objects regardless of net.)<br><br>To allow copper objects to overlap (collide), create a `clearance` constraint with the `min` value less than zero (for example, `-1`).<br>                                                                                                                      |
| `connection_width`        | min                                                                                                                   | Checks the width of connections between pads and zones.  An error will be generated for each pad connection that is narrower than the `min` value.<br>                                                                                                                                                                                  |
| `courtyard_clearance`     | min                                                                                                                   | Checks the clearance between footprint courtyards and generates an error if any two courtyards are closer than the `min` distance.  If a footprint does not have a courtyard shape, no errors will be generated from this constraint.<br>                                                                                                                                                                                                               |
| `creepage`                | min                                                                                                                   | Specifies the creepage distance between copper objects of different nets.<br>                                                                                                                                                                                                                                                                                                                                                                           |
| `diff_pair_gap`           | min/opt/max                                                                                                           | Checks the gap between parallel tracks in a differential pair.  The `opt` setting is used by the interactive router for placing new differential pairs.  An error will be generated if the spacing between tracks in a differential pair is outside of the `min` and `max` settings.  Differential pair gap is not tested on non-parallel portions of a differential pair (for example, the fanout from a component).<br>                                                                                                                                                                                                                                                                       |
| `diff_pair_uncoupled`     | max                                                                                                                   | Checks the distance that a differential pair track is routed uncoupled from the other polarity track in the pair (for example, where the pair fans out from a component, or becomes uncoupled to pass around another object such as a via).<br>                                                                                                                                                                                                         |
| `disallow`                | `track`<br>`via`<br>`through_via`<br>`blind_via`<br>`buried_via`<br>`micro_via`<br>`pad`<br>`zone`<br>`text`<br>`graphic`<br>`hole`<br>`footprint`<br> | Specify one or more object types to disallow, separated by spaces.  For example, `(constraint disallow track)` or `(constraint disallow track via pad)`.  If an object of this type matches the rule condition, a DRC error will be created.<br><br>This constraint is essentially the same as a keepout rule area, but can be used to create more specific keepout restrictions.<br>                                  |
| `edge_clearance`          | min                                                                                                                   | Checks the clearance between objects and the board edge.<br><br>This can also be thought of as the "milling tolerance" as the board edge will include all graphical items on the `Edge.Cuts` layer as well as any *oval* pad holes.  (See `physical_hole_clearance` for the drilling tolerance.)<br>                                                                                                                                                    |
| `hole_clearance`          | min                                                                                                                   | Checks the clearance between a drilled hole in a pad or via and copper objects on a different net.  The clearance is measured from the diameter of the hole, not its center.<br>                                                                                                                                                                                                                                                                        |
| `hole_size`               | min/opt/max                                                                                                           | Checks the size (diameter) of a drilled hole in a pad or via.  For oval holes, the smaller (minor) diameter will be tested against the `min` value (if specified) and the larger (major) diameter will be tested against the `max` value (if specified).  The `opt` value is used by the interactive router as the default via hole size for nets that match the rule condition.<br>                                                                    |
| `hole_to_hole`            | min                                                                                                                   | Checks the clearance between mechanically-drilled holes in pads and vias.  The clearance is measured between the diameters of the holes, not between their centers.<br><br>This constraint is soley for the protection of drill bits.  The clearance between **laser-drilled** (microvias) and other non-mechanically-drilled holes is not checked, nor is the clearance between **milled** (oval-shaped) and other non-mechanically-drilled holes.<br> |
| `length`                  | min/opt/max                                                                                                           | Checks the total routed length for the nets that match the rule condition and generates an error for each net that is below the `min` value (if specified) or above the `max` value (if specified) of the constraint.<br>The `opt` value sets a target length that is used by the length tuning tool for any nets that match the rule condition.<br>                                                                                                    |
| `min_resolved_spokes`     | `0`<br>`1`<br>`2`<br>`3`<br>`4`<br>                                                                                   | Checks the total number of connections (spokes) to a pad.  An error will be raised for each pad that has fewer than the specified number of spokes.<br>                                                                                                                                                                                 |
| `physical_clearance`      | min                                                                                                                   | Checks the clearance between two objects on a given layer (including non-copper layers).<br><br>While this can perform more general-purpose checks than `clearance`, it is much slower.  Use `clearance` where possible.<br>                                                                                                                                                                                                                            |
| `physical_hole_clearance` | min                                                                                                                   | Checks the clearance between a drilled hole in a pad or via and another object, regardless of net. The clearance is measured from the diameter of the hole, not its center.<br><br>This can also be thought of as the "drilling tolerance" as it only includes **round** holes (see `edge_clearance` for the milling tolerance).<br>                                                                                                                    |
| `silk_clearance`          | min                                                                                                                   | Checks the clearance between objects on silkscreen layers and other objects.<br>                                                                                                                                                                                                                                                                                                                                                                        |
| `skew`                    | min/opt/max/within\_diff\_pairs                                                                                       | Checks the total skew for the nets that match the rule condition, that is, the difference between the length of each net and the longest net that is matched by the rule.  If the difference between the longest net and any one net is above the constraint `max` value, an error will be generated.<br>This constraint also sets a target skew that is used by the skew tuning tool for any nets that match the rule condition.  The target skew is the `opt` value, if specified, or the `min` value if not.  If neither `min` nor `opt` are specified, the target skew is `0`.<br>If the option `within_diff_pairs` is specified, the skew will be tested separately for every differential pair in the nets matching the rule.  If `within_diff_pairs` is not specified, the skew will be tested for all matching nets (e.g. for skew tuning a bus).<br>                                                          |
| `solder_mask_expansion`   | opt                                                                                                                   | Specifies the solder mask expansion for pads, shapes and tracks.                                                                                                                                                                                                                                                                                                                                                                                        |
| `solder_paste_abs_margin` | opt                                                                                                                   | Specifies the absolute solder paste clearance for pads.  Usually negative to inset the paste.<br><br>The final solder paste clearance will be the absolute clearance plus the relative clearance.                                                                                                                                                                                                                                                        |
| `solder_paste_rel_margin` | opt                                                                                                                   | Specifies the relative solder paste clearance for pads.  Usually negative to inset the paste.<br><br>The final solder paste clearance will be the absolute clearance plus the relative clearance.                                                                                                                                                                                                                                                        |
| `text_height`             | min/max                                                                                                               | Checks the height of text, including text boxes.  An error will be generated for each text item that has a height below the `min` value (if specified) or above the `max` value (if specified).<br>                                                                                                                                                                                                                                                     |
| `text_thickness`          | min/max                                                                                                               | Checks the thickness of text, including text boxes.  An error will be generated for each text item that has a thickness below the `min` value (if specified) or above the `max` value (if specified).<br>                                                                                                                                                                                                                                               |
| `thermal_relief_gap`      | min                                                                                                                   | Specifies the width of the gap between a pad and a zone with a thermal-relief connection.<br>                                                                                                                                                                                                                                                                                                                                                           |
| `thermal_spoke_width`     | opt                                                                                                                   | Specifies the width of the spokes connecting a pad to a zone with a thermal-relief connection.<br>                                                                                                                                                                                                                                                                                                                                                      |
| `track_angle`             | min/max                                                                                                               | Checks the angle between two connected track segments.  An error will be generated for each connected pair with an angle below the `min` value (if specified) or above the `max` value (if specified).<br>                                                                                                                                                                                                                                              |
| `track_segment_length`    | min/max                                                                                                               | Checks the length of track and arc segments.  An error will be generated for each segment that has a length below the `min` value (if specified) or above the `max` value (if specified).<br>                                                                                                                                                                                                                                                           |
| `track_width`             | min/opt/max                                                                                                           | Checks the width of track and arc segments.  An error will be generated for each segment that has a width below the `min` value (if specified) or above the `max` value (if specified).  The `opt` value is used by the interactive router as the default track width for nets that match the rule condition.<br>                                                                                                                                       |
| `via_count`               | min/max                                                                                                               | Counts the number of vias on every net matched by the rule condition.  An error will be generated for each net that has fewer vias than the `min` value (if specified) or more than the `max` value (if specified).<br>                                                                                                                                                                                                                                 |
| `via_dangling`            |                                                                                                                       | Checks for vias that are unconnected or connected on only one layer.  This constraint does not take a min/opt/max value.  In combination with a severity clause, this constraint can be used to allow or disallow dangling vias in various conditions.<br>                                                                                                                                                                                              |
| `via_diameter`            | min/opt/max                                                                                                           | Checks the diameter of vias.  An error will be generated for each via that has a diameter below the `min` value (if specified) or above the `max` value (if specified).  The `opt` value is used by the interactive router as the default via diameter for nets that match the rule condition.<br>                                                                                                                                                      |
| `zone_connection`         | `solid`<br>`thermal_reliefs`<br>`none`                                                                                | Specifies the connection to be made between a zone and a pad.<br>                                                                                                                                                                                                                                                                                                                                                                                       |


