A method and apparatus for synchronizing calibration of a gantry bus system

By acquiring asynchronous clock deviation and performing counting compensation and adjustment, combined with adjusting filter gain and limiting mechanism, the clock synchronization problem between the two axes of the gantry in the gantry bus system is solved, improving control accuracy and stability and reducing error accumulation.

CN119788230BActive Publication Date: 2025-11-18SHANGHAI INVT INDUSTRY TECHNOLOGY CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510034987.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-01-09
Publication Date
2025-11-18
Estimated Expiration
2045-01-09

AI Technical Summary

Technical Problem

In a gantry bus system, the asynchronous clock deviation between the two gantry axes makes it difficult to meet the control accuracy requirements of high-precision application scenarios. Existing synchronous calibration methods suffer from problems such as the accumulation of asynchronous clock deviation, adjustment anomalies caused by hard-pull counting, and error accumulation.

Method used

By acquiring the asynchronous clock deviation during communication between the master and slave axes, latching the count value and performing count compensation, and adjusting the filter gain and count increment, clock synchronization between the two axes of the gantry is achieved. Closed-loop control and limiting mechanisms are used to avoid large single adjustments, and a delay module is used to measure the asynchronous clock deviation to improve calibration accuracy.

Benefits of technology

It achieves clock synchronization between the two axes of the gantry, reduces the error introduced by asynchronous clock deviation, improves control accuracy, avoids control anomalies, and enhances the stability and efficiency of calibration.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119788230B_ABST
    Figure CN119788230B_ABST
Patent Text Reader

Abstract

The application discloses a synchronous calibration method and equipment of a gantry bus system, and relates to the technical field of automatic control.The method compensates the count setting value of a time sequence counter through the asynchronous clock deviation between the communication of a gantry double shaft, obtains a count parameter compensation value, locks the count value of the time sequence counter at the current time when the slave shaft receives the data frame sent by the main shaft to obtain a communication lock count value, determines a count deviation value according to the count parameter compensation value and the communication lock count value, determines a count adjustment increment according to a preset adjustment filter gain, and adjusts the communication lock count value based on the count adjustment increment.The count adjustment increment obtained through the count deviation value is used to adjust the communication lock count value of the slave shaft, the communication between the main shaft and the slave shaft is synchronized, the adjustment filter gain is introduced when the count adjustment increment is determined, the interference part in the count deviation value is effectively filtered out, and finally the control precision of the gantry double shaft servo is improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of automation control, in particular to a gantry bus system synchronization calibration method and device. BACKGROUND

[0002] With the rapid development of the industry and intelligent manufacturing industry, the control accuracy of gantry machines for high-end equipment such as semiconductors is constantly improving. One important factor restricting the high-speed and high-precision performance of gantry control is the clock deviation of gantry synchronization communication. At present, the double-axis servo of the gantry bus system adopts an asynchronous communication mode. Asynchronous communication inevitably causes asynchronous clock deviation between the double-axis servo of the gantry. This asynchronous clock deviation cannot be predicted and ignored, which makes it difficult for the current double-axis servo of the gantry to meet the control needs of high-precision application scenarios. SUMMARY

[0003] The purpose of the present application is to provide a gantry bus system synchronization calibration method and device to improve the control accuracy of the double-axis servo of the gantry, so as to meet the control needs of the gantry bus system in high-precision application scenarios.

[0004] To solve the above technical problems, the present application provides a gantry bus system synchronization calibration method. The gantry bus system includes a master axis and a slave axis. The method is applied to the slave axis. The method includes:

[0005] Obtaining an asynchronous clock deviation when communicating with the master axis;

[0006] Obtaining a communication latch count value; wherein the communication latch count value is the current count value of the time sequence counter when receiving the data frame sent by the master axis;

[0007] According to the asynchronous clock deviation, the count set value of the time sequence counter is compensated to obtain a compensated count parameter compensation value;

[0008] According to the count parameter compensation value and the communication latch count value, a count deviation value is determined;

[0009] According to the count deviation value and a preset adjustment filter gain, a count adjustment increment is determined;

[0010] Based on the count adjustment increment, the communication latch count value is adjusted.

[0011] In one possible embodiment, adjusting the communication latch count value based on the count adjustment increment includes:

[0012] If the count adjustment increment is less than or equal to a preset adjustment threshold, the communication latch count value is adjusted according to the count adjustment increment.

[0013] In a possible embodiment, the adjusting the communication latched count value based on the count adjustment increment comprises:

[0014] If the count adjustment increment is greater than a preset adjustment threshold, the communication latched count value is adjusted according to the adjustment threshold.

[0015] In a possible embodiment, after the communication latched count value is adjusted based on the count adjustment increment, the method further comprises:

[0016] determining whether the adjusted communication latched count value is equal to the count parameter compensation value;

[0017] If not, returning to the step of determining the count deviation value according to the count parameter compensation value and the communication latched count value.

[0018] In a possible embodiment, the adjustment filter gain is 2 -k ; wherein k is any positive integer;

[0019] determining the count adjustment increment according to the count deviation value and a preset adjustment filter gain comprises:

[0020] performing right shift processing on the count deviation value by k bits to obtain the count adjustment increment.

[0021] In a possible embodiment, before the communication latched count value is adjusted based on the count adjustment increment, the method further comprises:

[0022] If the count deviation value meets a first condition and the count adjustment increment meets a second condition, adjusting the count adjustment increment to a preset value.

[0023] In a possible embodiment, determining the count deviation value according to the count parameter compensation value and the communication latched count value comprises:

[0024] selecting count parameter compensation values adjacent to the communication latched count value and located in two different count periods;

[0025] determining the difference between the two count parameter compensation values and the communication latched count value respectively to obtain two intermediate deviation values;

[0026] taking the intermediate deviation value with the smallest absolute value as the count deviation value;

[0027] pointing the direction of the communication latched count value to the count parameter compensation value as the adjustment direction corresponding to the count adjustment increment.

[0028] In a possible embodiment, obtaining the asynchronous clock deviation when communicating with the main shaft comprises:

[0029] obtaining the asynchronous clock deviation once when the gantry bus system is powered on;

[0030] acquiring the communication latch count value comprises:

[0031] the communication latch count value is acquired periodically, and each time a new communication latch count value is acquired, the step of determining the count deviation value according to the count parameter compensation value and the communication latch count value is triggered.

[0032] In a possible embodiment, the slave further comprises a delay module;

[0033] acquiring the asynchronous clock deviation when communicating with the master comprises:

[0034] transmitting the time delay detection frame between the master and the slave, and taking the transmission time delay of the transmission process as the delay measurement result;

[0035] under the condition that the delay module is used to inject a delay link into the communication between the master and the slave, transmitting the time delay detection frame between the master and the slave, and taking the transmission time delay of the transmission process as the second transmission time delay;

[0036] if the second transmission time delay is greater than the delay measurement result, taking the current delay measurement result as the asynchronous clock deviation.

[0037] In a possible embodiment, the method further comprises:

[0038] if the second transmission time delay is less than or equal to the delay measurement result, taking the second transmission time delay as the new delay measurement result;

[0039] increasing the number of delay links injected by the delay module;

[0040] if the number of times of increasing the number of delay links does not exceed a preset search number threshold, returning to the step of transmitting the time delay detection frame between the master and the slave under the condition that the delay module is used to inject a delay link into the communication between the master and the slave, and taking the transmission time delay of the transmission process as the second transmission time delay;

[0041] if the number of times of increasing the number of delay links exceeds the search number threshold, taking the current delay measurement result as the asynchronous clock deviation.

[0042] To solve the above technical problems, the application further provides a synchronization calibration method of a gantry bus system, the gantry bus system comprising a master and a slave; the method is applied to the master; and the method comprises:

[0043] acquiring the asynchronous clock deviation when communicating with the slave;

[0044] acquiring a communication latch count value; wherein the communication latch count value is a current count value of a time sequence counter when a data frame sent by the slave is received;

[0045] According to the asynchronous clock deviation, the count setting value of the time sequence counter is compensated to obtain a compensated count parameter compensation value;

[0046] According to the count parameter compensation value and the communication latched count value, a count deviation value is determined;

[0047] According to the count deviation value and a preset adjustment filter gain, a count adjustment increment is determined;

[0048] Based on the count adjustment increment, the communication latched count value is adjusted.

[0049] To solve the above technical problems, the application further provides a synchronization calibration device for a gantry bus system, comprising:

[0050] A memory for storing a computer program;

[0051] A processor for executing the computer program to implement the steps of the synchronization calibration method for the gantry bus system.

[0052] The synchronization calibration method for the gantry bus system provided by the application compensates the count setting value of the time sequence counter through the asynchronous clock deviation during communication between the gantry double shafts, thereby realizing clock synchronization between the gantry double shafts. Further, for asynchronous communication between the gantry double shafts, the method latches the count value of the time sequence counter at the current time when the slave shaft receives the data frame sent by the master shaft to obtain a communication latched count value. The communication latched count value represents the time when the slave shaft receives the data frame sent by the master shaft. Since the count setting value of the slave shaft has been compensated through the asynchronous clock deviation, clock synchronization between the master shaft and the slave shaft is realized. At this time, the count deviation value between the compensated count setting value and the communication latched count value in the slave shaft represents the communication delay required for the master shaft to send the data frame to the slave shaft. The method not only adjusts the communication latched count value of the slave shaft through the count adjustment increment obtained from the count deviation value to realize communication synchronization between the master shaft and the slave shaft, but also introduces an adjustment filter gain when determining the count adjustment increment to effectively filter out the interference part in the count deviation value, avoid the case of excessive single adjustment, realize the smoothing of the count value adjustment process in the time sequence synchronization process, better avoid the control abnormality problem that may occur in the adjustment process, and finally improve the control precision of the gantry double shaft servo.

[0053] The other synchronization calibration method for the gantry bus system and the synchronization calibration device for the gantry bus system provided by the application correspond to the above method and have the same effect. BRIEF DESCRIPTION OF DRAWINGS

[0054] In order to more clearly illustrate the embodiments of the present application, the following will briefly introduce the drawings needed to be used in the embodiments. Obviously, the drawings described below are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without any creative effort on the basis of these drawings.

[0055] Figure 1 Timing count schematic diagram for servo gantry communication bus;

[0056] Figure 2 Flow chart of the synchronization calibration method of the gantry bus system provided by the embodiment of the present application;

[0057] Figure 3 Counting deviation calibration schematic diagram provided by the embodiment of the present application;

[0058] Figure 4 Flow chart of the counting increment adjustment method provided by the embodiment of the present application;

[0059] Figure 5 Timing diagram before timing count value correction provided by the embodiment of the present application;

[0060] Figure 6 Timing diagram after timing count value correction provided by the embodiment of the present application;

[0061] Figure 7 Architectural schematic diagram of the gantry bus system provided by the embodiment of the present application;

[0062] Figure 8 Flow chart of the asynchronous clock deviation measurement method provided by the embodiment of the present application;

[0063] Figure 9 Timing principle diagram of the asynchronous clock deviation measurement method provided by the embodiment of the present application;

[0064] Figure 10 Timing diagram before injecting a delay link provided by the embodiment of the present application;

[0065] Figure 11 Timing diagram after injecting a delay link provided by the embodiment of the present application;

[0066] Figure 12 Structural diagram of the synchronization calibration device of the gantry bus system provided by the present application. DETAILED DESCRIPTION

[0067] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the protection scope of this application.

[0068] The core of this application is to provide a synchronous calibration method and device for a gantry bus system.

[0069] To enable those skilled in the art to better understand the present application, the present application will be further described in detail below with reference to the accompanying drawings and specific embodiments.

[0070] In related technologies, to achieve data communication between the two axes of a gantry servo system, bus communication functionality is added to both the master and slave axes. This enables communication between the master and slave axes (hereinafter referred to as communication between the master and slave axes). This overall system, where the master and slave axes communicate via a bus, is called a gantry bus system. Furthermore, to address the asynchronous communication issue between the master and slave axes in a gantry bus system, a current approach involves adding an internal clock synchronization function to the communication bus protocol of the master and slave axes. By forcibly aligning the timing counter values ​​of the two gantry servo systems, synchronization between the master and slave axes is achieved.

[0071] Specifically, such as Figure 1 As shown, the timing counter of the gantry servo system consists of two parts: an up-counting part and a down-counting part. These two parts together form a counting interval (also called a counting cycle). The up-counting phase is when the value of the timing counter increments from 0 to a preset count set value (i.e., ...). Figure 1 The counting process starts from 0 and progresses to Cmax. The next counting phase involves the timing counter decrementing from the set value back to 0 (i.e.,...). Figure 1 The counting process starts from Cmax and ends at 0. Communication between the two gantry axes occurs during the next counting phase, with data packets being sent to each other at the start of the next counting phase.

[0072] Based on the above, when the gantry dual-axis receives a data packet from the other party, it can perform synchronization calibration by sending a synchronization calibration frame back to the other party. Specifically, upon receiving the synchronization calibration frame from the other party, the communication delay can be calculated based on the time when it sent the data packet and the time when it received the synchronization calibration frame. Then, the timing counter is adjusted and compensated to bring the count values ​​of the gantry dual-axis together and achieve timing synchronization.

[0073] However, this calibration scheme has many problems:

[0074] 1. The gantry servo system experiences high-current interference during operation. If the starting position of the next counting stage is disturbed during calibration using the aforementioned hard-counting method, it will lead to abnormal adjustment. This will cause the servo system's control timing to become disordered, and in severe cases, it may even trigger a runaway alarm.

[0075] 2. Due to the asynchronous clock of the dual-axis gantry, cumulative deviations will occur over time. Therefore, it is necessary to continuously adjust the timing counter inside the servo, making the safety hazards caused by problem 1 above increasingly important.

[0076] 3. Furthermore, the above-described counting calibration method requires the master axis to send a data packet to the slave axis, and then the slave axis to return a synchronization calibration frame to the master axis for synchronization calibration. This involves one communication from the master axis to the slave axis and one communication from the slave axis to the master axis. Each communication between the master and slave axes introduces an asynchronous clock skew, resulting in two asynchronous clock skews between the two communications. Two asynchronous clock skews introduce a larger error than a single asynchronous clock skew, thus affecting the accuracy of the calibration more significantly.

[0077] To address the aforementioned problems, this application provides a synchronous calibration method for a gantry bus system, which includes a master spindle and a slave spindle. The method is specifically applied to the slave spindle, such as... Figure 2 As shown, the method includes:

[0078] S10: Obtain the asynchronous clock offset when communicating with the spindle.

[0079] S20: Obtain the communication latch count value.

[0080] The communication latch count value is the current count value of the timing counter that is latched when a data frame sent by the spindle is received. The communication latch count value represents the moment when the slave axis receives the data frame sent by the spindle.

[0081] S30: Based on the asynchronous clock deviation, compensate the counting set value of the timing counter to obtain the compensated counting parameter value.

[0082] S40: Determine the counting deviation value based on the counting parameter compensation value and the communication latch count value.

[0083] S50: Determine the count adjustment increment based on the count deviation value and the preset adjustment filter gain.

[0084] S60: Adjust the communication latch count value based on the count adjustment increment.

[0085] It should be noted that steps S10 and S20 can be implemented in parallel or sequentially. When implemented sequentially, there is no requirement for their order. Regarding the implementation of step S10, this embodiment does not impose limitations; the asynchronous clock deviation measurement can be implemented as described above in the related technology section. Alternatively, it can be implemented using another measurement method provided in subsequent embodiments of this application. For the implementation of step S20, as explained above, the communication latch count value is obtained by latching the current timing counter value when a data frame sent by another axis is received. The aforementioned data frame can be any data frame sent from the master axis to the slave axis; this embodiment does not limit the format of the data frame or the content contained within it.

[0086] In addition, this embodiment also provides another possible implementation:

[0087] The above-mentioned step S10 is executed once when the gantry bus system is powered on; step S20 is performed periodically, and step S30 is triggered whenever step S20 obtains a new communication latch count value.

[0088] It should be noted that the period for executing step S20 in this embodiment can be freely set according to actual needs, and the duration of this period is not limited in this embodiment. Furthermore, this period specifically refers to the time interval for repeatedly executing step S20, and is unrelated to the counting period mentioned above.

[0089] In other words, this embodiment provides a closed-loop control method that uses the communication latch count value as feedback to achieve closed-loop count value calibration. Thus, even if a cumulative count deviation occurs during the continuous operation of the gantry dual-axis, it can be detected in a timely manner, and the count value can be recalibrated based on the newly determined communication latch count value, thereby solving the cumulative count deviation problem. Furthermore, since the asynchronous clock deviation between the gantry dual axes is generally not prone to change, to reduce resource consumption and improve calibration efficiency, this embodiment adopts a strategy of performing the calibration only once when the communication gantry bus system is powered on.

[0090] Regarding step S30, as explained in the above-mentioned technical section, due to the asynchronous clock deviation between the master and slave axes, the timing of the slave axis sending data packets (when the timing counter reaches the set count value) is not the same as the timing of the master axis sending data packets. Therefore, step S30 compensates for the set count value using the asynchronous clock deviation obtained in step S10 to obtain the count value corresponding to the actual time the master station sends data packets, i.e., the count parameter compensation value.

[0091] Step S30 can be represented by the following formula (1):

[0092] (1);

[0093] This is the compensation value for the counting parameter. Set the count value. Asynchronous clock skew The corresponding count value.

[0094] For example, this embodiment provides a possible scenario diagram for determining the communication latch count value and the count parameter compensation value in the above steps S20 and S30, such as... Figure 3 As shown. Figure 3 The deviation between the communication latch count value and the count parameter compensation value is the count deviation value determined in step S40, which is also the part of the count value that needs to be calibrated by this method. In other words, the ultimate goal of this method is to adjust... Figure 3 The marker segment containing the communication latch count value is aligned with the marker segment containing the count parameter compensation value. However, it's important to note that step S30 corresponds to adjusting the set count value of the slave axis timing counter. The purpose is to achieve clock cycle synchronization between the master and slave axes, meaning the timing counters of the master and slave axes reach the set count value (the time of sending a data frame) at the same time. Step S60 corresponds to adjusting the count value latched by the slave axis timing counter when it receives a data frame sent by the master axis, i.e., the communication latch count value. This ensures that, while maintaining clock synchronization between the master and slave axes, the timing of the master axis sending data frames and the slave axis receiving data frames are also synchronized, resolving the issue of low control accuracy caused by asynchronous timing and communication between the two gantry axes.

[0095] In step S40, the adjusted filter gain is used to suppress the portion of the count deviation caused by interference. Generally, adjusting the absolute value of the filter gain to be less than 1 is sufficient to achieve the "suppression" effect. That is, by multiplying by a number with an absolute value less than 1, the absolute value of the count deviation is reduced (i.e., the count adjustment increment obtained in step S50), and the portion of the count deviation caused by interference also decreases. The introduction of the adjusted filter gain can effectively suppress large deviations caused by interference such as high currents in the gantry dual-axis working environment, thus avoiding large single adjustments due to large deviations and preventing control problems caused by excessive adjustments to the timing counter value in a single operation.

[0096] It should also be noted that the count setpoint refers to the maximum value that the sequential counter can reach in one counting cycle, which is also the midpoint of the entire counting cycle. Therefore, after compensating for the count setpoint, there is a moment in each counting cycle when the count value of the sequential counter reaches the compensated count setpoint (i.e., the compensated count parameter value). When adjusting the communication latch count value, such as... Figure 3As shown, the straight line segment corresponding to the communication latch count value can be adjusted to coincide with the straight line segment corresponding to the count parameter compensation value in any counting cycle, thereby achieving communication synchronization between the master and slave axes.

[0097] However, considering that the adjustment of the count value always aims to minimize the adjustment amount, when selecting the compensation value of the count parameter as the adjustment target, such as Figure 3 As shown, the adjustment target is typically selected from the compensation values ​​of the counting parameters in two adjacent counting cycles of the communication latch count. This is because the compensation value of the counting parameter corresponding to the smallest counting deviation always occurs in these two counting cycles adjacent to the communication latch count.

[0098] Furthermore, considering that there are two adjustment directions when adjusting the timing counter's count value—increasing (positive) and decreasing (negative)—corresponding to positive and negative count deviations respectively, it's important to note that increasing and decreasing the timing counter value also correspond to the direction of timing. Increasing the count value corresponds to the positive direction of timing, that is,... Figure 3 The rightward direction in the sequence. Similarly, a decrease in the count value corresponds to the reverse of the timing sequence, that is, to the rightward direction. Figure 3 The left direction in the middle. Especially as Figure 3 As shown, since a communication latch count value has two adjacent count parameter compensation values ​​in different counting periods, it is necessary to note that there are two adjustment directions: forward and reverse. These two adjustment directions can be freely chosen according to actual needs, and this embodiment does not impose any restrictions on them.

[0099] Therefore, to avoid changing the adjustment direction by adjusting the filter gain, a positive number can be selected as the value for adjusting the filter gain. Based on the above two selection conditions for adjusting the filter gain, the filter gain can be any value less than 1 and greater than 0.

[0100] The above adjustment process can be represented by the following equations (2) and (3):

[0101] (2);

[0102] (3);

[0103] in, This is the counting deviation value; The positive distance; The reverse distance; To adjust the direction, 1 represents positive and 0 represents negative.

[0104] In view of this, this embodiment also provides a possible implementation scheme for the specific implementation of step S40:

[0105] S41: Select a compensation value for the counting parameter that is adjacent to the communication latch count value and located in two different counting cycles.

[0106] S42: Determine the difference between the compensation values ​​of the two counting parameters and the communication latch count value respectively to obtain two intermediate deviation values.

[0107] S43: Take the intermediate deviation with the smaller absolute value among the two intermediate deviation values ​​as the counting deviation value.

[0108] Corresponding to step S50, this embodiment also includes:

[0109] The direction in which the communication latch count value points to the count parameter compensation value serves as the adjustment direction corresponding to the count adjustment increment.

[0110] In such Figure 3 In the example shown, it can be observed that the forward distance is greater than the reverse distance. Therefore, for Figure 3 In one example shown, the intermediate deviation value selected as the counting deviation value in step S43 is... Figure 3 The reverse distance in the calculation. And the adjustment direction corresponding to the count adjustment increment is reversed, i.e. Figure 4 The method involves adjusting the communication latch count value to the left to align it with the compensation value of the counting parameter to the left of the communication latch count value.

[0111] As described above, this embodiment further optimizes the two possible adjustment directions that exist during actual count value calibration. Using the adjustment distance as a reference, the direction with the shorter adjustment distance is selected as the adjustment direction, and the intermediate deviation value corresponding to this adjustment direction is also the final count deviation value involved in the adjustment. The adjustment scheme provided by this embodiment can reduce the adjustment amount of the count value, thereby completing calibration faster and better avoiding control anomalies caused by excessive adjustment.

[0112] Furthermore, this embodiment also provides a possible implementation for adjusting the communication latch count value, wherein step S60 includes:

[0113] S61: If the count adjustment increment is less than or equal to the preset adjustment threshold, the communication latch count value is adjusted according to the count adjustment increment.

[0114] Therefore, this embodiment provides a limiting mechanism that restricts the adjustment amount of a single adjustment to the communication latch count value (i.e., limits the size of the count adjustment increment) by using a pre-set adjustment threshold. The communication latch count value is adjusted only when the count adjustment increment is less than or equal to the adjustment threshold. Based on the setting of the adjustment threshold, it can be ensured that the adjustment amount of the communication latch count value is not too large, that is, the "limiting" of the count value adjustment is achieved, avoiding control anomalies caused by excessive single adjustments.

[0115] Furthermore, regarding how to adjust the communication latch count value when the count adjustment increment is greater than the adjustment threshold, this embodiment also provides a possible implementation scheme, step S60 including:

[0116] S62: If the count adjustment increment is greater than the preset adjustment threshold, the communication latch count value is adjusted according to the adjustment threshold.

[0117] Similar to the previous embodiment, this embodiment also provides a limiting mechanism. The difference lies in the different scenarios addressed in this embodiment. The previous embodiment focused on ensuring that the increment of the count adjustment was not too large when adjusting the communication latch count value. This embodiment, however, addresses how to adjust the communication latch count value when the increment is too large. This embodiment adjusts the communication latch count value directly using the limiting condition (i.e., the maximum acceptable adjustment amount) when the increment exceeds the adjustment threshold. This achieves the goal of adjusting the communication latch count value to realize communication synchronization while avoiding control anomalies caused by excessively large single adjustments.

[0118] In summary, after step S50 determines the count adjustment increment, based on the relationship between the count adjustment increment and the preset adjustment threshold, there are two possible branches, corresponding to steps S61 and S72 respectively. The adjustment threshold in the above embodiment is a limiting condition, that is, it limits the maximum value of the timing counter count in a single adjustment, avoiding control problems caused by excessive single adjustment.

[0119] Furthermore, based on the amplitude limiting condition and the setting of the adjusted filter gain, the deviation between the communication latch count value and the count parameter compensation value may not be completed in one adjustment. Therefore, this embodiment also provides another possible implementation scheme. After steps S61 and S62, the above method further includes:

[0120] S70: Determine whether the adjusted communication latch count value is equal to the count parameter compensation value. If not, return to step S40.

[0121] In other words, this embodiment provides a looping mechanism that, through repeated adjustments implemented in steps S40 to S70, ensures that the counting deviation between the communication latch count value and the counting parameter compensation value can be eliminated, thus achieving timing synchronization of data frame transmission and reception between the two gantry axes. It is easy to understand that, in addition to exiting the loop upon reaching the exit condition (i.e., the branch in step S70), the above loop can also enter a new loop when a new communication latch count value requiring adjustment is obtained in step S20. At this time, the old loop can exit, or the adjustments of the old and new loops can be performed in parallel; this embodiment does not impose any restrictions on this.

[0122] On the other hand, this embodiment also provides a further implementation scheme for adjusting the filter gain:

[0123] Adjust the filter gain to 2 -k Where k is any positive integer.

[0124] Furthermore, step S50 above is as follows:

[0125] The count deviation value is shifted right by k bits to obtain the count adjustment increment.

[0126] First, when the adjusted filter gain is the result of dividing 1 by any positive integer other than 1, this method can complete one calibration by adjusting the count value an integer number of times. In other words, for a communication latch count value determined in step S20, calibration can be completed by looping through steps S40 to S80 an integer number of times.

[0127] Furthermore, this embodiment also restricts the adjustment of the filter gain to a negative power of 2, with the exponent being k. Thus, the calculation of the count adjustment increment can be achieved through a shift algorithm. It should be noted that this method can be implemented using a Field-Programmable Gate Array (FPGA) in a practical communication-type gantry bus system. To facilitate FPGA calculations, shift calculations are used instead of multiplication or division, thereby further improving calibration efficiency.

[0128] In one possible implementation, the filter gain is adjusted to 2. -3 =0.125. At this time, step S32 can be achieved by shifting right by 3 bits, as shown in equation (4) below:

[0129] (4);

[0130] in, Adjust the increment for counting.

[0131] Regarding steps S60 and S70 above, since the actual limiting of an adjustment is generally expressed in terms of the duration corresponding to the adjustment increment, for example, in one possible case, the limiting condition is that the adjustment increment is less than 1µs. In this case, it is necessary to convert the time unit to a counting unit. For a counter with a counting frequency of 50MHz, 1µs corresponds to a count value of 50. Therefore, the above limiting condition of 1µs can be converted into 50 counting units, that is, the adjustment threshold = 50.

[0132] Furthermore, this embodiment provides a further implementation scheme based on the previous embodiment. Before step S60, the method further includes:

[0133] S80: If the counting deviation value meets the first condition and the counting adjustment increment meets the second condition, adjust the counting adjustment increment to the preset value.

[0134] Optionally, the first condition mentioned above can be: the count deviation value is not 0; the second condition mentioned above can be: the count adjustment increment is 0; in this case, the preset value mentioned above is 1.

[0135] It should be noted that the first and second conditions can be set according to actual needs. This embodiment does not impose any limitations on them.

[0136] It is readily known that computers and FPGAs generally ignore remainders when performing division operations. This is especially true in the above embodiment where step S50 is implemented using a shift algorithm, where the remainder is ignored. However, taking the example of adjusting the filter gain to 0.125, if the count deviation is any positive integer from 1 to 7, the count adjustment increment obtained after the shift calculation is 0. But since the count deviation is not actually 0, at least one unit of adjustment is still needed (i.e., the technical adjustment increment is 1). Therefore, this method provides a corresponding implementation scheme for this situation, effectively solving the problem of missing adjustment caused by the loss of remainders during division and right shift operations by computers and FPGAs in the underlying code implementation of this method.

[0137] Based on the specific implementation schemes proposed in the above embodiments for the count adjustment increment, this embodiment also provides a schematic diagram of the overall process for determining the count adjustment increment, as follows: Figure 4 As shown. Figure 4 In the example above, the limiting condition is 1µs and the counter's counting frequency is 50MHz, so the threshold is adjusted to 50. The counting deviation value is then obtained. and the count adjustment increment obtained after shift calculation Afterwards, as if Figure 5 The procedure shown is used to obtain the final count adjustment increment for calibration. .

[0138] In one possible example, the dual-axis timing before gantry bus synchronization calibration is as follows: Figure 6 As shown. After calibration using this method, the dual-axis timing is as follows. Figure 7 As shown.

[0139] In summary, the synchronous calibration method for a servo gantry communication bus provided in this application can achieve timing synchronization between the two axes of the gantry, thereby solving the control problems caused by asynchronous communication. Furthermore, the communication synchronization achieved by this method requires only one unidirectional data transmission from the master axis to the slave axis, introducing only one asynchronous clock deviation. Compared to the two asynchronous clock deviations introduced by the reciprocating communication between the master and slave axes in related technologies, this method introduces less error, thus resulting in higher control accuracy. In addition, this method introduces adjustment filter gain when determining the count adjustment increment, which can effectively reduce the portion of the count deviation value caused by interference. This avoids excessive single adjustment and smooths the count value adjustment process during timing synchronization, better preventing control anomalies that may occur during adjustment.

[0140] On the other hand, this embodiment also provides a corresponding implementation scheme for measuring the aforementioned asynchronous clock deviation, such as... Figure 8 As shown: The communication-type gantry bus system includes a master spindle and a slave spindle, both of which include a 485 transceiver module for communication. The slave spindle also includes a delay module and a communication measurement module.

[0141] The delay module injects a delay interval Tdelay when the slave axis returns a Transmission Delay Detection Frame (DCF) from the master axis. That is, after enabling the delay module, the slave axis no longer immediately returns a DCF frame to the master axis upon receiving it; instead, it returns the DCF frame after a certain delay. The delay module can be implemented using inverters. By controlling the path length between the two selected inverters, the delay time can be controlled. The smallest delay unit that the delay module can achieve is called a delay interval Tdelay.

[0142] The communication measurement module is specifically the execution body of the method provided in this embodiment on the shaft side, and can be implemented based on devices such as FPGA.

[0143] Specifically, such as Figure 9 As shown, step S10 specifically includes:

[0144] S11: Transmit the delay detection frame between the master axis and the slave axis, and use the transmission delay of the transmission process as the first transmission delay.

[0145] S12: Use the first transmission delay as the delay measurement result Tdl.

[0146] S13: Under the condition of injecting a delay element into the communication between the master and slave axes through the delay module, the delay detection frame between the master and slave axes is transmitted, and the transmission delay of the transmission process is used as the second transmission delay.

[0147] S14: If the second transmission delay is greater than the delay measurement result, then the current delay measurement result is taken as the asynchronous clock deviation.

[0148] The asynchronous clock deviation measurement principle implemented by the above steps is as follows: Figure 9 As shown in the figure. Here, Mtx represents the master spindle transmit timing, SRx represents the slave spindle receive timing, STx represents the slave spindle transmit timing, and MRx represents the master spindle receive timing. This indicates the total time taken to transmit one DCF frame round trip. This indicates the measured transmission delay. The transmission delay for each DCF.

[0149] Before describing the measurement scheme provided in this embodiment, let's first describe the measurement schemes proposed in related technologies: such as... Figure 10 As shown, in related technologies, the master axis sends a DCF frame to the slave axis, and the slave axis immediately returns a DCF frame to the master axis after receiving the DCF frame sent by the master axis. This completes one round-trip transmission of a DCF frame, and the total time for transmitting one DCF frame round-trip can then be measured. Furthermore, due to the transmission delay of DCF frames... Given that, therefore based on and The transmission delay can be calculated. and transmission delay This is the final measured asynchronous clock bias.

[0150] However, it's not difficult to see that this measurement process is affected by the clock frequencies of the master and slave axes. That is, as... Figure 10 As shown, there can be a maximum error of one clock cycle between the actual start time of receiving the DCF frame and the start time of latching the DCF frame received by the spindle. However, due to the performance and cost limitations of the 485 chip, the individual differences in communication latency for most 485 chips at the factory are between 30-60ns, which cannot be compensated for with a fixed value. Furthermore, most servo system FPGA products currently use a stable 50MHz clock, which adds another 20ns to the asynchronous clock deviation.

[0151] To address the above, this method compensates for the deviation of the dual-axis asynchronous clock by adding a delay element. As described above regarding the delay module, the delay module can be based on an inverter to inject a delay element with smaller time granularity, thereby filling the gap in the clock cycle of the gantry servo system. Furthermore, this embodiment also provides a possible implementation based on this, wherein step S10 above further includes:

[0152] S15: If the second transmission delay is less than or equal to the delay measurement result, then the second transmission delay shall be taken as the new delay measurement result.

[0153] S16: Increase the number of delay elements injected by the delay module.

[0154] S17: If the number of times the delay step is increased does not exceed the preset search count threshold, return to step S13.

[0155] As can be seen from the above, this embodiment continuously injects delay elements, and when entering the branch where step S15 is located, Figure 11 It can be filled in as follows Figure 11 The timing diagram is shown below. Figure 8 It is easy to see that injection based on a delay element can reduce the deviation between the receiving time and the latching time to no more than one delay element. Since the delay module can achieve finer-grained delays, the transmission delay measured by this method is... The deviation from the actual transmission delay is also smaller. Through extensive experiments and simulations, the asynchronous clock deviation measurement achieved by this method can reach an accuracy of 3ns, which is significantly better than the measurement schemes provided in related technologies.

[0156] Furthermore, since the loop formed by steps S13 to S16 generally has an upper limit on the number of loops in practical applications, the transmission delay measurement process of the injection delay stage is convergent. However, considering special cases and to ensure the closed loop of the control logic, this embodiment provides a loop exit mechanism in step S17 when the transmission delay measurement does not converge, to avoid the calibration process entering an infinite loop under special circumstances.

[0157] In this embodiment, based on the upper limit of the number of loops determined during design (e.g. Figure 12 As shown, in one example, the upper limit is 9. Each execution of step S113 is considered a search, the number of searches (Scnt) is counted, and it is determined whether the number of searches (Scnt) exceeds a preset search threshold. If so, the loop exits, and the current delay measurement result (Tdl) is used as the final asynchronous clock deviation. It should be noted that step S116 corresponds to a very special application scenario. Even in this scenario, this method injects a delay element with a number reaching the error search threshold. Although it does not achieve the optimal situation corresponding to step S115 (i.e., controlling the deviation between the receiving time and the latching time within one delay element), it still significantly reduces the deviation compared to before the delay injection (reducing the deviation by the error search threshold and the number of delay elements), and its accuracy is still higher than the measurement schemes proposed in related technologies.

[0158] On the other hand, regarding the detection of the first transmission delay and the second transmission delay in steps S11 and S13 above, this embodiment also provides a possible implementation scheme:

[0159] Multiple delay detection frames are transmitted between the master and slave axes, and the average of the transmission delays during the multiple transmission processes is calculated to obtain the first transmission delay / the second transmission delay.

[0160] Specifically, the measurement scheme provided in this embodiment can be represented by the following formulas (5) and (6):

[0161] (5);

[0162] (6);

[0163] Where n is the number of times the DCF frame is transmitted back and forth. In one possible embodiment, n is 3. This is the total time taken to transmit n DCF frames round trip. Measured without any delay intervention. This is the first transmission delay, which serves as the initial delay measurement result Tdl.

[0164] This embodiment further reduces the measurement error in the transmission delay measurement process by averaging multiple measurements, thereby improving the measurement accuracy. Additionally, after the delay element is injected in step S13, the second transmission delay Td can be obtained using the following formula (7):

[0165] Td = -Tdelay * 0.5 (7).

[0166] On the other hand, the synchronous calibration method for a gantry bus system provided in the above embodiments uses the slave axis in the gantry bus system as the execution subject for synchronous calibration. This is because in the communication process of a dual-axis gantry, the slave axis primarily acts as the data receiver, making it easier and more accurate to achieve communication synchronization through calibration at the receiver. However, it should be noted that this does not mean that the synchronous calibration method for a gantry bus system provided in this application cannot be implemented on the master axis. Based on this, this embodiment also provides a synchronous calibration method for a gantry bus system using the master axis as the execution subject, which is also applied to a gantry bus system including a master axis and a slave axis, with the master axis as the execution subject. The method includes:

[0167] Obtain the asynchronous clock offset when communicating with the slave axis.

[0168] Get the communication latch count value.

[0169] The communication latch count value is the current count value of the timing counter that is latched when a data frame sent from the axis is received.

[0170] The counting setpoint of the timing counter is compensated based on the asynchronous clock deviation to obtain the compensated counting parameter value.

[0171] The counting deviation value is determined based on the compensation value of the counting parameters and the count value of the communication latch.

[0172] The count adjustment increment is determined based on the count deviation value and the preset adjustment filter gain.

[0173] The communication latch count value is adjusted based on the count adjustment increment.

[0174] As can be seen from the above, the method steps provided in this embodiment are no different from the method applied to the slave axis provided in the above embodiments except for the actions required to interchange between the master and slave axes. Therefore, for a further embodiment of the synchronous calibration method for a gantry bus system applied to the master axis provided in this embodiment, please refer to the above embodiment of the method applied to the slave axis, which will not be repeated here.

[0175] Figure 12 A structural diagram of a synchronous calibration device for a gantry bus system provided in another embodiment of this application is shown below. Figure 12 As shown, a synchronous calibration device for a gantry bus system includes: a memory 10 for storing computer programs;

[0176] The processor 11 is used to execute a computer program to implement the steps of a synchronous calibration method for a gantry bus system as described in the above embodiment (which may be a method corresponding to the slave axis or a method corresponding to the master axis).

[0177] The synchronous calibration device for a gantry bus system provided in this embodiment may include, but is not limited to, mobile terminals, personal computers, workstations, etc.

[0178] The processor 11 may include one or more processing cores, such as a quad-core processor or an octa-core processor. The processor 11 may be implemented using at least one of the following hardware forms: Digital Signal Processor (DSP), Field-Programmable Gate Array (FPGA), or Programmable Logic Array (PLA). The processor 11 may also include a main processor and a coprocessor. The main processor, also known as the Central Processing Unit (CPU), is used to process data in the wake-up state; the coprocessor is a low-power processor used to process data in the standby state. In some embodiments, the processor 11 may integrate a Graphics Processing Unit (GPU), which is responsible for rendering and drawing the content to be displayed on the screen. In some embodiments, the processor 11 may also include an Artificial Intelligence (AI) processor, which is used to handle computational operations related to machine learning.

[0179] The memory 10 may include one or more computer-readable storage media, which may be non-transitory. The memory 10 may also include high-speed random access memory and non-volatile memory, such as one or more disk storage devices or flash memory devices. In this embodiment, the memory 10 is used to store at least the following computer program 101, which, after being loaded and executed by the processor 11, is capable of implementing the relevant steps of a synchronous calibration method for a servo gantry communication bus disclosed in any of the foregoing embodiments. In addition, the resources stored in the memory 10 may also include an operating system 102 and data 103, and the storage method may be temporary or permanent storage. The operating system 102 may include Windows, Unix, Linux, etc. The data 103 may include, but is not limited to, a synchronous calibration method for a servo gantry communication bus.

[0180] In some embodiments, a synchronous calibration device for a gantry bus system may further include a display screen 12, an input / output interface 13, a communication interface 14, a power supply 15, and a communication bus 16.

[0181] Those skilled in the art will understand that ​ The structure shown does not constitute a limitation on a synchronous calibration device for a gantry bus system and may include more or fewer components than shown.

[0182] This application provides a synchronous calibration device for a gantry bus system, including a memory and a processor. When the processor executes a program stored in the memory, it can implement the following method: a synchronous calibration method for a gantry bus system.

[0183] Finally, this application also provides an embodiment corresponding to a computer-readable storage medium. The computer-readable storage medium stores a computer program, which, when executed by a processor, implements the steps described in the above method embodiments.

[0184] It is understood that if the methods in the above embodiments are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and executes all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0185] The foregoing has provided a detailed description of a synchronization calibration method and apparatus for a gantry bus system provided in this application. The various embodiments in the specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For the apparatus disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple; relevant parts can be referred to in the method section. It should be noted that those skilled in the art can make several improvements and modifications to this application without departing from the principles of this application, and these improvements and modifications also fall within the protection scope of this application.

[0186] It should also be noted that, in this specification, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

Claims

1. A synchronous calibration method for a gantry bus system, characterized in that, The gantry bus system includes a master spindle and a slave spindle; the method is applied to the slave spindle; the method includes: Obtain the asynchronous clock offset when communicating with the spindle; Obtain the communication latch count value; wherein, the communication latch count value is the current count value of the latched timing counter when the data frame sent by the spindle is received; The counting set value of the timing counter is compensated according to the asynchronous clock deviation to obtain the compensated counting parameter compensation value. The counting deviation value is determined based on the compensation value of the counting parameter and the count value of the communication latch. The count adjustment increment is determined based on the count deviation value and the preset adjustment filter gain; The communication latch count value is adjusted based on the count adjustment increment.

2. The synchronous calibration method for a gantry bus system according to claim 1, characterized in that, The adjustment of the communication latch count value based on the count adjustment increment includes: If the count adjustment increment is less than or equal to a preset adjustment threshold, the communication latch count value is adjusted according to the count adjustment increment.

3. The synchronous calibration method for a gantry bus system according to claim 1, characterized in that, The adjustment of the communication latch count value based on the count adjustment increment includes: If the count adjustment increment is greater than the preset adjustment threshold, the communication latch count value is adjusted according to the adjustment threshold.

4. The synchronous calibration method for a gantry bus system according to claim 1, characterized in that, After adjusting the communication latch count value based on the count adjustment increment, the method further includes: Determine whether the adjusted communication latch count value is equal to the compensation value of the count parameter; If not, return to the step of determining the counting deviation value based on the counting parameter compensation value and the communication latch count value.

5. The synchronous calibration method for a gantry bus system according to claim 1, characterized in that, The adjusted filter gain is 2. -k Where k is any positive integer; The step of determining the count adjustment increment based on the count deviation value and the preset adjustment filter gain includes: The count deviation value is shifted right by k bits to obtain the count adjustment increment.

6. The synchronous calibration method for a gantry bus system according to claim 1, characterized in that, Before adjusting the communication latch count value based on the count adjustment increment, the method further includes: If the count deviation value meets the first condition and the count adjustment increment meets the second condition, the count adjustment increment is adjusted to a preset value.

7. The synchronous calibration method for a gantry bus system according to claim 1, characterized in that, The step of determining the counting deviation value based on the counting parameter compensation value and the communication latch count value includes: Select a compensation value for the counting parameter that is adjacent to the communication latch count value and corresponds to two different counting cycles; The differences between the two compensation values ​​of the counting parameters and the communication latch count value are determined respectively to obtain two intermediate deviation values; The intermediate deviation with the smallest absolute value among the two intermediate deviation values ​​is taken as the counting deviation value; The direction in which the communication latch count value points to the count parameter compensation value is taken as the adjustment direction corresponding to the count adjustment increment.

8. The synchronous calibration method for a gantry bus system according to claim 1, characterized in that, The acquisition of the asynchronous clock offset during communication with the spindle includes: The asynchronous clock offset is acquired once when the gantry bus system is powered on. The acquisition of the communication latch count value includes: The communication latch count value is periodically acquired, and whenever a new communication latch count value is acquired, the step of determining the count deviation value based on the count parameter compensation value and the communication latch count value is triggered.

9. The synchronous calibration method for a gantry bus system according to any one of claims 1 to 8, characterized in that, The slave axis also includes a delay module; The acquisition of the asynchronous clock offset during communication with the spindle includes: Transmit a delay detection frame between the master axis and the slave axis, and use the transmission delay during the transmission process as the delay measurement result; Under the condition that a delay element is injected into the communication between the master axis and the slave axis through the delay module, the delay detection frame between the master axis and the slave axis is transmitted, and the transmission delay of the transmission process is used as the second transmission delay; If the second transmission delay is greater than the delay measurement result, then the current delay measurement result is taken as the asynchronous clock deviation.

10. The synchronous calibration method for a gantry bus system according to claim 9, characterized in that, The method further includes: If the second transmission delay is less than or equal to the delay measurement result, then the second transmission delay is taken as the new delay measurement result; Increase the number of delay elements injected by the delay module; If the number of times the delay element is increased does not exceed the preset search count threshold, then return to the step of transmitting the delay detection frame between the master axis and the slave axis under the condition that the delay element is injected into the communication between the master axis and the slave axis through the delay module, and using the transmission delay of the transmission process as the second transmission delay. If the number of times the delay step is increased exceeds the search count threshold, the current delay measurement result is taken as the asynchronous clock deviation.

11. A synchronous calibration method for a gantry bus system, characterized in that, The gantry bus system includes a master spindle and a slave spindle; the method is applied to the master spindle; the method includes: Obtain the asynchronous clock offset during communication with the slave axis; Obtain the communication latch count value; wherein, the communication latch count value is the current count value of the latched timing counter when the data frame sent by the slave axis is received; The counting set value of the timing counter is compensated according to the asynchronous clock deviation to obtain the compensated counting parameter compensation value. The counting deviation value is determined based on the compensation value of the counting parameter and the count value of the communication latch. The count adjustment increment is determined based on the count deviation value and the preset adjustment filter gain; The communication latch count value is adjusted based on the count adjustment increment.

12. A synchronous calibration device for a gantry bus system, characterized in that, include: Memory, used to store computer programs; A processor, configured to implement the steps of the synchronous calibration method for a gantry bus system as described in any one of claims 1 to 11 when executing the computer program.

Citation Information

Patent Citations

  • Method of controlling encoder principle axis speed synchronization

    CN106404032A

  • Gantry type dual-drive control device and method and medium

    CN114488905A