What It Does
Design rules tell DRC what your manufacturer can build: minimum clearances, track widths, hole sizes and so on. Trace has presets for common manufacturers, and you can import any .kicad_dru rules file, such as one your manufacturer publishes.
Applying a preset or importing a file replaces the project's custom rules. Save a copy first if you have rules of your own.
How to Import
From the Trace App
- In the board editor, open Inspect > Design Rules Checker (or press DRC in the Simple layout).
- Beside Rules Preset, press Import....
- Pick the
.kicad_drufile and enter the manufacturer's name when asked. - Read the import log to confirm the rules loaded. The preset now reads Custom: followed by the name you gave.
- Press Run DRC and work through the findings.
From the DRC Rule Editor
Open Tools > DRC Rule Editor to read or change the imported rules. See DRC Rule Editor.
From the CLI
trace-cli comes with the Trace app; install the app and sign in first. See the CLI reference for the checks it can run.
What Gets Imported
A rules file can set clearance, track width, hole size, annular ring, edge clearance, courtyard spacing and text size, each with conditions such as a net class or layer. Impedance, drill aspect ratio, special stackups and assembly needs may need their own setup or a word with your manufacturer.
How Constraints Flow Into TraceRules
When you import rules, Trace can add a short summary of your manufacturer's limits to the project's TraceRules, so the assistant keeps them in mind. DRC itself always checks the board's actual rules.
Manufacturer Presets
- Choose your manufacturer in the Preferred Manufacturer list on the board editor's toolbar (Full layout), or ask the assistant to set it.
- Open the DRC window and check Rules Preset.
Presets are included for JLCPCB, PCBWay and Pikkolo. JLCPCB and PCBWay have presets for different layer counts and copper weights; check that Rules Preset matches your board.
Default (no manufacturer) goes back to your board's own rules and removes the manufacturer's rules. Custom (project rules) means the project has rules of its own.
From Trace 3.2, the Pikkolo rules catch plated slots, as their No plated slots rule intends. If your project already uses the Pikkolo preset, apply it again to get the fix.
A preset covers the limits it lists. Check your manufacturer's current capabilities for anything else.
Workflow: Import → Design → Validate
Pick or import your rules before you route, design to them, and run DRC after big changes and before you export. Ask the assistant to fix specific findings rather than to "fix everything", so you can see each change.
Overriding Imported Rules
Change a rule only when you know why, and with your manufacturer's agreement if you go below their limits. A note in TraceRules does not override DRC.
Creating a .kicad_dru for Your Manufacturer
Write rules in the DRC Rule Editor or in a text file. A simple example:
(version 1)
(rule "Minimum Clearance"
(constraint clearance (min 0.2mm))
)
(rule "Minimum Track Width"
(constraint track_width (min 0.2mm))
)
Use your manufacturer's real numbers, import the file into a copy of your project first, and run DRC.
Review Findings Before Excluding Them
Look at each finding before you exclude it. To accept one on purpose, right-click it in the DRC window and choose Exclude with comment..., then write why. Tick Exclusions under Show to see them again.
The assistant can exclude findings too, each with its reason, just as Exclude with comment... does. It can also list and clear exclusions, and it never excludes a finding without a reason. From Trace 3.2, findings you excluded are not reported to the assistant as errors, and they stay excluded after the assistant runs DRC. See Design Review.
If Import Fails
If the log reports that the file could not be copied or read, fix the file or put back your previous rules, then run DRC again. Until the rules load, DRC is checking against whatever was there before.