The 7360 CNC system of American AB Company adopts the extended DDA sampling interpolation algorithm. The system's interpolation cycle is the same as the position feedback sampling cycle, both being 10.24 ms, realized by real-time clock interruption of 10.24 ms.
Figure 2-30 Extended DDA linear interpolation
1. Extended DDA linear interpolation
Suppose that according to the programmed feedrate, the straight line segment OE shown in Fig. 2-30 is to be completed within the time period T. The end point is E(xe, ye) and the origin is at the origin O(0, 0). In the figure, vx and vy are the x and y coordinate components of velocity v, respectively. By the ratio of triangles in the diagram, you can get
The time interval T is divided into n sub-intervals by the sampling period λt (n is ≥ The nearest integer, so that the increment of coordinates in each sample period λt is
Where v is the required feed rate;
FRN——feed rate number, the formula is
For the same straight line, since v and xe, ye, and λt are known constants, FRN and λt in the equation are constant and can be denoted as λd=FRNλt. Therefore, the constants of the increments Δx and Δy in each sampling cycle of the same line (ie, the step length coefficient λd) are the same. Based on the Δx and Δy calculated for each sampling cycle, the coordinates xi and yi of the tool position at the end of the sampling period can be obtained.
From equations (2-28) and (2-29), it can also be seen that the feed step lengths Δx and Δy of each coordinate axis in the linear interpolation are the axial components of the contour step length (ie, the sub-line segment), respectively. Only changes with the feedrate programming value FRN or v.
Since the slope (Δy/Δx) of the sub-line segment formed in each iteration of the linear interpolation is equal to the given straight line slope, the trajectory requirement is ensured.
2. Extended DDA Circular Interpolation
Figure 2-31 shows the first quadrant arc segment AB with the arc equation x2+y2=R2
Figure 3-31 Extended DAA Circular Interpolation
Let the current tool be at the Ai (xi, yi) point. If in a sampling period λt, the contour feed step of the tool along the tangential direction is f, that is, it should reach after one feed step. Point, obviously,
The length is f. As can be seen from the figure, its radial error is larger. Extending the DDA algorithm does not allow the tool to feed along the tangent, but instead transforms the method of approaching the tangent to a circular arc into a string approach method.
If we pass The midpoint B of the segment is a tangent to the arc of radius OB
And then through Ai
Parallel line AiH, ie AiH∥
, and interception on AiH
(It is easy to prove that the Ai+1 point is not on the arc side). Expand DDA is to use line segments
AiAi+1 feed instead The tangent feed, that is, the result of the extended DDA calculation over a sampling period, should be that the tool travels from the Ai point along the string to the Ai+1 point (instead of walking along the tangent line)
point). Obviously, this feed reduces the radial error.
Now we calculate the coordinate components Δxi+1 and Δyi+1 of the contour feed step f within the sampling period λt. We obtain these two values ​​and it is easy to get the coordinate position Ai after this sampling period. +1.
Can be seen from Figure 2-31, in the right angle â–³ OPAi
Let the tool feed at constant speed, that is, the feed rate in each sampling period λt is v, obviously, AiAi+1=f=vλt. The B-point parallel line BS for the x-axis crosses the y-axis at point S, and the AiP segment goes to point S'. It can be seen that the right angle ΔOSB is similar to the right angle ΔAiN'Ai+1 and thus has a proportional relationship:
In the formula
In the right angle â–³AiS'B
therefore
In right angle â–³OAiB
Substituting the above formulas into equation (2-34),
Substituting (2-32) into the above formula and finishing
Since f>R, it will Abbreviated, the above formula is
If
then
In the above two similar triangle relations, there is the following formula:
which is
A known
By the right angle â–³AiS'B
And SS'=xi, so
Similarly, because f>R, it is omitted Excluding, then
Still remember
then
Since Ai(xi, yi) is known, Δxi+1 and Δyi+1 values ​​are easily found using equations (2-35) and (2-36). With these two values, the coordinate positions xi+1 and yi+1 that the tool should reach in this sampling period can be calculated.
According to this principle, it is not difficult for readers to find the calculation formulas for circular interpolation in other quadrants and other directions. I will not repeat them here.