PCB布线
Parent page: More about PCB Design
Working in harmony with the component placement, the routing is the other key factor in the success of your PCB design. Altium Designer includes a number of intuitive interactive routing features to help you efficiently and accurately route your board, from a simple double sided board all the way through to a high density, high speed, multi-layer board. It also includes a differential pair router, and interactive length tuning of both single-sided and differential routes. If your design is dense and has a high net count then you might like to explore ActiveRoute - it's not an autorouter, it is automated interactive routing technology that delivers efficient multi-net routing algorithms, applied to the specific nets or connections selected by you, the designer.
Before you commence routing, it is important that the board is ready. Use this article as a checklist to help you work out if your board is ready, then refer to the lower-level articles to learn more about the various approaches to routing.
Is it Ready to Route?
There is a saying that PCB design is 90% placement and 10% routing. While you could argue about the percentage of each, it is generally accepted that good component placement is the most important aspect to good board design. Keep in mind that you may need to tune the placement as you route too, perhaps running a test autoroute on a dense area first to see if it is route-able. If the autorouter can complete more than 80% of the nets, then you should be able to interactively route it with that number of layers.
If the design includes high speed nets, then the component placement becomes even more critical. Now you must consider the separation of noisy nets, such as clocks, from quiet nets, such as data lines. You must also consider the distribution of power over the board - referred to as the Power Distribution Network (PDN) - and plan where those critical return paths for the high-speed signals will flow. As part of this process, the placement of bypass and decoupling capacitors is critical. For the routing in and out of the components, the manufacturers often include layout guidelines in the device datasheet - follow these when they are available.
Prioritizing the Routing
Where to begin, you ask? An autorouter typically routes connections one by one, whereas a human can consider the impact of many connections simultaneously. For the autorouter to have any hope it must do a good job of ordering the connections for routing. It will use factors such as connection length, density of connections, assignment of direction to routing layers, alignment of the connection direction to routing directions, and so on. And if it is any good, it will review the order constantly as it routes. A human will consider these factors as well, but will also use higher-order skills, such as will this set of 16 routes pass between those two components, should these noisy nets be routed on a separate pair of layers from these sensitive nets, and so on.
First route or fan out the power nets. After the power nets, consider the critical signals, such as oscillators, differential pairs, high-speed interfaces, then the quiet nets.
Finding a Net on the Board
An unrouted board can appear intimidating - a mass of connection lines crisscrossing all over the board. A good approach to routing is to work from the schematic, where you can easily locate important components and critical nets. You can cross-select and cross-probe directly from the schematic components and nets, highlighting the equivalent item on the PCB. To learn more, refer to the Working Between the Schematic and the Board page.
You can also control the display of the connection lines by masking or hiding the nets you are not interested in. Setting the color of important connection lines will also help you manage the routing process. To learn more, refer to the Managing the Display of the Connection Lines section of the Understanding Connectivity on Your PCB page.
Net Color Override - Displaying the Net Color on Routed Nets
You can also use the net color for routed nets, by enabling the Net Override Color feature.
To use the Net Color Override feature:
- Apply the required color to the net(s) - double-click on the net in the PCB panel (in Nets mode) to open the Edit Net dialog, where the Connection Color can be configured as required. Alternatively, right-click on the net (or selected nets) in the PCB panel and use the Change Net Color command, as explained earlier in the Changing the Connection Line Color section of this page.
- Enable Color Override for the net(s) - color override is enabled for each net using the checkbox next to its name in the PCB panel, as shown for the net
YOUT
in the image below. The checkboxes can be toggled for multiple selected nets via the Right-click » Display Override » Selected On/Off commands. - Configure the Color Override options - the net color overrides the layer color in accordance with the Color Override settings configured in the PCB Editor - Board Insight Color Overrides page of the Preferences dialog, as shown below.
- Enable the Net Color Override feature - press F5 to globally toggle the Net Color Override feature on and off, or use the button in the View Options tab of the View Configurations panel.
How each net that has the Net Color Override checkbox enabled is displayed in the workspace, depends on the current Color Override settings, as shown above.
- When zoomed in, any net with the Override Color checkbox enabled will display in the chosen Base Pattern. In the example image above it is a checkerboard mix of layer color and net color.
- When zoomed out, the Zoom Out Behavior in the image above is for the override (net) color to dominate, as shown in the smaller image on the right.
Are the Design Rules Defined?
Main articles: Constraining the Design - Design Rules, Design Rules Reference
Before you start routing, you need to configure the applicable routing design rules. Select Design » Rules from the menus to display the PCB Rules and Constraints Editor dialog. The tree on the left of the dialog shows the 10 rule categories (Electrical, down to Signal Integrity). In each category there are a number of rule types, for example, there are eight different types of routing rules you can define.
Selecting a rule type will display all the rules of that type that are currently defined. The image below shows three routing width rules that have been defined for a board. Note the rule priority, this defines the precedence that the rules are applied, with 1 being the highest. The rules engine searches for the highest applicable rule when an object is being checked for rule compliance.
Click on an individual rule name in the tree on the left of the dialog to display the settings for that rule. There are two distinct parts to every design rule, the constraint - what are my requirements?, and the scope - what do I want this rule to target? Using the routing width design rule as an example, let's look at this in more detail.
The Rule Constraints
Main article: Constraining the Design - Design Rules
Rule constraints specify the settings or limits you want applied to the objects targeted by this rule.
For the Width rule, constraints define the minimum, preferred and maximum widths of the track segments that make up the routing. Note that the min / preferred / max settings can also be defined for each of layer of the board, an important feature for controlled impedance routing. A handy feature is the ability to change the routing width as you route, between the minimum and maximum settings, you can read more about this in the Interactive Routing article.
The Rule Scope
Main article: Scoping Design Rules
Altium Designer has a powerful and flexible rule definition system, making it possible to exactly specify the design requirements, however complex they might be. Rather than defining routing requirements as attributes of the objects, design rules are defined separately, and then target the objects they apply to via the rule's scope - along the lines of 'I want this rule to apply to those objects'.
The rule scoping system uses the filtering engine that underlies the PCB editor, to target the objects that it applies to. Ultimately each rule scope becomes a query, but for many rule scopes you can define it by selecting options from dropdown lists. For example, in the image above the query is targeting the GND
net - this actually becomes a query, of the form InNet('GND')
. When there is no suitable option in the dropdown you choose the Custom Query option, and then use the Query Builder to walk through the process of creating a query, or write one directly yourself, using the Query Helper if needed.
It is this ability to exactly scope each rule, in combination with the ability to assign each rule's priority that gives you complete control over the PCB design requirements.
The Width Rule
Rule reference: Width
The most basic routing rule is the Routing Width rule, which determines the width that the nets will be routed at. As a minimum, your design will have one width rule, targeting all nets on the board.
It is not good design practice to have only one width rule for a board, with the minimum width set to the smallest routing width you need on the board, and the maximum set to the widest route you need. A better approach is to have one rule that targets the largest number of nets, with a scope of All. You then add extra rules that target individual nets or classes of nets, such the GND net, or the PowerNets net class (if such a class has been created). Set these rules to have a higher priority, so whenever you start to route one of these nets the higher priority rule will override the All nets rule, giving you the correct routing width. Suitable Width rules need to be defined before you start routing.
The Clearance Constraint
Rules reference: Clearance Constraint
The partner to the width rule is the clearance constraint, which defines how close the net you are routing is allowed to get to other objects on the board. Again you can define multiple clearance constraints, to keep higher voltage nets or differential pair nets away from other routing, to keep polygon pours a specific distance from routing, and so on. Suitable Clearance Constraints need to be defined before you start routing.
Refer to the PCB Design Rules Reference to learn more about design rules.
Setting Up the Routing Layers
Main article: Defining the Layer Stack
Routing layers, also referred to as signal layers, are set up in the Layer Stack Manager (Design » Layer Stack Manager), as shown below. Use the right-click or main menu commands to add layers and set their location in the layer stack.
Check out the Layer Stack Manager page to learn more about configuring the fabrication layers.
The display of all layers, and the addition of mechanical layers, is controlled in the View Configurations panel (shortcut L) shown below.
Check out the View Configurations panel to learn more about configuring the display of layers, and the Working with Mechanical Layers page to learn more about the ins and outs of using mechanical layers.
Where to Next?
Ready to route? Altium Designer includes a number of interactive routing capabilities, including interactive and differential pair routing tools.
You also might like to explore ActiveRoute, an automated interactive routing technology that delivers efficient multi-net routing algorithms, applied to the specific nets or connections selected by the designer. ActiveRoute also allows the designer to interactively define a route path or Guide, which then defines the river along which the new routes will flow.