Motion control method and device of motion platform, computer device and storage medium
By pre-determining the acceleration and deceleration curves of the target motion platform, the problem of large jitter in stepper motor control was solved, and high-precision motion control was achieved.
Patent Information
- Application Number
- CN202211659791.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-22
- Publication Date
- 2025-11-18
- Estimated Expiration
- 2042-12-22
AI Technical Summary
In existing technologies, stepper motor control methods generate significant vibrations during acceleration and deceleration, making them difficult to apply to high-precision control scenarios.
By pre-determining the motion control parameters of the target motion platform, the target acceleration and deceleration curves are obtained. Based on the target mathematical model, multiple acceleration and deceleration curves are screened and tested. The target acceleration and deceleration curve that matches the target motion platform is selected, and the speed information of the acceleration and deceleration phases of the motion platform is controlled to reduce jitter.
This reduces vibration during motion and improves the control precision of the motion platform.
Smart Images

Figure CN115933521B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of computer technology, and more specifically, to a motion control method, apparatus, computer equipment, and storage medium for a motion platform. Background Technology
[0002] Currently, most motion platforms use stepper motors as their driving force. Therefore, the quality of the stepper motor control method directly determines the accuracy of controlling the motion platform during movement.
[0003] In related technologies, open-loop control methods such as trapezoidal acceleration and deceleration algorithms are often used to control motors. These control methods are simple to implement and inexpensive, but they may generate large vibrations during acceleration and deceleration, making them difficult to apply to high-precision control scenarios. Summary of the Invention
[0004] This disclosure provides at least one motion control method, device, computer equipment, and storage medium for a motion platform.
[0005] In a first aspect, embodiments of this disclosure provide a motion control method for a motion platform, including:
[0006] Obtain motion commands for the target motion platform, parse the motion commands, and obtain the target motion distance corresponding to the target motion platform;
[0007] Based on the target acceleration / deceleration curve matched with the target motion platform and the target motion distance, the target motion platform is controlled to move; wherein, the target acceleration / deceleration curve is predetermined based on the motion control parameters of the target motion platform and is used to characterize the speed information of the target motion platform at each moment during the acceleration and deceleration phases of controlling the target motion platform to move.
[0008] In one possible implementation, the method further includes obtaining a target acceleration / deceleration curve matching the target motion platform according to the following method:
[0009] Based on the motion control parameters and the pre-established target mathematical model, multiple acceleration / deceleration curves that conform to the target mathematical model under the simulation operation conditions corresponding to the motion control parameters are determined.
[0010] The multiple acceleration / deceleration curves to be screened are tested to obtain the target acceleration / deceleration curve that matches the target motion platform.
[0011] In one possible implementation, testing the plurality of acceleration / deceleration curves to obtain a target acceleration / deceleration curve that matches the target motion platform includes:
[0012] For any acceleration / deceleration curve to be screened, the target motion platform is controlled to move according to the acceleration / deceleration curve to be screened and the preset motion distance, and the jitter information of the target motion platform during the motion process is acquired;
[0013] The target acceleration / deceleration curve is determined based on the jitter information corresponding to each acceleration / deceleration curve to be screened.
[0014] In one possible implementation, the motion control parameters include at least one of the following:
[0015] Motor starting speed, acceleration time, deceleration time, cutoff speed, motor output power, motor microstepping, and motor load.
[0016] In one possible implementation, controlling the target motion platform to move based on a target acceleration / deceleration curve matched with the target motion platform and the target motion distance includes:
[0017] Based on the target acceleration / deceleration curve and the target motion distance, the motion duration of the target motion platform in each motion stage is determined;
[0018] The target motion platform is controlled to move according to the target acceleration / deceleration curve and the motion duration of the target motion platform in each motion stage.
[0019] In one possible implementation, determining the motion duration of the target motion platform in each motion phase based on the target acceleration / deceleration curve and the target motion distance includes:
[0020] Determine the simulated distance corresponding to the target acceleration / deceleration curve;
[0021] Based on the simulated distance and the target motion distance, the stage motion distance of the target motion platform in each motion stage is determined;
[0022] Based on the target acceleration / deceleration curve and the stage movement distance of the target motion platform in each movement stage, the movement duration of the target motion platform in each movement stage is determined.
[0023] In one possible implementation, the simulated distance is the sum of the first simulated distance during the acceleration phase and the second simulated distance during the deceleration phase;
[0024] The determination of the stage motion distance of the target motion platform in each motion phase based on the simulated distance and the target motion distance includes:
[0025] When the simulated distance is greater than or equal to the target motion distance, the target motion distance is divided into a first motion distance in the acceleration phase and a second motion distance in the deceleration phase according to a preset ratio.
[0026] If the simulated distance is less than the target motion distance, the first simulated distance is taken as the third motion distance in the acceleration phase, the second simulated distance is taken as the fourth motion distance in the deceleration phase, and the difference between the target motion distance and the simulated distance is taken as the fifth motion distance in the constant speed phase.
[0027] In one possible implementation, the method further includes:
[0028] Acquire motion state parameters of the target motion platform during its motion process; the motion state parameters include real-time motion speed and real-time motion distance during the current motion process;
[0029] Based on the motion state parameters and the target acceleration / deceleration curve, determine the motion error during the motion process at the current moment;
[0030] Based on the motion error and the target acceleration / deceleration curve, the target motion platform is controlled to move in the next moment.
[0031] Secondly, embodiments of this disclosure also provide a motion control device for a motion platform, comprising:
[0032] The acquisition module is used to acquire motion commands for the target motion platform and parse the motion commands to obtain the target motion distance corresponding to the target motion platform;
[0033] The control module is used to control the target motion platform to move based on the target acceleration / deceleration curve matched with the target motion platform and the target motion distance; wherein the target acceleration / deceleration curve is predetermined based on the motion control parameters of the target motion platform and is used to characterize the speed information of the target motion platform at each time point during the acceleration and deceleration phases of controlling the target motion platform to move.
[0034] In one possible implementation, the acquisition module is further configured to obtain a target acceleration / deceleration curve matching the target motion platform according to the following method:
[0035] Based on the motion control parameters and the pre-established target mathematical model, multiple acceleration / deceleration curves that conform to the target mathematical model under the simulation operation conditions corresponding to the motion control parameters are determined.
[0036] The multiple acceleration / deceleration curves to be screened are tested to obtain the target acceleration / deceleration curve that matches the target motion platform.
[0037] In one possible implementation, the acquisition module, when testing the multiple acceleration / deceleration curves to be screened and obtaining a target acceleration / deceleration curve that matches the target motion platform, is used to:
[0038] For any acceleration / deceleration curve to be screened, the target motion platform is controlled to move according to the acceleration / deceleration curve to be screened and the preset motion distance, and the jitter information of the target motion platform during the motion process is acquired;
[0039] The target acceleration / deceleration curve is determined based on the jitter information corresponding to each acceleration / deceleration curve to be screened.
[0040] In one possible implementation, the motion control parameters include at least one of the following:
[0041] Motor starting speed, acceleration time, deceleration time, cutoff speed, motor output power, motor microstepping, and motor load.
[0042] In one possible implementation, when the control module controls the target motion platform to move based on the target acceleration / deceleration curve matched with the target motion platform and the target motion distance, it is used to:
[0043] Based on the target acceleration / deceleration curve and the target motion distance, the motion duration of the target motion platform in each motion stage is determined;
[0044] The target motion platform is controlled to move according to the target acceleration / deceleration curve and the motion duration of the target motion platform in each motion stage.
[0045] In one possible implementation, the control module, when determining the motion duration of the target motion platform in each motion phase based on the target acceleration / deceleration curve and the target motion distance, is used to:
[0046] Determine the simulated distance corresponding to the target acceleration / deceleration curve;
[0047] Based on the simulated distance and the target motion distance, the stage motion distance of the target motion platform in each motion stage is determined;
[0048] Based on the target acceleration / deceleration curve and the stage movement distance of the target motion platform in each movement stage, the movement duration of the target motion platform in each movement stage is determined.
[0049] In one possible implementation, the simulated distance is the sum of the first simulated distance during the acceleration phase and the second simulated distance during the deceleration phase;
[0050] The control module, when determining the stage motion distance of the target motion platform in each motion stage based on the simulated distance and the target motion distance, is used to:
[0051] When the simulated distance is greater than or equal to the target motion distance, the target motion distance is divided into a first motion distance in the acceleration phase and a second motion distance in the deceleration phase according to a preset ratio.
[0052] If the simulated distance is less than the target motion distance, the first simulated distance is taken as the third motion distance in the acceleration phase, the second simulated distance is taken as the fourth motion distance in the deceleration phase, and the difference between the target motion distance and the simulated distance is taken as the fifth motion distance in the constant speed phase.
[0053] In one possible implementation, the acquisition module is further configured to:
[0054] Acquire motion state parameters of the target motion platform during its motion process; the motion state parameters include real-time motion speed and real-time motion distance during the current motion process;
[0055] Based on the motion state parameters and the target acceleration / deceleration curve, determine the motion error during the motion process at the current moment;
[0056] Based on the motion error and the target acceleration / deceleration curve, the target motion platform is controlled to move in the next moment.
[0057] Thirdly, embodiments of this disclosure also provide a computer device, including: a processor, a memory, and a bus, wherein the memory stores machine-readable instructions executable by the processor, and when the computer device is running, the processor communicates with the memory via the bus, and when the machine-readable instructions are executed by the processor, the steps of the first aspect above, or any possible implementation of the first aspect, are performed.
[0058] Fourthly, embodiments of this disclosure also provide a computer-readable storage medium storing a computer program that, when executed by a processor, performs the steps of the first aspect or any possible implementation of the first aspect.
[0059] The motion control method, apparatus, computer equipment, and storage medium for the motion platform provided in this disclosure can pre-determine a target acceleration / deceleration curve matching the target motion platform based on the motion control parameters of the target motion platform. Since the acceleration / deceleration process corresponding to the acceleration / deceleration curve is smoother in speed change than the acceleration / deceleration process corresponding to the trapezoidal acceleration / deceleration algorithm, jitter can be reduced during motion. Thus, high-precision control of the target motion platform can be achieved during specific motion based on the target acceleration / deceleration curve and the target motion distance corresponding to the motion command.
[0060] To make the above-mentioned objects, features and advantages of this disclosure more apparent and understandable, preferred embodiments are described below in detail with reference to the accompanying drawings. Attached Figure Description
[0061] To more clearly illustrate the technical solutions of the embodiments of this disclosure, the accompanying drawings used in the embodiments will be briefly described below. These drawings are incorporated in and constitute a part of this specification. They illustrate embodiments conforming to this disclosure and, together with the specification, serve to explain the technical solutions of this disclosure. It should be understood that the following drawings only show some embodiments of this disclosure and should not be considered as limiting the scope. Those skilled in the art can obtain other related drawings based on these drawings without creative effort.
[0062] Figure 1 A flowchart of a motion control method for a motion platform provided in an embodiment of this disclosure is shown;
[0063] Figure 2 A schematic diagram of the acceleration curve is shown in the motion control method of the motion platform provided in the embodiments of this disclosure;
[0064] Figure 3 This diagram illustrates the architecture of a motion control device for a motion platform provided in an embodiment of the present disclosure.
[0065] Figure 4 A schematic diagram of the structure of a computer device provided in an embodiment of this disclosure is shown. Detailed Implementation
[0066] To make the objectives, technical solutions, and advantages of the embodiments of this disclosure clearer, the technical solutions of the embodiments of this disclosure will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this disclosure, and not all of them. The components of the embodiments of this disclosure described and shown in the accompanying drawings can generally be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of this disclosure provided in the accompanying drawings is not intended to limit the scope of the claimed disclosure, but merely represents selected embodiments of this disclosure. All other embodiments obtained by those skilled in the art based on the embodiments of this disclosure without inventive effort are within the scope of protection of this disclosure.
[0067] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.
[0068] In this document, the term "and / or" merely describes a relationship, indicating that three relationships can exist. For example, A and / or B can represent three cases: A alone, A and B simultaneously, and B alone. Furthermore, the term "at least one" in this document means any combination of at least two of any one or more elements. For example, including at least one of A, B, and C can mean including any one or more elements selected from the set consisting of A, B, and C.
[0069] Research has found that related technologies often employ open-loop control methods such as trapezoidal acceleration / deceleration algorithms to control motors. These control methods are simple to implement and inexpensive, but they may generate significant vibrations during acceleration and deceleration, making them difficult to apply in high-precision control scenarios.
[0070] Based on the above research, this disclosure provides a motion control method, device, computer equipment, and storage medium for a motion platform. It can pre-determine a target acceleration / deceleration curve that matches the target motion platform based on the motion control parameters of the target motion platform. Since the acceleration / deceleration process corresponding to the acceleration / deceleration curve is smoother in speed change than the acceleration / deceleration process corresponding to the trapezoidal acceleration / deceleration algorithm, jitter can be reduced during motion. Thus, high-precision control of the target motion platform can be achieved during specific motion based on the target acceleration / deceleration curve and the target motion distance corresponding to the motion command.
[0071] To facilitate understanding of this embodiment, a detailed description of the motion control method for a motion platform disclosed in this disclosure is provided first. The execution entity of the motion control method for the motion platform provided in this disclosure is generally a computer device with certain computing capabilities. This computer device may include, for example, a terminal device, a server, or other processing devices. The terminal device may be a user equipment (UE), a mobile device, a user terminal, a terminal, a personal digital assistant (PDA), a handheld device, a computing device, an in-vehicle device, a wearable device, etc. In some possible implementations, the motion control method of this motion platform can be implemented by a processor calling computer-readable instructions stored in memory.
[0072] See Figure 1 The diagram shows a flowchart of a motion control method for a motion platform provided in an embodiment of this disclosure. The method includes steps S101 to S102, wherein:
[0073] S101: Obtain motion instructions for the target motion platform, parse the motion instructions, and obtain the target motion distance corresponding to the target motion platform.
[0074] S102: Based on the target acceleration / deceleration curve matched with the target motion platform and the target motion distance, control the target motion platform to move; wherein, the target acceleration / deceleration curve is predetermined based on the motion control parameters of the target motion platform and is used to characterize the speed information of the target motion platform at each moment during the acceleration and deceleration phases of controlling the target motion platform to move.
[0075] The following is a detailed explanation of the steps described above.
[0076] For S101,
[0077] Here, the target motion platform can be an XY motion platform, and the target motion platform can control the motion components in the target motion platform to move; the motion command can be sent by a host computer that has established a communication connection with the target motion platform, and the motion command can include the target motion distance corresponding to the motion components in the target motion platform.
[0078] For S102,
[0079] Here, the target acceleration / deceleration curve can be composed of an acceleration curve and a deceleration curve; wherein, the acceleration curve is used to characterize the velocity information of the target motion platform at each moment during the acceleration phase of controlling the target motion platform to move; the deceleration curve is used to characterize the velocity information of the target motion platform at each moment during the deceleration phase of controlling the target motion platform to move.
[0080] For example, a schematic diagram of the acceleration curve can be as follows: Figure 2 As shown, Figure 2 The horizontal axis represents time, and the vertical axis represents the speed information of the motor in the target motion platform. The motor in the target motion platform can be, for example, a stepper motor, which is a type of electric motor that converts electrical pulse signals into corresponding angular or linear displacements. The speed information can include the rotational speed of the stepper motor rotor.
[0081] In practical applications, the target acceleration / deceleration curve can be predetermined, and the motion control information affecting the target acceleration / deceleration curve can include at least one of the following: motor starting speed, acceleration time, deceleration time, cutoff speed, motor output power, motor microstepping, and motor load.
[0082] Wherein, the motor starting speed is used to characterize the theoretical speed of the motor at the moment of starting; the acceleration time is used to characterize the time spent in the acceleration phase of the motor during operation; the deceleration time is used to characterize the time spent in the deceleration phase of the motor during operation; the cutoff speed is used to characterize the maximum speed of the motor during operation; the motor output power is used to characterize the maximum power of the motor during operation; the motor microstepping is used to characterize how many pulse signals the motor needs to receive before it will start moving. Taking a stepper motor with a microstepping of 4 as an example, the motor will rotate once after receiving 4 pulse signals; the motor load is used to characterize the object moved by the motor during operation.
[0083] In one possible implementation, the target acceleration / deceleration curve can also be obtained through the following steps A1-A2:
[0084] A1: Based on the motion control parameters and the pre-established target mathematical model, determine multiple acceleration / deceleration curves that conform to the target mathematical model under the simulation operation conditions corresponding to the motion control parameters.
[0085] Here, the target mathematical model may include an arbitrary-order S-curve for high-precision control. For example, the target mathematical model may be y = A + B*sin(a*x + b), where y represents motor speed information; x represents time; A, B, a, and b are hyperparameters, which are related to the control parameters of the target motion platform and can be obtained by fitting parameters under simulation conditions. The simulation conditions may be, for example, the simulation conditions in Matrix Laboratory (MATLAB).
[0086] Specifically, when determining multiple acceleration / deceleration curves to be screened, corresponding parameter values can be assigned manually or randomly to the motion control parameters to obtain multiple sets of motion control parameter values. For each set of motion control parameter values, based on the target mathematical model and simulation operation conditions, the specific parameter values of each hyperparameter (i.e., A, B, a, b) in the target mathematical model can be determined when the motion platform is controlled by using this set of motion control parameter values.
[0087] In this way, by conducting simulations in advance, multiple acceleration / deceleration curves that conform to the preset target mathematical model can be obtained, which facilitates subsequent screening to obtain the target acceleration / deceleration curve that meets the actual needs.
[0088] A2: Test the multiple acceleration / deceleration curves to be screened to obtain the target acceleration / deceleration curve that matches the target motion platform.
[0089] Here, in order to further improve the control effect of the final acceleration and deceleration curve, during the test, the acceleration curve and deceleration curve in each of the acceleration and deceleration curves to be screened can be tested separately, and the target acceleration curve and target deceleration curve that meet the requirements can be combined to obtain the target acceleration and deceleration curve.
[0090] In one possible implementation, when testing the acceleration / deceleration curves to be screened, the following steps A21 to A22 can be used:
[0091] A21: For any acceleration / deceleration curve to be screened, control the target motion platform to move according to the acceleration / deceleration curve to be screened and the preset motion distance, and obtain the jitter information of the target motion platform during the motion process.
[0092] Here, the jitter information during the motion of the target motion platform is used to characterize the jitter of the motion components in the target motion platform during the motion process. The jitter information can be obtained by devices such as a laser interferometer.
[0093] For example, taking the use of a laser interferometer to obtain jitter information during the motion of the target motion platform as an example, the laser interferometer can detect the pose changes of the motion components in the target motion platform during operation. By measuring the pose changes at each time point, the jitter of the motion components can be determined. The pose changes are directly proportional to the jitter; that is, the greater the pose changes, the greater the jitter of the motion components.
[0094] A22: Based on the jitter information corresponding to each acceleration / deceleration curve to be screened, the target acceleration / deceleration curve is determined.
[0095] Here, when determining the target acceleration / deceleration curve based on the jitter information corresponding to each acceleration / deceleration curve to be screened, the acceleration / deceleration curve to be screened whose jitter information meets the preset jitter requirements can be used as the target acceleration / deceleration curve; or...
[0096] The acceleration curve whose jitter information meets the preset jitter requirements among the acceleration curves corresponding to each acceleration / deceleration curve to be screened can be taken as the target acceleration curve, and the deceleration curve whose jitter information meets the preset jitter requirements among the deceleration curves corresponding to each acceleration / deceleration curve to be screened can be taken as the target deceleration curve. The target acceleration curve and the target deceleration curve can be combined to obtain the target acceleration / deceleration curve.
[0097] The preset jitter requirement may be, for example, the minimum jitter, or the jitter parameter value used to characterize the jitter is less than a preset parameter threshold. The method for determining the jitter parameter value is not limited in this embodiment of the disclosure, but is based on the ability to characterize the jitter of the moving component during the movement.
[0098] In this way, by screening the acceleration and deceleration curves to be screened based on the vibration of the moving components during the testing process, the target acceleration and deceleration curve that meets the requirements of actual application can be determined.
[0099] In one possible implementation, when controlling the target motion platform to move, the following steps B1 to B2 can be used:
[0100] B1: Based on the target acceleration / deceleration curve and the target motion distance, determine the motion duration of the target motion platform in each motion stage.
[0101] Here, after determining the target acceleration / deceleration curve, the speed information corresponding to each moment can be obtained. The target movement distance in the actual operation process may be long or short. Therefore, based on the target acceleration / deceleration curve, the movement duration of each movement stage in the process of moving according to the target movement distance can be determined. Thus, the movement components of the target motion platform can be controlled to move according to the determined movement duration.
[0102] In one possible implementation, the determination of the motion duration of the target motion platform in each motion phase can be achieved through the following steps B11 to B12:
[0103] B11: Determine the simulated distance corresponding to the target acceleration / deceleration curve.
[0104] Here, the simulated distance is the sum of the first simulated distance of the acceleration phase and the second simulated distance of the deceleration phase; wherein, the first simulated distance can be determined based on the acceleration curve in the target acceleration / deceleration curve, the start time corresponding to the acceleration phase, and the end time corresponding to the acceleration phase; and the second simulated distance can be determined based on the deceleration curve in the target acceleration / deceleration curve, the start time corresponding to the deceleration phase, and the end time corresponding to the deceleration phase.
[0105] Specifically, when determining the first simulated distance, the integral of the acceleration curve from the start time to the end time of the acceleration phase can be used as the first simulated distance; and the integral of the deceleration curve from the start time to the end time of the deceleration phase can be used as the second simulated distance.
[0106] B12: Based on the simulated distance and the target motion distance, determine the stage motion distance of the target motion platform in each motion stage.
[0107] Based on the relationship between the simulated distance and the target's moving distance, the following two cases can be distinguished:
[0108] Case 1: The simulated distance is greater than or equal to the target movement distance.
[0109] Here, when the simulated distance is greater than or equal to the target motion distance, the target motion distance can be divided into a first motion distance in the acceleration phase and a second motion distance in the deceleration phase according to a preset ratio.
[0110] The preset ratio can be 1:1, that is, when the target movement distance is less than or equal to the simulated distance, the target movement distance can be divided into a first movement distance and a second movement distance.
[0111] For example, taking the simulation distance as 10 and the target motion distance as 8, the target motion distance can be divided into equal parts to obtain the first motion distance of 4 in the acceleration phase and the second motion distance of 4 in the deceleration phase.
[0112] Scenario 2: The simulated distance is less than the target movement distance.
[0113] Here, when the simulated distance is less than the target motion distance, the first simulated distance can be used as the third motion distance in the acceleration phase, the second simulated distance can be used as the fourth motion distance in the deceleration phase, and the difference between the target motion distance and the simulated distance can be used as the fifth motion distance in the constant speed phase.
[0114] For example, taking the simulated distance as 10 and the target movement distance as 12, the first simulated distance "5" can be used as the third movement distance in the acceleration phase, the second simulated distance "5" as the fourth movement distance in the deceleration phase, and the difference "2" between the target movement distance and the simulated distance as the fifth movement distance in the constant speed phase.
[0115] B13: Based on the target acceleration / deceleration curve and the stage movement distance of the target motion platform in each movement stage, determine the movement duration of the target motion platform in each movement stage.
[0116] Here, when determining the duration of each motion phase, the termination time of each motion phase can be determined based on the target acceleration / deceleration curve and the phase motion distance of the target motion platform in each motion phase. Thus, the duration of each motion phase can be determined based on the termination time of each motion phase.
[0117] Specifically, the integral of the acceleration curve in the target acceleration / deceleration curve over time can be expressed as the distance traveled at the current moment. Therefore, the correspondence between the distance traveled at each moment can be determined, and the termination time of each motion stage can be determined based on the stage motion distance. The starting time of the acceleration motion stage is "0", and the starting time of the deceleration motion stage is the moment when the maximum speed in the acceleration stage is reached (that is, the moment when deceleration begins).
[0118] Furthermore, since the uniform motion phase can be performed at the maximum speed, when the motion phase of the target motion platform includes the uniform motion phase, the motion duration of the uniform motion phase can be determined based on the fifth motion distance of the uniform motion phase and the cutoff speed (i.e., the maximum speed) in the target acceleration / deceleration curve. The quotient of the fifth motion distance and the cutoff speed is the motion duration of the uniform motion phase.
[0119] B2: Control the target motion platform to move according to the target acceleration / deceleration curve and the motion duration of the target motion platform in each motion stage.
[0120] In this way, by determining the motion duration and following the target acceleration / deceleration curve that meets the jitter requirements, the jitter problem of the target motion platform during motion can be reduced, thereby achieving high-precision control of the target motion platform.
[0121] In practical applications, due to abnormal factors such as motor aging or damage, or delay in motion command transmission, the target motion platform may not be able to move at the speed corresponding to the target acceleration and deceleration curve during the motion process. This results in a large deviation between the real-time motion speed and real-time motion distance and the preset values, making it impossible to achieve high-precision control of the target motion platform.
[0122] In one possible implementation, the target motion platform can also be controlled to move through the following steps C1 to C3:
[0123] C1: Obtain the motion state parameters of the target motion platform during its motion process; the motion state parameters include the real-time motion speed and the real-time motion distance during this motion process.
[0124] Here, the motion state parameters can be acquired using a motion state acquisition device corresponding to the target motion platform.
[0125] Specifically, the motion state acquisition device may be, for example, an encoder, and the encoder may be, for example, an incremental encoder; wherein, the real-time motion speed can be calculated by the width of the high level in the level signal acquired by the encoder, and the real-time motion distance can be calculated by the number of pulses acquired by the encoder.
[0126] C2: Based on the motion state parameters and the target acceleration / deceleration curve, determine the motion error during the motion process at the current moment.
[0127] Here, the target acceleration / deceleration curve may include the theoretical motion speed at any given moment. By integrating, the theoretical motion distance at any given moment can be obtained. Therefore, a first motion error representing the motion speed error value can be determined based on the theoretical motion speed and the real-time motion speed, and a second motion error representing the motion distance error value can be determined based on the theoretical motion distance and the real-time motion distance.
[0128] C3: Based on the motion error and the target acceleration / deceleration curve, control the target motion platform to move in the next moment.
[0129] Furthermore, after determining the motion error according to the above steps, error compensation can be performed on the motion error to achieve high-precision control of the target motion platform.
[0130] Specifically, when performing error compensation, the motion compensation value corresponding to the next moment can be determined based on the motion error, and the speed information after error compensation can be determined based on the target acceleration / deceleration curve and the motion compensation value, so as to control the target motion platform to move using the speed information after error compensation in the next moment.
[0131] It should be noted that the embodiments disclosed herein do not impose restrictions on how to perform error compensation after determining the motion error, but only require that the error compensation effect can be achieved.
[0132] In this way, by promptly compensating for motion errors after they are identified, abnormal problems caused by error accumulation can be avoided, thereby achieving high-precision control of the target motion platform.
[0133] The motion control method for the motion platform provided in this embodiment can pre-determine a target acceleration / deceleration curve that matches the target motion platform based on the motion control parameters of the target motion platform. Since the acceleration / deceleration process corresponding to the acceleration / deceleration curve is smoother in speed change than the acceleration / deceleration process corresponding to the trapezoidal acceleration / deceleration algorithm, jitter can be reduced during motion. Thus, high-precision control of the target motion platform can be achieved during specific motion based on the target acceleration / deceleration curve and the target motion distance corresponding to the motion command.
[0134] Those skilled in the art will understand that, in the above-described method of the specific implementation, the order in which each step is written does not imply a strict execution order and does not constitute any limitation on the implementation process. The specific execution order of each step should be determined by its function and possible internal logic.
[0135] Based on the same inventive concept, this disclosure also provides a motion control device for a motion platform corresponding to the motion control method of the motion platform. Since the principle of the device in this disclosure for solving the problem is similar to the motion control method of the motion platform described above in this disclosure, the implementation of the device can refer to the implementation of the method, and the repeated parts will not be described again.
[0136] Reference Figure 3 The diagram shown is an architectural schematic of a motion control device for a motion platform provided in an embodiment of this disclosure. The device includes: an acquisition module 301 and a control module 302; wherein,
[0137] The acquisition module 301 is used to acquire motion commands for the target motion platform and parse the motion commands to obtain the target motion distance corresponding to the target motion platform;
[0138] The control module 302 is used to control the target motion platform to move based on the target acceleration / deceleration curve matched with the target motion platform and the target motion distance; wherein the target acceleration / deceleration curve is predetermined based on the motion control parameters of the target motion platform and is used to characterize the speed information of the target motion platform at each time point during the acceleration and deceleration phases of controlling the target motion platform to move.
[0139] In one possible implementation, the acquisition module 301 is further configured to obtain a target acceleration / deceleration curve matching the target motion platform according to the following method:
[0140] Based on the motion control parameters and the pre-established target mathematical model, multiple acceleration / deceleration curves that conform to the target mathematical model under the simulation operation conditions corresponding to the motion control parameters are determined.
[0141] The multiple acceleration / deceleration curves to be screened are tested to obtain the target acceleration / deceleration curve that matches the target motion platform.
[0142] In one possible implementation, the acquisition module 301, when testing the plurality of acceleration / deceleration curves to be screened and obtaining a target acceleration / deceleration curve that matches the target motion platform, is used to:
[0143] For any acceleration / deceleration curve to be screened, the target motion platform is controlled to move according to the acceleration / deceleration curve to be screened and the preset motion distance, and the jitter information of the target motion platform during the motion process is acquired;
[0144] The target acceleration / deceleration curve is determined based on the jitter information corresponding to each acceleration / deceleration curve to be screened.
[0145] In one possible implementation, the motion control parameters include at least one of the following:
[0146] Motor starting speed, acceleration time, deceleration time, cutoff speed, motor output power, motor microstepping, and motor load.
[0147] In one possible implementation, when the control module 302 controls the target motion platform to move based on the target acceleration / deceleration curve matched with the target motion platform and the target motion distance, it is used to:
[0148] Based on the target acceleration / deceleration curve and the target motion distance, the motion duration of the target motion platform in each motion stage is determined;
[0149] The target motion platform is controlled to move according to the target acceleration / deceleration curve and the motion duration of the target motion platform in each motion stage.
[0150] In one possible implementation, the control module 302, when determining the motion duration of the target motion platform in each motion phase based on the target acceleration / deceleration curve and the target motion distance, is used to:
[0151] Determine the simulated distance corresponding to the target acceleration / deceleration curve;
[0152] Based on the simulated distance and the target motion distance, the stage motion distance of the target motion platform in each motion stage is determined;
[0153] Based on the target acceleration / deceleration curve and the stage movement distance of the target motion platform in each movement stage, the movement duration of the target motion platform in each movement stage is determined.
[0154] In one possible implementation, the simulated distance is the sum of the first simulated distance during the acceleration phase and the second simulated distance during the deceleration phase;
[0155] The control module 302, when determining the stage motion distance of the target motion platform in each motion stage based on the simulated distance and the target motion distance, is used to:
[0156] When the simulated distance is greater than or equal to the target motion distance, the target motion distance is divided into a first motion distance in the acceleration phase and a second motion distance in the deceleration phase according to a preset ratio.
[0157] If the simulated distance is less than the target motion distance, the first simulated distance is taken as the third motion distance in the acceleration phase, the second simulated distance is taken as the fourth motion distance in the deceleration phase, and the difference between the target motion distance and the simulated distance is taken as the fifth motion distance in the constant speed phase.
[0158] In one possible implementation, the acquisition module 301 is further configured to:
[0159] Acquire motion state parameters of the target motion platform during its motion process; the motion state parameters include real-time motion speed and real-time motion distance during the current motion process;
[0160] Based on the motion state parameters and the target acceleration / deceleration curve, determine the motion error during the motion process at the current moment;
[0161] Based on the motion error and the target acceleration / deceleration curve, the target motion platform is controlled to move in the next moment.
[0162] The motion control device for the motion platform provided in this embodiment can pre-determine a target acceleration / deceleration curve that matches the target motion platform based on the motion control parameters of the target motion platform. Since the acceleration / deceleration process corresponding to the acceleration / deceleration curve is smoother in speed change than the acceleration / deceleration process corresponding to the trapezoidal acceleration / deceleration algorithm, jitter can be reduced during motion. Thus, high-precision control of the target motion platform can be achieved during specific motion based on the target acceleration / deceleration curve and the target motion distance corresponding to the motion command.
[0163] The processing flow of each module in the device and the interaction flow between each module can be referred to the relevant descriptions in the above method embodiments, and will not be detailed here.
[0164] Based on the same technical concept, this disclosure also provides a computer device. (See also...) Figure 4 The diagram shows the structure of a computer device 400 provided in this embodiment, including a processor 401, a memory 402, and a bus 403. The memory 402 stores execution instructions and includes main memory 4021 and external memory 4022. The main memory 4021, also called internal memory, is used to temporarily store computational data in the processor 401 and data exchanged with external memory 4022 such as a hard disk. The processor 401 exchanges data with the external memory 4022 through the main memory 4021. When the computer device 400 is running, the processor 401 and the memory 402 communicate through the bus 403, causing the processor 401 to execute the following instructions:
[0165] Obtain motion commands for the target motion platform, parse the motion commands, and obtain the target motion distance corresponding to the target motion platform;
[0166] Based on the target acceleration / deceleration curve matched with the target motion platform and the target motion distance, the target motion platform is controlled to move; wherein, the target acceleration / deceleration curve is predetermined based on the motion control parameters of the target motion platform and is used to characterize the speed information of the target motion platform at each moment during the acceleration and deceleration phases of controlling the target motion platform to move.
[0167] In one possible implementation, the instructions of the processor 401 further include obtaining a target acceleration / deceleration curve matching the target motion platform according to the following method:
[0168] Based on the motion control parameters and the pre-established target mathematical model, multiple acceleration / deceleration curves that conform to the target mathematical model under the simulation operation conditions corresponding to the motion control parameters are determined.
[0169] The multiple acceleration / deceleration curves to be screened are tested to obtain the target acceleration / deceleration curve that matches the target motion platform.
[0170] In one possible implementation, the instructions of the processor 401, specifically the step of testing the plurality of acceleration / deceleration curves to be screened to obtain a target acceleration / deceleration curve matching the target motion platform, include:
[0171] For any acceleration / deceleration curve to be screened, the target motion platform is controlled to move according to the acceleration / deceleration curve to be screened and the preset motion distance, and the jitter information of the target motion platform during the motion process is acquired;
[0172] The target acceleration / deceleration curve is determined based on the jitter information corresponding to each acceleration / deceleration curve to be screened.
[0173] In one possible implementation, the motion control parameters in the instructions of the processor 401 include at least one of the following:
[0174] Motor starting speed, acceleration time, deceleration time, cutoff speed, motor output power, motor microstepping, and motor load.
[0175] In one possible implementation, the instructions of the processor 401, based on the target acceleration / deceleration curve matching the target motion platform and the target motion distance, control the target motion platform to move, including:
[0176] Based on the target acceleration / deceleration curve and the target motion distance, the motion duration of the target motion platform in each motion stage is determined;
[0177] The target motion platform is controlled to move according to the target acceleration / deceleration curve and the motion duration of the target motion platform in each motion stage.
[0178] In one possible implementation, the instruction of the processor 401, which determines the motion duration of the target motion platform in each motion phase based on the target acceleration / deceleration curve and the target motion distance, includes:
[0179] Determine the simulated distance corresponding to the target acceleration / deceleration curve;
[0180] Based on the simulated distance and the target motion distance, the stage motion distance of the target motion platform in each motion stage is determined;
[0181] Based on the target acceleration / deceleration curve and the stage movement distance of the target motion platform in each movement stage, the movement duration of the target motion platform in each movement stage is determined.
[0182] In one possible implementation, in the instructions of the processor 401, the simulation distance is the sum of the first simulation distance of the acceleration phase and the second simulation distance of the deceleration phase;
[0183] The determination of the stage motion distance of the target motion platform in each motion phase based on the simulated distance and the target motion distance includes:
[0184] When the simulated distance is greater than or equal to the target motion distance, the target motion distance is divided into a first motion distance in the acceleration phase and a second motion distance in the deceleration phase according to a preset ratio.
[0185] If the simulated distance is less than the target motion distance, the first simulated distance is taken as the third motion distance in the acceleration phase, the second simulated distance is taken as the fourth motion distance in the deceleration phase, and the difference between the target motion distance and the simulated distance is taken as the fifth motion distance in the constant speed phase.
[0186] 5. In one possible implementation, the instructions of the processor 401 further include:
[0187] Acquire motion state parameters of the target motion platform during its motion process; the motion state parameters include real-time motion speed and real-time motion distance during the current motion process;
[0188] Based on the motion state parameters and the target acceleration / deceleration curve, determine the motion error during the motion process at the current moment;
[0189] Based on the motion error and the target acceleration / deceleration curve, the target motion platform is controlled to move in the next moment.
[0190] This disclosure also provides a computer-readable storage medium storing a computer program, which, when executed by a processor, performs the above-described methods.
[0191] The steps of the motion control method for the motion platform described in the example. The storage medium can be a volatile or non-volatile computer-readable storage medium.
[0192] This disclosure also provides a computer program product carrying program code. The program code includes instructions that can be used to execute the steps of the motion control method of the motion platform described in the above method embodiments. For details, please refer to the above method embodiments, which will not be repeated here.
[0193] The aforementioned computer program product can be implemented through hardware, software, or a combination thereof. In one optional embodiment, the computer program product is specifically embodied in a computer storage medium; in another optional embodiment, the computer program product is specifically embodied in a software product, such as a software development kit (SDK), etc.
[0194] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems and devices described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here. In the several embodiments provided in this disclosure, it should be understood that the disclosed systems, devices, and methods can be implemented in other ways. The device embodiments described above are merely illustrative. For example, the division of units is only a logical functional division; in actual implementation, there may be other division methods. Furthermore, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Another point is that the displayed or discussed mutual coupling or direct coupling or communication connection may be through some communication interfaces; the indirect coupling or communication connection of devices or units may be electrical, mechanical, or other forms.
[0195] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0196] In addition, the functional units in the various embodiments of this disclosure can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
[0197] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a processor-executable, non-volatile, computer-readable storage medium. Based on this understanding, the technical solution of this disclosure, in essence, or the part that contributes to the prior art, or a portion 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 includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this disclosure. 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.
[0198] Finally, it should be noted that the above-described embodiments are merely specific implementations of this disclosure, used to illustrate the technical solutions of this disclosure, and not to limit it. The protection scope of this disclosure is not limited thereto. Although this disclosure has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that any person skilled in the art can still modify or easily conceive of changes to the technical solutions described in the foregoing embodiments, or make equivalent substitutions for some of the technical features, within the scope of the technology disclosed in this disclosure. Such modifications, changes, or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this disclosure, and should all be covered within the protection scope of this disclosure. Therefore, the protection scope of this disclosure should be determined by the protection scope of the claims.
Claims
1. A motion control method for a motion platform, characterized in that, include: Obtain motion commands for the target motion platform, parse the motion commands, and obtain the target motion distance corresponding to the target motion platform; Based on the target acceleration / deceleration curve matched with the target motion platform and the target motion distance, the target motion platform is controlled to move; wherein, the target acceleration / deceleration curve is predetermined based on the motion control parameters of the target motion platform and is used to characterize the speed information of the target motion platform at each moment during the acceleration and deceleration phases of controlling the target motion platform to move; The method further includes obtaining a target acceleration / deceleration curve that matches the target motion platform according to the following method: Based on the motion control parameters and the pre-established target mathematical model, multiple acceleration / deceleration curves that conform to the target mathematical model under the simulation operation conditions corresponding to the motion control parameters are determined. For any acceleration / deceleration curve to be screened, the target motion platform is controlled to move according to the acceleration / deceleration curve to be screened and a preset motion distance, and the jitter information of the target motion platform during the motion process is acquired; The target acceleration / deceleration curve is determined based on the jitter information corresponding to each acceleration / deceleration curve to be screened.
2. The method according to claim 1, characterized in that, The motion control parameters include at least one of the following: Motor starting speed, acceleration time, deceleration time, cutoff speed, motor output power, motor microstepping, and motor load.
3. The method according to claim 1, characterized in that, Based on the target acceleration / deceleration curve matched with the target motion platform and the target motion distance, the target motion platform is controlled to move, including: Based on the target acceleration / deceleration curve and the target motion distance, the motion duration of the target motion platform in each motion stage is determined; The target motion platform is controlled to move according to the target acceleration / deceleration curve and the motion duration of the target motion platform in each motion stage.
4. The method according to claim 3, characterized in that, The determination of the motion duration of the target motion platform in each motion phase based on the target acceleration / deceleration curve and the target motion distance includes: Determine the simulated distance corresponding to the target acceleration / deceleration curve; Based on the simulated distance and the target motion distance, the stage motion distance of the target motion platform in each motion stage is determined; Based on the target acceleration / deceleration curve and the stage movement distance of the target motion platform in each movement stage, the movement duration of the target motion platform in each movement stage is determined.
5. The method according to claim 4, characterized in that, The simulated distance is the sum of the first simulated distance during the acceleration phase and the second simulated distance during the deceleration phase; The determination of the stage motion distance of the target motion platform in each motion phase based on the simulated distance and the target motion distance includes: When the simulated distance is greater than or equal to the target motion distance, the target motion distance is divided into a first motion distance in the acceleration phase and a second motion distance in the deceleration phase according to a preset ratio. If the simulated distance is less than the target motion distance, the first simulated distance is taken as the third motion distance in the acceleration phase, the second simulated distance is taken as the fourth motion distance in the deceleration phase, and the difference between the target motion distance and the simulated distance is taken as the fifth motion distance in the constant speed phase.
6. The method according to claim 1, characterized in that, The method further includes: Acquire motion state parameters of the target motion platform during its motion process; the motion state parameters include real-time motion speed and real-time motion distance during the current motion process; Based on the motion state parameters and the target acceleration / deceleration curve, determine the motion error during the motion process at the current moment; Based on the motion error and the target acceleration / deceleration curve, the target motion platform is controlled to move in the next moment.
7. A motion control device for a motion platform, characterized in that, include: The acquisition module is used to acquire motion commands for the target motion platform and parse the motion commands to obtain the target motion distance corresponding to the target motion platform; The control module is used to control the target motion platform to move based on the target acceleration / deceleration curve matched with the target motion platform and the target motion distance; wherein, the target acceleration / deceleration curve is predetermined based on the motion control parameters of the target motion platform and is used to characterize the speed information of the target motion platform at each moment during the acceleration and deceleration phases of controlling the target motion platform to move; The acquisition module is also used to obtain a target acceleration / deceleration curve that matches the target motion platform according to the following method: Based on the motion control parameters and the pre-established target mathematical model, multiple acceleration / deceleration curves that conform to the target mathematical model under the simulation operation conditions corresponding to the motion control parameters are determined. For any acceleration / deceleration curve to be screened, the target motion platform is controlled to move according to the acceleration / deceleration curve to be screened and a preset motion distance, and the jitter information of the target motion platform during the motion process is acquired; The target acceleration / deceleration curve is determined based on the jitter information corresponding to each acceleration / deceleration curve to be screened.
8. A computer device, characterized in that, include: The computer device includes a processor, a memory, and a bus. The memory stores machine-readable instructions executable by the processor. When the computer device is running, the processor communicates with the memory via the bus. When the machine-readable instructions are executed by the processor, they perform the steps of the motion control method of the motion platform as described in any one of claims 1 to 6.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, performs the steps of the motion control method for the motion platform as described in any one of claims 1 to 6.
Citation Information
Patent Citations
Speed control method and device for moving target and readable storage medium
CN110968045A