Design Constraint Setup: Complete Guide to Specs, Rules, and Troubleshooting

Quick Answer (30 seconds)

Correct design constraint setup is the foundation of a manufacturable and functional Printed Circuit Board (PCB). It involves configuring the Design Rule Check (DRC) system in your EDA software to match the physical capabilities of the fabrication house and the electrical requirements of the circuit.

  • Physical Constraints: Define minimum trace widths, clearances, and via sizes to prevent shorts and opens during etching and plating.
  • Electrical Constraints: Set impedance profiles, differential pair gaps, and length matching for high-speed signal integrity.
  • Manufacturing Limits: Align settings with the specific capabilities of your manufacturer (e.g., APTPCB (APTPCB PCB Factory)) to avoid production holds.
  • Validation: Always run a full DRC and DFM check before generating Gerber files.
  • File Management: Save your configuration as a template (design rule file setup) to standardize future projects.

When design constraint setup applies (and when it doesn’t)

Establishing a robust constraint set is critical for most professional workflows, but understanding when to apply strict rules versus when to use relaxed defaults saves time.

When strict design constraint setup is required:

  • High-Speed Digital Design: Interfaces like DDR, PCIe, or USB require precise impedance and length matching rules.
  • HDI (High Density Interconnect): Designs utilizing microvias, blind/buried vias, or fine pitch BGAs (< 0.5mm) need tight physical constraints.
  • High Voltage/Power: Safety standards (UL/IEC) dictate specific creepage and clearance rules that must be enforced via constraints.
  • Mass Production: When moving from prototype to volume with APTPCB, constraints must match the statistical process control (SPC) limits to ensure high yield.
  • Rigid-Flex PCBs: These require unique constraints for the bend radius and transition zones to prevent mechanical failure.

When complex setup may be unnecessary:

  • Simple Breakout Boards: A 2-layer board connecting a connector to headers often works fine with default "conservative" rules (e.g., 10 mil trace/space).
  • Schematic-Only Simulation: If you are only simulating logic or analog behavior in SPICE without layout, physical layout constraints do not apply.
  • Mechanical Drafting: Creating a non-electrical dummy card for fit checks requires mechanical dimensions but ignores electrical clearance rules.
  • Rough Prototyping (Breadboarding): Hand-wired prototypes do not utilize EDA constraint managers.

Rules & specifications

Rules & specifications

The following table outlines the critical parameters required for a complete design constraint setup. These values represent standard industry capabilities. Tighter values are possible but may increase cost.

Rule Category Recommended Value/Range Why it matters How to verify If ignored
Min Trace Width 0.075mm - 0.127mm (3-5 mil) Ensures the etchant does not over-etch the copper, causing open circuits. DRC: Width Constraint Broken traces (opens) or high resistance.
Min Clearance (Gap) 0.075mm - 0.127mm (3-5 mil) Prevents copper features from bridging together during manufacturing. DRC: Clearance Constraint Short circuits between nets.
Min Via Hole Size 0.2mm - 0.3mm (8-12 mil) Mechanical drills have a limit before breakage becomes frequent; smaller requires laser drilling. DRC: Hole Size Drill bit breakage or missed plating.
Annular Ring 0.1mm - 0.15mm (4-6 mil) Ensures the drill hole remains fully enclosed by copper pad despite alignment tolerance. DFM Check / DRC Breakout (drill hitting edge of pad), open connection.
Solder Mask Expansion 0.05mm - 0.075mm (2-3 mil) Accounts for mask alignment shift so mask doesn't cover the solderable pad. Gerber Viewer Inspection Poor soldering, mask on pad (solder skip).
Impedance Tolerance ±10% (Standard) Matches the transmission line to the source/load to prevent signal reflection. Impedance Calculator Signal integrity loss, data corruption.
Differential Pair Gap Calculated (e.g., 4-8 mil) Determines the differential impedance and common-mode noise rejection. DRC: Diff Pair Rule EMI issues, timing skew, signal loss.
Copper to Board Edge 0.3mm - 0.5mm (12-20 mil) Prevents copper from being exposed or burred during routing/V-scoring. DRC: Board Outline Clearance Shorts to chassis, corrosion, peeling copper.
Solder Mask Dam 0.1mm (4 mil) min Prevents solder bridging between adjacent pads (especially fine-pitch ICs). DFM Analysis Solder bridges (shorts) during assembly.
Drill to Copper 0.2mm - 0.25mm (8-10 mil) Prevents the drill from accidentally hitting an internal layer trace. DRC: Hole to Copper Internal shorts (very hard to debug).
Paste Mask Expansion 1:1 or -10% reduction Controls the volume of solder paste deposited on the pad. Assembly Drawing Check Solder bridging (too much) or dry joints (too little).
Thermal Relief Width 0.2mm - 0.3mm Balances current carrying capacity with solderability (heat isolation). Visual / Power Plane Check Cold solder joints (cannot heat pad) or overheating.

Implementation steps

Implementation steps

Setting up constraints is a sequential process. Jumping straight to routing without this foundation leads to massive rework.

Step 1: Gather Manufacturer Capabilities Before opening the software, obtain the capability sheet from your fabricator.

  • Action: Download the "Standard" and "Advanced" capability lists.
  • Key Parameter: Minimum trace/space and minimum drill size.
  • Acceptance Check: Confirm if your design requires "Advanced" (higher cost) or fits "Standard."

Step 2: Define the Layer Stackup Constraints rely on the physical distance between layers.

  • Action: Input the layer count, copper weight, and dielectric thickness into the EDA stackup manager.
  • Key Parameter: Dielectric constant (Dk) and thickness.
  • Acceptance Check: Verify total board thickness matches the mechanical enclosure requirements.

Step 3: Create Net Classes Group signals with similar requirements to apply rules efficiently.

  • Action: Create classes for "Power," "Ground," "RF," "Diff_Pairs," and "Default."
  • Key Parameter: Class membership list.
  • Acceptance Check: Ensure high-voltage nets are separated from sensitive low-voltage analog nets.

Step 4: Configure Physical Rules (The design rule file setup) Apply the manufacturing limits to the net classes.

  • Action: Set minimum width, clearance, and via styles for each class.
  • Key Parameter: 0.1mm (4 mil) for HDI, 0.15mm (6 mil) for standard.
  • Acceptance Check: The software should prevent you from routing a trace smaller than the limit.

Step 5: Configure Electrical Rules Set up the constraints for signal integrity.

  • Action: Define impedance profiles (e.g., 50Ω single-ended, 100Ω differential) and assign them to specific layers.
  • Key Parameter: Trace width per layer for target impedance.
  • Acceptance Check: Use the built-in calculator to confirm width achieves target impedance within ±10%.

Step 6: Set Mechanical and DFM Rules Define constraints for non-electrical features.

  • Action: Set clearances for mounting holes, board edges, and component bodies (Courtyards).
  • Key Parameter: Component body clearance (usually 0.25mm).
  • Acceptance Check: Ensure no components overlap or hang over the board edge unless intended.

Step 7: Run a Baseline DRC Test the setup before routing.

  • Action: Run a Design Rule Check on the unrouted board (checking placement).
  • Key Parameter: 0 Errors (or only expected "unrouted" errors).
  • Acceptance Check: Resolve any component placement violations immediately.

Step 8: Save and Template Don't repeat this work.

  • Action: Export the rules to a file.
  • Key Parameter: .rul, .dru, or .cns file extension.
  • Acceptance Check: Import this file into a blank project to verify settings transfer correctly.

Failure modes & troubleshooting

Even with a careful design constraint setup, errors occur. This section maps common symptoms to their root causes in the constraint logic.

1. Symptom: Massive number of "Clearance Violation" errors.

  • Cause: The global default clearance is set tighter than the footprint pad spacing.
  • Check: Look at the "Default" rule vs. the specific "Component" rule.
  • Fix: Create a specific rule for fine-pitch components (e.g., BGA or QFN) that allows a smaller gap (e.g., 3.5 mil) only within that area (Room-based rule).
  • Prevention: Use "Rooms" or "Areas" in your EDA tool to apply tighter rules only where necessary.

2. Symptom: Impedance discontinuity warnings.

  • Cause: Trace width changes when moving between layers, but the constraint didn't account for different dielectric thicknesses.
  • Check: Review the impedance profile for each layer in the stackup manager.
  • Fix: Ensure the constraint manager assigns a specific width for Layer 1 (e.g., 5 mil) and Layer 3 (e.g., 4.5 mil) to maintain 50Ω.
  • Prevention: Use impedance-driven width rules rather than fixed width rules.

3. Symptom: Unroutable board (cannot complete connections).

  • Cause: Constraints are too conservative (e.g., requiring 10 mil spacing on a dense board).
  • Check: Compare board density (nets per sq inch) against the design rules.
  • Fix: Switch to "Advanced" manufacturing capabilities (e.g., drop to 4 mil trace/space) after confirming cost with APTPCB.
  • Prevention: Perform a feasibility study on component density before setting rules.

4. Symptom: "Antenna" or "Starved Thermal" violations.

  • Cause: Thermal relief spokes are too thin or the plane connection is too restrictive.
  • Check: Inspect the thermal relief rules for power vias.
  • Fix: Increase the spoke width or reduce the required number of spokes from 4 to 2 for dense areas.
  • Prevention: Set specific thermal rules for high-current vias vs. signal vias.

5. Symptom: Board fails mechanical fit or drop testing.

  • Cause: Component placement constraints ignored stress zones.
  • Check: Review drop test setup requirements; heavy components placed too close to the center or V-score lines.
  • Fix: Add a "Keep-Out" constraint for heavy components near board edges or mounting holes.
  • Prevention: Import the mechanical enclosure (STEP file) into the PCB tool and set 3D clearance rules.

6. Symptom: Manufacturing Hold (EQ) regarding Annular Rings.

  • Cause: The design constraint setup used "nominal" values without accounting for drill tolerance.
  • Check: Verify if the rule is Pad Diameter - Drill Diameter >= 2 * Min Annular Ring.
  • Fix: Increase pad size or decrease drill size in the library/rules.
  • Prevention: Always add 0.1mm to the drill size to determine the minimum pad size.

7. Symptom: Differential Pair Phase Mismatch.

  • Cause: The constraint checked for total length but not "static phase" within the pair.
  • Check: Look for "Phase Tolerance" in the differential pair rules.
  • Fix: Add phase tuning bumps (serpentine routing) at the point of mismatch, not just at the end.
  • Prevention: Enable "Online DRC" for differential pairs to see phase errors while routing.

8. Symptom: Solder Mask Slivers.

  • Cause: The gap between pads is barely larger than the mask expansion, leaving a tiny, unmanufacturable strip of mask.
  • Check: Calculate Pad Gap - (2 * Mask Expansion).
  • Fix: If the resulting sliver is < 3 mil, gang the mask opening (open the mask over both pads).
  • Prevention: Set a "Minimum Solder Mask Sliver" rule in the DFM section of your constraints.

Design decisions

Effective design constraint setup is not just about software settings; it connects directly to manufacturing reality and long-term reliability.

Connecting to Manufacturing Data (SPC) Advanced designers use spc chart setup data from previous production runs to inform their constraints. If a factory's Statistical Process Control (SPC) shows that 4 mil traces have a Cpk (process capability) of 1.33 but 3.5 mil traces drop to 0.9, the designer should set the constraint to 4 mil to ensure high yield. APTPCB provides feedback on these capabilities to help you optimize your DFM guidelines.

Reliability and Testing Constraints also dictate mechanical reliability. For products undergoing shock and vibration testing, the drop test setup influences how close components can be placed to mounting holes. A constraint rule should define a "Keep-Out" zone of at least 5mm around mounting points to prevent solder joint fractures during a drop event.

File Portability The design rule file setup is a valuable asset. By saving verified constraint sets for different technologies (e.g., "4-Layer_Standard_FR4.rul" vs. "6-Layer_Impedance_Rogers.rul"), teams reduce setup time and eliminate human error.

FAQ

1. What is the difference between DRC and DFM constraints? DRC (Design Rule Check) is a hard pass/fail check inside your software based on the rules you set. DFM (Design for Manufacturing) often refers to a broader analysis performed by the fabricator to check for yield issues, acid traps, and slivers that a basic DRC might miss.

2. Can I change design constraints halfway through a project? Yes, but it is risky. Tightening constraints (e.g., increasing clearance) may cause massive DRC violations requiring re-routing. Loosening constraints is safer but should only be done if the manufacturer confirms capability.

3. How do I handle constraints for high voltage? You must set up a specific "Creepage" rule. Standard clearance is the shortest distance through air; creepage is the distance along the surface. High voltage nets need their own class with significantly larger spacing (e.g., >2mm for mains voltage).

4. Why does my manufacturer ask to change my constraints? If your constraints are tighter than necessary (e.g., 3 mil trace when 5 mil fits), it lowers yield and increases cost. Conversely, if your constraints are too loose for the component density, the board may be unmanufacturable.

5. Do constraints affect the cost of the PCB? Absolutely. Rules that require "Advanced" features (e.g., < 4 mil trace, < 0.2mm drill, blind vias) trigger higher pricing tiers. Keeping constraints within "Standard" specs keeps costs down.

6. How do I set constraints for a 50-ohm trace? You cannot just "set" 50 ohms; you must calculate the trace width that results in 50 ohms based on your stackup (dielectric thickness and constant). You enter this calculated width into the physical constraint manager.

7. What is the "Minimum Solder Mask Sliver" rule? This rule ensures that there is enough space between solder mask openings to print a web of mask. If this web is too thin (< 3-4 mil), it will flake off during assembly, causing bridges.

8. Should I trust the default rules in Altium/Eagle/KiCad? No. Default rules are often generic placeholders. They might be too conservative (wasting space) or too aggressive (beyond standard fab capabilities). Always load a rule set based on your specific fabricator's specs.

9. How do constraints handle rigid-flex designs? Rigid-flex requires "Region-Specific" rules. The flexible area needs different constraints (e.g., larger trace width, curved routing, no vias) compared to the rigid sections.

10. What is a "Room" in constraint management? A Room is a defined geometric area on the board where specific rules apply. For example, under a BGA, you might allow 3.5 mil spacing, while the rest of the board requires 5 mil.

11. Why do I get "Unrouted Net" errors even when it looks connected? This often happens if the trace center doesn't snap exactly to the pad center, or if the trace width is slightly larger than the pad, preventing the software from registering the connection logic.

12. How do I verify my impedance constraints are correct? Use a PCB Viewer or impedance calculator before fabrication. After fabrication, request a TDR (Time Domain Reflectometry) test report from the factory to validate the physical board matches the design.

Glossary (key terms)

Term Definition
DRC (Design Rule Check) Software process that verifies the layout against the defined design constraint setup.
Clearance The minimum physical distance required between two conductive elements (nets) to prevent shorts.
Creepage The shortest distance between two conductors along the surface of the insulating material.
Annular Ring The ring of copper around a drilled hole; critical for ensuring the via connects to the trace.
Net Class A group of electrical connections (nets) that share the same physical or electrical rules.
Stackup The arrangement of copper layers and dielectric materials (Prepreg/Core) in the PCB.
Impedance Control Managing trace dimensions to maintain a specific AC resistance (impedance) for high-speed signals.
Via-in-Pad A design technique where the via is placed directly in the component pad (requires specific constraints and manufacturing steps).
Aspect Ratio The ratio of the board thickness to the drilled hole diameter; limits plating capability.
Courtyard The physical boundary including the component body and necessary assembly clearance area.
Thermal Relief A spoke pattern connecting a pad to a plane, preventing heat sink effects during soldering.
Solder Mask Expansion The gap between the copper pad and the edge of the solder mask opening.

Conclusion

A meticulous design constraint setup is the difference between a seamless production run and a project stalled by engineering queries (EQs). By translating the physical limitations of the factory and the electrical needs of your circuit into precise software rules, you ensure reliability and performance.

Whether you are configuring standard FR4 boards or complex high-speed interconnects, starting with the right rules saves time and money. For verified manufacturing specs to populate your constraint manager, or to review your DFM readiness, the engineering team at APTPCB is ready to assist.

Get a Quote