CN111324999B - Method and system for automatically creating via hole in PCB design - Google Patents

Method and system for automatically creating via hole in PCB design Download PDF

Info

Publication number
CN111324999B
CN111324999B CN202010130248.5A CN202010130248A CN111324999B CN 111324999 B CN111324999 B CN 111324999B CN 202010130248 A CN202010130248 A CN 202010130248A CN 111324999 B CN111324999 B CN 111324999B
Authority
CN
China
Prior art keywords
via hole
line segment
routing
calculating
coordinate
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010130248.5A
Other languages
Chinese (zh)
Other versions
CN111324999A (en
Inventor
付深圳
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Suzhou Inspur Intelligent Technology Co Ltd
Original Assignee
Suzhou Inspur Intelligent Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Suzhou Inspur Intelligent Technology Co Ltd filed Critical Suzhou Inspur Intelligent Technology Co Ltd
Priority to CN202010130248.5A priority Critical patent/CN111324999B/en
Publication of CN111324999A publication Critical patent/CN111324999A/en
Application granted granted Critical
Publication of CN111324999B publication Critical patent/CN111324999B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Design And Manufacture Of Integrated Circuits (AREA)

Abstract

The invention relates to the technical field of PCB design, and provides a method and a system for automatically creating a via hole in PCB design, wherein the method comprises the following steps: calculating the total length L of the routing according to the selected routing; calculating the distance S between the pre-created via holes according to the number N of the pre-created via holes and the total length L of the routing obtained by calculation; calculating the coordinate parameter (x) of the pre-established via hole on the selected routing according to the calculated space S between the via holes i ,y i ) (ii) a According to the calculated coordinate parameter (x) of the pre-created via hole i ,y i ) And the via hole is created in the PCB design window, so that the via hole is quickly created in the PCB design window, the defects of slow and inaccurate manual operation and poor beauty are overcome, the PCB design period is shortened, and the working efficiency and the accuracy are improved.

Description

Method and system for automatically creating via hole in PCB design
Technical Field
The invention belongs to the technical field of PCB design, and particularly relates to a method and a system for automatically creating a via hole in PCB design.
Background
There are many kinds of PCB design software on the market, cadence is the most widely applied software in the industry, not only it has powerful functions and many kinds of related software as support, but also because it provides open secondary development interface and more perfect development language library, the user can develop according to his own needs.
The twist language is a high-level programming language which is built in Cadence software and is based on a C language and a LISP language, and can be used as a simplest language tool and a powerful programming language for developing any application. Skill can interact with the underlying system, providing a rich interface to access Cadence tools. Users can access through the Skill language and develop their own Cadence platform-based tools.
When designing a PCB test verification board, an engineer needs to perform impedance verification on a routing wire, sometimes needs to create VIAs uniformly on the routing wires for testing, and the existing mode is to observe through human eyes and calculate an approximate value to create the VIAs, so that the mode is low in efficiency and inaccurate in calculation.
Disclosure of Invention
Aiming at the defects in the prior art, the invention provides an automatic VIA hole creating method in PCB design, aiming at solving the problems that the VIA is created by calculating an approximate value through human eye observation in the prior art, the method has low efficiency and the calculation is not accurate enough.
The technical scheme provided by the invention is as follows: a method for automatically creating a via in a PCB design, the method comprising the steps of:
calculating the total length L of the routing according to the selected routing;
calculating a distance S between the pre-established via holes according to the number N of the pre-established via holes and the total length L of the routing lines obtained through calculation, wherein S = L/N;
calculating the coordinate parameter (x) of the pre-established via holes on the selected routing according to the calculated space S between the via holes i ,y i ) Wherein i is an integer which is greater than or equal to 1 and less than or equal to N, and corresponds to the pre-established via hole on the routing line;
according to the calculated coordinate parameter (x) of the pre-created via hole i ,y i ) Creating a via in the PCB design window.
As an improved scheme, the step of calculating the total length L of the routing lines according to the selected routing lines specifically includes the following steps:
selecting a routing needing to create a via hole in a PCB design window, wherein the routing comprises two situations of a routing line segment and a whole routing line consisting of a plurality of line segments;
acquiring coordinate parameters of a starting point and an end point of the selected routing line segment;
in the PCB design window, calculating the total length L of the selected routing according to the obtained coordinate parameters of the starting point and the end point of the routing line segment, wherein L = L 1 +L 2 +…+L n And n is an integer of 1 or more.
As an improved scheme, when n =1, calculating a coordinate parameter (x) of a pre-created via on the selected trace according to the calculated pitch S between the vias i ,y i ) The method specifically comprises the following steps:
respectively calculating the via holes Z i And the starting point A (X) of the routing 1 ,Y 1 ) Distance L of AZi And the via hole Z i And the wiring end point B (X) 2 ,Y 2 ) Is a distance ofL ZiB
Calculating the current pre-created via hole Z i A value of the calculation constant λ is equal to the via hole Z i And the starting point A (X) of the trace 1 ,Y 1 ) And the via hole Z i And the wiring end point B (X) 2 ,Y 2 ) I.e. λ = L AZi /L ZiB
Respectively calculating the coordinate parameter (x) of each pre-established via hole on the routing according to the calculation constant lambda i ,y i ) Wherein, X = (X) 1 +λ*X 2 )/(1+λ),y=(Y 1 +λ*Y 2 )/(1+λ)。
As an improvement, when n is>1, calculating a coordinate parameter (x) of a pre-established via hole on the selected routing according to the calculated distance S between the via holes i ,y i ) The method specifically comprises the following steps:
sorting all the line segments according to the extending direction of the line according to the obtained coordinate parameters of the starting points and the end points of all the n line segments of the selected line, wherein the coordinates of the starting point of the next line segment are overlapped with the coordinates of the end point of the previous line segment, and n is more than or equal to 2;
calculating the coordinate parameter (x) of all pre-created via holes on the first line segment after sorting according to the line segments 1i ,y 1i );
Judging whether the coordinate of the last pre-created via hole on the first line segment is coincident with the end point coordinate of the first line segment;
when the coordinate of the last pre-created via hole on the first line segment is judged to be coincident with the coordinate of the end point of the first line segment, calculating the coordinate parameter (x) of all pre-created via holes on the second line segment 1i ,y 1i );
When the coordinate of the last pre-created via hole on the first line segment is judged not to be coincident with the terminal point coordinate of the first line segment, the last pre-created via hole Z on the first line segment is obtained 1m Coordinate (x) of (2) 1m ,y 1m ) Calculating the remaining length l of the trace on the first line segment 1
According to the calculated distance S between the pre-established via holes and the residual routing length l on the first line segment 1 Calculating the compensation length l of the trace on the second line segment 2
According to the calculated routing compensation length l 2 Calculating the coordinate parameter (x) of all the pre-created via holes on the second line segment 2i ,y 2i );
And the analogy is carried out from the second line segment until the coordinate parameter (x) of the last pre-created via hole of the last line segment is calculated Nk ,y Nk )。
As an improved scheme, the coordinate parameter (x) of all the pre-created through holes on the first line segment after the line segment is sequenced is calculated 1i ,y 1i ) The method specifically comprises the following steps:
respectively calculating the via holes Z 1i And the starting point A (X) of the routing 11 ,Y 11 ) Distance L of AZ1i And the via hole Z 1i And the line end point B (X) 21 ,Y 21 ) Distance L of Z1iB Wherein i is an integer greater than 1 and corresponds to a pre-established via hole on the trace;
calculating the current pre-created via hole Z 1i A value of the calculation constant λ is equal to the via hole Z 1i And the starting point A (X) of the routing 11 ,Y 11 ) Distance L of AZ1i And the via hole Z i And the line end point B (X) 12 ,Y 12 ) Distance L of Z1iB I.e. λ = L AZ1i /L Z1iB
Respectively calculating the coordinate parameter (x) of each pre-established via hole on the routing according to the calculation constant lambda 1i ,y 1i ) Wherein x is 1i =(X 11 +λ*X 12 )/(1+λ),y 1i =(Y 11 +λ*Y 12 )/(1+λ)。
Another object of the present invention is to provide a system for automatically creating a via in a PCB design, the system comprising:
the routing total length calculating module is used for calculating the total length L of the routing according to the selected routing;
the via hole pitch calculation module is used for calculating the pitch S between the pre-created via holes according to the number N of the pre-created via holes and the total length L of the routing lines obtained through calculation, wherein S = L/N;
a via hole coordinate parameter calculation module for calculating the coordinate parameter (x) of the pre-created via hole on the selected trace according to the calculated space S between via holes i ,y i ) Wherein i is an integer greater than or equal to 1 and less than or equal to N, and corresponds to the pre-established via hole on the trace;
a via hole creation module for calculating the coordinate parameter (x) of the pre-created via hole i ,y i ) And creating a via hole in the PCB design window.
As an improved solution, the total track length calculating module specifically includes:
the routing selection module is used for selecting a routing needing to establish a via hole in a PCB design window, wherein the routing comprises two situations of a routing line segment and a whole routing line consisting of a plurality of line segments;
the coordinate parameter acquisition module is used for acquiring coordinate parameters of a starting point and an end point of the selected routing line segment;
a summarizing calculation module, configured to calculate a total length L of the selected trace according to the obtained coordinate parameters of the start point and the end point of the trace line segment in the PCB design window, where L = L 1 +L 2 +…+L n And n is an integer of 1 or more.
As an improved scheme, when n =1, the via hole coordinate parameter calculation module specifically includes:
a first distance calculating module for calculating the via holes Z respectively i And the starting point A (X) of the routing 1 ,Y 1 ) Distance L of AZi And the via hole Z i And the wiring end point B (X) 2 ,Y 2 ) Distance L of ZiB
A first calculation constant calculation module for calculating the current pre-created via hole Z i A value of the calculation constant λ is equal to the via hole Z i And the starting point A (X) of the routing 1 ,Y 1 ) And the via hole Z i And the wiring end point B (X) 2 ,Y 2 ) I.e. λ = L AZi /L ZiB
A first coordinate parameter calculation module for calculating the coordinate parameter (x) of each pre-created via hole on the trace according to the calculation constant λ i ,y i ) Wherein X = (X) 1 +λ*X 2 )/(1+λ),y=(Y 1 +λ*Y 2 )/(1+λ)。
As an improved scheme, when n >1, the via coordinate parameter calculation module specifically includes:
the routing sorting module is used for sorting all the line segments according to the obtained coordinate parameters of the starting points and the end points of all the n line segments of the selected routing according to the extending direction of the routing, wherein the coordinates of the starting point of the next line segment are superposed with the coordinates of the end point of the previous line segment, and n is more than or equal to 2;
a first line segment via hole coordinate calculation module for calculating coordinate parameters (x) of all pre-created via holes on the first line segment after sorting according to line segments 1i ,y 1i );
The coincidence judgment module is used for judging whether the coordinate of the last pre-established via hole on the first line segment coincides with the end point coordinate of the first line segment;
a second line segment via hole coordinate first calculation module, configured to calculate coordinate parameters (x) of all pre-created via holes on a second line segment when it is determined that the coordinate of the last pre-created via hole on the first line segment coincides with the end point coordinate of the first line segment 1i ,y 1i );
A remaining routing length calculating module, configured to determine coordinates of a last pre-created via on the first line segment and an end point of the first line segment when determining that the last pre-created via is located on the first line segmentWhen the coordinates are not coincident, according to the last pre-created via hole Z on the obtained first line segment 1m Coordinate (x) of 1m ,y 1m ) Calculating the remaining length l of the trace on the first line segment 1
A routing compensation length calculating module, configured to calculate a distance S between the pre-created via holes and a remaining routing length l on the first line segment according to the calculated distance S between the pre-created via holes and the calculated remaining routing length l 1 Calculating the compensation length l of the trace on the second line segment 2
A second calculation module for calculating the via hole coordinate of the second line segment according to the calculated compensation length l of the routing 2 Calculating the coordinate parameter (x) of all the pre-created via holes on the second line segment 2i ,y 2i );
And the analogy calculation module is used for analogy in sequence from the second line segment until the coordinate parameter (x) of the last pre-created via hole of the last line segment is calculated Nk ,y Nk )。
As an improved scheme, the first line segment via hole coordinate calculation module specifically includes:
a second distance calculating module for calculating the via holes Z respectively 1i And the starting point A (X) of the routing 11 ,Y 11 ) Distance L of AZ1i And the via hole Z 1i And the wiring end point B (X) 21 ,Y 21 ) Distance L of Z1iB Wherein i is an integer greater than 1 and corresponds to a pre-established via hole on the trace;
a second calculation constant calculation module for calculating the current pre-created via hole Z 1i A value of the calculation constant λ is equal to the via hole Z 1i And the starting point A (X) of the routing 11 ,Y 11 ) Distance L of AZ1i And the via hole Z i And the wiring end point B (X) 12 ,Y 12 ) Distance L of Z1iB I.e. λ = L AZ1i /L Z1iB
A second coordinate parameter calculation module for calculating the coordinate parameter of each pre-created via hole on the routing line according to the calculation constant lambdaNumber (x) 1i ,y 1i ) Wherein x is 1i =(X 11 +λ*X 12 )/(1+λ),y 1i =(Y 11 +λ*Y 12 )/(1+λ)。
In the embodiment of the invention, the total length L of the routing is calculated according to the selected routing; calculating the distance S between the pre-created via holes according to the number N of the pre-created via holes and the total length L of the routing lines obtained through calculation; calculating the coordinate parameter (x) of the pre-established via hole on the selected routing according to the calculated space S between the via holes i ,y i ) (ii) a According to the calculated coordinate parameter (x) of the pre-created via hole i ,y i ) And the via hole is created in the PCB design window, so that the via hole is quickly created in the PCB design window, the defects of slow and inaccurate manual operation and unattractive appearance are overcome, the PCB design period is shortened, and the working efficiency and the accuracy are improved.
Drawings
In order to more clearly illustrate the detailed description of the invention or the technical solutions in the prior art, the drawings that are needed in the detailed description of the invention or the prior art will be briefly described below. Throughout the drawings, like elements or portions are generally identified by like reference numerals. In the drawings, elements or portions are not necessarily drawn to scale.
FIG. 1 is a flow chart of an implementation of a method for automatically creating via holes in a PCB design according to the present invention;
fig. 2 is a flowchart illustrating an implementation of calculating a total length L of a trace according to a selected trace according to the present invention;
fig. 3 is a diagram illustrating a coordinate parameter (x) of a pre-created via on a selected trace calculated according to a calculated via-to-via distance S when n =1 according to the present invention i ,y i ) The implementation flow chart of (1);
FIG. 4 is a graph showing the equation when n is provided by the present invention>1, calculating a coordinate parameter (x) of a pre-established via hole on the selected routing according to the calculated distance S between the via holes i ,y i ) The implementation flow chart of (1);
FIG. 5 is a table illustrating the coordinate parameters (x) for all pre-created vias on a first line segment after sorting the line segments according to the present invention 1i ,y 1i ) The implementation flow chart of (1);
FIG. 6 is a block diagram of an automatic via creation system for PCB design according to the present invention;
fig. 7 is a block diagram of a via coordinate parameter calculation module according to a first embodiment of the present invention;
fig. 8 is a block diagram of a via coordinate parameter calculation module according to a second embodiment of the present invention;
fig. 9 is a block diagram of a first line segment via coordinate calculation module provided in the present invention.
Detailed Description
Embodiments of the present invention will be described in detail below with reference to the accompanying drawings. The following examples are only for illustrating the technical solutions of the present invention more clearly, and therefore are only used as examples, and the protection scope of the present invention is not limited thereby.
Fig. 1 is a flowchart of an implementation of a method for automatically creating a via hole in a PCB design, which specifically includes the following steps:
in step S101, calculating a total length L of the routing according to the selected routing;
in step S102, calculating a space S between the pre-created via holes according to the number N of the pre-created via holes and the calculated total length L of the trace, where S = L/N;
the number of the via holes is determined according to the design of the PCB, and is not described herein any more, that is, N via holes are uniformly arranged on the whole routing line.
In step S103, according to the calculated distance S between the vias, a coordinate parameter (x) of the pre-created via on the selected trace is calculated i ,y i ) Wherein i is an integer greater than or equal to 1 and less than or equal to N, and corresponds to the pre-established via hole on the trace;
in step S104, the coordinate parameter (x) of the pre-created via hole is calculated i ,y i ) At a placeVias are created in the PCB design window.
In this step, there are various ways to create the via, such as axlddbcreatevia, which are not described herein again.
In the embodiment of the present invention, as shown in fig. 2, the step of calculating the total length L of the routing line according to the selected routing line specifically includes the following steps:
in step S201, in a PCB design window, selecting a trace that needs to create a via, where the trace includes two situations, namely a trace line segment and an entire trace composed of multiple line segments;
in the PCB design window, the corresponding trace can be selected according to the actual impedance verification requirement, and one or several of the traces can be selected, or of course, the trace can be selected completely, which is not described herein again.
In step S202, coordinate parameters of a start point and an end point of the selected routing line segment are obtained;
in this step, the coordinate parameters of the start point and the end point of each line segment are known and may be obtained from the attribute parameters.
In step S203, in the PCB design window, calculating a total length L of the selected trace according to the obtained coordinate parameters of the start point and the end point of the trace line segment, where L = L 1 +L 2 +…+L n And n is an integer of 1 or more.
In this step, in the PCB design window, after the coordinate parameters of the initial point and the end point of the line segment are known, the length of the line segment is calculated, which is a known manner and is not described herein again.
In the embodiment of the present invention, as shown in fig. 3, when n =1, the coordinate parameter (x) of the pre-created via on the selected trace is calculated according to the calculated space S between the via and the via i ,y i ) The method specifically comprises the following steps:
in step S301, the via holes Z are respectively calculated i And the starting point A (X) of the routing 1 ,Y 1 ) Distance L of AZi And the via hole Z i And the wiring end point B (X) 2 ,Y 2 ) Distance L of ZiB Wherein i is an integer greater than 1 and corresponds to a pre-established via hole on the trace;
in step S302, the current pre-created via Z is calculated i A value of the calculation constant λ is equal to the via hole Z i And the starting point A (X) of the routing 1 ,Y 1 ) And the via hole Z i And the wiring end point B (X) 2 ,Y 2 ) I.e. λ = L AZi /L ZiB
In step S303, according to the calculation constant λ, respectively calculating a coordinate parameter (x) of each pre-created via on the trace i ,y i ) Wherein X = (X) 1 +λ*X 2 )/(1+λ),y=(Y 1 +λ*Y 2 )/(1+λ)。
The above provides a way of calculating the coordinates of each via that selects a line segment, where the via may coincide with the coordinates of the end point of the line segment.
In the embodiment of the present invention, as shown in FIG. 4, when n is>1, calculating a coordinate parameter (x) of a pre-established via hole on the selected routing according to the calculated distance S between the via holes i ,y i ) The method specifically comprises the following steps:
in step S401, according to the obtained coordinate parameters of the starting point and the end point of all n line segments of the selected routing, all the line segments are sorted according to the extending direction of the routing, wherein the coordinates of the starting point of the next line segment coincide with the coordinates of the end point of the previous line segment, and n is greater than or equal to 2;
in step S402, the coordinate parameters (x) of all pre-created vias on the first line segment sorted by line segment are calculated 1i ,y 1i );
In step S403, it is determined whether the coordinate of the last pre-created via hole on the first line segment coincides with the end point coordinate of the first line segment, if yes, step S404 is executed, otherwise, step S405 is executed;
in step S404, when the coordinates of the last pre-created via on the first line segment and the coordinates of the last pre-created via on the first line segment are determinedWhen the coordinates of the end point of the first line segment coincide, calculating the coordinate parameters (x) of all the pre-created through holes on the second line segment 1i ,y 1i );
In step S405, when it is determined that the coordinate of the last pre-created via hole on the first line segment does not coincide with the end point coordinate of the first line segment, obtaining a last pre-created via hole Z on the first line segment according to the obtained result 1m Coordinate (x) of 1m ,y 1m ) Calculating the remaining length l of the trace on the first line segment 1
In step S406, according to the calculated distance S between the pre-created via holes and the calculated remaining trace length l on the first line segment, the method further includes 1 Calculating the compensation length l of the trace on the second line segment 2
The distance S between the pre-created through holes = the length l of the remaining trace on the first line segment 1 + second line segment routing compensation length l 2
In step S407, the calculated trace compensation length l is calculated 2 Calculating the coordinate parameter (x) of all the pre-created via holes on the second line segment 2i ,y 2i );
In step S408, the same analogy is repeated from the second line segment until the coordinate parameter (x) of the last pre-created via hole of the last line segment is calculated Nk ,y Nk )。
When the last via of one of the segments does not coincide with the end point, the difference needs to be calculated and compensated for by a certain length of the next segment.
As shown in fig. 5, the coordinate parameters (x) of all the pre-created vias on the first line segment after sorting by line segment are calculated 1i ,y 1i ) The method specifically comprises the following steps:
in step S501, the via holes Z are respectively calculated 1i And the starting point A (X) of the routing 11 ,Y 11 ) Distance L of AZ1i And the via hole Z 1i And the wiring end point B (X) 21 ,Y 21 ) Distance L of Z1iB Wherein i isIntegers greater than 1, corresponding to pre-created vias on the trace;
in step S502, the current pre-created via Z is calculated 1i A value of the calculation constant λ is equal to the via hole Z 1i And the starting point A (X) of the trace 11 ,Y 11 ) Distance L of AZ1i And the via hole Z i And the wiring end point B (X) 12 ,Y 12 ) Distance L of Z1iB I.e. λ = L AZ1i /L Z1iB
In step S503, according to the calculation constant λ, respectively calculating a coordinate parameter (x) of each pre-created via hole on the trace 1i ,y 1i ) Wherein x is 1i =(X 11 +λ*X 12 )/(1+λ),y 1i =(Y 11 +λ*Y 12 )/(1+λ)。
Fig. 6 shows a block diagram of an automatic via creation system in a PCB design provided by the present invention, and for convenience of illustration, only the parts related to the embodiment of the present invention are shown in the diagram.
The automatic via creating system in PCB design comprises:
the routing total length calculating module 11 is configured to calculate a total length L of the routing according to the selected routing;
the via hole pitch calculation module 12 is configured to calculate a pitch S between the pre-created via holes according to the number N of the pre-created via holes and the calculated total length L of the trace, where S = L/N;
a via hole coordinate parameter calculation module 13, configured to calculate a coordinate parameter (x) of a pre-created via hole on the selected trace according to the calculated distance S between the via holes i ,y i ) Wherein i is an integer greater than or equal to 1 and less than or equal to N, and corresponds to the pre-established via hole on the trace;
a via creating module 14 for calculating the coordinate parameter (x) of the pre-created via according to the calculated coordinate parameter (x) i ,y i ) And creating a via hole in the PCB design window.
In this embodiment, as shown in fig. 6, the total track length calculating module 11 specifically includes:
the routing selection module 15 is used for selecting a routing which needs to create a via hole in a PCB design window, wherein the routing comprises two situations of a routing line segment and a whole routing line consisting of a plurality of line segments;
a coordinate parameter obtaining module 16, configured to obtain coordinate parameters of a starting point and an ending point of the selected routing line segment;
a summary calculating module 17, configured to calculate, in the PCB design window, a total length L of the selected trace according to the obtained coordinate parameters of the start point and the end point of the trace line segment, where L = L 1 +L 2 +…+L n And n is an integer of 1 or more.
In this embodiment of the present invention, as shown in fig. 7, when n =1, the via hole coordinate parameter calculating module 13 specifically includes:
a first distance calculating module 18 for calculating the via holes Z respectively i And the starting point A (X) of the routing 1 ,Y 1 ) Distance L of AZi And the via hole Z i And the line end point B (X) 2 ,Y 2 ) Distance L of ZiB Wherein i is an integer greater than 1 and corresponds to a pre-established via hole on the trace;
a first calculation constant calculation module 19 for calculating the via hole Z pre-created currently i A value of the calculation constant λ is equal to the via hole Z i And the starting point A (X) of the routing 1 ,Y 1 ) And the via hole Z i And the wiring end point B (X) 2 ,Y 2 ) I.e. λ = L AZi /L ZiB
A first coordinate parameter calculating module 20, configured to calculate, according to the calculation constant λ, a coordinate parameter (x) of each pre-created via on the trace respectively i ,y i ) Wherein X = (X) 1 +λ*X 2 )/(1+λ),y=(Y 1 +λ*Y 2 )/(1+λ)。
As shown in fig. 8, when n >1, the via coordinate parameter calculation module 13 specifically includes:
the routing sorting module 21 is configured to sort all the line segments according to the extending direction of the routing according to the obtained coordinate parameters of the starting point and the end point of all the n line segments of the selected routing, where a coordinate of the starting point of a subsequent line segment coincides with a coordinate of the end point of a previous line segment, and n is greater than or equal to 2;
a first line segment via hole coordinate calculation module 22, configured to calculate coordinate parameters (x) of all pre-created via holes on the first line segment sorted according to line segment 1i ,y 1i );
A coincidence judgment module 23, configured to judge whether the coordinate of the last pre-created via hole on the first line segment coincides with the end point coordinate of the first line segment;
a second line segment via coordinate first calculation module 24, configured to calculate coordinate parameters (x) of all pre-created vias on a second line segment when it is determined that the coordinate of the last pre-created via on the first line segment coincides with the end point coordinate of the first line segment 1i ,y 1i );
A remaining routing length calculating module 25, configured to, when it is determined that the coordinate of the last pre-created via on the first line segment is not coincident with the end point coordinate of the first line segment, obtain a last pre-created via Z on the first line segment 1m Coordinate (x) of 1m ,y 1m ) Calculating the remaining length l of the trace on the first line segment 1
A trace compensation length calculating module 26, configured to calculate a distance S between the pre-created via holes and a remaining trace length l on the first line segment according to the calculated distance S between the pre-created via holes and the calculated trace length l 1 Calculating the compensation length l of the trace on the second line segment 2
A second calculating module 27 for calculating the second line segment via hole coordinate, which is used for calculating the calculated trace compensation length l 2 Calculating the coordinate parameter (x) of all the pre-created via holes on the second line segment 2i ,y 2i );
And the analogy calculation module 28 is used for analogy from the second line segment to the analogy until the coordinates of the last pre-created via hole of the last line segment are calculatedParameter (x) Nk ,y Nk )。
In this embodiment, as shown in fig. 9, the first line segment via coordinate calculation module 24 specifically includes:
a second distance calculating module 29 for calculating the via holes Z respectively 1i And the starting point A (X) of the routing 11 ,Y 11 ) Distance L of AZ1i And the via hole Z 1i And the line end point B (X) 21 ,Y 21 ) Distance L of Z1iB Wherein i is an integer greater than 1 and corresponds to a pre-established via hole on the trace;
a second calculation constant calculation module 30 for calculating the via hole Z pre-created currently 1i A value of the calculation constant λ is equal to the via hole Z 1i And the starting point A (X) of the routing 11 ,Y 11 ) Distance L of AZ1i And the via hole Z i And the wiring end point B (X) 12 ,Y 12 ) Distance L of Z1iB I.e. λ = L AZ1i /L Z1iB
A second coordinate parameter calculating module 31, configured to calculate, according to the calculation constant λ, coordinate parameters (x) of each pre-created via on the trace respectively 1i ,y 1i ) Wherein x is 1i =(X 11 +λ*X 12 )/(1+λ),y 1i =(Y 11 +λ*Y 12 )/(1+λ)。
In the embodiment of the invention, the total length L of the routing is calculated according to the selected routing; calculating the distance S between the pre-created via holes according to the number N of the pre-created via holes and the total length L of the routing obtained by calculation; calculating the coordinate parameter (x) of the pre-established via hole on the selected routing according to the calculated space S between the via holes i ,y i ) (ii) a According to the calculated coordinate parameter (x) of the pre-created via hole i ,y i ) And the via hole is created in the PCB design window, so that the via hole is quickly created in the PCB design window, the defects of slow and inaccurate manual operation and unattractive appearance are overcome, the PCB design period is shortened, and the working efficiency and the accuracy are improved.
The above embodiments are only used to illustrate the technical solution of the present invention, and not to limit the same; while the invention has been described in detail and with reference to the foregoing embodiments, it will be understood by those skilled in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; such modifications and substitutions do not depart from the spirit and scope of the present invention, and they should be construed as being included in the following claims and description.

Claims (6)

1. A method for automatically creating a via hole in a PCB design, the method comprising the steps of:
calculating the total length L of the routing according to the selected routing;
calculating the distance S between the pre-created via holes according to the number N of the pre-created via holes and the total length L of the routing lines obtained through calculation, wherein S = L/N;
calculating the coordinate parameter (x) of the pre-established via hole on the selected routing according to the calculated space S between the via holes i ,y i ) Wherein i is an integer greater than or equal to 1 and less than or equal to N, and corresponds to the pre-established via hole on the trace;
according to the calculated coordinate parameter (x) of the pre-created via hole i ,y i ) Creating a via in the PCB design window;
the step of calculating the total length L of the routing according to the selected routing specifically includes the following steps:
selecting a routing needing to create a via hole in a PCB design window, wherein the routing comprises two situations of a routing line segment and a whole routing line consisting of a plurality of line segments;
acquiring coordinate parameters of a starting point and an end point of the selected routing line segment;
in the PCB design window, calculating the total length L of the selected routing according to the obtained coordinate parameters of the starting point and the end point of the routing line segment, wherein L = L 1 +L 2 +…+L n N is an integer of 1 or more;
when n =1, calculating a coordinate parameter (x) of a pre-created via hole on the selected trace according to the calculated space S between the via holes i ,y i ) The method specifically comprises the following steps:
respectively calculating the via holes Z i And the starting point A (X) of the routing 1 ,Y 1 ) Distance L of AZi And the via hole Z i And the wiring end point B (X) 2 ,Y 2 ) Distance L of ZiB
Calculating the current pre-created via hole Z i A value of the calculation constant λ is equal to the via hole Z i And the starting point A (X) of the routing 1 ,Y 1 ) And the via hole Z i And the wiring end point B (X) 2 ,Y 2 ) I.e. λ = L AZi /L ZiB
Respectively calculating the coordinate parameter (x) of each pre-established via hole on the routing according to the calculation constant lambda i ,y i ) Wherein X = (X) 1 +λ*X 2 )/(1+λ),y=(Y 1 +λ*Y 2 )/(1+λ)。
2. The method of claim 1, wherein when n is the number of vias in the PCB design, the method further comprises>1, calculating a coordinate parameter (x) of a pre-established via hole on the selected routing according to the calculated distance S between the via holes i ,y i ) The method specifically comprises the following steps:
sequencing all the line segments according to the extending direction of the routing according to the obtained coordinate parameters of the starting point and the end point of all n line segments of the selected routing, wherein the coordinates of the starting point of the next line segment are overlapped with the coordinates of the end point of the previous line segment, and n is more than or equal to 2;
calculating the coordinate parameter (x) of all pre-created via holes on the first line segment after sorting according to the line segments 1i ,y 1i );
Judging whether the coordinate of the last pre-created via hole on the first line segment is coincident with the end point coordinate of the first line segment;
when the coordinate of the last pre-created via hole on the first line segment is judged to be coincident with the coordinate of the end point of the first line segment, calculating the coordinate parameter (x) of all pre-created via holes on the second line segment 1i ,y 1i );
When the coordinate of the last pre-created via hole on the first line segment is judged not to be coincident with the terminal point coordinate of the first line segment, the last pre-created via hole Z on the first line segment is obtained 1m Coordinate (x) of 1m ,y 1m ) Calculating the remaining length l of the trace on the first line segment 1
According to the calculated distance S between the pre-established via holes and the residual routing length l on the first line segment 1 Calculating the compensation length l of the trace on the second line segment 2
According to the calculated routing compensation length l 2 Calculating the coordinate parameter (x) of all the pre-created via holes on the second line segment 2i ,y 2i );
And the analogy is carried out from the second line segment until the coordinate parameter (x) of the last pre-created via hole of the last line segment is calculated Nk ,y Nk )。
3. The method of claim 2, wherein the computing of the coordinate parameter (x) of all pre-created vias on the first line segment after sorting by line segments is performed 1i ,y 1i ) The method specifically comprises the following steps:
respectively calculating the via holes Z 1i And the starting point A (X) of the routing 11 ,Y 11 ) Distance L of AZ1i And the via hole Z 1i And the line end point B (X) 21 ,Y 21 ) Distance L of Z1iB Wherein i is an integer greater than 1 and corresponds to a pre-established via hole on the trace;
calculating current pre-createdVia hole Z 1i A value of the calculation constant λ is equal to the via hole Z 1i And the starting point A (X) of the routing 11 ,Y 11 ) Distance L of AZ1i And the via hole Z i And the wiring end point B (X) 12 ,Y 12 ) Distance L of Z1iB I.e. λ = L AZ1i /L Z1iB
Respectively calculating the coordinate parameter (x) of each pre-established via hole on the routing according to the calculation constant lambda 1i ,y 1i ) Wherein x is 1i =(X 11 +λ*X 12 )/(1+λ),y 1i =(Y 11 +λ*Y 12 )/(1+λ)。
4. An automatic via creation system in a PCB design, the system comprising:
the routing total length calculating module is used for calculating the total length L of the routing according to the selected routing;
the via hole pitch calculation module is used for calculating the pitch S between the pre-created via holes according to the number N of the pre-created via holes and the total length L of the routing lines obtained through calculation, wherein S = L/N;
a via hole coordinate parameter calculation module for calculating the coordinate parameter (x) of the pre-created via hole on the selected trace according to the calculated space S between the via holes i ,y i ) Wherein i is an integer greater than or equal to 1 and less than or equal to N, and corresponds to the pre-established via hole on the trace;
a via hole creation module for calculating the coordinate parameter (x) of the pre-created via hole i ,y i ) Creating a via in the PCB design window;
the total track length calculating module specifically includes:
the routing selection module is used for selecting a routing needing to create a via hole in a PCB design window, wherein the routing comprises two situations of a routing line segment and a whole routing line consisting of a plurality of line segments;
the coordinate parameter acquisition module is used for acquiring coordinate parameters of a starting point and an end point of the selected routing line segment;
a summary calculation module, configured to calculate, in the PCB design window, a total length L of the selected trace according to the obtained coordinate parameters of the start point and the end point of the trace line segment, where L = L 1 +L 2 +…+L n N is an integer of 1 or more;
when n =1, the via hole coordinate parameter calculation module specifically includes:
a first distance calculating module for calculating the via holes Z respectively i And the starting point A (X) of the routing 1 ,Y 1 ) Distance L of AZi And the via hole Z i And the wiring end point B (X) 2 ,Y 2 ) Distance L of ZiB
A first calculation constant calculation module for calculating the current pre-created via hole Z i A value of the calculation constant λ is equal to the via hole Z i And the starting point A (X) of the routing 1 ,Y 1 ) And the via hole Z i And the line end point B (X) 2 ,Y 2 ) I.e. λ = L AZi /L ZiB
A first coordinate parameter calculation module for calculating the coordinate parameter (x) of each pre-created via hole on the trace according to the calculation constant λ i ,y i ) Wherein X = (X) 1 +λ*X 2 )/(1+λ),y=(Y 1 +λ*Y 2 )/(1+λ)。
5. The system of claim 4, wherein when n >1, the via coordinate parameter calculation module comprises:
the routing sorting module is used for sorting all the line segments according to the extending direction of the routing according to the obtained coordinate parameters of the starting point and the end point of all the n line segments of the selected routing, wherein the coordinates of the starting point of the next line segment are overlapped with the coordinates of the end point of the previous line segment, and n is more than or equal to 2;
a first line segment via hole coordinate calculation module for calculating the line segment rowCoordinate parameter (x) of all pre-created vias on the first line segment after the sequence 1i ,y 1i );
The coincidence judgment module is used for judging whether the coordinate of the last pre-established via hole on the first line segment coincides with the end point coordinate of the first line segment;
a second line segment via hole coordinate first calculation module, configured to calculate coordinate parameters (x) of all pre-created via holes on a second line segment when it is determined that the coordinate of the last pre-created via hole on the first line segment coincides with the end point coordinate of the first line segment 1i ,y 1i );
A remaining trace length calculating module, configured to, when it is determined that the coordinate of the last pre-created via on the first line segment is not coincident with the end point coordinate of the first line segment, obtain a Z-value of the last pre-created via on the first line segment 1m Coordinate (x) of 1m ,y 1m ) Calculating the remaining trace length l on the first line segment 1
A routing compensation length calculating module, configured to calculate a distance S between the pre-created via holes and a remaining routing length l on the first line segment according to the calculated distance S between the pre-created via holes and the calculated remaining routing length l 1 Calculating the compensation length l of the trace on the second line segment 2
A second calculation module for calculating the via hole coordinate of the second line segment according to the calculated compensation length l of the routing 2 Calculating the coordinate parameter (x) of all the pre-created via holes on the second line segment 2i ,y 2i );
And the analogy calculation module is used for analogy in sequence from the second line segment until the coordinate parameter (x) of the last pre-created via hole of the last line segment is calculated Nk ,y Nk )。
6. The system of claim 5, wherein the first line segment via coordinate calculation module specifically comprises:
a second distance calculating module for calculating the via holes Z respectively 1i And the starting point A (X) of the routing 11 ,Y 11 ) Distance L of AZ1i And the via hole Z 1i And the wiring end point B (X) 21 ,Y 21 ) Distance L of Z1iB Wherein i is an integer greater than 1 and corresponds to a pre-established via hole on the trace;
a second calculation constant calculation module for calculating the via hole Z pre-created currently 1i A value of the calculation constant λ is equal to the via hole Z 1i And the starting point A (X) of the routing 11 ,Y 11 ) Distance L of AZ1i And the via hole Z i And the line end point B (X) 12 ,Y 12 ) Distance L of Z1iB I.e. λ = L AZ1i /L Z1iB
A second coordinate parameter calculating module for calculating the coordinate parameter (x) of each pre-established via hole on the trace line according to the calculation constant λ 1i ,y 1i ) Wherein x is 1i =(X 11 +λ*X 12 )/(1+λ),y 1i =(Y 11 +λ*Y 12 )/(1+λ)。
CN202010130248.5A 2020-02-28 2020-02-28 Method and system for automatically creating via hole in PCB design Active CN111324999B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010130248.5A CN111324999B (en) 2020-02-28 2020-02-28 Method and system for automatically creating via hole in PCB design

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010130248.5A CN111324999B (en) 2020-02-28 2020-02-28 Method and system for automatically creating via hole in PCB design

Publications (2)

Publication Number Publication Date
CN111324999A CN111324999A (en) 2020-06-23
CN111324999B true CN111324999B (en) 2022-12-23

Family

ID=71168909

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010130248.5A Active CN111324999B (en) 2020-02-28 2020-02-28 Method and system for automatically creating via hole in PCB design

Country Status (1)

Country Link
CN (1) CN111324999B (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109800496A (en) * 2019-01-15 2019-05-24 郑州云海信息技术有限公司 A method of via hole is added along pcb board side

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109800496A (en) * 2019-01-15 2019-05-24 郑州云海信息技术有限公司 A method of via hole is added along pcb board side

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于skill语言的PowerPAD封装的EPAD过孔设计;吴慧玲等;《数字化用户》;20191130(第11期);第227-228页 *

Also Published As

Publication number Publication date
CN111324999A (en) 2020-06-23

Similar Documents

Publication Publication Date Title
CN109697500B (en) Data processing method and device, electronic equipment and storage medium
CN109102797B (en) Speech recognition test method, device, computer equipment and storage medium
CN109800534B (en) FPGA (field programmable Gate array) design circuit diagram generation method and device, computer equipment and storage medium
US8230382B2 (en) Model based simulation of electronic discharge and optimization methodology for design checking
CN105138461A (en) Interface testing method and device for application program
CN109473093A (en) Audio recognition method, device, computer equipment and storage medium
CN110866306A (en) Train whole vehicle simulation verification method and system
CN111324999B (en) Method and system for automatically creating via hole in PCB design
CN116108642A (en) Parameter debugging model training method, debugging method and equipment for machine
CN111796578A (en) Vehicle controller testing method, device and system and storage medium
CN109271677B (en) Method for repairing layout grid point problem in online layering manner
CN111624475B (en) Method and system for testing large-scale integrated circuit
CN111177989B (en) Method, device and system for controlling layout and wiring by taking wiring result as guide
KR100642906B1 (en) Programming device
JP2012123592A (en) Optimization program, apparatus and program
CN111581101A (en) Software model testing method, device, equipment and medium
CN108536585B (en) Data change influence domain analysis method
CN106709217A (en) Method for automatically detecting routing angles
CN113283213B (en) Circuit design system and method based on machine learning
CN110597874B (en) Data analysis model creation method and device, computer equipment and storage medium
US20170220726A1 (en) Method and system for performing a design space exploration of a circuit
CN114185781A (en) Logic test case automatic generation method and device based on control logic diagram
CN110398681B (en) Double-strip-line inspection method and related device
CN107992287B (en) Method and device for checking system demand priority ranking result
CN113505283A (en) Test data screening method and system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant