Time calibration and displacement calculation method and terminal for pulse axis signal data

By time calibration and conversion of pulse axis signal data and servo axis signal data, the problem of difficulty in analyzing multi-pulse axis data information is solved, and the calculation of combined speed and combined acceleration and trajectory observation are realized.

CN120143732APending Publication Date: 2025-06-13FUZHOU WECON ELECTRONICS TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510175579.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-31
Publication Date
2025-06-13

AI Technical Summary

Technical Problem

In industrial control, multi-pulse axis data information is difficult to analyze, resulting in difficulty in diagnosing the pulse axis running trajectory, and it is impossible to achieve a comprehensive analysis of combined speed and combined acceleration.

Method used

By time calibration of the pulse axis signal data and the servo axis signal data, the rising edge point is extracted, the pulse direction and current position are calculated, and the associated data of time and relative displacement are converted into equal interval resampling to calculate the combined speed and acceleration.

Benefits of technology

Timescale synchronization of multi-pulse axis data is realized, combined speed and combined acceleration are calculated, curves are drawn, and actual position and trajectory observations are realized under the joint control of the pulse axis and the servo axis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120143732A_ABST
    Figure CN120143732A_ABST
Patent Text Reader

Abstract

The invention discloses a multi-axis pulse space trajectory reconstruction method and a terminal. The method comprises the following steps: acquiring pulse axis signal data and servo axis signal data; converting the pulse axis signal data into associated data of time and relative displacement by taking the servo axis signal data as a reference; performing sampling synchronization on all converted pulse axis signal data at the same time point; performing equal-interval resampling on the converted pulse axis signal data according to a preset sampling frequency; and calculating a resultant velocity and a resultant acceleration according to a sampling result and drawing a curve. According to the method, pulse axis signal data are converted into associated data of time and relative displacement by referring to a display mode of servo axis signal data, sampling synchronization is carried out on the converted multiple pulse axis signal data according to the same time point, the multiple pulse axis data are summarized on the same time scale, and therefore the accuracy of the data is improved. And the actual position and the corresponding track can be observed when the pulse axis and the bus servo axis are jointly controlled.
Need to check novelty before this filing date? Find Prior Art

Description

[0001] This divisional application is based on the invention patent with the application date of October 31, 2024, application number 202411534107.4, and title "A Method and Terminal for Reconstructing a Multi-axis Pulse Space Trajectory". Technical Field

[0002] The present invention relates to the field of industrial control, and particularly to a method and terminal for time calibration and displacement calculation of pulse axis signal data. Background Art

[0003] In industrial scenarios, processing needs to be carried out on a machine table. In PLCs and motion controllers, it is often necessary to verify whether the processing trajectory is consistent with the planned one. In trajectory processing, the speed of the running trajectory and the planned path are crucial. Due to its particularity, the pulse axis has almost no correlation with the time slice. Therefore, it is difficult to diagnose the machine table trajectory of the pulse axis operation, and it is very difficult to analyze the situation of the machine table during the operation of the pulse axis.

[0004] In existing analysis methods, motion control is mainly carried out based on known three-dimensional information, the speed curve of a single axis is disassembled, a logic analyzer is used to collect single-axis pulse data, and the corresponding speed is calculated. However, it is only applicable to a single axis. When there are multiple axes, there is a problem of inability to synchronize, and the efficiency of separately testing single axes is low. The combined speed and combined acceleration curves cannot be obtained, and the operation situation of the machine table cannot be comprehensively analyzed. Summary of the Invention

[0005] The technical problem to be solved by the present invention is: to provide a method and terminal for time calibration and displacement calculation of pulse axis signal data, and solve the problem that it is difficult to analyze multi-pulse axis data information.

[0006] To solve the above technical problem, the technical solution adopted by the present invention is as follows:

[0007] A method for time calibration and displacement calculation of pulse axis signal data includes the steps of:

[0008] S1. Perform time calibration on the pulse axis signal data and the servo axis signal data;

[0009] S2. Extract the rising edge points in the pulse axis signal data;

[0010] S3. Obtain the pulse direction of the rising edge point and calculate the current position according to the pulse direction;

[0011] S4. Obtain the current time and convert the pulse axis signal data into associated data of time and relative displacement in combination with the current position.

[0012] To solve the above technical problems, another technical solution adopted by the present invention is as follows:

[0013] A time calibration and displacement calculation terminal for pulse axis signal data, characterized in that it includes a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, the following steps are completed:

[0014] S1. Perform time calibration on the pulse axis signal data and the servo axis signal data;

[0015] S2. Extract the rising edge points in the pulse axis signal data;

[0016] S3. Obtain the pulse direction of the rising edge points and calculate the current position according to the pulse direction;

[0017] S4. Obtain the current time and convert the pulse axis signal data into associated data of time and relative displacement in combination with the current position.

[0018] The beneficial effect of the present invention lies in: A time calibration and displacement calculation method and terminal for pulse axis signal data. Since the pulses shown in the pulse axis signal data are fixed but the transmission time intervals are not fixed, the pulse axis signal data is converted into associated data of time and relative displacement with reference to the display mode of the servo axis signal data, and the converted multiple pulse axis signal data are sampled and synchronized at the same time point, so as to summarize multiple pulse axis data on the same time scale, and then calculate the combined velocity and combined acceleration by the equidistant resampling method and draw the corresponding curves, realizing the observation of the actual position and the corresponding trajectory during the joint control of the pulse axis and the bus servo axis. Description of the Drawings

[0019] Figure 1 It is a flowchart of a method for reconstructing a multi-axis pulse space trajectory in an embodiment of the present invention;

[0020] Figure 2 It is a schematic diagram of the conversion of pulse axis signal data in an embodiment of the present invention;

[0021] Figure 3 It is a flowchart of the conversion of pulse axis signal data in an embodiment of the present invention;

[0022] Figure 4 It is a flowchart of multi-axis synchronization in an embodiment of the present invention;

[0023] Figure 5 It is a flowchart of the calculation of combined velocity and combined acceleration in an embodiment of the present invention;

[0024] Figure 6 It is a schematic diagram of the reconstruction of the space trajectory in an embodiment of the present invention;

[0025] Figure 7 Schematic diagram of the resultant velocity curve in the embodiment of the present invention;

[0026] Figure 8 Schematic diagram of the resultant acceleration curve in the embodiment of the present invention;

[0027] Figure 9 Schematic diagram of a reconstruction terminal for a multi-axis pulse space trajectory in the embodiment of the present invention;

[0028] Label description:

[0029] 1. A reconstruction terminal for a multi-axis pulse space trajectory; 2. Memory; 3. Processor. Detailed implementation manners

[0030] To describe in detail the technical content, achieved objectives and effects of the present invention, the following is described in conjunction with the implementation manners and with reference to the accompanying drawings.

[0031] Please refer to Figure 1 , a method for reconstructing a multi-axis pulse space trajectory, comprising the steps of:

[0032] S1. Collect pulse axis signal data and servo axis signal data;

[0033] S2. Taking the servo axis signal data as a reference, convert the pulse axis signal data into association data of time and relative displacement;

[0034] S3. Synchronize the sampled all the converted pulse axis signal data at the same time point;

[0035] S4. Resample the converted pulse axis signal data at equal intervals according to a preset sampling frequency;

[0036] S5. Calculate the resultant velocity and resultant acceleration according to the sampling results and draw curves.

[0037] It can be understood that a pulse axis is a system that controls a mechanical device or a motion axis by sending a series of electrical pulse signals. Each pulse represents a fixed displacement unit, the number of pulses determines the distance the axis moves, and the frequency (time interval) of the pulses determines the speed of the axis. Pulse axes are usually used for stepper motor control, such as CNC (computer numerical control) machines, printers, etc. Such systems usually control the speed and position of mechanical motion by controlling the number and frequency of pulse signals. Its characteristics are that the number of pulses is controllable, but the pulse frequency (time interval) is uncertain; the control is relatively simple and there is no real-time feedback mechanism, so it is impossible to automatically correct position or speed errors. This means that if there are external interferences or load changes, the pulse axis may have positioning errors or instabilities.

[0038] A servo axis is a moving axis driven by a servo control system. The servo system is a system with closed-loop feedback control that can monitor and adjust the speed, position, and acceleration of the motor in real time to ensure that the axis moves precisely along the predetermined trajectory. Servo axes are commonly used in scenarios with high precision requirements, such as robotic arms, automated production lines, and high-precision machining equipment. It can precisely control mechanical position, speed, and acceleration, and can self-adjust and compensate for deviations. Its characteristics are that the servo axis has advantages such as high precision, feedback control, and fast dynamic response. Even if there are external interferences, the system can make adjustments to ensure precise control.

[0039] As can be seen from the above description, the beneficial effect of the present invention is to provide a method for reconstructing the multi-axis pulse space trajectory. Since the pulse axis signal data shows fixed pulses but the transmission time intervals are not fixed, the pulse axis signal data is converted into associated data of time and relative displacement by referring to the display method of the servo axis signal data, and the converted multiple pulse axis signal data is sampled and synchronized at the same time point, so as to summarize the multiple pulse axis data on the same time scale. Furthermore, the combined velocity and acceleration are calculated by the equidistant resampling method and the corresponding curves are plotted to realize the observation of the actual position and the corresponding trajectory during the joint control of the pulse axis and the bus servo axis.

[0040] Please refer to Figures 2 to 3 , in the embodiment of the present invention, the step S2 specifically includes the steps:

[0041] S21. Calibrate the time of the pulse axis signal data and the servo axis signal data;

[0042] S22. Extract the rising edge points in the pulse axis signal data;

[0043] S23. Obtain the pulse direction of the rising edge point and calculate the current position according to the pulse direction;

[0044] S24. Obtain the current time and convert the pulse axis signal data into associated data of time and relative displacement in combination with the current position.

[0045] It can be understood that the rising edge point refers to the instant when a digital signal jumps from a low level (usually represented as 0) to a high level (usually represented as 1). Here, obtaining the rising edge signal is to statistically calculate the time difference of the same sending reference of the same pulse for corresponding speed adjustment, using the rising edge as the reference.

[0046] Specifically, for example:

[0047] 1. Initialize the data

[0048] The relative distance S of the previous time last= 0;

[0049] The previous pulse signal Signal last = 0;

[0050] 2. Time calibration

[0051] Obtain the first data T of the pulse axis and the servo axis 0 , subtract all time intervals by T 0 , and obtain a T-S data starting from 0.

[0052] 3. Obtain the pulse rising edge point;

[0053] Loop judgment

[0054] When Signal last = 0 and the current pulse signal Signal = 1, this is the rising edge point at this time;

[0055] 4. Calculate the current position according to the direction

[0056] When there is a rising edge of Signal:

[0057] If the current pulse direction Direction now = 1: S last = S last + 1

[0058] If the current pulse direction Direction now = 0: S last = S last - 1

[0059] 5. Record data

[0060] According to the current time T and the current relative position S, re-save the data information, that is, convert the pulse axis signal data into a T-S curve that matches the bus servo axis signal data.

[0061] Please refer to Figure 4 , in the embodiment of the present invention, the step S3 specifically includes the steps:

[0062] S31. Obtain the minimum time point in all pulse axis signal data;

[0063] S32. Calculate the synchronization points of the current positions of the other two axes:

[0064]

[0065] In the formula, P is the synchronization position; T is the minimum time point, T last is the time point of the previous action, T next represents the time point of the next action; Plast is the position of the previous action; P next is the position of the next action;

[0066] S33. Synchronize all pulse axis signal data according to the same time axis.

[0067] As can be seen from the above description, by sampling and synchronizing the converted pulse axis signals at the same time point, it can ensure that the data of all axes are observed on the same time scale. For a multi-axis system, especially in the motion control in three-dimensional space, it is crucial to ensure that the motions of each axis are synchronized at the same time point. Through this synchronization process, it can effectively avoid the problems of data mismatch or out-of-sync between different axes, thereby improving the control accuracy of the entire system.

[0068] Please refer to Figure 5 , in the embodiment of the present invention, the step S4 specifically includes the steps:

[0069] Traverse each synchronized point according to the preset sampling frequency, and calculate each synchronized point corresponding to the preset sampling frequency by using the linear interpolation method.

[0070] As can be seen from the above description, by resampling the converted pulse axis signals at equal intervals according to the preset sampling frequency, it ensures the smoothness and consistency of the data. Equal-interval resampling can not only improve the accuracy of data processing, but also eliminate the problem of uneven time intervals of pulse signal transmission, making the data analysis more reliable. In this way, more accurate parameters such as speed and acceleration can be obtained and further analyzed.

[0071] Please refer to Figures 6 to 8 , in the embodiment of the present invention, the step S5 specifically includes the steps:

[0072] Calculate the resultant velocity and resultant acceleration according to the synchronized points and respectively draw the resultant velocity curve and the resultant acceleration curve.

[0073] As can be seen from the above description, in multi-axis motion control, the resultant velocity and resultant acceleration are important indicators to measure the operating state of the system. By calculating the resultant velocity (i.e., the vector sum of the velocities on multiple axes) and the resultant acceleration (i.e., the rate of change of velocity), it can more accurately reflect the actual state of the machine motion. The calculation method of the present invention ensures the accuracy of these data, and by drawing the resultant velocity and resultant acceleration curves, the dynamic performance of the system operation is intuitively displayed, which is helpful for diagnosing and optimizing the motion control system.

[0074] Please refer to Figure 9, A reconstruction terminal for a multi-axis pulse space trajectory, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, it completes the steps in a method for reconstructing a multi-axis pulse space trajectory.

[0075] As can be seen from the above description, an execution carrier for a method for reconstructing a multi-axis pulse space trajectory is provided. During the execution of the above method, since the pulses shown in the pulse axis signal data are fixed but the transmission time intervals are not fixed, the pulse axis signal data is converted into associated data of time and relative displacement with reference to the display mode of the servo axis signal data. Then, the converted multiple pulse axis signal data is sampled and synchronized at the same time point, so as to summarize the multiple pulse axis data on the same time scale. Furthermore, the combined velocity and acceleration are calculated by the equidistant resampling method and the corresponding curves are drawn, realizing the observation of the actual position and the corresponding trajectory during the joint control of the pulse axis and the bus servo axis.

[0076] The present invention provides a method and a terminal for reconstructing a multi-axis pulse space trajectory, which are mainly applied to the reconstruction of multi-axis pulse trajectories in the field of industrial automation.

[0077] Please refer to Figure 1 , Embodiment 1 of the present invention is as follows:

[0078] A method for reconstructing a multi-axis pulse space trajectory includes the steps:

[0079] S1. Collect pulse axis signal data and servo axis signal data;

[0080] That is, collect relevant signals, pulse axis signals, and bus servo axis signals

[0081] Pulse axis signal data: Time[s], Channel 0 (pulse), Channel 1 (direction)

[0082] Servo axis signal data: Time[s], Relative displacement S;

[0083] S2. With reference to the servo axis signal data, convert the pulse axis signal data into associated data of time and relative displacement; since only the T of the pulse data is of variable length and S is of fixed length, only the pulse data needs to be specially processed, that is, only the pulse axis signal data is processed and converted into T-S data, so as to match the data format of the servo axis;

[0084] S3. Sample and synchronize all the converted pulse axis signal data at the same time point;

[0085] S4. Perform equidistant resampling on the converted pulse axis signal data according to a preset sampling frequency;

[0086] S5. Calculate the resultant velocity and resultant acceleration based on the sampling results and plot the curves.

[0087] That is, in this embodiment, since the pulses shown in the pulse axis signal data are fixed but the transmission time intervals are not fixed, the pulse axis signal data is converted into the associated data of time and relative displacement with reference to the display method of the servo axis signal data, and the multiple pulse axis signal data after conversion are sampled and synchronized at the same time point, so as to summarize the multiple pulse axis data on the same time scale. Furthermore, the resultant velocity and resultant acceleration are calculated by the equidistant resampling method and the corresponding curves are plotted, realizing the observation of the actual position and the corresponding trajectory during the joint control of the pulse axis and the bus servo axis.

[0088] Please refer to Figures 2 to 3 , Embodiment 2 of the present invention is:

[0089] On the basis of Embodiment 1, step S2 specifically includes the steps:

[0090] S21. Initialize the data

[0091] The relative distance S of the previous time last = 0;

[0092] The pulse signal Signal of the previous time last = 0;

[0093] Perform time calibration on the pulse axis signal data and the servo axis signal data; that is, obtain the first data T of the pulse axis and the servo axis 0 , subtract T from all the time intervals 0 , and obtain a T-S data starting from 0.

[0094] S22. Extract the rising edge points in the pulse axis signal data; judge cyclically. When Signal last = 0 and the current pulse signal Signal = 1, this is the rising edge point at this time;

[0095] S23. Obtain the pulse direction of the rising edge point and calculate the current position according to the pulse direction;

[0096] When it is the rising edge of Signal:

[0097] If the current pulse direction Direction now = 1: S last = S last + 1

[0098] If the current pulse direction Direction now = 0: S last = S last - 1

[0099] S24. Obtain the current time and combine the current position to convert the pulse axis signal data into the associated data of time and relative displacement. According to the current time T and the current relative position S, re-save the data information, that is, convert the pulse axis signal data into the T-S curve that matches the bus servo axis signal data.

[0100] Please refer to Figures 4 to 8 , Embodiment 3 of the present invention is as follows:

[0101] On the basis of Embodiment 2, please refer to Figure 4 , Step S3 specifically includes the steps:

[0102] S31. Obtain the minimum time point among all the pulse axis signal data;

[0103] S32. Calculate the synchronization points of the current positions of the other two axes:

[0104]

[0105] In the formula, P is the synchronization position; T is the minimum time point, T last is the time point of the previous action, T next represents the time point of the next action; P last is the position of the previous action; P next is the position of the next action;

[0106] S33. Synchronize all the pulse axis signal data according to the same time axis, and store all the data in the data format synchronized by the same time axis, that is, (t, x, y, z).

[0107] Step S4 specifically includes the steps:

[0108] Please refer to Figure 5 , Traverse each synchronized point according to the preset sampling frequency, and calculate each synchronization point corresponding to the preset sampling frequency by using the linear interpolation method. Specifically, the steps are as follows: Set the synchronization period T sample ;

[0109] 1. Through the time T = n×T sample , traverse each point

[0110] 2. Calculate each synchronization point P (linear interpolation calculation), the current position In the formula: the current time is TT; T last is the previous time point; T next is the next time point; P last is the previous data source; P next is the next data point;

[0111] Equidistant resampling of the transformed pulse axis signal at a preset sampling frequency ensures the smoothness and consistency of the data. Equidistant resampling can not only improve the accuracy of data processing, but also eliminate the problem of uneven time intervals between pulse signal transmissions, making data analysis more reliable. In this way, more accurate parameters such as speed and acceleration can be obtained for further analysis.

[0112] Please refer to Figures 6 to 8 , step S5 specifically includes the steps:

[0113] Calculate the resultant velocity and resultant acceleration based on the synchronization points and respectively plot the resultant velocity curve and resultant acceleration curve.

[0114] Calculate the resultant velocity V 合 , resultant acceleration A 合 , specifically refer to the following formula:

[0115]

[0116] In the formula, x, y, and z are the vector velocities of the three axes calculated based on the synchronization points.

[0117] Please refer to Figure 9 , Embodiment 4 of the present invention is:

[0118] A reconstruction terminal 1 for a multi-axis pulse space trajectory, including a memory 2, a processor 3, and a computer program stored on the memory 2 and executable on the processor 3. When the processor 3 executes the computer program, it completes the steps in a method for reconstructing a multi-axis pulse space trajectory.

[0119] In summary, for a method and terminal for reconstructing a multi-axis pulse space trajectory provided by the present invention, since the pulse axis signal data shows fixed pulses but non-fixed transmission time intervals, the pulse axis signal data is transformed into associated data of time and relative displacement with reference to the display mode of the servo axis signal data, and the transformed multiple pulse axis signal data is sampled and synchronized at the same time point, so as to summarize the multiple pulse axis data on the same time scale. Furthermore, the resultant velocity and resultant acceleration are calculated by the equidistant resampling method and the corresponding curves are plotted, realizing the observation of the actual position and the corresponding trajectory during the joint control of the pulse axis and the bus servo axis.

[0120] The above are only the embodiments of the present invention, and do not limit the patent scope of the present invention accordingly. Any equivalent transformation made using the content of the specification and drawings of the present invention, or directly or indirectly applied in the related technical fields, shall be equally included in the patent protection scope of the present invention.

Claims

1. A method for time calibration and displacement calculation of pulse axis signal data, characterized in that: Includes steps: S1, time-calibrating the pulse axis signal data and the servo axis signal data; S2, extracting the rising edge point in the pulse axis signal data; S3, obtaining the pulse direction of the rising edge point and calculating the current position according to the pulse direction; S4. Obtain the current time and convert the pulse axis signal data into correlation data of time and relative displacement in combination with the current position.

2. A method for time calibration and displacement calculation of pulse axis signal data according to claim 1, characterized in that: The step S4 further includes the following steps: S5, sampling and synchronizing all the converted pulse axis signal data at the same time point; S6, resampling the converted pulse axis signal data at equal intervals according to a preset sampling frequency; S7. Calculate the combined velocity and combined acceleration according to the sampling results and draw a curve.

3. A method for time calibration and displacement calculation of pulse axis signal data according to claim 2, characterized in that: The step S5 specifically comprises the following steps: S51, obtaining the minimum time point in all pulse axis signal data; S52, calculate the synchronization point of the current positions of the other two axes: Where P is the synchronization position; T is the minimum time point, T last is the time point of the last action, T next Indicates the time point of the next action; P last is the position of the last action; P next The position for the next action; S53, synchronizing all pulse axis signal data according to the same time axis.

4. The method for time calibration and displacement calculation of pulse axis signal data according to claim 2, characterized in that: The step S6 specifically comprises the following steps: Each synchronized point is traversed according to a preset sampling frequency, and each synchronization point corresponding to the preset sampling frequency is calculated using a linear interpolation method.

5. The method for time calibration and displacement calculation of pulse axis signal data according to claim 1, characterized in that: The rising edge point represents the moment when a digital signal jumps from a low level to a high level.

6. A time calibration and displacement calculation terminal for pulse axis signal data, characterized in that: The invention comprises a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the following steps are performed: S1, time-calibrating the pulse axis signal data and the servo axis signal data; S2, extracting the rising edge point in the pulse axis signal data; S3, obtaining the pulse direction of the rising edge point and calculating the current position according to the pulse direction; S4. Obtain the current time and convert the pulse axis signal data into correlation data of time and relative displacement in combination with the current position.

7. A time calibration and displacement calculation terminal for pulse axis signal data according to claim 6, characterized in that: The step S4 further includes the following steps: S5, sampling and synchronizing all the converted pulse axis signal data at the same time point; S6, resampling the converted pulse axis signal data at equal intervals according to a preset sampling frequency; S7. Calculate the combined velocity and combined acceleration according to the sampling results and draw a curve.

8. A time calibration and displacement calculation terminal for pulse axis signal data according to claim 7, characterized in that: The step S5 specifically comprises the following steps: S51, obtaining the minimum time point in all pulse axis signal data; S52, calculate the synchronization point of the current positions of the other two axes: Where P is the synchronization position; T is the minimum time point, T last is the time point of the last action, T next Indicates the time point of the next action; P last is the position of the last action; P next The position for the next action; S53, synchronizing all pulse axis signal data according to the same time axis.

9. A time calibration and displacement calculation terminal for pulse axis signal data according to claim 7, characterized in that: The step S6 specifically comprises the following steps: Each synchronized point is traversed according to a preset sampling frequency, and each synchronization point corresponding to the preset sampling frequency is calculated using a linear interpolation method.

10. The time calibration and displacement calculation terminal of pulse axis signal data according to claim 6, characterized in that: The rising edge point represents the moment when a digital signal jumps from a low level to a high level.