CN115242130A - Driving method and device of servo motor, storage medium and processor - Google Patents

Driving method and device of servo motor, storage medium and processor Download PDF

Info

Publication number
CN115242130A
CN115242130A CN202210963770.0A CN202210963770A CN115242130A CN 115242130 A CN115242130 A CN 115242130A CN 202210963770 A CN202210963770 A CN 202210963770A CN 115242130 A CN115242130 A CN 115242130A
Authority
CN
China
Prior art keywords
servo motor
target
current value
determining
driving
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.)
Pending
Application number
CN202210963770.0A
Other languages
Chinese (zh)
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.)
Beijing Fujirui Optoelectronic Technology Co ltd
Original Assignee
Beijing Fujirui Optoelectronic 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 Beijing Fujirui Optoelectronic Technology Co ltd filed Critical Beijing Fujirui Optoelectronic Technology Co ltd
Priority to CN202210963770.0A priority Critical patent/CN115242130A/en
Publication of CN115242130A publication Critical patent/CN115242130A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H02GENERATION; CONVERSION OR DISTRIBUTION OF ELECTRIC POWER
    • H02PCONTROL OR REGULATION OF ELECTRIC MOTORS, ELECTRIC GENERATORS OR DYNAMO-ELECTRIC CONVERTERS; CONTROLLING TRANSFORMERS, REACTORS OR CHOKE COILS
    • H02P1/00Arrangements for starting electric motors or dynamo-electric converters
    • H02P1/02Details of starting control
    • H02P1/04Means for controlling progress of starting sequence in dependence upon time or upon current, speed, or other motor parameter
    • HELECTRICITY
    • H02GENERATION; CONVERSION OR DISTRIBUTION OF ELECTRIC POWER
    • H02PCONTROL OR REGULATION OF ELECTRIC MOTORS, ELECTRIC GENERATORS OR DYNAMO-ELECTRIC CONVERTERS; CONTROLLING TRANSFORMERS, REACTORS OR CHOKE COILS
    • H02P29/00Arrangements for regulating or controlling electric motors, appropriate for both AC and DC motors
    • H02P29/40Regulating or controlling the amount of current drawn or delivered by the motor for controlling the mechanical load

Landscapes

  • Engineering & Computer Science (AREA)
  • Power Engineering (AREA)
  • Control Of Electric Motors In General (AREA)

Abstract

The application discloses a driving method and device of a servo motor, a storage medium and a processor. The method comprises the following steps: determining a target environment temperature value according to the current environment temperature value of the servo motor; determining a preset current value according to a target running speed of the servo motor, wherein the target running speed is a running speed configured for the servo motor in advance; determining a target current value according to the target environment temperature value and a preset current value; and driving the servo motor by combining a PID algorithm based on the target current value. Through this application, solved in the correlation technique in the motor start-up in the twinkling of an eye and when driving servo motor under high low temperature environment, be difficult to guarantee servo motor's even running's problem.

Description

Driving method and device of servo motor, storage medium and processor
Technical Field
The present disclosure relates to the field of controllers, and in particular, to a method and an apparatus for driving a servo motor, a storage medium, and a processor.
Background
In the process of motor drive control, under different industrial controls, the motor can influence the running stability of the motor due to different torques. Moreover, the output torque of the motor is greatly influenced by the temperature, generally, the same driving current is loaded, the torque of the motor is small under the low-temperature condition, and the load resistance is large; the motor torque is large and the load resistance is small under the high temperature condition. At the same time, the load resistance is also influenced by the rotational speed.
In the related technology, the conventional motor PID driving algorithm mainly carries out closed-loop control through three loops of current, speed and position of the motor. The method comprises the steps of firstly, calculating and setting the maximum current, the voltage and the driving frequency required by motor driving according to factory parameters of a motor, setting a position which the motor wants to reach, carrying out PID algorithm of a position loop according to the set position, calculating the running speed required by the motor, carrying out PID algorithm of a speed loop according to the calculated speed, and calculating the current value required by the driving motor. And finally, the duty ratio of PWM is adjusted through a current loop PID, so that three-loop closed-loop control of the motor is realized.
However, the related art ignores the variation of the motor parameter due to the temperature influence throughout the closed loop process. Generally, at low temperatures, the internal resistance of the motor increases, the transmission resistance increases, and the output torque of the motor decreases. Under the high temperature condition, the internal resistance of the motor is reduced, the resistance of the transmission mechanism is reduced, and the output torque of the motor is increased. In addition, in the motor movement process, the load resistance can be changed under different speed conditions, and the prominent effect is shown at the motor starting moment. The transition of load resistance from static to dynamic friction causes a step decrease in resistance. Therefore, the motor is driven by the prior art, so that the motor does not move stably at the starting moment and under the conditions of high and low temperatures. The starting speed is slow, the response bandwidth is low, or the phenomena of jitter and overshoot exist.
Aiming at the problem that in the prior art, when the servo motor is driven at the moment of starting the motor and in a high-temperature and low-temperature environment, the stable operation of the servo motor is difficult to ensure, an effective solution is not provided at present.
Disclosure of Invention
The present application mainly aims to provide a method and an apparatus for driving a servo motor, a storage medium, and a processor, so as to solve the problem in the related art that it is difficult to ensure stable operation of the servo motor when the servo motor is driven at the instant of starting the motor and in a high/low temperature environment.
In order to achieve the above object, according to one aspect of the present application, there is provided a driving method of a servo motor. The method comprises the following steps: determining a target environment temperature value according to the current environment temperature value of the servo motor; determining a preset current value according to a target running speed of the servo motor, wherein the target running speed is a running speed configured for the servo motor in advance; determining a target current value according to the target environment temperature value and the preset current value; and driving the servo motor by combining a PID algorithm based on the target current value.
Further, determining a preset current value according to the target operating speed of the servo motor includes: acquiring target position data information, wherein the target position data information is used for representing the current position information of the servo motor; determining the target running speed based on the target position data information and in combination with the PID algorithm; and determining the preset current value based on the target running speed by combining the PID algorithm.
Further, determining the preset current value based on the target operating speed in combination with the PID algorithm includes: setting a corresponding relation between the operating speed and the current value of the servo motor; determining a first current value according to the corresponding relation and the target running speed; performing PID algorithm processing in a speed loop of the servo motor based on the target running speed to obtain a second current value; and determining the preset current value according to the first current value and the second current value.
Further, determining the target operating speed based on the target position data information in conjunction with the PID algorithm comprises: carrying out differential processing on the target position data information to obtain a first running speed; performing PID algorithm processing in a position loop of the servo motor based on the target position data information to obtain a second running speed; and determining the target operation speed according to the first operation speed and the second operation speed.
Further, the method is applied to a motor driving system, wherein the motor driving system at least comprises a motor driving module, the motor driving module at least comprises an encoder, and acquiring the target position data information comprises: and acquiring target position data information of the servo motor through the encoder.
Further, the method is applied to a motor driving system, wherein the motor driving system at least comprises a main control module, the main control module at least comprises a main control chip, and determining the target ambient temperature value according to the current ambient temperature value of the servo motor comprises: acquiring the current ambient temperature of the servo motor through the main control chip; and calculating the current environment temperature by combining a temperature compensation algorithm to obtain the target environment temperature value.
Further, the driving the servo motor based on the target current value in combination with a PID algorithm includes: based on the target current value, carrying out PID algorithm processing in a current loop of the servo motor, and adjusting the duty ratio of a driving signal of the servo motor; and driving the servo motor according to the adjusted duty ratio of the driving signal of the servo motor.
In order to achieve the above object, according to another aspect of the present application, there is provided a driving apparatus of a servo motor. The device comprises: the first determining unit is used for determining a target environment temperature value according to the current environment temperature value of the servo motor; the second determining unit is used for determining a preset current value according to a target running speed of the servo motor, wherein the target running speed is a running speed configured for the servo motor in advance; a third determining unit, configured to determine a target current value according to the target ambient temperature value and the preset current value; and the first driving unit is used for driving the servo motor by combining a PID algorithm based on the target current value.
Further, the second determination unit includes: the servo motor position acquisition device comprises a first acquisition module, a second acquisition module and a control module, wherein the first acquisition module is used for acquiring target position data information, and the target position data information is used for representing the current position information of the servo motor; the first determining module is used for determining the target running speed based on the target position data information by combining the PID algorithm; and the second determining module is used for determining the preset current value based on the target running speed by combining the PID algorithm.
Further, the second determining module includes: the first setting submodule is used for setting the corresponding relation between the operating speed of the servo motor and the current value; the first determining submodule is used for determining a first current value according to the corresponding relation and the target running speed; the first processing submodule is used for carrying out PID algorithm processing in a speed ring of the servo motor based on the target running speed to obtain a second current value; and the second determining submodule is used for determining the preset current value according to the first current value and the second current value.
Further, the first determining module comprises: the second processing submodule is used for carrying out differential processing on the target position data information to obtain a first running speed; the third processing submodule is used for carrying out PID algorithm processing in the position ring of the servo motor based on the target position data information to obtain a second running speed; and the third determining submodule is used for determining the target running speed according to the first running speed and the second running speed.
Further, the apparatus is applied to a motor driving system, wherein the motor driving system at least includes a motor driving module, the motor driving module at least includes an encoder, and the first obtaining module includes: and the first acquisition submodule is used for acquiring the target position data information of the servo motor through the encoder.
Further, the apparatus is applied to a motor driving system, wherein the motor driving system at least includes a main control module, the main control module at least includes a main control chip, and the first determining unit includes: the first acquisition module is used for acquiring the current environment temperature of the servo motor through the main control chip; and the first calculation module is used for calculating the current environment temperature by combining a temperature compensation algorithm to obtain the target environment temperature value.
Further, the first driving unit includes: the first processing module is used for carrying out PID algorithm processing in a current loop of the servo motor based on the target current value and adjusting the duty ratio of a driving signal of the servo motor; and the first driving module is used for driving the servo motor according to the adjusted duty ratio of the driving signal of the servo motor.
In order to achieve the above object, according to another aspect of the present application, there is provided a computer-readable storage medium storing a program, wherein the program executes the driving method of the servo motor according to any one of the above.
In order to achieve the above object, according to another aspect of the present application, there is provided a processor for executing a program, wherein the program is executed to execute the driving method of the servo motor according to any one of the above.
By the application, the following steps are adopted: determining a target environment temperature value according to the current environment temperature value of the servo motor; determining a preset current value according to a target running speed of the servo motor, wherein the target running speed is a running speed configured for the servo motor in advance; determining a target current value according to the target environment temperature value and a preset current value; based on the target current value, the servo motor is driven by combining a PID algorithm, and the problem that stable operation of the servo motor is difficult to guarantee in the related art when the servo motor is driven at the moment of starting the motor and in a high-temperature and low-temperature environment is solved. The target current value is determined according to the target environment temperature value determined according to the current environment temperature value where the servo motor is located and the preset current value determined according to the target running speed of the servo motor, and the servo motor is driven by combining a PID algorithm based on the target current value, so that the effect of ensuring stable running of the servo motor is achieved when the servo motor is driven at the moment of starting the motor and in a high-low temperature environment.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this application, illustrate embodiments of the application and, together with the description, serve to explain the application and are not intended to limit the application. In the drawings:
fig. 1 is a flowchart of a driving method of a servo motor according to an embodiment of the present application;
FIG. 2 is a block diagram of a motor drive system provided in accordance with an embodiment of the present application;
FIG. 3 is a block diagram of a power module in an embodiment of the present application;
FIG. 4 is a flow chart of an alternative servo motor driving method provided in accordance with an embodiment of the present application;
fig. 5 is a schematic diagram of a driving device of a servo motor provided according to an embodiment of the present application.
Detailed Description
It should be noted that, in the present application, the embodiments and features of the embodiments may be combined with each other without conflict. The present application will be described in detail below with reference to the embodiments with reference to the attached drawings.
In order to make the technical solutions of the present application better understood by those skilled in the art, 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 only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, other embodiments that can be obtained by a person skilled in the art without inventive efforts shall fall within the scope of protection of the present application.
It should be noted that the terms "first," "second," and the like in the description and claims of this application and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It should be understood that the data so used may be interchanged under appropriate circumstances such that embodiments of the application described herein may be used. Moreover, the terms "comprises," "comprising," and "includes" and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements explicitly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
The present invention is described below with reference to preferred implementation steps, and fig. 1 is a flowchart of a driving method of a servo motor according to an embodiment of the present application, as shown in fig. 1, the method includes the following steps:
step S101, determining a target environment temperature value according to the current environment temperature value of the servo motor.
For example, a current ambient temperature value at which the servo motor to be driven is located is determined, and an ambient temperature value (the above-mentioned target ambient temperature value) that is finally required to be used in the motor driving process is calculated according to the current ambient temperature value.
Step S102, a preset current value is determined according to a target running speed of the servo motor, wherein the target running speed is a running speed configured for the servo motor in advance.
For example, an operation speed (the target operation speed) required by the servo motor when the servo motor is driven is set, and a current value (the preset current value) is determined according to the operation speed required by the servo motor when the servo motor is driven and a preset current algorithm.
Step S103, determining a target current value according to the target environment temperature value and a preset current value.
For example, a final current value (the above-described target current value) is calculated based on the calculated ambient temperature value to be used during the motor driving and the determined current value.
And step S104, driving the servo motor by combining a PID algorithm based on the target current value.
For example, the servo motor is closed-loop controlled according to the calculated final current value and a PID driving algorithm to drive the servo motor. Moreover, PID is: abbreviations for proportionality, integral, differential. The PID control algorithm is a control algorithm which combines three links of proportion, integration and differentiation.
Through the steps S101 to S104, the target current value is determined according to the target ambient temperature value determined according to the current ambient temperature value at which the servo motor is located and the preset current value determined according to the target operating speed of the servo motor, and the servo motor is driven based on the target current value and in combination with the PID algorithm, so that the effect of ensuring stable operation of the servo motor is achieved at the moment of starting the motor and when the servo motor is driven in a high-temperature and low-temperature environment.
In order to accurately obtain the target position data information, in the driving method of the servo motor provided in the embodiment of the present application, the target position data information may be obtained by the following steps: the driving method of the servo motor provided by the embodiment of the application is applied to a motor driving system, wherein the motor driving system at least comprises a motor driving module, the motor driving module at least comprises an encoder, and target position data information of the servo motor is acquired through the encoder.
For example, fig. 2 is a frame diagram of a motor driving system provided according to an embodiment of the present disclosure, and as shown in fig. 2, a servo controller (motor driving system) is composed of a main control module, a power management module, an interface circuit module and a motor driving module, and a control circuit module includes a memory chip, a main control chip and peripheral circuits thereof. The power management module comprises a power isolation module, a linear voltage stabilizing module and a reverse connection overcurrent protection module. The interface circuit module comprises communication interface circuits such as a driving interface and the like, and the communication interfaces are all designed in an electric isolation mode. The motor driving module comprises a driving control chip, a driving circuit, a voltage and current protection circuit and the like.
For example, the servo controller has a high requirement on the power management module, and it not only needs to convert the external power supply voltage into a special voltage used inside the control circuit, but also needs to monitor the voltage and current of the driving part in real time. Fig. 3 is a frame diagram of a power module in an embodiment of the present application, and as shown in fig. 3, the power management module further integrates a voltage reduction and stabilization function, a reverse connection protection function, and an overvoltage and overcurrent alarm function. In addition, the servo controller carries out isolation filtering on the power supply of the board card, so that the electromagnetic compatibility of the single board is ensured, and the interference of weak and small signals by large-current driving signals is prevented.
In order to ensure the use requirement of the system and the subsequent function requirement which can be expanded, the servo controller reserves abundant external interfaces during design. And considering the requirement of electromagnetic compatibility, the interface with higher communication speed adopts an electric isolation form, so that the interference caused by other peripheral equipment of the system or large driving current is avoided.
In addition, when the circuit layout is designed, the electromagnetic compatibility and the heat dissipation of the board card are fully considered in the design, and the PCB board card is laid out reasonably through the installation and routing. The power device and the digital signal device are separated and distributed, small signal wiring is protected and processed in a ground covering mode, copper is paved on multiple points in a large area, and power signals are electrically isolated.
The motor drive includes a drive circuit, a current sampling circuit, and an encoder sampling circuit. And the position information of the servo motor can be acquired by utilizing an encoder sampling circuit.
By the scheme, the position information of the servo motor can be quickly and accurately obtained by utilizing the encoder in the hardware system.
In order to accurately obtain a target ambient temperature value, in the driving method of the servo motor provided in the embodiment of the present application, the target ambient temperature value may also be obtained through the following steps: the driving method of the servo motor provided by the embodiment of the application is applied to a motor driving system, wherein the motor driving system at least comprises a main control module, the main control module at least comprises a main control chip, and the main control chip is used for acquiring the current ambient temperature of the servo motor; and calculating the current environment temperature by combining a temperature compensation algorithm to obtain a target environment temperature value.
For example, the servo controller can receive the central control instruction, and complete the execution work of the central control instruction by combining sensor data such as an encoder and a gyroscope, and the control platform can meet the use requirements of different states such as guidance, positioning, tracking and stability.
For example, a temperature sensor in the main control chip may be used to acquire the current ambient temperature of the servo motor, and then the acquired current temperature and a temperature compensation algorithm are used to perform calculation to obtain a target ambient temperature value.
By the scheme, the ambient temperature value of the servo motor can be quickly and accurately obtained by using the main control chip and the temperature compensation algorithm in the hardware system.
In order to accurately determine the preset current value, in the driving method of the servo motor provided in the embodiment of the present application, the preset current value may also be determined through the following steps: acquiring target position data information, wherein the target position data information is used for representing the current position information of a servo motor; determining a target running speed based on target position data information and in combination with a PID algorithm; and determining a preset current value based on the target running speed by combining a PID algorithm.
For example, the position information of the servo motor is acquired by using an encoder, then the running speed required by the motor when the motor is driven is calculated according to the acquired position information of the servo motor and a motor drive PID algorithm, and then the preset current value is calculated according to the calculated running speed and the motor drive PID algorithm.
In summary, the preset current value can be conveniently calculated according to the position information of the servo motor, the motor driving PID algorithm and the running speed required by the motor when the motor is driven.
In order to accurately determine the target operating speed, in the driving method of the servo motor provided in the embodiment of the present application, the target operating speed may also be determined through the following steps: carrying out differential processing on the target position data information to obtain a first running speed; performing PID algorithm processing in a position loop of the servo motor based on the target position data information to obtain a second running speed; and determining a target operation speed according to the first operation speed and the second operation speed.
For example, differential calculation is performed on the position information of the servo motor acquired by the encoder, PID algorithm processing is performed in the position loop of the servo motor based on the position information of the servo motor acquired by the encoder, and the operating speed required by the motor when the motor is driven is calculated.
In summary, according to the position information of the servo motor and the motor driving PID algorithm, the required operating speed of the motor can be conveniently calculated when the motor is driven.
In order to accurately determine the preset current value, in the driving method of the servo motor provided in the embodiment of the present application, the preset current value may also be determined through the following steps: setting a corresponding relation between the operating speed of the servo motor and the current value; determining a first current value according to the corresponding relation and the target running speed; performing PID algorithm processing in a speed loop of the servo motor based on the target running speed to obtain a second current value; and determining a preset current value according to the first current value and the second current value.
For example, a correspondence relationship between the operation speed of the servo motor and the current value is set in advance, and a current value is obtained according to the correspondence relationship, a preset current algorithm, and the operation speed required by the motor when the motor is driven. And performing PID algorithm processing in a speed loop of the servo motor based on the running speed required by the motor when the motor is driven, obtaining a current value, and finally determining a preset current value according to the two current values.
Through the scheme, the preset current value can be conveniently determined according to the preset corresponding relation between the operating speed and the current value of the servo motor, the operating speed required by the motor when the motor is driven and the motor drive PID algorithm.
In order to conveniently drive the servo motor, in the driving method of the servo motor provided in the embodiment of the present application, the servo motor may be further driven through the following steps: based on the target current value, carrying out PID algorithm processing in a current loop of the servo motor, and adjusting the duty ratio of a driving signal of the servo motor; and driving the servo motor according to the adjusted duty ratio of the driving signal of the servo motor.
For example, based on the finally obtained current value, the current loop of the servo motor is processed by a PID algorithm, the duty ratio of PWM of the servo motor is adjusted, and then the three-loop closed-loop control of the motor is realized according to the adjusted duty ratio of the PWM so as to drive the servo motor.
Through the scheme, the servo motor can be conveniently driven according to the finally obtained current value and the PID algorithm.
For example, fig. 4 is a flowchart of an alternative driving method of a servo motor according to an embodiment of the present application, and as shown in fig. 4, a temperature sensor is used to acquire an ambient temperature during driving, and a driving current is dynamically adjusted according to a motor parameter. Meanwhile, the rotation speed of the motor is calculated through motor encoder data acquired through differentiation. And a preset current is adopted in a known speed interval to finish the stable transition of the step resistance. Therefore, the change of the motor and the transmission mechanism caused by the influence of high and low temperatures is fully considered, and the known step resistance is preprocessed, so that the stable running of the motor in the full-temperature and full-speed process can be ensured. That is, the motor is driven by dynamically using the adjusting motor through temperature and speed feedback, so that the motor can be stably controlled in the full temperature range and the full speed range, and the temperature adaptability and the environmental adaptability of the rotary table are improved.
In summary, in the driving method of the servo motor provided in the embodiment of the present application, the target ambient temperature value is determined according to the current ambient temperature value at which the servo motor is located; determining a preset current value according to a target running speed of the servo motor, wherein the target running speed is a running speed configured for the servo motor in advance; determining a target current value according to the target environment temperature value and a preset current value; based on the target current value, the servo motor is driven by combining a PID algorithm, and the problem that stable operation of the servo motor is difficult to guarantee in the related art when the servo motor is driven at the moment of starting the motor and in a high-temperature and low-temperature environment is solved. The target current value is determined according to the target environment temperature value determined according to the current environment temperature value of the servo motor and the preset current value determined according to the target running speed of the servo motor, and the servo motor is driven by combining a PID algorithm based on the target current value, so that the effect of ensuring the stable running of the servo motor is achieved when the servo motor is driven at the moment of starting the motor and in a high-temperature and low-temperature environment.
It should be noted that the steps illustrated in the flowcharts of the figures may be performed in a computer system such as a set of computer-executable instructions and that, although a logical order is illustrated in the flowcharts, in some cases, the steps illustrated or described may be performed in an order different than presented herein.
The embodiment of the present application further provides a driving apparatus of a servo motor, and it should be noted that the driving apparatus of the servo motor according to the embodiment of the present application may be used to execute the driving method for the servo motor according to the embodiment of the present application. The following describes a drive device for a servo motor according to an embodiment of the present application.
Fig. 5 is a schematic diagram of a driving apparatus of a servo motor according to an embodiment of the present application. As shown in fig. 5, the apparatus includes: a first determination unit 501, a second determination unit 502, a third determination unit 503, and a first driving unit 504.
Specifically, the first determining unit 501 is configured to determine a target ambient temperature value according to a current ambient temperature value at which the servo motor is located;
a second determining unit 502, configured to determine a preset current value according to a target operating speed of the servo motor, where the target operating speed is an operating speed configured for the servo motor in advance;
a third determining unit 503, configured to determine a target current value according to the target ambient temperature value and the preset current value;
and a first driving unit 504, configured to drive the servo motor based on the target current value in combination with a PID algorithm.
In summary, in the driving apparatus of the servo motor provided in the embodiment of the present application, the first determining unit 501 determines the target ambient temperature value according to the current ambient temperature value of the servo motor; the second determining unit 502 determines a preset current value according to a target operating speed of the servo motor, wherein the target operating speed is an operating speed configured for the servo motor in advance; the third determining unit 503 determines a target current value according to the target ambient temperature value and the preset current value; the first driving unit 504 drives the servo motor based on the target current value in combination with a PID algorithm, thereby solving the problem in the related art that it is difficult to ensure stable operation of the servo motor at the instant of motor start and when the servo motor is driven in a high-temperature and low-temperature environment. The target current value is determined according to the target environment temperature value determined according to the current environment temperature value of the servo motor and the preset current value determined according to the target running speed of the servo motor, and the servo motor is driven by combining a PID algorithm based on the target current value, so that the effect of ensuring the stable running of the servo motor is achieved when the servo motor is driven at the moment of starting the motor and in a high-temperature and low-temperature environment.
Optionally, in the driving apparatus for a servo motor provided in an embodiment of the present application, the second determining unit includes: the servo motor control system comprises a first acquisition module, a second acquisition module and a control module, wherein the first acquisition module is used for acquiring target position data information, and the target position data information is used for representing the current position information of a servo motor; the first determining module is used for determining the target running speed based on the target position data information by combining a PID algorithm; and the second determination module is used for determining the preset current value based on the target running speed by combining a PID algorithm.
Optionally, in the driving apparatus for a servo motor provided in an embodiment of the present application, the second determining module includes: the first setting submodule is used for setting the corresponding relation between the operating speed of the servo motor and the current value; the first determining submodule is used for determining a first current value according to the corresponding relation and the target running speed; the first processing submodule is used for carrying out PID algorithm processing in a speed ring of the servo motor based on the target running speed to obtain a second current value; and the second determining submodule is used for determining the preset current value according to the first current value and the second current value.
Optionally, in the driving apparatus for a servo motor provided in an embodiment of the present application, the first determining module includes: the second processing submodule is used for carrying out differential processing on the target position data information to obtain a first running speed; the third processing submodule is used for carrying out PID algorithm processing in a position ring of the servo motor based on the target position data information to obtain a second running speed; and the third determining submodule is used for determining the target operation speed according to the first operation speed and the second operation speed.
Optionally, in a driving apparatus of a servo motor provided in an embodiment of the present application, the apparatus is applied to a motor driving system, where the motor driving system at least includes a motor driving module, the motor driving module at least includes an encoder, and the first obtaining module includes: and the first acquisition submodule is used for acquiring the target position data information of the servo motor through the encoder.
Optionally, in the driving apparatus for a servo motor provided in an embodiment of the present application, the apparatus is applied to a motor driving system, where the motor driving system at least includes a main control module, the main control module at least includes a main control chip, and the first determining unit includes: the first acquisition module is used for acquiring the current environment temperature of the servo motor through the main control chip; and the first calculation module is used for calculating the current environment temperature by combining a temperature compensation algorithm to obtain a target environment temperature value.
Optionally, in the drive device for a servo motor provided in an embodiment of the present application, the first drive unit includes: the first processing module is used for carrying out PID algorithm processing in a current loop of the servo motor based on a target current value and adjusting the duty ratio of a driving signal of the servo motor; and the first driving module is used for driving the servo motor according to the adjusted duty ratio of the driving signal of the servo motor.
The driving device of the servo motor comprises a processor and a memory, wherein the first determining unit 501, the second determining unit 502, the third determining unit 503, the first driving unit 504 and the like are stored in the memory as program units, and the processor executes the program units stored in the memory to realize corresponding functions.
The processor comprises a kernel, and the kernel calls the corresponding program unit from the memory. The kernel can be set to one or more than one, and the effect of ensuring stable operation of the servo motor is realized by adjusting the kernel parameters when the motor is started instantly and the servo motor is driven in a high-temperature and low-temperature environment.
The memory may include volatile memory in a computer readable medium, random Access Memory (RAM) and/or nonvolatile memory such as Read Only Memory (ROM) or flash memory (flash RAM), and the memory includes at least one memory chip.
An embodiment of the present invention provides a computer-readable storage medium, on which a program is stored, and the program, when executed by a processor, implements a driving method of the servo motor.
The embodiment of the invention provides a processor, which is used for running a program, wherein the program executes a driving method of a servo motor when running.
The embodiment of the invention provides electronic equipment, which comprises a processor, a memory and a program which is stored on the memory and can run on the processor, wherein the processor executes the program and realizes the following steps: determining a target environment temperature value according to the current environment temperature value of the servo motor; determining a preset current value according to a target running speed of the servo motor, wherein the target running speed is a running speed configured for the servo motor in advance; determining a target current value according to the target environment temperature value and the preset current value; and driving the servo motor by combining a PID algorithm based on the target current value.
The processor executes the program and further realizes the following steps: determining a preset current value according to the target operating speed of the servo motor comprises: acquiring target position data information, wherein the target position data information is used for representing the current position information of the servo motor; determining the target running speed based on the target position data information and in combination with the PID algorithm; and determining the preset current value based on the target running speed by combining the PID algorithm.
The processor executes the program and further realizes the following steps: determining the preset current value based on the target operating speed in combination with the PID algorithm comprises: setting a corresponding relation between the operating speed of the servo motor and a current value; determining a first current value according to the corresponding relation and the target running speed; performing PID algorithm processing in a speed loop of the servo motor based on the target running speed to obtain a second current value; and determining the preset current value according to the first current value and the second current value.
The processor executes the program and further realizes the following steps: determining the target operating speed based on the target position data information in combination with the PID algorithm comprises: carrying out differential processing on the target position data information to obtain a first running speed; performing PID algorithm processing in a position loop of the servo motor based on the target position data information to obtain a second running speed; and determining the target operation speed according to the first operation speed and the second operation speed.
The processor executes the program and further realizes the following steps: the method is applied to a motor driving system, wherein the motor driving system at least comprises a motor driving module, the motor driving module at least comprises an encoder, and the step of acquiring the target position data information comprises the following steps: and acquiring target position data information of the servo motor through the encoder.
The processor executes the program and further realizes the following steps: the method is applied to a motor driving system, wherein the motor driving system at least comprises a main control module, the main control module at least comprises a main control chip, and the step of determining the target environment temperature value according to the current environment temperature value of the servo motor comprises the following steps: acquiring the current ambient temperature of the servo motor through the main control chip; and calculating the current environment temperature by combining a temperature compensation algorithm to obtain the target environment temperature value.
The processor executes the program and further realizes the following steps: based on the target current value, the driving of the servo motor by combining a PID algorithm comprises the following steps: based on the target current value, carrying out PID algorithm processing in a current loop of the servo motor, and adjusting the duty ratio of a driving signal of the servo motor; and driving the servo motor according to the adjusted duty ratio of the driving signal of the servo motor.
The device herein may be a server, a PC, a PAD, a mobile phone, etc.
The present application further provides a computer program product adapted to perform a program for initializing the presence of the following method steps when executed on a data processing device: determining a target environment temperature value according to the current environment temperature value of the servo motor; determining a preset current value according to a target running speed of the servo motor, wherein the target running speed is a running speed configured for the servo motor in advance; determining a target current value according to the target environment temperature value and the preset current value; and driving the servo motor by combining a PID algorithm based on the target current value.
When executed on a data processing device, is further adapted to perform a procedure for initializing the following method steps: determining a preset current value according to the target operating speed of the servo motor comprises: acquiring target position data information, wherein the target position data information is used for representing the current position information of the servo motor; determining the target running speed based on the target position data information and in combination with the PID algorithm; and determining the preset current value based on the target running speed by combining the PID algorithm.
When executed on a data processing device, is further adapted to perform a procedure for initializing the following method steps: determining the preset current value based on the target operating speed in combination with the PID algorithm comprises: setting a corresponding relation between the operating speed of the servo motor and a current value; determining a first current value according to the corresponding relation and the target running speed; performing PID algorithm processing in a speed loop of the servo motor based on the target running speed to obtain a second current value; and determining the preset current value according to the first current value and the second current value.
When executed on a data processing device, is further adapted to perform a procedure for initializing the following method steps: determining the target operating speed based on the target position data information in combination with the PID algorithm comprises: carrying out differential processing on the target position data information to obtain a first running speed; performing PID algorithm processing in a position loop of the servo motor based on the target position data information to obtain a second running speed; and determining the target operation speed according to the first operation speed and the second operation speed.
When executed on a data processing device, is further adapted to perform a procedure for initializing the following method steps: the method is applied to a motor driving system, wherein the motor driving system at least comprises a motor driving module, the motor driving module at least comprises an encoder, and the step of acquiring the target position data information comprises the following steps: and acquiring target position data information of the servo motor through the encoder.
When executed on a data processing device, is further adapted to perform a procedure for initializing the following method steps: the method is applied to a motor driving system, wherein the motor driving system at least comprises a main control module, the main control module at least comprises a main control chip, and the step of determining the target environment temperature value according to the current environment temperature value of the servo motor comprises the following steps: acquiring the current ambient temperature of the servo motor through the main control chip; and calculating the current environment temperature by combining a temperature compensation algorithm to obtain the target environment temperature value.
When executed on a data processing device, is further adapted to perform a procedure for initializing the following method steps: based on the target current value, the driving of the servo motor by combining a PID algorithm comprises the following steps: based on the target current value, carrying out PID algorithm processing in a current loop of the servo motor, and adjusting the duty ratio of a driving signal of the servo motor; and driving the servo motor according to the adjusted duty ratio of the driving signal of the servo motor.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). The memory is an example of a computer-readable medium.
Computer-readable media, including both permanent and non-permanent, removable and non-removable media, may implement the information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static Random Access Memory (SRAM), dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), read Only Memory (ROM), electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device. As defined herein, a computer readable medium does not include a transitory computer readable medium such as a modulated data signal and a carrier wave.
It is also noted that 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 a … …" does not exclude the presence of another identical element in a process, method, article, or apparatus that comprises the element.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.
The above are merely examples of the present application and are not intended to limit the present application. Various modifications and changes may occur to those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the scope of the claims of the present application.

Claims (10)

1. A method of driving a servo motor, comprising:
determining a target environment temperature value according to the current environment temperature value of the servo motor;
determining a preset current value according to a target running speed of the servo motor, wherein the target running speed is a running speed configured for the servo motor in advance;
determining a target current value according to the target environment temperature value and the preset current value;
and driving the servo motor by combining a PID algorithm based on the target current value.
2. The method of claim 1, wherein determining a preset current value as a function of a target operating speed of the servo motor comprises:
acquiring target position data information, wherein the target position data information is used for representing the current position information of the servo motor;
determining the target running speed based on the target position data information and in combination with the PID algorithm; and determining the preset current value based on the target running speed by combining the PID algorithm.
3. The method of claim 2, wherein determining the preset current value based on the target operating speed in conjunction with the PID algorithm comprises:
setting a corresponding relation between the operating speed of the servo motor and a current value;
determining a first current value according to the corresponding relation and the target running speed;
performing PID algorithm processing in a speed loop of the servo motor based on the target running speed to obtain a second current value;
and determining the preset current value according to the first current value and the second current value.
4. The method of claim 2, wherein determining the target operating speed based on the target position data information in conjunction with the PID algorithm comprises:
carrying out differential processing on the target position data information to obtain a first running speed;
performing PID algorithm processing in a position loop of the servo motor based on the target position data information to obtain a second running speed;
and determining the target operation speed according to the first operation speed and the second operation speed.
5. The method of claim 2, wherein the method is applied to a motor driving system, wherein the motor driving system at least comprises a motor driving module, the motor driving module at least comprises an encoder, and the obtaining of the target position data information comprises:
and acquiring target position data information of the servo motor through the encoder.
6. The method of claim 1, wherein the method is applied to a motor driving system, wherein the motor driving system at least includes a main control module, the main control module at least includes a main control chip, and determining the target ambient temperature value according to the current ambient temperature value of the servo motor comprises:
acquiring the current environment temperature of the servo motor through the main control chip;
and calculating the current environment temperature by combining a temperature compensation algorithm to obtain the target environment temperature value.
7. The method of claim 1, wherein driving the servo motor in conjunction with a PID algorithm based on the target current value comprises:
based on the target current value, carrying out PID algorithm processing in a current loop of the servo motor, and adjusting the duty ratio of a driving signal of the servo motor;
and driving the servo motor according to the adjusted duty ratio of the driving signal of the servo motor.
8. A drive device of a servo motor, comprising:
the first determining unit is used for determining a target environment temperature value according to the current environment temperature value of the servo motor;
the second determining unit is used for determining a preset current value according to a target running speed of the servo motor, wherein the target running speed is a running speed configured for the servo motor in advance;
a third determining unit, configured to determine a target current value according to the target ambient temperature value and the preset current value;
and the first driving unit is used for driving the servo motor by combining a PID algorithm based on the target current value.
9. A computer-readable storage medium characterized in that the storage medium stores a program, wherein the program executes the driving method of a servo motor according to any one of claims 1 to 7.
10. A processor, characterized in that the processor is configured to execute a program, wherein the program executes the method for driving a servo motor according to any one of claims 1 to 7.
CN202210963770.0A 2022-08-11 2022-08-11 Driving method and device of servo motor, storage medium and processor Pending CN115242130A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210963770.0A CN115242130A (en) 2022-08-11 2022-08-11 Driving method and device of servo motor, storage medium and processor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210963770.0A CN115242130A (en) 2022-08-11 2022-08-11 Driving method and device of servo motor, storage medium and processor

Publications (1)

Publication Number Publication Date
CN115242130A true CN115242130A (en) 2022-10-25

Family

ID=83678549

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210963770.0A Pending CN115242130A (en) 2022-08-11 2022-08-11 Driving method and device of servo motor, storage medium and processor

Country Status (1)

Country Link
CN (1) CN115242130A (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102624315A (en) * 2012-04-11 2012-08-01 上海三一精机有限公司 High-precision permanent magnetic servo motor three-closed-loop control system and method
CN106330040A (en) * 2016-11-05 2017-01-11 杭州畅动智能科技有限公司 Control method and system of servo motor
CN108155834A (en) * 2016-12-06 2018-06-12 美蓓亚三美株式会社 The control method of motor drive control device and motor drive control device
US20190160659A1 (en) * 2017-11-27 2019-05-30 Ubtech Robotics Corp Servo driving method, apparatus, and robot thereof
CN113983660A (en) * 2021-10-20 2022-01-28 北京小米移动软件有限公司 Outdoor environment temperature detection method and device and air exchange equipment

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102624315A (en) * 2012-04-11 2012-08-01 上海三一精机有限公司 High-precision permanent magnetic servo motor three-closed-loop control system and method
CN106330040A (en) * 2016-11-05 2017-01-11 杭州畅动智能科技有限公司 Control method and system of servo motor
CN108155834A (en) * 2016-12-06 2018-06-12 美蓓亚三美株式会社 The control method of motor drive control device and motor drive control device
US20190160659A1 (en) * 2017-11-27 2019-05-30 Ubtech Robotics Corp Servo driving method, apparatus, and robot thereof
CN113983660A (en) * 2021-10-20 2022-01-28 北京小米移动软件有限公司 Outdoor environment temperature detection method and device and air exchange equipment

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
汪明添主编: "西门子PLC原理与编程", 31 August 2020, 北京航空航天大学出版社, pages: 221 *
聂振华,岳秋琴主编: "数控机床故障诊断与维修", 31 January 2019, 西南交通大学出版社, pages: 138 - 142 *
计时鸣主编: "机电一体化控制技术与***", 30 June 2009, 西安电子科技大学出版社, pages: 299 - 301 *

Similar Documents

Publication Publication Date Title
CN103644136B (en) A kind of fan control system, system administration manager and fan
CN114415454B (en) Projection device heat dissipation control method and device, projection device and storage medium
CN111158447A (en) Server heat dissipation parameter regulation and control method, device, equipment and readable storage medium
CN111350686B (en) Control method and control device
CN105673540A (en) Rotating speed adjustment method and device for fan and rotating speed adjustment system for fan
CN103187909A (en) Motor control unit and electric pump unit
CN110647224A (en) Method and device for controlling running state
CN109039160B (en) Compressor starting method and device and storage medium
CN115242130A (en) Driving method and device of servo motor, storage medium and processor
CN114877582A (en) Temperature control method, device and system based on air cooling
CN109696825B (en) Control response method and device of steering engine and steering engine
CN113672065B (en) Method and device for regulating speed of fan and storage medium
CN115031018B (en) Method, device, processor and tractor for adjusting transmission ratio of gearbox
CN110566492A (en) fan speed regulation method, device, equipment and medium
CN112025699B (en) Method and device for determining robot operating parameters and control system of robot
CN104883105A (en) Motor rotating speed control method, rotating speed controlling device and motor control system
CN109391200B (en) Synchronous motor parameter self-identification setting method
CN113844268A (en) Method and device for determining the operating speed of a cooling device of an electric vehicle
CN117411374B (en) Motor control method, system, device and electronic equipment
CN112268010A (en) Fan control method, device and equipment and readable storage medium
Mallick et al. Comparative performance study of lyapunov based MRAC technique and MRAC augmented with PID controller for speed control of a DC motor
CN113568805A (en) Real-time adjustment method and device for power consumption of server and electronic equipment
CN115412380B (en) POE power supply monitoring method, equipment and storage medium of POE switch
CN113452306B (en) Open-loop control method, system, server and storage medium for pulse width modulation motor
US20170237385A1 (en) Systems and methods for implementing multiple motor control modes in a motor drive controller

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