Edit PCB Rule

Modified by Susan Riege on Aug 3, 2017

An example of the Edit PCB Rule dialog (displaying Clearance Rule)

Summary

The Edit PCB Rule dialog allows you to edit the properties of the selected design rule, including the name, scope, and constraints.

The controls offered by the dialog and its banner text will vary depending on the type of design rule being edited.
For more information about PCB Design Rules, click here.

Access

The dialog is accessed from within the PCB Editor in the following ways:

Options/Controls

  • Name - the current name of the rule. This can be changed as required.
  • Comment - this field displays any comment added for the rule, for example, a meaningful description of what the rule is being used for.
  • Unique ID - the unique identifier for the rule. Every rule is itself a design object, and therefore, a tangible piece of data. The use of an ID ensures uniqueness. Where the Unique ID really comes into play, however, is for a rule that has been created within the schematic domain. When adding design rule parameters to objects on a schematic, a unique ID is given to each rule parameter. The same IDs are given to the corresponding design rules that are created in the PCB. With this Unique ID, the constraints of a rule can be edited on either the schematic or PCB side and the changes pushed through upon synchronization.
  • Test Queries - click to open the Test Queries Result dialog that displays the number of objects affected by the selected rule, taking into account any defined rule specializations. This allows you to see if any objects match the query and check if those objects affected by the filters and rules are the desired result of your search terms.

Rule Scoping Controls

When defining the scope of a design rule - the extent of its application - you are essentially building a query to define the member objects that are governed by the rule. Use the options available in the dialog to build the query required. Depending on whether the rule is unary or binary, you will need to define one or two scopes, respectively.

For a unary design rule, controls will be provided to define a single rule scope (Where the Object Matches). Use the options available in the Where The First Object Matches region to help build the query expression, which will be presented in the region to the right. For a binary design rule, controls also will be provided to define a second rule scope. Use the options available in the Where The Second Object Matches region to help build the query expression, which will be presented in the region to the right.

Controls are identical, whether defining one or two rule scopes and are detailed in the following sections.

Where The Object Matches

  • Scoping Option - use the drop-down to select one of the following options to determine how to generate the scoping query expression:
    • All - choose this option to generate a scope query that targets all design objects. The expression All will be loaded into the associated Full Query region on the right.
    • Net - choose this option to generate a scope query that targets all objects in a specific net. Choose the required net from the top drop-down field. The expression loaded into the associated Full Query region on the right will be in the format InNet('<NetName>').
    • Net Class - choose this option to generate a scope query that targets all objects in a specific net class. Choose the required net class from the top drop-down field. The expression loaded into the associated Full Query region on the right will be in the format InNetClass('<NetClassName>').
    • Layer - choose this option to generate a scope query that targets all objects on a specific layer. Choose the required layer from the top drop-down field. The expression loaded into the associated Full Query region on the right will be in the format OnLayer('<LayerName>').
    • Net and Layer - choose this option to generate a scope query that targets all objects in a specific net and on a specific layer. Choose the required net from the top drop-down field and the required layer from the bottom drop-down field. The expression loaded into the associated Full Query region on the right will be in the format InNet('<NetName>') And OnLayer('<LayerName>').
When using the NetNet and Layer, Net Class, or Layer options, the field will populate with all defined nets in the design, all defined net classes in the design, or all currently enabled layers in the design, respectively. Use the drop-downs to choose the required target.
When using the Net and Layer option, the field will populate with all currently enabled layers in the design. Use the drop-downs to select the required layer.
  • Custom Query - choose this option to be able to write your own, more complex, but also more specific query. Use the drop-downs to build the query.
  • Query Helper - this button becomes available when the Custom Query option is chosen. Click to access the Query Helper dialog. The underlying query engine analyzes the PCB design and lists all available objects, along with generic keywords for use in queries. The resulting query appears in the region to the right.
  • Query Builder - this button becomes available when the Custom Query option is chosen. Click to open the Building Query from Board dialog, which enables you to create a query for targeting specific objects in the design document by simple construction of a string of AND'ed and/or OR'ed conditions. The resulting query appears in the region to the right.
Alternatively, and if you are conversant with the Query Language, you can enter a query expression directly in the region to the right.

You also can paste a query expression from your favorite editor directly into the region. You also can copy an expression, perhaps to work on it in an external editor, or even to paste into the second scope of a binary rule - especially useful if the two scopes are complex, but differ only slightly.
The Query Builder is a simpler method of constructing a query, using sensitive condition types and values that only allow the designer to build using relevant 'building blocks'. For advanced query construction, with full keyword specification and operator syntax, use the Query Helper.

Constraints

This region of the dialog presents the constraints applicable to the type of rule being edited. The controls vary depending upon the type of design rule being edited. Use the various controls to configure these constraints as required.

Diagram

Controls highlighted in blue can be clicked on and edited, if desired. Enable any of the various options provided, if desired.

Grid

Click on a cell to edit the data, as required.

Query Expression Operator Precedence

Brackets have the highest precedence within an order of precedence that has been defined for the various operators and that determines how queries are interpreted by the software (whenever you have not provided brackets). The sequence of this order is as follows:

Brackets
Not
^, *, /, Div, Mod, And
+, -, Or, Xor
=, <>, <, >, <=, >=
&&, ||

This order of precedence is similar to that used in Pascal type languages. Ambiguities are resolved by working from left to right. Parentheses are evaluated from inside to outside and equal levels are evaluated left to right.

It is highly advisable to use brackets whenever there is any possibility that the query might not be correctly interpreted. Generous usage of brackets removes doubt and makes the resulting queries easier to read by others.
Found an issue with this document? Highlight the area, then use Ctrl+Enter to report it.

Contact Us

Contact our corporate or local offices directly.

You are reporting an issue with the following selected text
and/or image within the active document:
ALTIUM DESIGNER FREE TRIAL
Altium Designer Free Trial
Let’s get started. First off, are you or your organization already using Altium Designer?

If would like to speak with a representative, please contact your local Altium office.
Copyright © 2019 Altium Limited

In that case, why do you need an evaluation license?

If would like to speak with a representative, please contact your local Altium office.
Copyright © 2019 Altium Limited

Got it. You actually don’t need an evaluation license for that.

Click the button below to download the latest Altium Designer installer.

Download Altium Designer Installer

If would like to speak with a representative, please contact your local Altium office.
Copyright © 2019 Altium Limited

Please fill out the form below to get a quote for a new seat of Altium Designer.

By clicking “Get Your Free Trial”, you are agreeing to our Privacy Policy.
You may receive communications from Altium and can change your notification preferences at any time.

If you are on Altium Subscription, you don’t need an evaluation license.

If you are not an active Altium Subscription member, please fill out the form below to get your free trial.

By clicking “Get Your Free Trial”, you are agreeing to our Privacy Policy.
You may receive communications from Altium and can change your notification preferences at any time.

Why are you looking to evaluate Altium Designer?

If would like to speak with a representative, please contact your local Altium office.
Copyright © 2019 Altium Limited

You came to the right place! Please fill out the form below to get your free trial started.

By clicking “Get Your Free Trial”, you are agreeing to our Privacy Policy.
You may receive communications from Altium and can change your notification preferences at any time.

Sounds exciting! Did you know we offer special discounted student licenses? For more information, click here.

In the meantime, feel free to request a free trial by filling out the form below.

By clicking “Get Your Free Trial”, you are agreeing to our Privacy Policy.
You may receive communications from Altium and can change your notification preferences at any time.

Got it. You can download a free Altium Designer Viewer license which is valid for a 6 months.

Please fill out the form below to request one.

By clicking “Get Your Free Trial”, you are agreeing to our Privacy Policy.
You may receive communications from Altium and can change your notification preferences at any time.

That’s great! Making things is awesome. We have the perfect program for you.

Upverter is a free community-driven platform designed specifically to meet the needs of makers like you.

Click here to give it a try!

If would like to speak with a representative, please contact your local Altium office.
Copyright © 2019 Altium Limited

Got it. You can download a free Altium Designer Viewer license which is valid for a 6 months.

Please fill out the form below to request one.

By clicking “Get Your Free Trial”, you are agreeing to our Privacy Policy.
You may receive communications from Altium and can change your notification preferences at any time.