CN114337404B - DC motor control method, air conditioner and computer readable storage medium - Google Patents

DC motor control method, air conditioner and computer readable storage medium Download PDF

Info

Publication number
CN114337404B
CN114337404B CN202111657852.4A CN202111657852A CN114337404B CN 114337404 B CN114337404 B CN 114337404B CN 202111657852 A CN202111657852 A CN 202111657852A CN 114337404 B CN114337404 B CN 114337404B
Authority
CN
China
Prior art keywords
motor
rotating speed
value
speed
time period
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.)
Active
Application number
CN202111657852.4A
Other languages
Chinese (zh)
Other versions
CN114337404A (en
Inventor
王新民
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hisense Guangdong Air Conditioning Co Ltd
Original Assignee
Hisense Guangdong Air Conditioning 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 Hisense Guangdong Air Conditioning Co Ltd filed Critical Hisense Guangdong Air Conditioning Co Ltd
Priority to CN202111657852.4A priority Critical patent/CN114337404B/en
Publication of CN114337404A publication Critical patent/CN114337404A/en
Application granted granted Critical
Publication of CN114337404B publication Critical patent/CN114337404B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Control Of Motors That Do Not Use Commutators (AREA)
  • Control Of Electric Motors In General (AREA)

Abstract

The invention discloses a direct current motor control method, an air conditioner and a computer readable storage medium, wherein the direct current motor control method comprises the following steps: s1, receiving a final target rotating speed value of a motor; s2, obtaining a current target rotating speed value according to a speed curve; s3, obtaining a time period for calculating the motor rotation speed according to the final target rotation speed value and the current target rotation speed value; s4, acquiring a motor feedback pulse count value, and acquiring an average rotating speed value of the motor in a time period for calculating the rotating speed of the motor according to the motor feedback pulse count value; s5, obtaining a speed regulation duty ratio corresponding to the current target rotating speed value according to the current target rotating speed value and the average rotating speed value so as to drive the motor; s6, determining that the motor rotation speed reaches a current target rotation speed value, assigning the current target rotation speed value to the current rotation speed of the motor, and returning to the step S2 until the motor rotation speed reaches a final target rotation speed value. The method can improve the dynamic response capability of the motor and the accuracy and stability of the motor in the speed regulation process.

Description

DC motor control method, air conditioner and computer readable storage medium
Technical Field
The present invention relates to the field of dc motors, and more particularly, to a dc motor control method, an air conditioner, and a computer readable storage medium.
Background
In the related art, for the speed regulation control of a direct current motor, the current rotating speed of the motor is calculated by adopting a fixed time period, the current rotating speed is directly compared with a final target rotating speed value, and the output speed regulation duty ratio is regulated according to the comparison result. However, since the rotation speed is calculated and adjusted by using a fixed time period, the calculated rotation speed is actually an average speed in the fixed time period, and therefore, in the case of high dynamic requirements for acceleration or deceleration, the accuracy of the output rotation speed is affected.
Disclosure of Invention
The present invention aims to solve at least one of the technical problems existing in the prior art. Therefore, an object of the present invention is to provide a method for controlling a dc motor, by which the dynamic response capability of the motor can be improved, and the accuracy and stability of the motor in the speed regulation process can be improved.
Another object of the present invention is to provide an air conditioner.
It is a third object of the present invention to provide a computer-readable storage medium.
In order to solve the above problems, an embodiment of a first aspect of the present invention provides a dc motor control method, including: s1, receiving a final target rotating speed value of a motor; s2, obtaining a current target rotating speed value according to a speed curve; s3, obtaining a time period for calculating the motor rotation speed according to the final target rotation speed value and the current target rotation speed value; s4, acquiring a motor feedback pulse count value, and acquiring an average rotating speed value of the motor in the time period for calculating the rotating speed of the motor according to the motor feedback pulse count value; s5, obtaining a speed regulation duty ratio corresponding to the current target rotating speed value according to the current target rotating speed value and the average rotating speed value so as to drive the motor; s6, determining that the motor rotation speed reaches the current target rotation speed value, assigning the current target rotation speed value to the current rotation speed of the motor, and returning to the step S2 until the motor rotation speed reaches the final target rotation speed value.
According to the direct current motor control method, when the motor is regulated, the time period for calculating the motor speed is obtained by the final target speed value and the current target speed value, namely, the determination of the time period for calculating the motor speed is related to the final target speed value and the current target speed value, the time period for calculating the motor speed is not the only fixed, and further, the average speed value of the motor is calculated by the motor feedback pulse count value in the time period for calculating the motor speed.
In some embodiments, obtaining a time period for calculating motor speed from the final target speed value and the current target speed value includes: calculating a speed difference value between the final target rotating speed of the motor and the current target rotating speed value; and obtaining the time period for calculating the rotating speed of the motor according to the speed difference value.
In some embodiments, obtaining the time period for calculating the motor speed from the speed difference comprises: determining that the speed difference value is smaller than or equal to a preset speed threshold value, wherein the time period for calculating the rotating speed of the motor is a first time period; and if the speed difference value is larger than the preset speed threshold value, the time period for calculating the rotating speed of the motor is a second time period, wherein the second time period is smaller than the first time period.
In some embodiments, obtaining a governor duty cycle corresponding to the current target speed value from the current target speed value and the average speed value includes: obtaining the target regulation parameter according to the time period of calculating the motor rotating speed; and obtaining a speed regulation duty ratio corresponding to the current target rotating speed value according to the current target rotating speed value, the average rotating speed value and the target regulating parameter.
In some embodiments, obtaining the target adjustment parameter from the time period of calculating motor speed comprises: and determining the time period for calculating the rotating speed of the motor as the first time period, and determining the target adjusting parameter as a first adjusting parameter.
In some embodiments, the target adjustment parameter is obtained from the time period of calculating the motor speed, further comprising: and determining that the time period for calculating the motor rotating speed is the second time period, and then determining that the target adjusting parameter is a second adjusting parameter, wherein the second adjusting parameter is different from the first adjusting parameter.
In some embodiments, the target adjustment parameters include a target proportional parameter and a target integral parameter, and obtaining a governor duty cycle corresponding to the current target speed value according to the current target speed value and the average speed value and the target adjustment parameters includes: and performing proportional-integral calculation according to the current target rotating speed value and the average rotating speed value, and the target proportion parameter and the target integral parameter to obtain the speed regulation duty ratio.
In some embodiments, the first time period takes a value of 0.5s to 1s.
An embodiment of a second aspect of the present invention provides an air conditioner, including: at least one processor; a memory communicatively coupled to the at least one processor; wherein the memory stores a computer program executable by the at least one processor, and the at least one processor implements the dc motor control method according to the above embodiment when executing the computer program.
According to the air conditioner provided by the embodiment of the invention, the direct current motor control method provided by the embodiment of the invention is executed by the processor, so that the dynamic response capability of the motor can be improved, and the accuracy and stability of the motor in the speed regulation process can be improved.
An embodiment of a third aspect of the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the dc motor control method described in the above embodiment.
Additional aspects and advantages of the invention will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention.
Drawings
The foregoing and/or additional aspects and advantages of the invention will become apparent and may be better understood from the following description of embodiments taken in conjunction with the accompanying drawings in which:
fig. 1 is a flowchart of a direct current motor control method according to an embodiment of the present invention;
Fig. 2 is a flowchart of a direct current motor control method according to another embodiment of the present invention;
Fig. 3 is a block diagram of an air conditioner according to an embodiment of the present invention.
Reference numerals:
An air conditioner 10;
A processor 1; a memory 2.
Detailed Description
Embodiments of the present invention will be described in detail below, by way of example with reference to the accompanying drawings.
In the related art, for a mode of calculating the feedback rotation speed of the motor by using a fixed speed period, the speed calculation accuracy=60/(a×n), where a is the fixed speed period and N is the number of feedback pulses per rotation of the motor. However, since the motor model is fixed and the feedback pulse number N per revolution is fixed, the speed calculation accuracy is only related to the fixed speed period a, and the larger a, the higher the speed calculation accuracy, but the longer the time for calculating the average rotation speed in the fixed speed period, the more easily the calculated average speed deviates from the current actual rotation speed of the motor, and therefore, the accuracy of the output rotation speed is affected in the case of starting or requiring rapid change of the motor speed. For example, when the motor needs to be accelerated and decelerated frequently, the speed is averaged at the time of acceleration and deceleration, which always results in that the output duty ratio cannot drive the motor to run in a set speed curve well, for example, the motor is required to be decelerated to 500rpm from 500rpm to 1000rpm immediately, the motor always starts to decelerate when the motor is increased to more than 1000rpm, and acceleration is started after the rotational speed is less than 500rpm in the process of decelerating to acceleration.
In order to solve the above problems, an embodiment of a first aspect of the present invention provides a method for controlling a dc motor, by which the dynamic response capability of the motor can be improved, and the accuracy and stability of the motor in the speed regulation process can be improved.
The following describes a dc motor control method according to an embodiment of the present invention with reference to fig. 1, and as shown in fig. 1, the dc motor control method at least includes steps S1 to S6.
Step S1, receiving a final target rotating speed value of the motor.
The final target rotating speed value of the motor is a rotating speed value to which the actual rotating speed of the motor is finally adjusted when the rotating speed of the motor is adjusted.
Specifically, taking an air conditioner as an example, after the air conditioner is powered on and started, the controller of the air conditioner calculates a final target rotating speed value of the motor according to a set temperature, and sends a motor starting command and the final target rotating speed value of the motor to the motor controller.
And S2, obtaining a current target rotating speed value according to the speed curve.
Specifically, in response to a motor start command, the motor controller may generate a speed profile according to the received final target rotational speed value of the motor and the set speed regulation time, and divide the speed profile into a plurality of operation phases according to a certain rule, and an upper limit value of each operation phase is used as a current target rotational speed value of the operation phase. The speed curve may be a diagonal curve or an S curve, which is not limited thereto.
The set speed regulating time can be set according to actual conditions, and it can be understood that the shorter the speed regulating time is under the same target rotating speed, the faster the change rate of the rotating speed of the motor is, and the slower the change rate of the rotating speed of the motor is otherwise.
For example, taking the final target rotation speed value of the motor as 100rpm and the speed regulation time as 1s as an example, the initial rotation speed of the motor at the time of starting is 0rpm, if the speed curve is divided into ten operation stages, the speed curve can be increased by 10rpm every 0.1s, the current target rotation speed value corresponding to each operation stage is respectively: 10rpm, 20rpm, 30rpm, 40rpm, 50rpm, 60rpm, 70rpm, 80rpm, 90rpm, 100rpm.
And step S3, obtaining a time period for calculating the motor rotation speed according to the final target rotation speed value and the current target rotation speed value.
The time period for calculating the motor rotation speed refers to a calculation period of the motor rotation speed.
In the embodiment, when the motor is regulated, the calculated motor speed is actually the average speed in the fixed time period, but for the situation that the dynamic requirements such as motor acceleration or deceleration are higher, the calculated average speed deviates from the current actual speed of the motor due to longer calculation time, and the accuracy of the output speed is affected.
Specifically, the running state of the motor is determined by the final target rotating speed value and the current target rotating speed value, so as to obtain a time period for calculating the rotating speed of the motor, which is more in line with the running state of the motor, for example, when the motor is in a state with higher dynamic requirements such as acceleration or deceleration according to the final target rotating speed value and the current target rotating speed value, the time period for calculating the rotating speed of the motor can be properly reduced, so that the shorter the time for calculating the rotating speed of the average motor is compared with the mode of calculating the rotating speed of the motor by adopting a fixed time period, the closer the calculated average rotating speed value is to the actual rotating speed at the current moment of the motor, the shorter the period for adjusting the rotating speed is, the frequency for subsequently calculating PWM (Pulse width modulation ) is improved, the dynamic response capability of the motor is improved, the accuracy in the motor speed regulation process is improved, and the speed regulation performance is improved; or when the motor is in a stable running state according to the final target rotating speed value and the current target rotating speed value, the rotating speed of the motor only fluctuates in a small range under the condition, so that the time period of the rotating speed of the motor can be properly increased, the calculating precision of the rotating speed of the motor can be improved when the average rotating speed value in the time period of calculating the rotating speed of the motor is calculated, the rotating speed of the motor is better stabilized at a certain rotating speed, the speed fluctuation is reduced, the speed deviation is reduced, and the chip resources of the motor in stable running are saved.
And S4, acquiring a motor feedback pulse count value, and acquiring an average rotating speed value of the motor in a time period for calculating the rotating speed of the motor according to the motor feedback pulse count value.
The feedback pulse count value of the motor can be obtained by calculating an external interrupt in a time period for calculating the rotating speed of the motor, and the external interrupt can be specifically configured to be triggered by a rising and falling edge.
Specifically, the average rotation speed value may be calculated by the following formula.
Wherein,Is the average rotation speed value,/>Feedback pulse count for motor,/>For calculating the time period of the motor speed,/>The number of pulses is fed back for each revolution of the motor. Wherein, the feedback pulse number per turn of the motor is related to the motor model, and after the motor model is fixed, the feedback pulse number per turn of the motor is correspondingly fixed.
And S5, obtaining a speed regulation duty ratio corresponding to the current target rotating speed value according to the current target rotating speed value and the average rotating speed value so as to drive the motor.
Specifically, in the prior art, the final target rotation speed value is directly adopted to be compared with the calculated average rotation speed value so as to adjust the output duty ratio, but the method is easy to cause speed overshoot due to over-high acceleration or to cause the rotation speed of the motor to be delayed and not to reach the final target rotation speed value due to over-low acceleration when the motor is started, and the output duty ratio can certainly fluctuate at a certain value due to the existence of rotation speed calculation errors, so that the best performance can not be realized.
And S6, determining that the rotating speed of the motor reaches a current target rotating speed value, assigning the current target rotating speed value to the current rotating speed of the motor, and returning to the step S2 until the rotating speed of the motor reaches a final target rotating speed value.
According to the direct current motor control method, when the motor is regulated, the time period for calculating the motor speed is obtained by the final target speed value and the current target speed value, namely, the determination of the time period for calculating the motor speed is related to the final target speed value and the current target speed value, the time period for calculating the motor speed is not the only fixed, and further, the average speed value of the motor is calculated by the motor feedback pulse count value in the time period for calculating the motor speed.
In some embodiments, calculating a speed difference between the final target rotational speed of the motor and the current target rotational speed value to determine whether the motor is in a speed regulation state or a steady operation state according to the magnitude of the speed difference, for example, when the speed difference is large, the motor is in an acceleration or deceleration speed regulation state, otherwise, when the speed difference is small, the motor is in a steady operation state; the time period for calculating the motor rotating speed is obtained according to the speed difference value, so that the time period for calculating the motor rotating speed can be properly reduced when the motor is in a speed regulation state, the time for calculating the average rotating speed can be shortened when the average rotating speed value in the time period for calculating the motor rotating speed is calculated, the calculated average rotating speed value is more close to the actual rotating speed of the motor at the current moment, the period for regulating the rotating speed is also shorter, the frequency of the follow-up calculation duty ratio is improved, the dynamic response capability of the motor is improved, the accuracy in the motor speed regulation process is improved, the speed regulation performance is improved, the time period for properly increasing the motor rotating speed when the motor is in a stable running state, the calculation precision of the motor rotating speed can be improved when the average rotating speed value in the time period for calculating the motor rotating speed is calculated, the rotating speed of the motor is better stabilized at a certain rotating speed, the speed fluctuation is reduced, the speed deviation is reduced, and the chip resources during the stable running of the motor are saved.
In some embodiments, if the speed difference is less than or equal to the preset speed threshold, calculating a time period of the motor speed as the first time period; if the speed difference is determined to be greater than the preset speed threshold, calculating the time period of the motor rotating speed as a second time period, wherein the second time period is smaller than the first time period. That is, in the process that the motor is in acceleration or deceleration, the calculation period of the average rotating speed value of the motor is reduced to be a first time period, so that the time interval of the average rotating speed value is shortened, the calculated average rotating speed value is closer to the current actual rotating speed of the motor, the calculation accuracy of the rotating speed of the motor is improved, meanwhile, the adjustment period of the rotating speed of the motor is shortened, the frequency of PWM (pulse width modulation) calculation is improved, the dynamic response capability of the motor is improved, the problem of speed overshoot during acceleration or deceleration of the motor is reduced, and the speed regulation experience of the whole motor is improved.
In some embodiments, the target adjustment parameter is obtained according to a time period for calculating the motor speed, i.e. different target adjustment parameters are corresponding to different time periods for calculating the motor speed; and obtaining the speed regulation duty ratio corresponding to the current target rotating speed value according to the current target rotating speed value, the average rotating speed value and the target regulating parameter. Therefore, the accuracy, the rapidity and the stability of the adjusting link can be improved by replacing the final target rotating speed value with the current target rotating speed value of different operating stages and adopting different target adjusting parameters in different operating stages.
In some embodiments, the time period for calculating the motor speed is determined to be a first time period and the target adjustment parameter is a first adjustment parameter. And determining that the time period for calculating the motor speed is a second time period, and determining that the target adjustment parameter is a second adjustment parameter, wherein the second adjustment parameter is different from the first adjustment parameter. Therefore, when the duty ratio is adjusted, by adopting different adjusting parameters, the problem of speed overshoot during acceleration or deceleration of the motor can be reduced, and the accuracy, the rapidness and the stability of an adjusting link are improved.
In some embodiments, the target adjustment parameters include a target proportional parameter and a target integral parameter, and the proportional integral calculation is performed according to the current target rotation speed value and the average rotation speed value and the target proportional parameter and the target integral parameter to obtain the speed regulation duty cycle. That is, when the duty ratio is adjusted, the PI parameter, namely the target proportion parameter and the target integral parameter, are adopted to calculate, so that the accuracy, the rapidity and the stability of the adjustment link are improved.
In some embodiments, the first time period takes a value of 0.5s to 1s.
The following describes an example of a control method of a dc motor according to an embodiment of the present invention with reference to fig. 2, and the specific steps are as follows.
And S7, powering on the air conditioner.
In step S8, the timer is configured to set the time period for calculating the rotation speed of the motor as the first time period A1 second, and configure the external interrupt as the rising and falling edge trigger.
Step S9, a motor start command and a final target motor rotation speed value spd_ aim are received.
Step S10, generating a current target rotation speed value spd_ref according to the speed curve.
Step S11, judging whether the difference between the final target rotating speed value spd_ aim of the motor and the current target rotating speed value spd_ref is larger than a preset speed threshold value N. If not, executing step S12; if yes, go to step S19.
Step S12, the time period for calculating the motor rotation speed is restored to A1 seconds.
Step S13, a motor feedback pulse count value is obtained, and an average rotating speed value in A1 seconds is calculated.
Step S14, judging whether the timing period reaches A1 seconds. If not, executing step S15; if yes, go to step S16.
Step S15, executing other logic programs, and waiting for the timing period to reach A1 seconds.
Step S16, a motor feedback pulse count value is obtained, and an average rotating speed value spd_ fbk in A1 seconds is calculated.
And S17, performing PI calculation by adopting a second adjustment parameter according to the spd_ref and the spd_ fbk1 to obtain the speed regulation duty ratio.
And S18, outputting high and low levels according to the speed regulation duty ratio, and driving the motor to rotate.
Step S19, the time period for calculating the motor rotation speed is shortened to a second time period A2 seconds.
Step S20, determining whether the timing period reaches A2 seconds. If not, executing step S21; if yes, go to step S22.
Step S21, executing other logic program, waiting for the timing period to reach A1 second.
Step S22, obtaining a motor feedback pulse count value, and calculating an average rotating speed value spd_ fbk2 in A2 seconds.
And S23, performing PI calculation by adopting a first adjustment parameter according to the spd_ref and the spd_ fbk to obtain a speed regulation duty ratio.
And step S24, outputting high and low levels according to the speed regulation duty ratio, and driving the motor to rotate.
In summary, according to the method for controlling the direct current motor according to the embodiment of the invention, when the motor rotation speed starts or requires rapid change, the time period for calculating the motor rotation speed is properly reduced, namely, the second time period is adopted, so that the smaller the time for calculating the average rotation speed value is, the closer the calculated average rotation speed value is to the actual rotation speed at the current moment of the motor, the effect of improving the rotation speed calculation accuracy is achieved, the period for adjusting the rotation speed is shorter, the dynamic response capability of the motor is improved, and the speed regulation performance of the motor is also improved under the conditions of higher rotation speed accuracy and smaller adjustment period; in addition, after the rotating speed of the motor reaches a stable state, the time period for calculating the rotating speed of the motor is recovered from the second time period to the first time period, so that the time for calculating the average rotating speed value is prolonged, and the rotating speed calculation precision is improved. Therefore, by the mode, the tracking performance of the current target rotating speed value and the final target rotating speed value when the rotating speed of the motor changes is effectively improved, the speed accuracy of the motor in a stable state can be considered, and the speed regulation experience of the whole motor is improved.
The second aspect of the present invention provides an air conditioner, as shown in fig. 3, the air conditioner 10 including at least one processor 1 and a memory 2 communicatively connected to the at least one processor 1.
Wherein the memory 2 stores a computer program executable by the at least one processor 1, and the at least one processor 1 implements the dc motor control method provided in the above embodiment when executing the computer program.
It should be noted that, the specific implementation manner of the air conditioner 10 according to the embodiment of the present invention is similar to the specific implementation manner of the dc motor control method according to any of the above embodiments of the present invention, and please refer to the description of the method section specifically, and in order to reduce redundancy, the description is omitted here.
According to the air conditioner 10 of the embodiment of the invention, the processor 1 executes the direct current motor control method provided by the embodiment, so that the dynamic response capability of the motor can be improved, and the accuracy and stability of the motor in the speed regulation process can be improved.
An embodiment of a third aspect of the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the dc motor control method provided by the above embodiment.
In the description of this specification, any process or method description in a flowchart or otherwise described herein may be understood as representing modules, segments, or portions of code which include one or more executable instructions for implementing logical functions or steps of the process, and in which the scope of the preferred embodiments of the present invention include additional implementations in which functions may be executed out of order from that shown or discussed, including substantially concurrently or in reverse order, depending on the functionality involved, as would be understood by those reasonably skilled in the art of the embodiments of the present invention.
Logic and/or steps represented in the flowcharts or otherwise described herein, e.g., a ordered listing of executable instructions for implementing logical functions, can be embodied in any computer-readable medium for use by or in connection with an instruction execution system, apparatus, or device, such as a computer-based system, processor-containing system, or other system that can fetch the instructions from the instruction execution system, apparatus, or device and execute the instructions. For the purposes of this description, a "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transport the program for use by or in connection with the instruction execution system, apparatus, or device. More specific examples (a non-exhaustive list) of the computer-readable medium would include the following: an electrical connection (electronic device) having one or more wires, a portable computer diskette (magnetic device), a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). In addition, the computer readable medium may even be paper or other suitable medium on which the program is printed, as the program may be electronically captured, via, for instance, optical scanning of the paper or other medium, then compiled, interpreted or otherwise processed in a suitable manner, if necessary, and then stored in a computer memory.
It is to be understood that portions of the present invention may be implemented in hardware, software, firmware, or a combination thereof. In the above-described embodiments, the various steps or methods may be implemented in software or firmware stored in a memory and executed by a suitable instruction execution system. As with the other embodiments, if implemented in hardware, may be implemented using any one or combination of the following techniques, as is well known in the art: discrete logic circuits having logic gates for implementing logic functions on data signals, application specific integrated circuits having suitable combinational logic gates, programmable Gate Arrays (PGAs), field Programmable Gate Arrays (FPGAs), and the like.
Those of ordinary skill in the art will appreciate that all or a portion of the steps carried out in the method of the above-described embodiments may be implemented by a program to instruct related hardware, where the program may be stored in a computer readable storage medium, and where the program, when executed, includes one or a combination of the steps of the method embodiments.
In addition, each functional unit in the embodiments of the present invention may be integrated in one processing module, or each unit may exist alone physically, or two or more units may be integrated in one module. The integrated modules may be implemented in hardware or in software functional modules. The integrated modules may also be stored in a computer readable storage medium if implemented in the form of software functional modules and sold or used as a stand-alone product.
The above-mentioned storage medium may be a read-only memory, a magnetic disk or an optical disk, or the like. While embodiments of the present invention have been shown and described above, it will be understood that the above embodiments are illustrative and not to be construed as limiting the invention, and that variations, modifications, alternatives and variations may be made to the above embodiments by one of ordinary skill in the art within the scope of the invention.
In the description of the present specification, reference to the terms "one embodiment," "some embodiments," "illustrative embodiments," "examples," "specific examples," or "some examples," etc., means that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the invention. In this specification, schematic representations of the above terms do not necessarily refer to the same embodiments or examples.
While embodiments of the present invention have been shown and described, it will be understood by those of ordinary skill in the art that: many changes, modifications, substitutions and variations may be made to the embodiments without departing from the spirit and principles of the invention, the scope of which is defined by the claims and their equivalents.

Claims (8)

1.A direct current motor control method, characterized by comprising:
S1, receiving a final target rotating speed value of a motor;
S2, obtaining a current target rotating speed value according to a speed curve;
s3, obtaining a time period for calculating the motor rotation speed according to the final target rotation speed value and the current target rotation speed value;
S4, acquiring a motor feedback pulse count value, and acquiring an average rotating speed value of the motor in the time period for calculating the rotating speed of the motor according to the motor feedback pulse count value;
S5, obtaining a speed regulation duty ratio corresponding to the current target rotating speed value according to the current target rotating speed value and the average rotating speed value so as to drive the motor;
s6, determining that the rotating speed of the motor reaches the current target rotating speed value, assigning the current target rotating speed value to the current rotating speed of the motor, and returning to the step S2 until the rotating speed of the motor reaches the final target rotating speed value;
Wherein obtaining a time period for calculating the motor speed according to the final target speed value and the current target speed value includes:
Calculating a speed difference value between the final target rotating speed of the motor and the current target rotating speed value;
obtaining the time period for calculating the rotating speed of the motor according to the speed difference value;
Wherein obtaining the time period for calculating the motor rotation speed according to the speed difference value comprises:
Determining that the speed difference value is smaller than or equal to a preset speed threshold value, wherein the time period for calculating the rotating speed of the motor is a first time period;
And if the speed difference value is larger than the preset speed threshold value, the time period for calculating the rotating speed of the motor is a second time period, wherein the second time period is smaller than the first time period.
2. The direct current motor control method according to claim 1, wherein obtaining a speed regulation duty ratio corresponding to the current target rotational speed value from the current target rotational speed value and the average rotational speed value, comprises:
Obtaining a target regulation parameter according to the time period for calculating the rotating speed of the motor;
and obtaining a speed regulation duty ratio corresponding to the current target rotating speed value according to the current target rotating speed value, the average rotating speed value and the target regulating parameter.
3. The direct current motor control method according to claim 2, wherein obtaining the target adjustment parameter according to the time period of calculating the motor rotation speed includes:
and determining the time period for calculating the rotating speed of the motor as the first time period, and determining the target adjusting parameter as a first adjusting parameter.
4. The direct current motor control method according to claim 3, wherein the target adjustment parameter is obtained from the time period of calculating the motor rotation speed, further comprising:
and determining that the time period for calculating the motor rotating speed is the second time period, and then determining that the target adjusting parameter is a second adjusting parameter, wherein the second adjusting parameter is different from the first adjusting parameter.
5. The direct current motor control method according to claim 2, wherein the target adjustment parameter includes a target proportion parameter and a target integral parameter, and obtaining a speed-adjusting duty ratio corresponding to the current target rotation speed value from the current target rotation speed value and the average rotation speed value and the target adjustment parameter includes:
And performing proportional-integral calculation according to the current target rotating speed value and the average rotating speed value, and the target proportion parameter and the target integral parameter to obtain the speed regulation duty ratio.
6. The method according to any one of claims 1 to 4, wherein the first time period takes a value of 0.5s to 1s.
7. An air conditioner, comprising:
At least one processor;
A memory communicatively coupled to the at least one processor;
Wherein the memory stores a computer program executable by the at least one processor, the at least one processor implementing the direct current motor control method of any of claims 1-6 when the computer program is executed.
8. A computer-readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the direct current motor control method as claimed in any one of claims 1-6.
CN202111657852.4A 2021-12-30 2021-12-30 DC motor control method, air conditioner and computer readable storage medium Active CN114337404B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111657852.4A CN114337404B (en) 2021-12-30 2021-12-30 DC motor control method, air conditioner and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111657852.4A CN114337404B (en) 2021-12-30 2021-12-30 DC motor control method, air conditioner and computer readable storage medium

Publications (2)

Publication Number Publication Date
CN114337404A CN114337404A (en) 2022-04-12
CN114337404B true CN114337404B (en) 2024-06-18

Family

ID=81019771

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111657852.4A Active CN114337404B (en) 2021-12-30 2021-12-30 DC motor control method, air conditioner and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN114337404B (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101478285A (en) * 2009-01-20 2009-07-08 东元总合科技(杭州)有限公司 Motor speed detection method

Family Cites Families (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0817588B2 (en) * 1988-06-27 1996-02-21 富士電機株式会社 Instantaneous motor speed detection method
JP3859115B2 (en) * 1999-07-26 2006-12-20 セイコーエプソン株式会社 Printer motor control apparatus, control method, and recording medium recording control program
CN101784900B (en) * 2007-09-11 2012-07-18 株式会社安川电机 Velocity detection method and motor control device using the method
JP2009095154A (en) * 2007-10-10 2009-04-30 Yaskawa Electric Corp Motor controller and its speed detection method
CN103308707A (en) * 2013-05-21 2013-09-18 中国科学院自动化研究所 Self-adaptation rotating speed measurement method
CN103995144B (en) * 2014-06-05 2016-05-18 北京航空航天大学 A kind of brshless DC motor high-performance speed-measuring method
CN104569472B (en) * 2015-01-23 2017-11-10 上海大学 A kind of velocity acquiring method based on photoelectric pulse coder
JP6452210B1 (en) * 2017-09-12 2019-01-16 Ckd日機電装株式会社 Speed detection device
CN110843552B (en) * 2019-11-29 2021-05-11 安徽江淮汽车集团股份有限公司 Electric vehicle torque control method, device, equipment and storage medium
CN113804914A (en) * 2021-08-02 2021-12-17 上海联影医疗科技股份有限公司 Motor speed measuring method and device, computer equipment and storage medium

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101478285A (en) * 2009-01-20 2009-07-08 东元总合科技(杭州)有限公司 Motor speed detection method

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于高速脉冲计数器的电机转速测量系统设计;李晓海 等;《微电机》;20120229;第45卷(第2期);第72-74页 *

Also Published As

Publication number Publication date
CN114337404A (en) 2022-04-12

Similar Documents

Publication Publication Date Title
CN109462352B (en) Motor control method, device and computer readable storage medium
CN110086382B (en) Control method of brushless direct current motor, computer device and readable storage medium
US11606050B2 (en) Method and system for controlling electric motor, and controller
US9257928B2 (en) Control device for stepping motor and control method for stepping motor
CN107154758B (en) Motor control device and method for electric tail gate of automobile
CN111342733B (en) Method and device for starting control of variable frequency compressor and computer storage medium
US20180331640A1 (en) Control device, optical device, control method, and storage medium
CN100385369C (en) Apparatus and method for controlling rotation speed of multistage speed and intelligent fan
CN107204726B (en) Control method and system of permanent magnet synchronous motor
CN114337404B (en) DC motor control method, air conditioner and computer readable storage medium
US10498284B2 (en) Motor drive controller and method for controlling motor
JPH11356081A (en) Inverter device
US10396697B2 (en) Motor operating systems and methods thereof
CN116015141A (en) Closed-loop control system and method for position of stepping motor
US10727771B2 (en) Motor control apparatus and method of controlling the same
CN114928272A (en) Frequency converter runaway starting method and frequency converter thereof
JP6056629B2 (en) Motor control device
JP2002247878A (en) Electric motor controlling method
CN111162700B (en) Motor drive control device, electronic apparatus, and motor control method
CN112769369B (en) Acceleration correction method and device and computer readable storage medium
JP7423498B2 (en) Motor control device, motor drive system, hydraulic pressure generator, motor control method, and motor control program
JP2024070048A (en) Motor Control Device
WO2017085853A1 (en) Motor control device and motor control method
WO2024051227A1 (en) Control method and apparatus, and storage medium
JPH10295095A (en) Motor 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
GR01 Patent grant
GR01 Patent grant