CN110968119A - Control method and device for double-shaft synchronization - Google Patents

Control method and device for double-shaft synchronization Download PDF

Info

Publication number
CN110968119A
CN110968119A CN201911185575.4A CN201911185575A CN110968119A CN 110968119 A CN110968119 A CN 110968119A CN 201911185575 A CN201911185575 A CN 201911185575A CN 110968119 A CN110968119 A CN 110968119A
Authority
CN
China
Prior art keywords
servo
synchronization
servo driver
actual position
value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201911185575.4A
Other languages
Chinese (zh)
Other versions
CN110968119B (en
Inventor
骆鹏
章健
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Suzhou Weichuang Electrical Technology Co Ltd
Original Assignee
Suzhou Weichuang Electrical Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Suzhou Weichuang Electrical Technology Co Ltd filed Critical Suzhou Weichuang Electrical Technology Co Ltd
Priority to CN201911185575.4A priority Critical patent/CN110968119B/en
Publication of CN110968119A publication Critical patent/CN110968119A/en
Application granted granted Critical
Publication of CN110968119B publication Critical patent/CN110968119B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05DSYSTEMS FOR CONTROLLING OR REGULATING NON-ELECTRIC VARIABLES
    • G05D3/00Control of position or direction
    • G05D3/12Control of position or direction using feedback
    • G05D3/20Control of position or direction using feedback using a digital comparing device

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Automation & Control Theory (AREA)
  • Numerical Control (AREA)
  • Control Of Multiple Motors (AREA)

Abstract

The application relates to a control method and a device for double-shaft synchronization, wherein the method is applied to any servo driver of a double-shaft synchronization control system, the double-shaft synchronization control system comprises two servo drivers needing synchronization, each servo driver corresponds to one servo shaft, and the method comprises the following steps: acquiring a synchronous frame signal sent by an upper computer based on a bus; exchanging an actual position value with another servo driver according to the synchronous frame signal; obtaining a position deviation value between the servo driver and another servo driver according to the actual position value; and eliminating the position deviation value so as to synchronize the servo axes corresponding to the two servo drivers. According to the method, the two servo drivers exchange actual position values through the bus, and are adjusted according to the position deviation value between the two servo drivers, so that double-shaft synchronization is realized.

Description

Control method and device for double-shaft synchronization
Technical Field
The present application relates to the field of servo driver control technologies, and in particular, to a method and an apparatus for controlling dual-axis synchronization.
Background
The traditional large gantry equipment generally adopts two servo drivers to simultaneously drive one gantry shaft to operate. In the operation process of the two drivers, the upper computer sends position pulses, and one path of pulses are divided into two paths of pulses through the adapter plate and are simultaneously sent to the two servo drivers to be executed, so that the two servo drivers are ensured to receive the pulses consistently. However, in the whole operation process, due to the influence of different acceleration and deceleration and different loads of the two servo drivers, the positions of the two servo drivers in the motion process may be inconsistent, so that the two ends of the gantry are unbalanced.
Disclosure of Invention
In order to solve the above technical problem, the present embodiment provides a method and an apparatus for controlling dual-axis synchronization.
In a first aspect, this embodiment provides a control method for dual-axis synchronization, which is applied to any servo driver of a dual-axis synchronization control system, where the dual-axis synchronization control system includes two servo drivers that need to be synchronized, and each servo driver corresponds to a servo axis, and the method includes:
acquiring a synchronous frame signal sent by an upper computer based on a bus;
exchanging an actual position value with another servo driver according to the synchronous frame signal;
obtaining a position deviation value between the servo driver and another servo driver according to the actual position value;
and eliminating the position deviation value so as to synchronize the servo axes corresponding to the two servo drivers.
Optionally, the exchanging the actual position value with another servo driver according to the synchronization frame signal includes:
reading a current actual position value when receiving the synchronous frame signal;
and sending the actual position value to another servo driver, and receiving the actual position value sent by the other servo driver.
Optionally, the obtaining a position deviation value with another servo driver according to the actual position value includes:
when receiving the next synchronous frame signal and entering the next synchronous period, reading the actual position value in the last synchronous period and the actual position value of the other servo driver in the last synchronous period;
and calculating the deviation value between the actual position value in the last synchronization period and the actual position value of the other servo driver in the last synchronization period to obtain the position deviation value.
Optionally, a synchronization period includes at least one control period, and in each control period, the eliminating the position deviation value to synchronize the servo axes corresponding to the two servo drivers includes:
compensating the driving speed of the servo driver according to the proportional regulator to obtain an updated driving instruction;
and compensating the double-shaft synchronous deviation according to integral compensation when the double-shaft synchronous deviation is unchanged within a preset time length to reduce the double-shaft synchronous deviation to 0, and eliminating the position deviation value to synchronize the servo shafts corresponding to the two servo drivers.
Optionally, if one synchronization cycle includes a plurality of control cycles, the offset value is evenly distributed to the plurality of control cycles for compensation and elimination.
Optionally, after acquiring the synchronization frame signal sent from the upper computer based on the bus, the method further includes:
and synchronizing a control period according to the synchronization frame signal.
Optionally, the synchronizing the control period according to the synchronization frame signal includes:
when the synchronous frame signal is received, the control period is adjusted to eliminate the time difference with the other servo driver in the power-on process, so that the control period is synchronized with the control period of the other servo driver, and the synchronization period is aligned with the synchronization period of the other servo driver.
Optionally, the acquiring a synchronization frame signal sent from an upper computer based on a bus further includes:
and acquiring message information sent by an upper computer based on the bus.
Optionally, the obtaining, based on the bus, message information sent from the upper computer includes:
the method comprises the steps of obtaining unique message information sent by an upper computer based on a bus, enabling two servo drivers to receive the same message information at the same time, and enabling the two servo drivers to execute synchronously according to an instruction generated by the message information.
In a second aspect, the present embodiment provides a control apparatus for biaxial synchronization, the apparatus comprising:
the receiving unit is used for acquiring a synchronous frame signal sent by an upper computer based on a bus;
the switching unit is used for switching an actual position value with another servo driver according to the synchronous frame signal;
a deviation calculating unit for obtaining a position deviation value between the servo driver and another servo driver according to the actual position value;
and the synchronization unit is used for eliminating the position deviation value so as to synchronize the servo axes corresponding to the two servo drivers.
Optionally, the switching unit includes:
the acquisition unit is used for reading the current actual position value when receiving the synchronous frame signal;
and the transceiving unit is used for sending the actual position value to another servo driver and receiving the actual position value sent by the other servo driver.
Optionally, the calculating a deviation unit includes:
a reading unit for reading an actual position value in a previous synchronization period and an actual position value of another servo driver in the previous synchronization period when a next synchronization frame signal is received and a next synchronization period is entered;
and the calculating unit is used for calculating the deviation value between the actual position value in the last synchronization period and the actual position value of the other servo driver in the last synchronization period to obtain the position deviation value.
Optionally, the synchronization unit includes:
the compensation unit is used for compensating the driving speed of the servo driver according to the proportion regulator so as to obtain an updated driving instruction;
and the deviation eliminating unit is used for compensating the double-shaft synchronous deviation according to integral compensation when the double-shaft synchronous deviation is unchanged within a preset time length, so that the double-shaft synchronous deviation is reduced to 0, and the position deviation value is eliminated, so that the servo shafts corresponding to the two servo drivers are synchronous.
Optionally, if one synchronization cycle includes a plurality of control cycles, the offset value is evenly distributed to the plurality of control cycles for compensation and elimination.
Optionally, the apparatus further comprises:
and the signal synchronization unit is used for synchronizing the control period according to the synchronization frame signal.
Optionally, the signal synchronization unit includes:
and the period synchronization unit is used for adjusting the control period to eliminate the time difference with the other servo driver in the power-on process when the synchronization frame signal is received so as to synchronize the control period with the control period of the other servo driver and align the control period with the synchronization period of the other servo driver.
Optionally, the apparatus further comprises:
and the message acquisition unit is used for acquiring message information sent by the upper computer based on the bus.
Optionally, the packet obtaining unit includes:
and the synchronous execution unit is used for acquiring unique message information sent by the upper computer based on the bus, enabling the two servo drivers to simultaneously receive the same message information and enabling the two servo drivers to synchronously execute instructions generated according to the message information.
The invention has the beneficial effects that:
the invention discloses a control method and a device for double-shaft synchronization, wherein the method is applied to any servo driver of a double-shaft synchronization control system, the double-shaft synchronization control system comprises two servo drivers which need to be synchronized, each servo driver corresponds to a servo shaft, and the method comprises the following steps: acquiring a synchronous frame signal sent by an upper computer based on a bus; exchanging an actual position value with another servo driver according to the synchronous frame signal; obtaining a position deviation value between the servo driver and another servo driver according to the actual position value; and eliminating the position deviation value so as to synchronize the servo axes corresponding to the two servo drivers. According to the method, the two servo drivers exchange actual position values through the bus, and are adjusted according to the position deviation value between the two servo drivers, so that double-shaft synchronization is realized.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and together with the description, serve to explain the principles of the invention.
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, and it is obvious for those skilled in the art that other drawings can be obtained according to the drawings without inventive exercise.
FIG. 1 is a schematic flow chart of a control method for dual-axis synchronization according to an embodiment;
FIG. 2 is a functional block diagram of a control method of biaxial synchronization in one embodiment;
FIG. 3 is a functional block diagram of the exchange of location information in one embodiment;
FIG. 4 is a schematic diagram of a synchronization control cycle in one embodiment;
FIG. 5 is a functional block diagram of receiving message information in one embodiment;
fig. 6 is a control device for dual-axis synchronization in one embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some embodiments of the present application, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
Fig. 1 is a schematic flow chart of a dual-axis synchronization control method in an embodiment, and in the embodiment of the present invention, referring to fig. 1, this embodiment provides a dual-axis synchronization control method applied to any servo driver of a dual-axis synchronization control system, where the dual-axis synchronization control system includes a first servo driver and a second servo driver that need to be synchronized, the first servo driver corresponds to a first servo axis, and the second servo driver corresponds to a second servo axis, and the method includes:
step S110 is to acquire a synchronization frame signal transmitted from the host computer based on the bus.
In this embodiment, the bus is a CAN bus, and communication based on the CAN bus has the advantages of strong real-time performance of data communication and short development period.
Step S120, exchanging the actual position value with another servo driver according to the synchronous frame signal.
In this embodiment, when the synchronization frame signal is received, the first servo driver transmits the sampled actual position value of the first servo axis to the second servo driver, and the second servo driver transmits the sampled actual position value of the second servo axis to the first servo driver, so that the first servo driver and the second servo driver exchange the respective actual position values with each other.
Step S130, obtaining a position deviation value between the servo driver and another servo driver according to the actual position value.
In this embodiment, a difference between the actual position value sampled by the first servo driver and the actual position value sent by the second servo driver is calculated to obtain a position deviation value.
Step S140, eliminating the position deviation value to synchronize the servo axes corresponding to the two servo drivers.
Specifically, fig. 2 is a schematic block diagram of a control method of dual-axis synchronization in an embodiment, and referring to fig. 1 and 2, a synchronization frame signal sent from an upper computer is acquired based on a CAN bus, and when the synchronization frame signal is received, a first servo driver sends a sampled actual position value to a second servo driver, and the second servo driver sends the sampled actual position value to the first servo driver, so that the first servo driver and the second servo driver exchange respective actual position values with each other; calculating the difference value between the actual position value sampled by the first servo driver and the actual position value sent by the second servo driver to obtain a position deviation value; and eliminating the position deviation value so as to synchronize the servo axes corresponding to the two servo drivers. According to the method, the two servo drivers exchange actual position values through the CAN bus, and are adjusted according to the position deviation value between the two servo drivers, so that double-shaft synchronization is realized.
In one embodiment, when the sync frame signal is received, reading a current actual position value; and sending the actual position value to another servo driver, and receiving the actual position value sent by the other servo driver.
Specifically, fig. 3 is a schematic block diagram of position information exchange in an embodiment, and referring to fig. 3, a shaft 1 servo in fig. 3 represents a first servo driver, a shaft 2 servo represents a second servo driver, when receiving the synchronization frame signal SYNC1, the first servo driver and the second servo driver respectively sample a current actual position value at the same time, eliminate a position deviation caused by dual-shaft position sampling, respectively store the sampled actual position values in respective buffer areas BUF, the first servo driver sends the sampled actual position value to a receiving area RCV2 of the second servo driver, and the second servo driver sends the sampled actual position value to a receiving area RCV1 of the first servo driver, so that the first servo driver and the second servo driver exchange respective actual position values with each other.
In one embodiment, when a next synchronization frame signal is received and a next synchronization period is entered, an actual position value in a previous synchronization period and an actual position value of another servo driver in the previous synchronization period are read; and calculating the deviation value between the actual position value in the last synchronization period and the actual position value of the other servo driver in the last synchronization period to obtain the position deviation value.
Specifically, referring to fig. 3, when the next synchronization frame signal SYNC2 arrives, the first servo driver reads the actual position value of the first servo driver in the previous synchronization period in the buffer area BUF1, reads the actual position value sent by the second servo driver in the previous synchronization period in the receiving area RCV1, and calculates the offset value between the actual position value in the previous synchronization period and the actual position value of the other servo driver in the previous synchronization period to obtain the position offset value. Similarly, the second servo driver reads the actual position value of itself in the last synchronization period in its buffer area BUF2, and reads the actual position value sent by the first servo driver in the last synchronization period in the receiving area RCV2, to calculate the synchronization deviation. If the sampling of the actual position value and the calculation of the synchronous deviation are in the same synchronous period, the position error caused by the time error during the sampling affects the position deviation of the double shafts, so that the sampling of the actual position value and the synchronous deviation are not performed in the same synchronous period, the position deviation caused by the time difference of the double shaft sampling is avoided, the actual position value is sampled and stored in advance, the simultaneous reading calculation is performed when the next synchronous period arrives, and the position error caused by the double shaft position sampling is eliminated.
In one embodiment, one synchronization period comprises at least one control period, and in each control period, the servo driver is compensated for the driving speed according to the proportional regulator so as to obtain an updated driving command; and compensating the double-shaft synchronous deviation according to integral compensation when the double-shaft synchronous deviation is unchanged within a preset time length to reduce the double-shaft synchronous deviation to 0, and eliminating the position deviation value to synchronize the servo shafts corresponding to the two servo drivers.
Specifically, the method comprises the steps of compensating according to an actual position value of a first servo driver in a previous synchronization period sampled by the first servo driver and an actual position value sent by a second servo driver in the previous synchronization period, compensating the driving speed of the servo driver according to a proportional regulator to obtain an updated driving instruction, and adjusting and tracking the running speed of a first servo shaft by using the proportional regulator in the tracking process. And in the same way, the compensation is carried out according to the actual position value of the second servo driver in the last synchronous period sampled by the first servo driver in the last synchronous period and the actual position value sent by the first servo driver in the last synchronous period, so that the quick tracking of the double-shaft quick synchronous deviation is realized. When the double-shaft synchronous deviation is stable, integral compensation is added to compensate the double-shaft synchronous deviation, because the single proportional regulator is a differential regulator, the double-shaft synchronous deviation cannot be completely eliminated by only depending on the proportional regulator, the double-shaft synchronous deviation can be 0 by introducing the integral compensation, but the introduction of the integral compensation easily causes loop vibration, and therefore, after the proportional regulator is stable, an integral link is added to compensate.
In one embodiment, if a synchronization cycle includes a plurality of control cycles, the offset value is evenly distributed to the plurality of control cycles for compensation elimination.
Specifically, the position deviation value is adjusted according to a synchronization frame signal of the upper computer, that is, the calculation is performed once per synchronization period, and a control period for removing the position deviation value is generally shorter than a synchronization period of the upper computer.
In one embodiment, the control period is synchronized according to the synchronization frame signal.
Specifically, in an actual servo system, each servo driver has its own clock, and there is necessarily a certain deviation between the clocks of the two servo drivers, and if the clocks of the two servo drivers are not adjusted, the clock deviations of the two servo drivers in each synchronization period will increase, and after the running time reaches a certain time, the clock deviations of the two servo drivers are continuously accumulated, which inevitably results in that the difference between the control cycle numbers of the two axes is advanced or delayed by one cycle, which causes the deviation in the operation of the two axes. The two servo drivers can be called as double-shaft servo drivers for short, the double-shaft servo drivers adjust respective control periods once in each synchronization period according to received synchronization frame signals SYNC sent by an upper computer, and double-shaft control period synchronization is achieved, so that double-shaft synchronization period alignment is achieved.
In one embodiment, the control period is adjusted to eliminate a time difference with the other servo driver during power-up when the synchronization frame signal is received, to synchronize with the control period of the other servo driver, to align with the synchronization period of the other servo driver.
In particular, fig. 4 is a schematic diagram of the principle of the synchronous control cycle in one embodiment, referring to fig. 4,in fig. 4, clock synchronization represents control period synchronization, axis 1 control period represents control period of the first servo axis, axis 2 control period represents control period of the second servo axis, and in the power-on process of the dual-axis servo driver, because the power-on processes of the axes cannot be completely consistent, t exists between the dual-axis control periods after the power-on process is completed1A delay in time. This t is1Will result in a delay of t each period of the control periods of the first and second servo axes1Time. In addition, the internal clocks of the dual-axis drivers may not be perfectly uniform. Assuming that a control period time is t under the first servo axis clock2The time of one control cycle in the case of the second servo axis clock is t3. When the running time is T, the execution times of the first servo axis control cycle is
Figure BDA0002292322310000101
The number of execution of the control cycle of the shaft 2 is
Figure BDA0002292322310000102
If it is not
Figure BDA0002292322310000103
The control cycle number between the two axes will generate a cycle deviation after the time T, and the cycle deviation will cause the position deviation of the two axes to generate a large jitter.
And synchronizing the control cycles of the two shafts according to the synchronous frame signal of the upper computer so as to align the synchronous cycles of the two shafts. When the synchronous frame signal SYNC1 arrives, the double-shaft servo driver receives SYNC1 signals (the physical delay of double-shaft CAN communication is ignored) at the same time, the double-shaft servo driver adjusts respective control periods to be synchronous with the SYNC1 signals, and the time difference t in the double-shaft power-on process is eliminated1. When the next SYNC frame signal SYNC2 arrives, the control period execution number of the first servo driver is as follows
Figure BDA0002292322310000104
The control period execution number of the second servo driver is
Figure BDA0002292322310000105
In the synchronization period tsAnd after the SYNC2 signal arrives, the double shafts continue to synchronize the control period, so that the time difference caused by the clock deviation of the double shafts is eliminated. Under the condition that the upper computer synchronous frame signals are accurate, the different influences of the double-shaft clock are eliminated, and the control periods of the double shafts are synchronous and the synchronous periods are aligned.
In one embodiment, the message information sent from the upper computer is acquired based on the bus.
Specifically, during data transmission based on the CAN bus, transmission data may be lost due to system interference and other influences, the CAN bus may retransmit the lost data, if a dual-axis servo motor is controlled to operate by using dual-axis message information, if one axis of the CAN bus normally transmits a message and the other axis of the CAN bus does not normally receive the message information, a dual-axis position instruction may be deviated, so that the dual-axis instruction may not be synchronized, thereby generating a dual-axis position deviation. Therefore, the double-shaft servo driver obtains the message information sent by the upper computer based on the bus, the double-shaft servo operation is controlled by using the same frame of message information, the two servo drivers simultaneously receive the same message information and execute the instruction, and the double-shaft position deviation is avoided.
In one embodiment, the method comprises the steps of acquiring unique message information sent by an upper computer based on a bus, enabling two servo drivers to receive the same message information at the same time, and enabling the two servo drivers to execute synchronously according to an instruction generated by the message information.
Specifically, fig. 5 is a schematic block diagram of receiving message information in an embodiment, and as shown in fig. 5(a), the upper computer sends two frames of message information in one synchronization period to control the operation of the dual-axis servo. If the double-axis servo can correctly receive the message sent by the upper computer in one synchronous period, the double-axis servo operates synchronously. However, if there is a situation that the message cmd1 in one synchronization period is discarded and the message cmd2 is normally sent, the dual-axis servo in this synchronization period will generate a synchronization deviation of one period.
As shown in fig. 5(b), when the upper computer sends the same frame of message information cmd1, and the dual-axis servo driver receives the same frame of message information cmd1 at the same time, the dual-axis command can be executed synchronously, and the dual-axis synchronization deviation is not easy to occur. In addition, in order to improve the biaxial synchronization accuracy, the biaxial synchronization response is faster as the biaxial synchronization period is shorter. However, the shorter the synchronization cycle is, the higher the load rate of the CAN bus is, and the higher the load rate of the CAN bus is, the communication fault of the CAN bus is easily generated.
Fig. 1 is a schematic flow chart of a control method of biaxial synchronization according to an embodiment. It should be understood that, although the steps in the flowchart of fig. 1 are shown in order as indicated by the arrows, the steps are not necessarily performed in order as indicated by the arrows. The steps are not performed in the exact order shown and described, and may be performed in other orders, unless explicitly stated otherwise. Moreover, at least a portion of the steps in fig. 1 may include multiple sub-steps or multiple stages that are not necessarily performed at the same time, but may be performed at different times, and the order of performance of the sub-steps or stages is not necessarily sequential, but may be performed in turn or alternately with other steps or at least a portion of the sub-steps or stages of other steps.
In an embodiment, fig. 6 is a control device for dual-axis synchronization in an embodiment, and referring to fig. 6, the embodiment provides a control device for dual-axis synchronization, the device comprising:
a receiving unit 210, configured to obtain a synchronization frame signal sent from an upper computer based on a bus;
a switching unit 220 for switching an actual position value with another servo driver according to the sync frame signal;
a deviation calculating unit 230, configured to obtain a position deviation value with another servo driver according to the actual position value;
and a synchronization unit 240 for eliminating the position deviation value to synchronize the servo axes corresponding to the two servo drivers.
Specifically, a synchronization frame signal sent from the upper computer is acquired by the receiving unit 210 based on the bus; exchanging an actual position value with another servo driver through the exchanging unit 220 according to the synchronous frame signal; obtaining a position deviation value between the servo driver and another servo driver according to the actual position value through a calculating deviation unit 230; the position deviation value is eliminated by the synchronization unit 240, so that the servo axes corresponding to the two servo drivers are synchronized.
In one embodiment, the switching unit 220 includes:
the acquisition unit is used for reading the current actual position value when receiving the synchronous frame signal;
and the transceiving unit is used for sending the actual position value to another servo driver and receiving the actual position value sent by the other servo driver.
In one embodiment, the calculate deviations unit 230 includes:
a reading unit for reading an actual position value in a previous synchronization period and an actual position value of another servo driver in the previous synchronization period when a next synchronization frame signal is received and a next synchronization period is entered;
and the calculating unit is used for calculating the deviation value between the actual position value in the last synchronization period and the actual position value of the other servo driver in the last synchronization period to obtain the position deviation value.
In one embodiment, the synchronization unit 240 includes:
the compensation unit is used for compensating the driving speed of the servo driver according to the proportion regulator so as to obtain an updated driving instruction;
and the deviation eliminating unit is used for compensating the double-shaft synchronous deviation according to integral compensation when the double-shaft synchronous deviation is unchanged within a preset time length, so that the double-shaft synchronous deviation is reduced to 0, and the position deviation value is eliminated, so that the servo shafts corresponding to the two servo drivers are synchronous.
In one embodiment, if a synchronization cycle includes a plurality of control cycles, the offset value is evenly distributed to the plurality of control cycles for compensation elimination.
In one embodiment, the apparatus further comprises:
a signal synchronization unit 240 for synchronizing a control period according to the synchronization frame signal.
In one embodiment, the signal synchronization unit 240 includes:
and a period synchronization unit 240 for adjusting the control period to eliminate a time difference with the other servo driver during power-on when the synchronization frame signal is received, so as to synchronize with the control period of the other servo driver, so as to align with the synchronization period of the other servo driver.
In one embodiment, the apparatus further comprises:
and the message acquisition unit is used for acquiring message information sent by the upper computer based on the bus.
In one embodiment, the packet obtaining unit includes:
and the synchronous execution unit is used for acquiring unique message information sent by the upper computer based on the bus, enabling the two servo drivers to simultaneously receive the same message information and enabling the two servo drivers to synchronously execute instructions generated according to the message information.
The application discloses control method and device for double-shaft synchronization, the method is applied to any servo driver of a double-shaft synchronization control system, the double-shaft synchronization control system comprises two servo drivers needing synchronization, each servo driver corresponds to one servo shaft, and the method comprises the following steps: acquiring a synchronous frame signal sent by an upper computer based on a bus; exchanging an actual position value with another servo driver according to the synchronous frame signal; obtaining a position deviation value between the servo driver and another servo driver according to the actual position value; and eliminating the position deviation value so as to synchronize the servo axes corresponding to the two servo drivers. According to the method, the two servo drivers exchange actual position values through the bus, and are adjusted according to the position deviation value between the two servo drivers, so that double-shaft synchronization is realized. Under the condition that the upper computer synchronous clock is accurate, the program internally adjusts the double-shaft clock synchronization, namely, the control period synchronization, and ensures the instruction synchronization in the double-shaft synchronous operation process. Under the condition that the loads of the two shafts are inconsistent, the synchronous deviation of the two shafts is adjusted once through each synchronous period of the CAN bus, and the quick tracking of the two shafts is realized. In actual test, the motor of the servo driver can normally run under the condition of a rated rotating speed of 3000rpm, and the double-shaft synchronization precision can be guaranteed within 1 degree. Under the condition that the load of the double shafts changes, the double shafts can be quickly adjusted, and the synchronous deviation of the double shafts is guaranteed to be 0.
The device comprises: a receiving unit 210, configured to obtain a synchronization frame signal sent from an upper computer based on a bus; a switching unit 220 for switching an actual position value with another servo driver according to the sync frame signal; a deviation calculating unit 230, configured to obtain a position deviation value with another servo driver according to the actual position value; and a synchronization unit 240 for eliminating the position deviation value to synchronize the servo axes corresponding to the two servo drivers. According to the device, the position deviation value between the two servo drivers is eliminated, and the synchronous operation of the two servo drivers is realized.
It is noted that, in this document, relational terms such as "first" and "second," and the like, may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The foregoing are merely exemplary embodiments of the present invention, which enable those skilled in the art to understand or practice the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (10)

1. A control method of dual-axis synchronization is applied to any servo driver of a dual-axis synchronization control system, the dual-axis synchronization control system comprises two servo drivers needing synchronization, and each servo driver corresponds to a servo axis, and the method comprises the following steps:
acquiring a synchronous frame signal sent by an upper computer based on a bus;
exchanging an actual position value with another servo driver according to the synchronous frame signal;
obtaining a position deviation value between the servo driver and another servo driver according to the actual position value;
and eliminating the position deviation value so as to synchronize the servo axes corresponding to the two servo drivers.
2. The method of claim 1, wherein exchanging actual position values with another servo driver based on the sync frame signal comprises:
reading a current actual position value when receiving the synchronous frame signal;
and sending the actual position value to another servo driver, and receiving the actual position value sent by the other servo driver.
3. The method of claim 2, wherein obtaining a position offset value from another servo driver according to the actual position value comprises:
when receiving the next synchronous frame signal and entering the next synchronous period, reading the actual position value in the last synchronous period and the actual position value of the other servo driver in the last synchronous period;
and calculating the deviation value between the actual position value in the last synchronization period and the actual position value of the other servo driver in the last synchronization period to obtain the position deviation value.
4. The method of claim 3, wherein a synchronization period comprises at least one control period, and wherein the removing the position deviation value to synchronize the servo axes of the two servo drivers in each control period comprises:
compensating the driving speed of the servo driver according to the proportional regulator to obtain an updated driving instruction;
and compensating the double-shaft synchronous deviation according to integral compensation when the double-shaft synchronous deviation is unchanged within a preset time length to reduce the double-shaft synchronous deviation to 0, and eliminating the position deviation value to synchronize the servo shafts corresponding to the two servo drivers.
5. The method of claim 4, wherein if a synchronization cycle comprises a plurality of control cycles, the offset value is evenly distributed over the plurality of control cycles for compensation cancellation.
6. The method according to claim 1, wherein after the bus-based acquisition of the synchronization frame signal transmitted from the upper computer, the method further comprises:
and synchronizing a control period according to the synchronization frame signal.
7. The method of claim 6, wherein synchronizing a control period according to the synchronization frame signal comprises:
when the synchronous frame signal is received, the control period is adjusted to eliminate the time difference with the other servo driver in the power-on process, so that the control period is synchronized with the control period of the other servo driver, and the synchronization period is aligned with the synchronization period of the other servo driver.
8. The method of claim 1, wherein the bus-based acquisition of the synchronization frame signal transmitted from the upper computer further comprises:
and acquiring message information sent by an upper computer based on the bus.
9. The method according to claim 8, wherein the obtaining message information sent from the upper computer based on the bus comprises:
the method comprises the steps of obtaining unique message information sent by an upper computer based on a bus, enabling two servo drivers to receive the same message information at the same time, and enabling the two servo drivers to execute synchronously according to an instruction generated by the message information.
10. A dual-axis synchronous control device, the device comprising:
the receiving unit is used for acquiring a synchronous frame signal sent by an upper computer based on a bus;
the switching unit is used for switching an actual position value with another servo driver according to the synchronous frame signal;
a deviation calculating unit for obtaining a position deviation value between the servo driver and another servo driver according to the actual position value;
and the synchronization unit is used for eliminating the position deviation value so as to synchronize the servo axes corresponding to the two servo drivers.
CN201911185575.4A 2019-11-27 2019-11-27 Control method and device for double-shaft synchronization Active CN110968119B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911185575.4A CN110968119B (en) 2019-11-27 2019-11-27 Control method and device for double-shaft synchronization

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911185575.4A CN110968119B (en) 2019-11-27 2019-11-27 Control method and device for double-shaft synchronization

Publications (2)

Publication Number Publication Date
CN110968119A true CN110968119A (en) 2020-04-07
CN110968119B CN110968119B (en) 2022-12-13

Family

ID=70031914

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911185575.4A Active CN110968119B (en) 2019-11-27 2019-11-27 Control method and device for double-shaft synchronization

Country Status (1)

Country Link
CN (1) CN110968119B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112835287A (en) * 2020-12-31 2021-05-25 常州洛源智能科技有限公司 Cross-coupled gantry control system and control method
CN116501020A (en) * 2023-05-10 2023-07-28 上海铼钠克数控科技有限公司 Servo matching detection method, apparatus, device and readable storage medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR19980075591A (en) * 1997-03-31 1998-11-16 윤종용 Position control method and position controller of synchronous control system
JP2006285752A (en) * 2005-04-01 2006-10-19 Yaskawa Electric Corp Synchronous control method and synchronous control device between two shaft
CN102298357A (en) * 2011-03-28 2011-12-28 中国科学院沈阳计算技术研究所有限公司 CNC double-spindle coordinated synchronization control method based on field bus
CN102710183A (en) * 2012-06-13 2012-10-03 苏州汇川技术有限公司 Crossed coupling synchronous control system and method of multiple motors
CN103269187A (en) * 2013-05-31 2013-08-28 南京工程学院 Dual-motor synchronous control system and control method thereof
CN103676653A (en) * 2013-12-16 2014-03-26 成都乐创自动化技术股份有限公司 Servo synchronous control method and system applied to gantry mechanism
CN106788852A (en) * 2017-01-16 2017-05-31 深圳市雷赛智能控制股份有限公司 A kind of synchronous method of EtherCAT motor drivers and master clock

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR19980075591A (en) * 1997-03-31 1998-11-16 윤종용 Position control method and position controller of synchronous control system
JP2006285752A (en) * 2005-04-01 2006-10-19 Yaskawa Electric Corp Synchronous control method and synchronous control device between two shaft
CN102298357A (en) * 2011-03-28 2011-12-28 中国科学院沈阳计算技术研究所有限公司 CNC double-spindle coordinated synchronization control method based on field bus
CN102710183A (en) * 2012-06-13 2012-10-03 苏州汇川技术有限公司 Crossed coupling synchronous control system and method of multiple motors
CN103269187A (en) * 2013-05-31 2013-08-28 南京工程学院 Dual-motor synchronous control system and control method thereof
CN103676653A (en) * 2013-12-16 2014-03-26 成都乐创自动化技术股份有限公司 Servo synchronous control method and system applied to gantry mechanism
CN106788852A (en) * 2017-01-16 2017-05-31 深圳市雷赛智能控制股份有限公司 A kind of synchronous method of EtherCAT motor drivers and master clock

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112835287A (en) * 2020-12-31 2021-05-25 常州洛源智能科技有限公司 Cross-coupled gantry control system and control method
CN112835287B (en) * 2020-12-31 2023-01-10 常州洛源智能科技有限公司 Cross-coupled gantry control system and control method
CN116501020A (en) * 2023-05-10 2023-07-28 上海铼钠克数控科技有限公司 Servo matching detection method, apparatus, device and readable storage medium
CN116501020B (en) * 2023-05-10 2023-11-03 上海铼钠克数控科技有限公司 Servo matching detection method, apparatus, device and readable storage medium

Also Published As

Publication number Publication date
CN110968119B (en) 2022-12-13

Similar Documents

Publication Publication Date Title
CN105024777B (en) Servo-driver synchronous method based on EtherCAT real-time ethernets
CN101960770B (en) Clock synchronization system, node, clock synchronization method
US7379480B2 (en) Fast frequency adjustment method for synchronizing network clocks
CN110968119B (en) Control method and device for double-shaft synchronization
US7525263B2 (en) Control system
US20110051754A1 (en) Measurement and adjustment of real-time values according to residence time in networking equipment without access to real time
CN105959079A (en) Clock synchronization method based on distributed control system
US20230188239A1 (en) Clock Synchronization Method and Apparatus, and Electronic Device
KR20190074026A (en) Synchronization method and system among multiple MCUs in EtherCAT-based slave system
KR101492910B1 (en) Method and system for ethercat-based distributed clokc synchronization
JP5243786B2 (en) Remote I / O system and time synchronization method in remote I / O system
JP4961589B2 (en) Network system and slave synchronization method
JP4487522B2 (en) Motor drive device
US10222786B2 (en) Numerical control system having synchronous control function between units
CN109660310B (en) Clock synchronization method and device, computing equipment and computer storage medium
CN102843764B (en) Method for outputting synchronization signals accurately to solve problem on synchronization of multi-stations
JP2007089331A (en) Synchronous control system
US11853116B2 (en) Clock error-bound tracker
JP2007536659A (en) Method and apparatus for simulation of automated systems
CN106647574B (en) Multi-axis servo driver synchronization system control method
JP2018106513A (en) Detection device
Li et al. A synchronization method for local applications of EtherCAT master-slave in Open CNC system
JP2007272367A (en) Multiple-shaft synchronization system and control method
CN110492966B (en) Time synchronization method of distributed relay protection device
JP2001202156A (en) Time synchronizer

Legal Events

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