CN113805611B - Video image stabilizing method based on triaxial holder - Google Patents

Video image stabilizing method based on triaxial holder Download PDF

Info

Publication number
CN113805611B
CN113805611B CN202111123803.2A CN202111123803A CN113805611B CN 113805611 B CN113805611 B CN 113805611B CN 202111123803 A CN202111123803 A CN 202111123803A CN 113805611 B CN113805611 B CN 113805611B
Authority
CN
China
Prior art keywords
angle
speed
stepping motor
control
algorithm
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
CN202111123803.2A
Other languages
Chinese (zh)
Other versions
CN113805611A (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.)
Dalian Maritime University
Original Assignee
Dalian Maritime University
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 Dalian Maritime University filed Critical Dalian Maritime University
Priority to CN202111123803.2A priority Critical patent/CN113805611B/en
Publication of CN113805611A publication Critical patent/CN113805611A/en
Application granted granted Critical
Publication of CN113805611B publication Critical patent/CN113805611B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

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

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Automation & Control Theory (AREA)
  • Studio Devices (AREA)
  • Control Of Position Or Direction (AREA)

Abstract

The invention relates to a video image stabilizing method based on a triaxial holder, which is divided into a gesture information acquisition part and a control part. The attitude information acquisition part uses a three-axis cradle head based on a stepping motor as an image stabilizing platform, an inertial sensor is used as an attitude information acquisition element, and attitude data acquired by an accelerometer and a gyroscope in the inertial sensor are fused to calculate an attitude angle; the control part controller adopts a hierarchical adjustment mode to control the driving of the stepping motor driver, directly calculates the number of pulses of smaller angle errors and outputs the pulses, and uses a double-layer control algorithm to determine the correlation between the angle and the speed for larger angle errors, and uses a Time Shortened PID (Time Shortened-PID) algorithm to control the output of the pulses, thereby shortening the compensation Time of the attitude angle errors when the errors are smaller.

Description

Video image stabilizing method based on triaxial holder
Technical Field
The invention relates to the technical field of video processing, in particular to a video image stabilizing method based on a triaxial holder.
Background
Video monitoring systems are applied in various aspects of daily life. However, in the process of acquiring video information, the image capturing device inevitably suffers shaking noise to cause shaking, blurring, distortion and other conditions of video images, and important monitoring information is lost. The mechanical image stabilizing technology can effectively reduce the shaking degree of the image pickup device, the image pickup device is arranged on a document holder, and the shaking amplitude of the image pickup device can be stabilized in a smaller range by adjusting the posture of the holder.
The camera shooting equipment can produce the shake of three kinds of angles under rocking by a wide margin: pitch angle, yaw angle and roll angle. The electronic image stabilizing means is often used for assisting the mechanical image stabilizing means to compensate small-amplitude shake outside mechanical image stabilizing precision, the electronic image stabilizing means is most difficult to compensate image rolling, common two-axis cloud platforms can only realize the compensation of pitch angle and yaw angle, and in order to reduce the complexity of the electronic image stabilizing, the mechanical image stabilizing means can compensate three-axis cloud platforms including rolling angles and three attitude angles to serve as image stabilizing platforms.
Aiming at the condition that the shaking angle range of the image pickup equipment is large, different control methods are adopted to compensate errors, the characteristics of the stepping motor are combined with a PID algorithm, the calculated pulse number is directly output by the small angle, and the pulses are output by the double-layer control algorithm by the large angle. When the error is smaller, the output control amount of the traditional PID control algorithm becomes very small, so that the speed of the deviation approaching zero becomes slow, and the traditional PID control algorithm needs to be improved, so that the running frequency of the stepping motor when the error is smaller is quickened, and the time for the cradle head to reach stability is shortened.
Disclosure of Invention
Aiming at the problems, the invention aims to provide a video image stabilizing method based on a three-axis tripod head, which can effectively solve the problems that the electronic image stabilizing technology has poor large-amplitude shaking processing effect on video, the common two-axis tripod head cannot realize the compensation of rolling angles and the like, and improve a control algorithm and shorten the compensation time on the basis of guaranteeing the realization of three-gesture angle compensation.
The technical scheme adopted by the invention is as follows:
the invention provides a video image stabilizing method based on a triaxial holder, which specifically comprises the following steps:
s1: using a three-axis tripod head based on a stepping motor and provided with a pitching axis, a yawing axis and a rolling shaft as an image stabilizing platform, arranging the image pickup device at the intersection point of three axes of the three-axis tripod head, and arranging an inertial sensor on the plane of the three-axis tripod headAcquiring attitude information of the camera equipment at the intersection point of the coordinate axes; the attitude information acquisition is based on an inertial sensor installed on a three-dimensional image stabilizing platform, and an accelerometer and a gyroscope in the inertial sensor respectively acquire triaxial acceleration a of the image pickup device x ,a y ,a z And a triaxial angular velocity omega x ',ω y ',ω z ';
S2: correcting the angular velocity drift by using the collected acceleration, carrying out data fusion on the collected acceleration and the collected angular velocity by using a vector outer product compensation algorithm, and calculating the attitude angle of the camera by using a quaternion solution: roll angle phi, vertical pitch angle theta, horizontal azimuth angle phi;
s3: posture adjustment is carried out on the triaxial holder through a stepping motor; the inertial sensor is connected with the microcontroller, the microcontroller is connected with a driver of the stepping motor, and the pulse signal output by the microcontroller controls the driver of the stepping motor to drive the stepping motor to rotate; the stepping motor driver is controlled to drive the stepping motor to rotate in a step-by-step adjustment mode, a control method is selected according to the current angle and the expected angle difference value, and when the angle difference value is smaller than T 1 When the pulse frequency is higher than the pulse frequency, the pulse number and the pulse frequency to be output are directly calculated; when the angle difference is greater than T 1 When the pulse is output by using a double-layer control algorithm, the first layer is controlled to be an angle layer, the second layer is controlled to be a speed layer, the angle layer controller is called an angle controller, and the speed layer controller is called a speed controller;
s4: inputting the difference value between the expected angle and the actual angle into an angle controller, and outputting the difference value as the expected speed; in the angle controller, a positive correlation exists between the output of the angle controller and the speed expectation, and in order to enhance the smoothness of speed change, the angle controller outputs the speed expectation by adopting an evolution control algorithm to control the rotating speed of the stepping motor;
s5: the speed layer uses a TS-PID control algorithm, the difference between the speed expected output by the angle layer and the actual speed is input into a speed controller, and the speed controller outputs the expected speed;
s6: calculating the expected pulse frequency of the stepping motor according to the expected speed, and using a microcontrollerOutputting pulse to the step motor driver to drive the step motor to rotate, when the difference between the acquired angle and the expected angle is smaller than T 1 And (3) directly outputting a pulse by adopting the method in the step (S3), and circulating the control process until the difference value between the acquired angle and the expected angle reaches the allowable error range.
Further, in the step S2, the acceleration a collected by the accelerometer and the gyroscope in the inertial sensor is calculated x ,a y ,a z And angular velocity omega x ',ω y ',ω z ' data fusion is carried out by adopting a vector outer product compensation algorithm, and a quaternion is used for calculating an attitude angle; the method comprises the following specific steps:
when the moment is n, firstly, the remembering quaternion is initialized, q 0 (0) =1,q 1 (0) =0,q 2 (0) =0,q 3 (0) =0; the accelerometer signal firstly passes through a low-pass filter to eliminate high-frequency noise, and then the gravity acceleration measured by the accelerometer is normalized to obtain an accelerometer value normalized at the moment n Acquiring gravity components of quaternion in an equivalent cosine matrix, and carrying out vector outer product operation on the normalized acceleration and the gravity components to obtain an attitude error E n
The error is accumulated to obtain I n Compensating the attitude error to the angular velocity through a proportional-integral control algorithm, predicting the angular velocity, and correcting integral drift of the angular velocity;
W n =W' (n) +C p E n +I n
will I n =I n-1 +C i E n Substitution into the above formula can be obtained:
W n =W' n +C p E n +C i E n +I n-1
wherein,for the corrected triaxial angular velocity, +.>Acquiring three-axis angular velocity values for an n-moment gyroscope, C p Is a proportionality coefficient, C i Is an integral coefficient;
C p controlling the credibility of accelerometer data, C p The larger the trust of the data measured by the accelerometer is, the higher the trust is, and the smaller the trust is on the contrary; in the long term, the value of the acceleration is very accurate, and the data measured by the gyroscope is more accurate in a short time, so the value of the accelerometer should keep a small weight in the compensation process in a short time, C p Keeping the value small, C increases with time p The value of (2) is properly increased;
according to the corrected angular velocity value, the quaternion differential equation and the Longku tower method are utilized to recursively calculate the quaternion value, and then the real-time attitude angle can be calculated:
φ=tan -1 [2(q 0 q 1 +q 2 q 3 )/q 0 2 -q 1 2 -q 2 2 +q 3 2 ]
θ=-sin -1 (2(q 1 q 3 -q 0 q 2 ))
ψ=tan -1 [2(q 0 q 3 +q 1 q 2 )/q 0 2 +q 1 2 -q 2 2 -q 3 2 ]。
further, in the step S3, the threshold T 1 The determination mode of (2) is as follows: the sampling time of the inertial sensor to the attitude angle of the image pickup device is T s Proper pulse frequency f of a pulse output by a main control chip can be selected to accurately drive a stepping motor, and under the condition that the subdivision number of a stepping motor driver is determined, the stepping angle of the stepping motor is determined, and the assumption is n and T 1 I.e. the rotatable angle of the stepping motor in one sampling period, T 1 =T s ·f·n。
Further, in the step S4, the evolution control algorithm adopted in the angle control includes: setting a demarcation quantityDividing a linear region range by taking positive and negative values of the quantity as dividing lines, wherein K is a proportionality coefficient, and K.e is followed in the range a The control quantity is output by a calculation mode, and after the control quantity exceeds L, the error is larger, and the control quantity is required to be in a square form>Calculating the actual control quantity, i.e. the speed is desired +.>e a A is the difference between the desired angle and the actual angle max For the maximum acceleration value achievable by the system.
Further, in the step S5, the TS-PID algorithm is an algorithm obtained by modifying the PID algorithm, and when the difference is smaller, the compensation speed is kept faster, and the compensation time is shortened:
the incremental discrete PID algorithm formula is as follows:
Δu(k)=K p (e(k)-e(k-1))+K i ·e(k)+K d (e(k)-2e(k-1)+e(k-2))
let x (0) =e (k) -e (k-1)
x(1)=e(k)
x(2)=e(k)-2e(k-1)+e(k-2)
Then Δu (K) =k p (x(0))+K i ·x(1)+K d (x(2))
Wherein Deltau (k) is the control amount of the speed at time k, e is the deviation, and when e is small, the output control amount becomes small with the output of the control amount, resulting in the slow deviation compensation speed, the PID algorithm is improved, and the threshold T is set 2 Performing hierarchical adjustment, T 2 Is greater than T 1 A smaller value; when err>T 2 Outputting control quantity by PID control algorithm, and continuously updating the values of x (0), x (1) and x (3) until err<T 2 When the control quantity output of the previous moment is unchanged, x (0), x (1) and x (3) are kept until the angle error is smaller than T 1 And then continue to press the angle error smaller than T 1 Is compensated for angle errors.
Further, in the step S5, the data of the inertial sensor may not only calculate the angle, but also obtain the current speed from the gyroscope in the inertial sensor; in view of the zero drift characteristics of the gyroscope, zero calibration and zero drift removal of the gyroscope are required.
Compared with the prior art, the invention has the following beneficial effects:
1. the invention can realize the compensation of three attitude angles, thereby reducing the complexity of electronic image stabilization;
2. different control methods are adopted when the error to be compensated is different, the pulse can be directly output from the angle which can be completely compensated in one sampling period, and a double-layer control algorithm is adopted when one sampling period is difficult to compensate, so that the compensation and time are shortened, and the compensation precision is improved;
3. adopting a TS-PID algorithm to reduce the error compensation time;
4. the cost is low, and the gesture acquisition sensor and the controller are various.
Drawings
Fig. 1 is a schematic overall flow chart of a video image stabilizing method based on a triaxial holder according to the present invention;
FIG. 2 is a block diagram of attitude angle control;
FIG. 3 is a schematic diagram of an evolution control algorithm simulation;
FIG. 4 is a schematic diagram showing simulation comparison of PID algorithm and TS-PID algorithm.
Detailed Description
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings that are required in the embodiments or the description of the prior art will be briefly described, and it is obvious that the drawings in the following description are some embodiments of the present invention, and other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Referring to fig. 1 to 4, the specific implementation process of the video image stabilizing method based on the triaxial holder provided by the invention comprises the following steps:
s1: using a three-axis cradle head based on a stepping motor and provided with a pitching axis, a yawing axis and a rolling shaft as an image stabilizing platform, placing the image pickup device on the three-axis cradle head, and collecting posture information of the image pickup device by an inertial sensor, wherein the three-axis acceleration is a x ,a y ,a z And a triaxial angular velocity omega x ',ω y ',ω z The inertial sensor may also collect the camera device for use as a rear speed control feedback.
S2: the acquired triaxial acceleration a x ,a y ,a z And a triaxial angular velocity omega x ',ω y ',ω z The vector outer product compensation algorithm is applied to data fusion, so that the attitude angles of the image pickup device, namely a rolling angle phi, a vertical pitch angle theta and a horizontal azimuth angle phi, are obtained, and the specific process is as follows:
first, register quaternion initialization, q 0 (0) =1,q 1 (0) =0,q 2 (0) =0,q 3 (0) =0; the accelerometer signal firstly passes through a low-pass filter to eliminate high-frequency noise, and then the gravity acceleration measured by the accelerometer is normalized to obtain an accelerometer value normalized at the moment n
Acquiring gravity components of quaternions in an equivalent cosine matrix:
V n =C 2 T E 1
wherein,C 2 is a directional cosine matrix>
Vector cross-multiplication yields the attitude error:
E n =A n ×V n
wherein,for the acceleration matrix, the operation can be obtained:
integrating the errors, accumulating the errors in a recursive mode, and reducing budget complexity:
I n =I n-1 +C i E n
wherein the method comprises the steps ofC i Is an integral coefficient;
and compensating the vector outer product, namely compensating the attitude error to the angular velocity through a proportional-integral controller, predicting the angular velocity, and correcting the integral drift of the angular velocity:
W n =W' (n) +C p E n +I n
will I n =I n-1 +C i E n Substitution into the above formula can be obtained:
W n =W' n +C p E n +C i E n +I n-1
wherein,for the corrected angular velocity value, +.>C is the angular velocity value acquired by the gyroscope at n sampling moments p Is a proportionality coefficient;
C p controlling the credibility of accelerometer data, C p The greater the confidence in the data measured by the accelerometer, the greater the confidence, and conversely, the lesser the confidence. In the long term, the value of the acceleration is very accurate, and the data measured by the gyroscope is relatively accurate in a short time, so C is in a short time p Keeping the value small, C increases with time p The value of (2) is increased appropriately.
The quaternion differential equation and the Longgugar tower method can be used for obtaining a quaternion update equation:
Q n+1 =Q n +μ·U n
wherein,Δt is the attitude sampling time interval;
the quaternion is continuously updated, and three new Euler angles are calculated according to the relation between the Euler angles and the quaternion to obtain:
φ=tan -1 [2(q 0 q 1 +q 2 q 3 )/q 0 2 -q 1 2 -q 2 2 +q 3 2 ]
θ=-sin -1 (2(q 1 q 3 -q 0 q 2 ))
ψ=tan -1 [2(q 0 q 3 +q 1 q 2 )/q 0 2 +q 1 2 -q 2 2 -q 3 2 ]
s3: posture adjustment is carried out on the triaxial holder through a stepping motor; the inertial sensor is connected with a microcontroller, the microcontroller is connected with a driver of the stepping motor, and the inertial sensor is output by the microcontrollerThe pulse signal controls the stepping motor driver to drive the stepping motor to rotate; the stepping motor driver is controlled to drive the stepping motor to rotate in a step-by-step adjustment mode, a control method is selected according to the current angle and the expected angle difference value, and when the angle difference value is smaller than T 1 When the pulse frequency is higher than the pulse frequency, the pulse number and the pulse frequency to be output are directly calculated; when the angle difference is greater than T 1 When the pulse is output by using a double-layer control algorithm, the first layer is controlled to be an angle layer, the second layer is controlled to be a speed layer, the angle layer controller is called an angle controller, and the speed layer controller is called a speed controller; the specific process is as follows:
threshold T 1 The determination mode of (a) is as follows: the sampling time of the inertial sensor to the attitude angle of the image pickup device is T s Proper pulse frequency f of a pulse output by a main control chip can be selected to accurately drive a stepping motor, and under the condition that the subdivision number of a stepping motor driver is determined, the stepping angle of the stepping motor is determined, and the assumption is n and T 1 I.e. the rotatable angle of the stepping motor in one sampling period, T 1 =T s ·f·n。
Taking the compensation of the roll angle difference as an example: the desired difference between the roll angle at time k and the roll angle:
e φ (k)=φ-φ target
when e φ (k)<T 1 The method for directly calculating the pulse number output is adopted, and the pulse number calculation method is as follows: under the condition that the subdivision number of the stepping motor driver is determined, assuming that the stepping angle of the stepping motor is n, the number of pulses to be output is:when e φ (k)>T 1 And outputting the pulse by adopting a double-layer control algorithm.
S4: inputting the difference value between the expected angle and the actual angle into an angle controller, and outputting the difference value as the expected speed; in the angle controller, a positive correlation exists between the output of the angle controller and the speed expectation, and in order to enhance the smoothness of speed change, the angle controller outputs the speed expectation by adopting an evolution control algorithm to control the rotating speed of the stepping motor. The specific process is as follows:
the input of the angle controller is the difference between the actual angle and the expected angle, the output is the expected speed, the larger the angle is, the faster the compensation is expected, and the positive correlation relationship between the speed and the angle is maintained. At the same time, in order to enhance the smoothness of the speed change, as shown in FIG. 3, a demarcation quantity is setDividing a linear region range by taking positive and negative values of the quantity as dividing lines, outputting a control quantity in the range according to a K.e calculation mode, and indicating that the error is larger after the control quantity exceeds L, wherein the control quantity is required to be expressed in the form of square->Calculating the actual control quantity, i.e. the speed is desired +.>a max Maximum acceleration value achievable for the system;
s5: the speed layer uses a TS-PID control algorithm to input the difference between the speed expected and actual speed output by the angle layer into a speed controller, and the speed controller outputs the expected speed. The specific process is as follows:
the speed controller inputs the difference between the expected speed and the actual speed, the output speed is the rotation speed of the stepping motor, and the actual speed value is obtained from the measured value after the gyroscope zero point in the inertial sensor shifts. Considering that the angle error is smaller and smaller along with the rotation of the stepping motor and the compensation speed is slower and slower, the compensation time side length is caused, the speed layer PID algorithm is improved, the hierarchical adjustment is carried out, and T 2 Is greater than T 1 Is a smaller value of (a). When err>T 2 Outputting control quantity by PID control algorithm until err<T 2 In order to avoid overshoot, the control quantity output at the previous moment is kept unchanged, and the proportion coefficient K p A smaller value should be set.
The incremental discrete PID algorithm formula is as follows:
Δu(k)=K p (e(k)-e(k-1))+K i ·e(k)+K d (e(k)-2e(k-1)+e(k-2))
let x (0) =e (k) -e (k-1)
x(1)=e(k)
x(2)=e(k)-2e(k-1)+e(k-2)
Then Δu (K) =k p (x(0))+K i ·x(1)+K d (x(2))
Wherein Deltau (k) is the control amount of the speed at time k, e is the deviation, and when e is small, the output control amount becomes small with the output of the control amount, resulting in the slow deviation compensation speed, the PID algorithm is improved, and the threshold T is set 2 Performing hierarchical adjustment, T 2 Is greater than T 1 A smaller value; when err>T 2 Outputting control quantity by PID control algorithm, and continuously updating the values of x (0), x (1) and x (3) until err<T 2 When the control quantity output of the previous moment is unchanged, x (0), x (1) and x (3) are kept until the angle error is smaller than T 1 And then continue to press the angle error smaller than T 1 Is compensated for angle errors.
FIG. 4 is a graph of simulation comparison of the conventional PID algorithm and the TS-PID algorithm in the range of error compensation to allow, and by taking compensation step signals as an example, the validity of the TS-PID algorithm is verified, and the proportional, integral and differential coefficients of the two algorithms are consistent, so that it can be obviously seen that when the error is smaller than T 2 When the method is used, the prior compensation speed is still maintained by the TS-PID algorithm, the compensation time is obviously shortened compared with the traditional PID algorithm, and the effectiveness of the TS-PID algorithm is proved.
S6: calculating the expected pulse frequency of the stepping motor according to the expected speed, outputting pulses to the stepping motor driver through the microcontroller to drive the stepping motor to rotate, and when the difference value between the acquired angle and the expected angle is smaller than T 1 And directly outputting a pulse, and circulating the control process until the difference between the acquired angle and the expected angle reaches the allowable error range.
The above examples are only illustrative of the preferred embodiments of the present invention and are not intended to limit the scope of the present invention, and various modifications and improvements made by those skilled in the art to the technical solution of the present invention should fall within the scope of protection defined by the claims of the present invention without departing from the spirit of the design of the present invention.

Claims (6)

1. The video image stabilizing method based on the three-axis cradle head is characterized by comprising the following steps of:
s1: using a three-axis tripod head based on a stepping motor and provided with a pitching axis, a yawing axis and a turning shaft as an image stabilizing platform, arranging the image pickup device at the intersection point of three axes of the three-axis tripod head, and arranging an inertial sensor at the intersection point of plane coordinate axes of the three-axis tripod head to collect the attitude information of the image pickup device; the attitude information acquisition is based on an inertial sensor installed on a three-dimensional image stabilizing platform, and an accelerometer and a gyroscope in the inertial sensor respectively acquire triaxial acceleration a of the image pickup device x ,a y ,a z And a triaxial angular velocity omega x ',ω y ',ω z ';
S2: correcting the angular velocity drift by using the collected acceleration, carrying out data fusion on the collected acceleration and the collected angular velocity by using a vector outer product compensation algorithm, and calculating the attitude angle of the camera by using a quaternion solution: roll angle phi, vertical pitch angle theta, horizontal azimuth angle phi;
s3: posture adjustment is carried out on the triaxial holder through a stepping motor; the inertial sensor is connected with the microcontroller, the microcontroller is connected with a driver of the stepping motor, and the pulse signal output by the microcontroller controls the driver of the stepping motor to drive the stepping motor to rotate; the stepping motor driver is controlled to drive the stepping motor to rotate in a step-by-step adjustment mode, a control method is selected according to the current angle and the expected angle difference value, and when the angle difference value is smaller than T 1 When the pulse frequency is higher than the pulse frequency, the pulse number and the pulse frequency to be output are directly calculated; when the angle difference is greater than T 1 When the pulse is output by using a double-layer control algorithm, the first layer is controlled to be an angle layer, the second layer is controlled to be a speed layer, the angle layer controller is called an angle controller, and the speed layer controller is called a speed controller;
s4: inputting the difference value between the expected angle and the actual angle into an angle controller, and outputting the difference value as the expected speed; in the angle controller, a positive correlation exists between the output of the angle controller and the speed expectation, and in order to enhance the smoothness of speed change, the angle controller outputs the speed expectation by adopting an evolution control algorithm to control the rotating speed of the stepping motor;
s5: the speed layer uses a TS-PID control algorithm, the difference between the speed expected output by the angle layer and the actual speed is input into a speed controller, and the speed controller outputs the expected speed;
s6: calculating the expected pulse frequency of the stepping motor according to the expected speed, outputting pulses to the stepping motor driver through the microcontroller to drive the stepping motor to rotate, and when the difference value between the acquired angle and the expected angle is smaller than T 1 And (3) directly outputting a pulse by adopting the method in the step (S3), and circulating the control process until the difference value between the acquired angle and the expected angle reaches the allowable error range.
2. The video image stabilization control method based on the three-axis holder of claim 1, wherein the method comprises the following steps: in the step S2, the acceleration a acquired by the accelerometer and the gyroscope in the inertial sensor is calculated x ,a y ,a z And angular velocity omega x ',ω y ',ω z ' data fusion is carried out by adopting a vector outer product compensation algorithm, and a quaternion is used for calculating an attitude angle; the method comprises the following specific steps:
when the moment is n, firstly, the remembering quaternion is initialized, q 0 (0) =1,q 1 (0) =0,q 2 (0) =0,q 3 (0) =0; the accelerometer signal firstly passes through a low-pass filter to eliminate high-frequency noise, and then the gravity acceleration measured by the accelerometer is normalized to obtain an accelerometer value normalized at the moment n Acquiring quaternion in equivalent cosine momentThe gravity component in the array carries out vector outer product operation on the normalized acceleration and the gravity component to obtain an attitude error E n
The error is accumulated to obtain I n Compensating the attitude error to the angular velocity through a proportional-integral control algorithm, predicting the angular velocity, and correcting integral drift of the angular velocity;
W n =W' (n) +C p E n +I n
will I n =I n-1 +C i E n Substitution into the above formula can be obtained:
W n =W' n +C p E n +C i E n +I n-1
wherein,for the corrected triaxial angular velocity, +.>Acquiring three-axis angular velocity values for an n-moment gyroscope, C p Is a proportionality coefficient, C i Is an integral coefficient;
C p controlling the credibility of accelerometer data, C p The larger the trust of the data measured by the accelerometer is, the higher the trust is, and the smaller the trust is on the contrary; in the long term, the value of the acceleration is very accurate, and the data measured by the gyroscope is more accurate in a short time, so the value of the accelerometer should keep a small weight in the compensation process in a short time, C p Keeping the value small, C increases with time p The value of (2) is properly increased;
according to the corrected angular velocity value, the quaternion differential equation and the Longku tower method are utilized to recursively calculate the quaternion value, and then the real-time attitude angle can be calculated:
φ=tan -1 [2(q 0 q 1 +q 2 q 3 )/q 0 2 -q 1 2 -q 2 2 +q 3 2 ]
θ=-sin -1 (2(q 1 q 3 -q 0 q 2 ))
ψ=tan -1 [2(q 0 q 3 +q 1 q 2 )/q 0 2 +q 1 2 -q 2 2 -q 3 2 ]。
3. the video stabilization method based on the three-axis holder of claim 1, wherein the video stabilization method is characterized by comprising the following steps: in the step S3, a threshold T 1 The determination mode of (2) is as follows: the sampling time of the inertial sensor to the attitude angle of the image pickup device is T s Proper pulse frequency f of a pulse output by a main control chip can be selected to accurately drive a stepping motor, and under the condition that the subdivision number of a stepping motor driver is determined, the stepping angle of the stepping motor is determined, and the assumption is n and T 1 I.e. the rotatable angle of the stepping motor in one sampling period, T 1 =T s ·f·n。
4. The video stabilization method based on the three-axis holder of claim 1, wherein the video stabilization method is characterized by comprising the following steps: in the step S4, the evolution control algorithm adopted in the angle control includes: setting a demarcation quantityDividing a linear region range by taking positive and negative values of the quantity as dividing lines, wherein K is a proportionality coefficient, and K.e is followed in the range a The control quantity is output by a calculation mode, and after the control quantity exceeds L, the error is larger, and the control quantity is required to be in a square form>Calculating the actual control quantity, i.e. the speed is desired +.>e a A is the difference between the desired angle and the actual angle max Maximum acceleration achievable for a systemValues.
5. The video stabilization method based on the three-axis holder of claim 1, wherein the video stabilization method is characterized by comprising the following steps: in the step S5, the TS-PID algorithm is an algorithm obtained by modifying the PID algorithm, and when the difference is smaller, the compensation speed is kept faster, and the compensation time is shortened:
the incremental discrete PID algorithm formula is as follows:
Δu(k)=K p (e(k)-e(k-1))+K i ·e(k)+K d (e(k)-2e(k-1)+e(k-2))
let x (0) =e (k) -e (k-1)
x(1)=e(k)
x(2)=e(k)-2e(k-1)+e(k-2)
Then Δu (K) =k p (x(0))+K i ·x(1)+K d (x(2))
Wherein Deltau (k) is the control amount of the speed at time k, e is the deviation, and when e is small, the output control amount becomes small with the output of the control amount, resulting in the slow deviation compensation speed, the PID algorithm is improved, and the threshold T is set 2 Performing hierarchical adjustment, T 2 Is greater than T 1 A smaller value; when err>T 2 Outputting control quantity by PID control algorithm, and continuously updating the values of x (0), x (1) and x (3) until err<T 2 When the control quantity output of the previous moment is unchanged, x (0), x (1) and x (3) are kept until the angle error is smaller than T 1 And then continue to press the angle error smaller than T 1 Is compensated for angle errors.
6. The video stabilization method based on the three-axis holder of claim 1, wherein the video stabilization method is characterized by comprising the following steps: in the step S5, the data of the inertial sensor may not only calculate the angle, but also obtain the current speed from the gyroscope in the inertial sensor; in view of the zero drift characteristics of the gyroscope, zero calibration and zero drift removal of the gyroscope are required.
CN202111123803.2A 2021-09-24 2021-09-24 Video image stabilizing method based on triaxial holder Active CN113805611B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111123803.2A CN113805611B (en) 2021-09-24 2021-09-24 Video image stabilizing method based on triaxial holder

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111123803.2A CN113805611B (en) 2021-09-24 2021-09-24 Video image stabilizing method based on triaxial holder

Publications (2)

Publication Number Publication Date
CN113805611A CN113805611A (en) 2021-12-17
CN113805611B true CN113805611B (en) 2023-12-12

Family

ID=78896576

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111123803.2A Active CN113805611B (en) 2021-09-24 2021-09-24 Video image stabilizing method based on triaxial holder

Country Status (1)

Country Link
CN (1) CN113805611B (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114515228B (en) * 2022-03-11 2023-05-23 上海新纪元机器人有限公司 Active vibration reduction method and system and active vibration reduction stretcher
CN114604439B (en) * 2022-03-23 2022-10-18 北京科技大学 Aerial photography video image stabilization system for flapping wing flying robot
CN114815583B (en) * 2022-03-28 2024-08-20 河南科技大学 Image stabilizing method of vehicle-mounted strawberry picking robot
CN115174610A (en) * 2022-05-31 2022-10-11 亿航智能设备(广州)有限公司 Aircraft and external environment monitoring system and firmware OTA method thereof
CN114900616B (en) * 2022-07-14 2022-10-28 四川三思德科技有限公司 Direct current motor driving device and method for photovoltaic camera
CN115420306A (en) * 2022-11-07 2022-12-02 浙江芯昇电子技术有限公司 Digital filtering mode-based gyroscope temperature drift compensation implementation method and system

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106679649A (en) * 2016-12-12 2017-05-17 浙江大学 Hand movement tracking system and tracking method
WO2018214071A1 (en) * 2017-05-24 2018-11-29 深圳市大疆创新科技有限公司 Method and device for controlling unmanned aerial vehicle, and unmanned aerial vehicle system
WO2018214157A1 (en) * 2017-05-26 2018-11-29 SZ DJI Technology Co., Ltd. Method and system for motion camera with embedded gimbal
CN109564433A (en) * 2016-11-02 2019-04-02 深圳市大疆创新科技有限公司 The system and method that height for loose impediment controls
CN113365043A (en) * 2021-06-02 2021-09-07 北京理工大学 Variable-scale panoramic imaging synchronous switching reflector device and panoramic expansion method
CN113359867A (en) * 2021-06-07 2021-09-07 合肥工业大学 Unmanned aerial vehicle self-stabilizing cradle head and control method

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109564433A (en) * 2016-11-02 2019-04-02 深圳市大疆创新科技有限公司 The system and method that height for loose impediment controls
CN106679649A (en) * 2016-12-12 2017-05-17 浙江大学 Hand movement tracking system and tracking method
WO2018214071A1 (en) * 2017-05-24 2018-11-29 深圳市大疆创新科技有限公司 Method and device for controlling unmanned aerial vehicle, and unmanned aerial vehicle system
WO2018214157A1 (en) * 2017-05-26 2018-11-29 SZ DJI Technology Co., Ltd. Method and system for motion camera with embedded gimbal
CN113365043A (en) * 2021-06-02 2021-09-07 北京理工大学 Variable-scale panoramic imaging synchronous switching reflector device and panoramic expansion method
CN113359867A (en) * 2021-06-07 2021-09-07 合肥工业大学 Unmanned aerial vehicle self-stabilizing cradle head and control method

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
一种四旋翼姿态解算与控制优化方法设计分析;江杰;王康;李刚;;计算机仿真(第11期);全文 *
基于信息融合的四旋翼飞行器的姿态解算;黄艳国;樊云东;陈自如;;计算机仿真(第09期);全文 *

Also Published As

Publication number Publication date
CN113805611A (en) 2021-12-17

Similar Documents

Publication Publication Date Title
CN113805611B (en) Video image stabilizing method based on triaxial holder
WO2018184467A1 (en) Method and device for detecting posture of ball head
CN105116926B (en) Cloud platform control method and device
WO2019223271A1 (en) Correction method and device for yaw of aircraft, and aircraft
CN106200693B (en) The holder real-time control system and control method of land investigation small drone
US10659695B2 (en) Gimbal control method, gimbal control system and gimbal device
CN107607113B (en) Method for measuring inclination angles of two-axis attitude
CN104811588B (en) A kind of boat-carrying based on gyroscope is surely as control method
WO2021027638A1 (en) Yaw angle fusion method and apparatus, and aerial vehicle
US11669109B2 (en) Method and apparatus for yaw fusion and aircraft
CN111522352B (en) Design method of single-parameter active disturbance rejection attitude controller of multi-rotor aircraft
WO2018191964A1 (en) Camera mount control method, and camera mount
CN110873563B (en) Cloud deck attitude estimation method and device
WO2021037047A1 (en) Yaw angle correction method and apparatus for aircraft, and aircraft
CN106248082B (en) A kind of aircraft autonomous navigation system and air navigation aid
JP4775296B2 (en) Imaging space stabilization device and subject tracking device
CN110986928A (en) Real-time drift correction method for triaxial gyroscope of photoelectric pod
Mansur et al. Deploying Complementary filter to avert gimbal lock in drones using Quaternion angles
CN117235412B (en) Post-processing system for photoelectric pod geographic tracking deviation angle
CN114510065A (en) Ground target tracking control method for multi-rotor unmanned aerial vehicle
CN110530400A (en) Gyroscopic drift modification method, device, photoelectric nacelle and aircraft
JP5888115B2 (en) TRACKING DEVICE AND TRACKING METHOD
CN108181919B (en) Small-sized transporter attitude control method based on Kalman filtering
CN109674480A (en) A kind of human motion attitude algorithm method based on improvement complementary filter
CN109788200B (en) Camera stability control method based on predictive analysis

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