CN117674653A - Speed planning fuzzy control method based on arctangent function - Google Patents
Speed planning fuzzy control method based on arctangent function Download PDFInfo
- Publication number
- CN117674653A CN117674653A CN202311715864.7A CN202311715864A CN117674653A CN 117674653 A CN117674653 A CN 117674653A CN 202311715864 A CN202311715864 A CN 202311715864A CN 117674653 A CN117674653 A CN 117674653A
- Authority
- CN
- China
- Prior art keywords
- speed
- error
- control
- running
- value
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 40
- 230000007246 mechanism Effects 0.000 claims abstract description 48
- 230000001133 acceleration Effects 0.000 claims description 17
- 230000000737 periodic effect Effects 0.000 claims description 2
- 230000005540 biological transmission Effects 0.000 description 7
- 230000010355 oscillation Effects 0.000 description 4
- 230000008859 change Effects 0.000 description 2
- 230000036461 convulsion Effects 0.000 description 2
- 238000010586 diagram Methods 0.000 description 2
- 230000006340 racemization Effects 0.000 description 2
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000012423 maintenance Methods 0.000 description 1
- 239000000463 material Substances 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000035772 mutation Effects 0.000 description 1
- 230000009467 reduction Effects 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H02—GENERATION; CONVERSION OR DISTRIBUTION OF ELECTRIC POWER
- H02P—CONTROL OR REGULATION OF ELECTRIC MOTORS, ELECTRIC GENERATORS OR DYNAMO-ELECTRIC CONVERTERS; CONTROLLING TRANSFORMERS, REACTORS OR CHOKE COILS
- H02P8/00—Arrangements for controlling dynamo-electric motors rotating step by step
- H02P8/14—Arrangements for controlling speed or speed and torque
-
- G—PHYSICS
- G02—OPTICS
- G02B—OPTICAL ELEMENTS, SYSTEMS OR APPARATUS
- G02B23/00—Telescopes, e.g. binoculars; Periscopes; Instruments for viewing the inside of hollow bodies; Viewfinders; Optical aiming or sighting devices
- G02B23/12—Telescopes, e.g. binoculars; Periscopes; Instruments for viewing the inside of hollow bodies; Viewfinders; Optical aiming or sighting devices with means for image conversion or intensification
-
- G—PHYSICS
- G02—OPTICS
- G02B—OPTICAL ELEMENTS, SYSTEMS OR APPARATUS
- G02B7/00—Mountings, adjusting means, or light-tight connections, for optical elements
-
- G—PHYSICS
- G05—CONTROLLING; REGULATING
- G05D—SYSTEMS FOR CONTROLLING OR REGULATING NON-ELECTRIC VARIABLES
- G05D13/00—Control of linear speed; Control of angular speed; Control of acceleration or deceleration, e.g. of a prime mover
- G05D13/62—Control of linear speed; Control of angular speed; Control of acceleration or deceleration, e.g. of a prime mover characterised by the use of electric means, e.g. use of a tachometric dynamo, use of a transducer converting an electric value into a displacement
-
- H—ELECTRICITY
- H02—GENERATION; CONVERSION OR DISTRIBUTION OF ELECTRIC POWER
- H02P—CONTROL OR REGULATION OF ELECTRIC MOTORS, ELECTRIC GENERATORS OR DYNAMO-ELECTRIC CONVERTERS; CONTROLLING TRANSFORMERS, REACTORS OR CHOKE COILS
- H02P23/00—Arrangements or methods for the control of AC motors characterised by a control method other than vector control
- H02P23/0004—Control strategies in general, e.g. linear type, e.g. P, PI, PID, using robust control
- H02P23/0013—Control strategies in general, e.g. linear type, e.g. P, PI, PID, using robust control using fuzzy control
-
- H—ELECTRICITY
- H02—GENERATION; CONVERSION OR DISTRIBUTION OF ELECTRIC POWER
- H02P—CONTROL OR REGULATION OF ELECTRIC MOTORS, ELECTRIC GENERATORS OR DYNAMO-ELECTRIC CONVERTERS; CONTROLLING TRANSFORMERS, REACTORS OR CHOKE COILS
- H02P23/00—Arrangements or methods for the control of AC motors characterised by a control method other than vector control
- H02P23/14—Estimation or adaptation of motor parameters, e.g. rotor time constant, flux, speed, current or voltage
Landscapes
- Physics & Mathematics (AREA)
- Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Power Engineering (AREA)
- Automation & Control Theory (AREA)
- Optics & Photonics (AREA)
- Astronomy & Astrophysics (AREA)
- Fuzzy Systems (AREA)
- Feedback Control In General (AREA)
Abstract
The invention discloses a speed planning fuzzy control method based on an arctangent function. The method calculates the running speed of the stepping motor at the next moment according to the current rotating speed of the running mechanism, the maximum speed of the motor of the running mechanism, the positioning deceleration zone and the current position error. The method is small in calculated amount, simple and effective, suitable for a distributed control system with strong nonlinearity, containing backlash or gaps and large difference of control mechanisms, and has good effect in the control and application of a high-precision dimming and focusing mechanism of the photoelectric telescope in occasions with high requirements on motion precision and stability.
Description
Technical Field
The invention belongs to the technical field of stepping motor control, and particularly relates to a speed planning fuzzy control method based on an arctangent function, which can be used for acceleration and deceleration control of a stepping motor.
Background
The current method for controlling the motion of the stepping motor mostly adopts trapezoidal control, and the control of the method is simple, but when the method is used for high-precision control, oscillation is converged due to sudden change of jerk in closed-loop control.
At present, a learner proposes a positive vector acceleration method and a parabolic acceleration method for controlling a stepping motor, the two methods are more in line with the moment-frequency characteristic of the stepping motor, the speed is planned through the running step number, the jerk is free from mutation, the running is stable, but the two methods are planned based on the step number, when a mechanical structure contains a gap or returns, the running step number is unknown due to the unknown gap size, and the two methods for planning based on the step number are not applicable, so that a speed planning mode based on a position error is needed.
Disclosure of Invention
In order to solve the technical problems, the invention provides a fuzzy control method for planning the speed through position errors based on an arctangent function, which can be used for nonlinear controlled objects and is used for solving the problems of oscillation and low positioning accuracy when trapezoidal control converges.
In order to achieve the above purpose, the technical scheme adopted by the invention is as follows:
a speed planning fuzzy control method based on an arctangent function is characterized in that:
the control object of the method is a motor which can be controlled by adopting pulse width modulation waveforms, and the motor drives a mechanism to operate;
the method comprises the steps of inferentially calculating the operation speed of the next period of the mechanism through the operation position error, the operation speed, the maximum acceleration and the maximum position error of the current period of the mechanism, so as to control the operation of the mechanism;
the method specifically comprises the following steps:
step 1: calculating the position deceleration zone value θ slow Wherein the position deceleration zone refers to when the running position error of the current period of the mechanism is less than theta slow When the speed is reduced, starting a deceleration operation area;
step 2: according to the position deceleration zone value and the maximum speed value v max Maximum acceleration value a max The running speed value v (k) of the current period and the running position error calculate the running direction and the running speed v (k+1) of the mechanism of the next period and are used for control.
Further, in the step 1, the position decelerating region value θ slow Maximum speed value v according to current period of mechanism max Maximum acceleration a max To calculate, the specific calculation formula is as follows:
further, the step 2 includes the following steps:
let the current period of the mechanism have an operating speed v (k), the next period have an operating speed v (k+1), and the desired position value is θ exp The current time position value is theta cur The error of the running position is theta error Wherein θ is error =θ exp -θ cur ,θ threshold For the positioning threshold, i.e. the maximum allowable positioning error value, the running direction and the running speed v (k+1) of the next periodic mechanism are determined according to the calculation result of the following formula:
wherein,arctan (x) is an arctangent function, pi=3.14159 … is a circumference ratio, TFor the control period sign indicates the direction of the mechanism running speed, -1 indicates the negative direction, and 1 indicates the positive direction.
Further, the control object is a stepper motor.
The specific control rules are as follows:
rule 1: if the position is error theta error > 0, then the motor drive direction is positive, i.e., sign (v (k+1))=1.
Rule 2: if the position is error theta error And < 0, the running direction of the motor driving mechanism is negative, namely sign (v (k+1)) = -1.
Rule 3: if the current running period position error is |theta error |>θ slow And the current running speed |v (k) | < v max Then the next cycle operation speed |v (k+1) |= |v (k) |+a) max ×T;
Rule 4: if the current running period position error is |theta error |>θ slow And the current running speed |v (k) |v max Then the next cycle operation speed |v (k+1) |=v max ;
Rule 5: if the current running period position error is |theta error |≤θ slow Then the next cycle run speed
Rule 6: if the current running period position error is |theta error |≤θ threshold Then the next cycle speed is zero.
The invention has the following beneficial effects:
the method is suitable for a motion mechanism which is driven by a motor and has an encoder at the load end and comprises a speed reducing mechanism, is suitable for occasions needing high-precision control, and has the advantages of stable operation due to the fact that the acceleration is variable during speed reduction and no abrupt change exists in the acceleration. Compared with trapezoidal control, the oscillation during convergence is effectively reduced. The invention also solves the problem that the existing positive vector type acceleration and parabolic acceleration methods are not suitable for the structure containing the gap control, and has smaller calculated amount and stronger universality.
Drawings
FIG. 1 is a flow chart of a fuzzy control method for speed planning based on an arctangent function;
FIG. 2 is when θ initial =0°,θ exp Motion control curve at =100°;
FIG. 3 is a control comparison curve of the method of the present invention and the fuzzy control, PI control method at the time of step input;
fig. 4 shows an actual control operation diagram of the racemization mechanism.
Detailed Description
The invention is further described below with reference to the drawings and the detailed description.
The invention provides a speed planning fuzzy control method based on an arctangent function, wherein the control object of the method is a motor which can be controlled by adopting pulse width modulation waveforms, and the motor drives a mechanism to operate; the method comprises the steps of inferentially calculating the operation speed of the next period of the mechanism through the operation position error, the operation speed, the maximum acceleration and the maximum position error of the current period of the mechanism, so as to control the operation of the mechanism;
the method specifically comprises the following steps:
step 1: calculating a position deceleration zone value theta of the motor slow The method comprises the steps of carrying out a first treatment on the surface of the The position deceleration zone is when the position error is smaller than theta slow When the speed is reduced, the speed is reduced;
step 2: according to the running position error theta of the current period error (θ error =θ exp -θ cur ) Position deceleration zone value θ slow Maximum speed value v max And calculating the running direction and the running speed v (k+1) of the motor driving mechanism in the next period and controlling the motor driving mechanism.
In step 1, each time the desired position is changed, the position deceleration range value θ is set to reduce the adjustment time of the control system and prevent the control system from moving to overshoot to cause oscillation slow According to maximum velocity v max Maximum acceleration a max To calculate the position decelerating region value theta slow Specific meter of (2)The calculation formula is as follows:
in the step 2, the operation speed of the mechanism in the current period is set to be v (k), the operation speed of the mechanism in the next period is set to be v (k+1), and the expected position value is set to be θ exp The current time position value is theta cur The position error is theta error Wherein θ is error =θ exp -θ cur ,θ threshold For the positioning threshold, i.e. the maximum allowable position error value, the speed planning formula is as follows:
wherein,arctan (x) is an arctangent function, pi=3.14159 … is a circumference ratio, T is a control period, sign represents a direction of a mechanism operation speed, -1 represents a negative direction, and 1 represents a positive direction.
The specific control flow is shown in fig. 1.
Assume a maximum speed value v of a control mechanism max =5 °/s, maximum acceleration a max =20°/s 2 ,θ threshold =0.0002°, initial time position value θ initial =0°, desired position θ exp When=100°:
then there is theta slow =3.9789°。
Assuming that the control operation period T is 1ms, according to the rule of the fuzzy control method of the present invention, the expected speed can be calculated through the position error and the speed at the current moment, so that the corresponding Pulse Width Modulation (PWM) waveform can be calculated and output to the motor driver, thereby driving the motor to rotate. The specific rules are as follows:
rule 1: if the position is error theta error > 0, then the motor drive direction is positive, i.e., sign (v (k+1))=1;
rule 2: if the position is error theta error < 0, then the motor drive direction is negative, i.e. sign (v (k+1)) = -1;
rule 3: if the current running period position error is |theta error |>3.9789 deg. and the current running speed |v (k) | < 5 deg./s, then the next cycle motor running speed |v (k+1) |= |v (k) |+0.02;
rule 4: if the current running period position error is |theta error |>3.9789 DEG and the current operating speed |v (k) |gtoreq 5 DEG/s, then the next cycle motor operating speed |v (k+1) |=v max =5°/s;
Rule 5: if the current running period position error is |theta error The angle is less than or equal to 3.9789 degrees, the mechanism starts to run at a reduced speed, next cycle of mechanism running speed
Rule 6: if the current running period position error is |theta error And 0.0002 degrees or less, which means that the expected position is reached and the position error is within the allowable range, then the next cycle speed is zero.
According to the control rule, when θ initial =0°,θ exp When=100°, the motion control curve is shown in fig. 2.
Examples:
taking a 1.2m large-view-field telescope as an example, the dimming and focusing control mechanism of the telescope comprises a plurality of mechanisms such as focusing, image eliminating rotation, correcting lens focusing, lens cover and the like. The transmission mechanisms of all the mechanisms are different, wherein the transmission mechanisms comprise various transmission modes such as ball screw transmission, gear transmission, worm and gear transmission and the like, and the various transmission modes all have nonlinear characteristics and are also different in friction coefficient due to different materials. The fuzzy control method of the invention is adopted for the control of the mechanisms, the control programs in the board card are consistent, the maximum speed value, the deceleration zone value, the maximum position error and the maximum acceleration of each mechanism are set as configurable parameters and stored in the EEPROM, the mechanisms are distinguished through a dial switch, and when a control object is changed, only the configurable parameters are required to be changed. Therefore, the universality of the board card and the program is enhanced, the debugging period is shortened, the program development time is shortened, and the later maintenance is convenient. The method has the advantages of small calculated amount, simple calculation formula, greatly reduced requirement on the calculation performance of the control board card and higher control precision. FIG. 3 is a control comparison curve of the method of the present invention and the fuzzy control, PI control method at the time of step input. Fig. 4 shows an actual control operation diagram of the racemization mechanism, and the final positioning accuracy reaches 0.2 angular seconds.
While the invention has been described with respect to specific embodiments thereof, it will be appreciated that the invention is not limited thereto, but rather encompasses modifications and substitutions within the scope of the present invention as will be appreciated by those skilled in the art.
Claims (3)
1. A speed planning fuzzy control method based on an arctangent function is characterized in that:
the control object of the method is a motor controlled by adopting pulse width modulation waveforms, and the motor drives a mechanism to operate;
the method comprises the steps of inferentially calculating the operation speed of the next period of the mechanism through the operation position error, the operation speed, the maximum acceleration and the maximum position error of the current period of the mechanism, so as to control the operation of the mechanism;
the method specifically comprises the following steps:
step 1: calculating the position deceleration zone value θ slow Wherein the position deceleration zone refers to when the running position error of the current cycle of the mechanism is less than theta slow When the speed is reduced, starting a deceleration operation area; θ slow According to the maximum speed value v max Maximum acceleration a max And (3) performing calculation:
step 2: according to the position deceleration zone value theta slow Maximum speed value v max Maximum acceleration a max The running speed value v (k) of the current period and the running speed value v (k+1) of the next period mechanism are calculated by running position errors and used for control.
2. The method for fuzzy control of a velocity planning based on an arctangent function according to claim 1, wherein the step 2 comprises the steps of:
let the current period of the mechanism have an operating speed value v (k), the next period have an operating speed value v (k+1), and the desired position value θ exp The current time position value is theta cur The error of the running position is theta error Wherein θ is error =θ exp -θ cur ,θ threshold For the positioning threshold, i.e. the maximum allowable positioning error value, the running direction and the running speed v (k+1) of the next periodic mechanism are determined according to the calculation result of the following formula:
wherein,arctan (x) is an arctangent function, pi=3.14159 … is a circumference ratio, T is a control period, sign represents a direction of a mechanism operation speed, -1 represents a negative direction, and 1 represents a positive direction.
3. The method for fuzzy control of a velocity planning based on an arctangent function of claim 1, wherein the control object is a stepper motor.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202311715864.7A CN117674653A (en) | 2023-12-14 | 2023-12-14 | Speed planning fuzzy control method based on arctangent function |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202311715864.7A CN117674653A (en) | 2023-12-14 | 2023-12-14 | Speed planning fuzzy control method based on arctangent function |
Publications (1)
Publication Number | Publication Date |
---|---|
CN117674653A true CN117674653A (en) | 2024-03-08 |
Family
ID=90082438
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202311715864.7A Pending CN117674653A (en) | 2023-12-14 | 2023-12-14 | Speed planning fuzzy control method based on arctangent function |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN117674653A (en) |
-
2023
- 2023-12-14 CN CN202311715864.7A patent/CN117674653A/en active Pending
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US7339342B2 (en) | Stepper motor controlling apparatus and pen recorder | |
CN106060380A (en) | Linkage camera control system and method | |
CN111240370B (en) | Position correction method, device and system for cradle head and storage medium | |
CN108345269B (en) | Control device, control system, and recording medium | |
US8901871B2 (en) | Robust controller for electro-mechanical actuators employing sliding and second control modes | |
CN108762117B (en) | Servo driver control method and device | |
CN108092561A (en) | A kind of Dual-Servo Motor of full digital disappears slot sytem and its control method | |
CN111953240B (en) | Double-motor backlash eliminating method and system based on optimal control | |
CN109514540A (en) | Steering wheel and robot | |
CN101587327B (en) | Universal motion control system and control method on industrial control platform | |
Zhang et al. | Research on stepper motor motion control based on MCU | |
CN117674653A (en) | Speed planning fuzzy control method based on arctangent function | |
CN115097596B (en) | Fuzzy control method for dimming or focusing control mechanism | |
CN106996358B (en) | Torque smooth control method for positive and negative rotation switching of variable pitch motor of wind power generation system | |
TW202143628A (en) | Control device for stepping motor | |
CN111525853B (en) | Motor rotation control method and terminal | |
CN116780951A (en) | Speed planning fuzzy control method based on position error | |
CN106933261B (en) | Position follow-up control system and control method based on stepping drive | |
CN111336241A (en) | High-precision control system and method for eliminating rotating back clearance of speed reducer | |
CN116015141A (en) | Closed-loop control system and method for position of stepping motor | |
CN107065943B (en) | It is a kind of directly to turn platform position control system and control method | |
CN114714364A (en) | Robot joint friction compensation adjusting method and robot friction compensation method | |
Polyuschenkov | Development of control system for interconnected electric drives with electromechanical torsion | |
CN117439460B (en) | Planar stepping biaxial system interpolation method, planar stepping biaxial system interpolation system, planar stepping biaxial system control device and planar stepping biaxial system interpolation control method | |
US7541766B1 (en) | System and method for the intelligent use of software deadband control in a control system |
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 |