Voice coil motor control method, device and system and shooting equipment

文档序号:1849359 发布日期:2021-11-16 浏览:18次 中文

阅读说明:本技术 音圈电机控制方法、装置、系统及拍摄设备 (Voice coil motor control method, device and system and shooting equipment ) 是由 向贤宝 蔡宾 陈斌 王海波 丁宁 于 2021-07-13 设计创作,主要内容包括:本发明属于相机镜头自动控制技术领域,公开了一种音圈电机控制方法、装置、系统及拍摄设备。所述方法包括:接收上位机下发的动作指令;根据所述动作指令,解析得到目标位置;根据所述目标位置,通过控制算法生成音圈电机驱动信号;将所述音圈电机驱动信号发送至所述音圈电机驱动芯片,以使所述音圈电机驱动芯片驱动所述音圈电机的动子运动并带动镜片移动,从而实现相机镜头的快速变焦和聚焦;接收位置检测装置反馈的实时位置信号;根据所述线圈动子实时位置信号,更新所述驱动信号,以完成对所述音圈电机的闭环控制。本发明通过模糊PID控制,提高了音圈电机移动的速度和到达目标位置的准确性。(The invention belongs to the technical field of automatic control of camera lenses and discloses a voice coil motor control method, a voice coil motor control device, a voice coil motor control system and shooting equipment. The method comprises the following steps: receiving an action instruction sent by an upper computer; analyzing to obtain a target position according to the action instruction; generating a voice coil motor driving signal through a control algorithm according to the target position; sending the voice coil motor driving signal to the voice coil motor driving chip so that the voice coil motor driving chip drives a rotor of the voice coil motor to move and drives a lens to move, and therefore the camera lens is quickly zoomed and focused; receiving a real-time position signal fed back by a position detection device; and updating the driving signal according to the real-time position signal of the coil rotor so as to complete the closed-loop control of the voice coil motor. According to the invention, through fuzzy PID control, the moving speed of the voice coil motor and the accuracy of reaching the target position are improved.)

1. The voice coil motor control method is characterized by being applied to a voice coil motor control device, wherein the voice coil motor control device is connected with an upper computer, the output end of the voice coil motor control device is connected with the input end of a voice coil motor driving chip, the input end of the voice coil motor control device is connected with a position detection device, the output end of the voice coil motor driving chip is connected with a coil of a voice coil motor, a rotor of the voice coil motor is provided with a lens, and the position detection device is installed on the voice coil motor; the voice coil motor control method comprises the following steps:

receiving an action instruction sent by an upper computer;

analyzing to obtain a target position instruction according to the action instruction;

generating a driving signal according to the target position instruction;

sending the driving signal to the voice coil motor driving chip so that the voice coil motor driving chip drives a rotor of the voice coil motor to move and drives a lens to move;

receiving a real-time position signal fed back by a position detection device;

and updating the driving signal according to the real-time position signal so as to realize the closed-loop control of the voice coil motor.

2. The voice coil motor control method of claim 1, wherein the updating the driving signal according to the real-time position signal comprises:

obtaining a position deviation and an error change rate according to the target position instruction and the real-time position signal;

performing PID calculation according to the position deviation and the error change rate to obtain a calculation result;

determining an update drive signal according to the calculation result;

and updating the driving signal according to the updating driving signal.

3. The voice coil motor control method of claim 2, wherein the performing PID calculations based on the position deviation and the error rate of change to obtain a calculation result comprises:

obtaining a first calculation result according to the real-time position signal and a first PID algorithm;

and obtaining a second calculation result according to the real-time position signal, the first calculation result and a second PID algorithm.

4. The voice coil motor control method of claim 3, wherein said deriving a first calculation based on the real-time position signal and a first PID algorithm comprises:

obtaining a position deviation according to the real-time position signal and the target position instruction;

and calculating the position deviation through the first PID algorithm to obtain a first calculation result.

5. The voice coil motor control method of claim 3, wherein obtaining a second calculation result based on the real-time position signal, the first calculation result, and a second PID algorithm comprises:

obtaining a speed deviation according to the real-time position signal and the first calculation result;

and calculating the speed deviation through a second PID algorithm to obtain a second calculation result.

6. The voice coil motor control method of claim 5, wherein prior to the step of calculating the speed deviation by a second PID algorithm to obtain a second calculation, the method further comprises:

obtaining the error change rate according to the speed deviation;

and obtaining a PID coefficient according to the speed deviation and the error change rate, wherein the PID coefficient is a calculation result of the second PID algorithm.

7. A voice coil motor control apparatus, comprising: the serial port module and the control module are connected with each other;

the serial port module is used for receiving an action instruction sent by the upper computer;

the control module is used for analyzing to obtain a target position instruction according to the action instruction and generating a driving signal according to the target position instruction;

the control module is further used for sending the driving signal to the voice coil motor driving chip so that the voice coil motor driving chip drives a rotor of the voice coil motor to move and drives the lens to move;

and the control module is also used for receiving a real-time position signal fed back by the position detection device and updating the driving signal according to the real-time position signal so as to realize closed-loop control on the voice coil motor.

8. A voice coil motor control system, comprising: the voice coil motor control system comprises a voice coil motor control device, an upper computer, a voice coil motor driving chip, a voice coil motor, a lens and a position detection device, wherein the voice coil motor control device comprises a serial port module and a control module, and the voice coil motor control system can realize the steps of the voice coil motor control method according to any one of claims 1 to 6.

9. The voice coil motor control system according to claim 8, wherein a serial port module of the voice coil motor control device is connected to the host computer, an output terminal of a control module of the voice coil motor control device is connected to an input terminal of the voice coil motor driver chip, an input terminal of the control module of the voice coil motor control device is connected to the position detection device, an output terminal of the voice coil motor driver chip is connected to a mover of the voice coil motor, a mirror is mounted on the mover of the voice coil motor, and the position detection device is mounted on the voice coil motor.

10. A photographing apparatus characterized by comprising the voice coil motor control system according to any one of claims 8 to 9.

Technical Field

The invention relates to the field of automatic control of camera lenses, in particular to a voice coil motor control method, a voice coil motor control device, a voice coil motor control system and shooting equipment.

Background

The traditional lens focusing is controlled by a stepping motor or a direct current motor, the time consumption is long, the speed is low, and the motor has the possibility of gaps, elastic deformation, friction damping and the like in the transmission process, so that the reduction and the loss of the rigidity and the response characteristic of equipment are caused. When the lens is focused, the traditional control method is difficult to ensure that the camera lens is controlled quickly and accurately.

The above is only for the purpose of assisting understanding of the technical aspects of the present invention, and does not represent an admission that the above is prior art.

Disclosure of Invention

The invention mainly aims to provide a voice coil motor control method, a voice coil motor control device, a voice coil motor control system and shooting equipment, and aims to solve the technical problems that in the prior art, a lens is low in action speed and inaccurate in position.

In order to achieve the above object, the present invention provides a voice coil motor control method, which is applied to a voice coil motor control device, wherein the voice coil motor control device is connected to an upper computer, an output end of the voice coil motor control device is connected to an input end of a voice coil motor driving chip, an input end of the voice coil motor control device is connected to a position detection device, an output end of the voice coil motor driving chip is connected to a coil of a voice coil motor, a mover of the voice coil motor is loaded with a lens, and the position detection device is installed on the voice coil motor; the voice coil motor control method comprises the following steps:

receiving an action instruction sent by an upper computer;

analyzing to obtain a target position instruction according to the action instruction;

generating a driving signal according to the target position instruction;

sending the driving signal to the voice coil motor driving chip so that the voice coil motor driving chip drives a rotor of the voice coil motor to move and drives a lens to move;

receiving a real-time position signal fed back by a position detection device;

and updating the driving signal according to the real-time position signal so as to realize the closed-loop control of the voice coil motor.

Optionally, the updating the driving signal according to the real-time position signal includes:

obtaining a position deviation and an error change rate according to the target position instruction and the real-time position signal;

performing PID calculation according to the position deviation and the error change rate to obtain a calculation result;

determining an update drive signal according to the calculation result;

and updating the driving signal according to the updating driving signal.

Optionally, the performing PID calculation according to the position deviation and the error change rate to obtain a calculation result includes:

obtaining a first calculation result according to the real-time position signal and a first PID algorithm;

and obtaining a second calculation result according to the real-time position signal, the first calculation result and a second PID algorithm.

Optionally, the obtaining a first calculation result according to the real-time position signal and a first PID algorithm includes:

obtaining a position deviation according to the real-time position signal and the target position instruction;

and calculating the position deviation through the first PID algorithm to obtain a first calculation result.

Optionally, the obtaining a second calculation result according to the real-time position signal, the first calculation result, and a second PID algorithm includes:

obtaining a speed deviation according to the real-time position signal and the first calculation result;

and calculating the speed deviation through a second PID algorithm to obtain a second calculation result.

Optionally, before the step of calculating the speed deviation by the second PID algorithm to obtain the second calculation result, the method further includes:

obtaining the error change rate according to the speed deviation;

and obtaining a PID coefficient according to the speed deviation and the error change rate, wherein the PID coefficient is a calculation result of the second PID algorithm.

In addition, in order to achieve the above object, the present invention further provides a voice coil motor control apparatus, including: the serial port module and the control module are connected with each other;

the serial port module is used for receiving an action instruction sent by the upper computer;

the control module is used for analyzing to obtain a target position instruction according to the action instruction and generating a driving signal according to the target position instruction;

the control module is further used for sending the driving signal to the voice coil motor driving chip so that the voice coil motor driving chip drives a rotor of the voice coil motor to move and drives the lens to move;

the control module is also used for feeding back a real-time position signal by the position detection device, and updating the driving signal according to the real-time position signal so as to realize the closed-loop control of the voice coil motor.

In addition, in order to achieve the above object, the present invention further provides a voice coil motor control system, including: the voice coil motor control device comprises a serial port module and a control module, and the voice coil motor control system can realize the steps of the voice coil motor control method.

Optionally, a serial port module of the voice coil motor control device is connected to the upper computer, an output end of a control module of the voice coil motor control device is connected to an input end of the voice coil motor driving chip, an input end of the control module of the voice coil motor control device is connected to the position detection device, an output end of the voice coil motor driving chip is connected to a coil of the voice coil motor, a lens is mounted on the coil of the voice coil motor, and the position detection device is mounted on the voice coil motor.

In addition, in order to achieve the above object, the present invention also proposes a photographing apparatus including the voice coil motor control system as described above.

The voice coil motor control method provided by the invention receives an action instruction sent by an upper computer; analyzing to obtain a target position instruction according to the action instruction; generating a driving signal according to the target position instruction; sending the driving signal to the voice coil motor driving chip so that the voice coil motor driving chip drives a rotor of the voice coil motor to move and drives a lens to move; receiving a real-time position signal fed back by a position detection device; and updating the driving signal according to the real-time position signal so as to realize the closed-loop control of the voice coil motor. Thereby constantly adjusting voice coil motor's drive signal, making the displacement of camera lens more accurate.

Drawings

In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the structures shown in the drawings without creative efforts.

Fig. 1 is a schematic flowchart of a voice coil motor control method according to a first embodiment of the present invention;

FIG. 2 is a flowchart illustrating a voice coil motor control method according to a second embodiment of the present invention;

FIG. 3 is a flowchart illustrating a voice coil motor control method according to a third embodiment of the present invention;

FIG. 4 is a flowchart illustrating a voice coil motor control method according to a fourth embodiment of the present invention;

FIG. 5 is a control block diagram of a voice coil motor control method according to an embodiment of the present invention;

FIG. 6 is a block diagram of a mathematical model of an embodiment of a voice coil motor control method according to the present invention;

FIG. 7 is a schematic structural diagram of a voice coil motor control apparatus according to an embodiment of the present invention;

fig. 8 is a schematic structural diagram of a voice coil motor control system according to an embodiment of the present invention.

The reference numbers illustrate:

reference numerals Name (R) Reference numerals Name (R)
100 Voice coil motor control device 30 Voice coil motor
110 Serial port module 40 Lens
120 Control module 50 Position detecting device
20 Voice coil motor driving chip 00 Upper computer

The implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.

Detailed Description

It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.

The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.

It should be noted that all the directional indicators (such as up, down, left, right, front, and rear … …) in the embodiment of the present invention are only used to explain the relative position relationship between the components, the movement situation, etc. in a specific posture (as shown in the drawing), and if the specific posture is changed, the directional indicator is changed accordingly.

In addition, the descriptions related to "first", "second", etc. in the present invention are for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one such feature. In addition, the technical solutions in the embodiments may be combined with each other, but it must be based on the realization of those skilled in the art, and when the technical solutions are contradictory or cannot be realized, such a combination should be considered to be absent and not within the protection scope of the present invention.

The present invention provides a method for controlling a voice coil motor, and referring to fig. 1, fig. 1 is a schematic flow chart of a first embodiment of a method for controlling a voice coil motor according to the present invention.

In this embodiment, the voice coil motor control method is applied to a voice coil motor control device, the voice coil motor control device is connected to an upper computer, an output end of the voice coil motor control device is connected to an input end of a voice coil motor driving chip, an input end of the voice coil motor control device is connected to a position detection device, an output end of the voice coil motor driving chip is connected to a coil of a voice coil motor, a rotor of the voice coil motor is provided with a lens, and the position detection device is mounted on the voice coil motor; the voice coil motor control method comprises the following steps:

step S100: and receiving an action instruction sent by the upper computer.

In this embodiment, the execution main body is a microprocessor at least including an internal timer, a digital-to-analog converter and an analog-to-digital converter, for example: STM32 singlechip. In specific implementation, the type of the microprocessor may be selected according to specific situations, which is not limited in this embodiment.

It can be understood that the upper computer is a computer capable of burning programs, for example: notebook computers and desktop computers, and operators can write related codes in an upper computer. The communication mode of the upper computer and the execution main body microprocessor is serial communication. And the action command comprises information of a target motion position of a coil of the voice coil motor.

And analyzing to obtain a target position instruction according to the action instruction.

It is understood that the target position command refers to a target point that the mover of the voice coil motor needs to reach. The program burned by the microprocessor contains an algorithm for analyzing the action command, and the action command can be analyzed and calculated to obtain a corresponding target position command.

Step S300: and generating a driving signal according to the target position instruction.

It should be noted that the driving signal is a signal which is generated by analyzing the target position according to an action command issued by the upper computer and can enable the driver to drive the motor to move to the target position. The driving signal comprises two paths of PWM waves with the same frequency and different duty ratios, which are generated by a timer inside the microprocessor, a selection signal and a voltage threshold value generated by an internal digital-to-analog converter.

Step S400: and sending the driving signal to the voice coil motor driving chip so that the voice coil motor driving chip drives the rotor of the voice coil motor to move and drives the lens to move.

It can be understood that, after the voice coil motor driving chip receives the driving signal, the driving signal can be converted into an electrical signal required for driving the voice coil motor to move to the target movement position, and the electrical signal is output to the voice coil motor; since the lens is arranged on the mover of the voice coil motor, when the coil of the voice coil motor moves, the lens is carried along with the coil of the voice coil motor.

In this embodiment, the voice coil motor is driven to operate according to the selected PWM wave and the voltage threshold, and the moving direction and the driving force of the voice coil motor are changed, so that the voice coil motor drives the mirror to move to the target position.

It should be noted that the transfer function between the armature voltage ua and the voice coil motor displacement x is:

in the formula: kS=BσL;

x (S) -Voice coil Motor Displacement;

u(s) -armature voltage;

b sigma is the magnetic induction intensity of the space where the coil is located;

l-the average effective length of each turn of the coil conductor in the magnetic field;

v is the speed (m/s) at which the armature cuts the magnetic lines;

m-total mass of the mover part;

mu-coefficient of kinetic friction;

Ra-the resistance of the armature circuit;

La-the inductance of the armature winding;

step S500: and receiving the real-time position signal fed back by the position detection device.

It should be noted that the position detector is a giant magnetoresistance detector, and the focusing giant magnetoresistance detector detects the magnetic pole strength through a wheatstone bridge structure and then calculates the displacement through a voltage signal.

Step S600: and updating the driving signal according to the real-time position signal so as to realize the closed-loop control of the voice coil motor.

It can be understood that the real-time position signal is used as a feedback signal to timely and accurately feed back the action of the voice coil motor to the execution main body, and at this time, the execution main body can timely adjust the difference value between the fed-back real-time position signal and the target motion position and update the driving signal after calculating through a fuzzy PID algorithm, so that the motion position of the voice coil motor approaches to the target motion position.

The embodiment provides a voice coil motor control method, which includes: receiving an action instruction sent by an upper computer; analyzing to obtain a target position instruction according to the action instruction; generating a driving signal according to the target position instruction; sending the driving signal to the voice coil motor driving chip so that the voice coil motor driving chip drives a rotor of the voice coil motor to move and drives a lens to move; receiving a real-time position signal fed back by a position detection device; and updating the driving signal according to the real-time position signal so as to complete the closed-loop control of the voice coil motor. According to the method, the driving signal is updated according to the current movement position of the voice coil motor, the movement direction and the driving force of the voice coil motor are changed, and the lens group can move quickly and accurately.

Further, a second embodiment of the voice coil motor control method of the present invention is proposed based on the first embodiment of the voice coil motor control method of the present invention. Referring to fig. 2, fig. 2 is a flowchart illustrating a voice coil motor control method according to a second embodiment of the present invention.

The step S600 includes:

step S610: and obtaining the position deviation and the error change rate according to the target position instruction and the real-time position signal.

It is understood that the position deviation reflects a difference between a current moving position of the voice coil motor and a target position, and the error change rate reflects a change rate of the difference between the current moving position of the voice coil motor and the target position.

Step S620: and performing PID calculation according to the position deviation and the error change rate to obtain a calculation result.

It should be noted that, a program burned in the microprocessor has a module responsible for PID calculation, and a PID controller can be divided in the program of the microprocessor for PID calculation.

Step S630: and determining an update drive signal according to the calculation result.

It can be understood that, due to the variation of the deviation between the real-time position signal and the target position command, the executing subject needs to generate a new driving signal through the fuzzy PID algorithm according to the real-time position signal so as to continuously reduce the deviation.

Step S640: and updating the driving signal according to the updating driving signal.

It can be understood that the update driving signal is a driving signal that can reduce the deviation between the real-time position signal and the target position command, when the update driving signal is generated, the original driving signal is overwritten, and the voice coil motor driving chip drives the voice coil motor by using the new driving signal.

In the embodiment, the position deviation and the error change rate are obtained, the fuzzy PID calculation is carried out to obtain a new driving signal, and the new driving signal is used for driving the voice coil motor, so that the lens is driven to move to the target position, the position deviation is continuously reduced, and the lens is more accurate in movement.

Further, a third embodiment of the method for controlling a voice coil motor according to the present invention is provided based on the first embodiment or the second embodiment, and referring to fig. 3, fig. 3 is a flowchart of the third embodiment of the method for controlling a voice coil motor according to the present invention.

In this embodiment, the step S620 includes:

step S621: and obtaining a first calculation result according to the real-time position signal and a first PID algorithm.

It should be noted that the first PID algorithm is stored in the microprocessor, and a program of the first PID algorithm is regarded as the first PID controller, and the first calculation result is obtained by the first PID controller.

It can be understood that the PID parameters in the first PID algorithm are entered in advance by the operator when programming, and are three preset parameters, respectively: a first proportional coefficient, a first integral coefficient, and a first differential coefficient.

Step S622: and obtaining a second calculation result according to the real-time position signal, the first calculation result and a second PID algorithm.

It should be noted that the second PID algorithm is stored in the microprocessor, and a program of the second PID algorithm is regarded as a second PID controller, and the second calculation result is obtained by the second PID controller.

It will be appreciated that the PID parameters in the second PID algorithm are determined by the fuzzy controller in the microprocessor based on two parameters: the speed of a rotor of the voice coil motor is subtracted from a first calculation result to obtain a difference value, and the variation rate of the difference value is obtained; the fuzzy controller obtains three parameters in the second PID algorithm according to the two parameters, wherein the three parameters are respectively as follows: a second proportional coefficient, a second integral coefficient, and a second differential coefficient.

According to the embodiment, the real-time position signal is processed to obtain the first calculation result, then the PID calculation is performed for the second time according to the speed signal of the rotor of the voice coil motor to obtain the second calculation result, and through the two PID calculations, the accuracy of the position and the speed of the rotor of the voice coil motor can be guaranteed, and the precision and the robustness of the lens movement are improved.

Further, a fourth embodiment of the method for controlling a voice coil motor according to the present invention is provided based on the first embodiment, the second embodiment and the third embodiment, and referring to fig. 4, fig. 4 is a flowchart of the fourth embodiment of the method for controlling a voice coil motor according to the present invention.

In this embodiment, the step S621 includes:

step S6211: and obtaining a position deviation according to the real-time position signal and the target position instruction.

It should be noted that the position deviation makes the input quantity of the first PID algorithm obtained by subtracting the target position command from the real-time position signal.

Step S6212: and calculating the position deviation through the first PID algorithm to obtain a first calculation result.

It should be noted that the first calculation result is a voltage signal that can represent the moving speed of the voice coil motor.

Further, the step S622 includes:

step S6221: and obtaining a speed deviation according to the real-time position signal and the first calculation result.

It should be noted that the speed deviation is obtained by subtracting the first calculation result from the differential of the real-time position signal.

Step S6222: and calculating the speed deviation through a second PID algorithm to obtain a second calculation result.

It should be noted that the second calculation result is a voltage signal, and the voltage signal may be used to generate an update driving signal and may be directly sent to the voice coil motor driving chip, so that the voice coil motor driving chip drives the voice coil motor to continue to operate.

Further, before the step of calculating the speed deviation by the second PID algorithm to obtain the second calculation result, the method further includes:

and obtaining the error change rate according to the speed deviation.

It will be appreciated that the error rate of change is the result of differentiating the speed deviation with respect to time.

And obtaining a PID coefficient according to the speed deviation and the error change rate, and obtaining a calculation result of a second PID algorithm according to the PID coefficient.

It should be noted that the program for calculating the PID coefficients is stored in the microprocessor, and the program for calculating the PID coefficients is defined as a fuzzy controller, and the PID coefficients are obtained by the fuzzy controller based on the error change rate and the speed deviation.

It can be understood that the PID parameters in the second PID algorithm are three preset parameters, which are respectively: a second proportional coefficient, a second integral coefficient, and a second differential coefficient.

Referring to fig. 5 and 6, fig. 5 is a control block diagram of an embodiment of a voice coil motor control method according to the present invention, and fig. 6 is a mathematical model block diagram of an embodiment of a voice coil motor control method according to the present invention.

The first PID controller, the second PID controller, the fuzzy controller, the voice coil motor driving chip, the voice coil motor and the position detection device form a control system.

The second PID controller, the voice coil motor driving chip and the position detection device form a PID controlled speed ring, the speed ring takes the differential of the voice coil motor displacement as a feedback quantity, and the displacement quantity is the real-time position signal.

The second PID controller is configured to execute a second PID calculation, and it should be noted that a transfer function of the second PID calculation is:

in the formula, KvpIs a second scaling factor, TviIs the second integral coefficient, TvDIs the second differential coefficient.

The first PID controller, the second PID controller, the voice coil motor driving chip, the voice coil motor and the position detection device form a position ring controlled by PID, the position ring takes the voice coil motor displacement as a feedback quantity, and the displacement is the rotor real-time position signal of the voice coil motor.

The first PID controller is configured to perform a first PID calculation, where a transfer function of the first PID calculation is:

in the formula, KpIs a first scale factor, TiIs a first integral coefficient, TDIs the first differential coefficient.

And the fuzzy controller and the second PID controller form a PID controlled feedforward loop for obtaining the coefficient calculated by the second PID in real time.

The voice coil motor detects the position of a rotor of the voice coil motor in real time through a position detection device, the position is differed with a target position instruction to obtain deviation, the deviation enters a first PID controller, the difference is made between the result calculated by the first PID controller and the derivative of the position, namely the real-time speed value of the rotor of the voice coil motor, and then a fuzzy controller obtains the most appropriate PID coefficient, namely K at the moment according to the deviation and the error change rateVP、KVI、KVDAnd the result of the PID calculation is output by the singlechip and then is sent to a voice coil motor driving chip, so that the voice coil motor is driven to act.

In addition, referring to fig. 7, an embodiment of the present invention further provides a voice coil motor control apparatus, where the voice coil motor control apparatus includes: a serial port module 110 and a control module 120 connected with each other.

The serial port module 110 is configured to receive an action instruction issued by an upper computer.

It should be noted that the serial port module 110 is a chip capable of implementing serial port communication, for example: CH340, may implement debug and communication functions. In specific implementation, the type may be selected according to actual situations, and this embodiment does not limit this.

The control module 120 is configured to analyze the action instruction to obtain a target position instruction, and generate a driving signal according to the target position instruction.

It should be noted that the control module 120 is a microprocessor at least including an internal timer, a digital-to-analog converter and an analog-to-digital converter, for example: STM32 singlechip. In specific implementation, the type of the microprocessor may be selected according to specific situations, which is not limited in this embodiment.

It can be understood that the upper computer is a computer capable of burning programs, for example: desktop computers and notebook computers, and operators can write related codes in an upper computer. The communication mode of the upper computer and the execution main body microprocessor is serial communication. And the information contained in the action command is the target motion position of a rotor of the voice coil motor.

It should be noted that the driving signal is a signal which is generated by analyzing the target position according to an action command issued by the upper computer and can enable the driver to drive the motor to move to the target position. The driving signal comprises two paths of PWM waves with the same frequency and different duty ratios, which are generated by a timer inside the microprocessor, a selection signal and a voltage threshold value generated by an internal digital-to-analog converter.

The control module 120 is further configured to send the driving signal to the voice coil motor driving chip, so that the voice coil motor driving chip drives the rotor of the voice coil motor to move and drives the lens to move.

It can be understood that, after the voice coil motor driving chip receives the driving signal, the driving signal can be analyzed into an electrical signal required for driving the voice coil motor to move to the target movement position, and the electrical signal is output to the voice coil motor; since the mirror is disposed on the coil of the voice coil motor, when the coil of the voice coil motor moves, the mirror is carried along with the coil.

The control module 120 is further configured to update the driving signal according to a real-time position signal fed back by the position detection device, so as to implement closed-loop control on the voice coil motor.

It should be noted that the position detector is a giant magnetoresistance detector, and the focusing giant magnetoresistance detector detects the magnetic pole strength through a wheatstone bridge structure and then calculates the displacement through a voltage signal.

It can be understood that the real-time position signal is used as a feedback signal to timely and accurately transmit the action of the voice coil motor back to the execution main body, and at this time, the execution main body can timely adjust and update the driving signal according to the difference between the fed-back real-time position signal and the target motion position, so that the motion position of the voice coil motor approaches to the target motion position.

This embodiment proposes a voice coil motor control device, the voice coil motor control includes serial module 110 and control module 120 of interconnect: the serial port module 110 is configured to receive an action instruction issued by an upper computer; the control module 120 is configured to obtain a target position instruction according to the action instruction, and generate a driving signal according to the target position instruction; the control module 120 is further configured to send the driving signal to a voice coil motor driving chip, so that the voice coil motor driving chip drives the voice coil motor to move and drives the lens to move; the control module 120 is further configured to receive a real-time position signal transmitted by a position detection device, and update the driving signal according to the real-time position signal, so as to complete closed-loop control of the voice coil motor. The method updates the driving signal according to the current movement position of the voice coil motor, changes the movement direction and the driving force of the voice coil motor, and realizes the quick and accurate movement of the lens.

In addition, referring to fig. 8, an embodiment of the present invention further provides a voice coil motor control system, where the voice coil motor control system includes: the control method of the voice coil motor 30 comprises a voice coil motor control device 100, an upper computer 00, a voice coil motor driving chip 20, a voice coil motor 30, a lens 40 and a position detection device 50, wherein the voice coil motor control device 100 comprises a serial module and a control module, and the voice coil motor control system can realize the steps of the control method of the voice coil motor 30 as claimed in the claims.

Further, the serial port module of the voice coil motor control device 100 is connected to the upper computer 00, the output end of the control module of the voice coil motor control device 100 is connected to the input end of the voice coil motor driving chip 20, the input end of the control module of the voice coil motor control device 100 is connected to the position detection device 50, the output end of the voice coil motor driving chip 20 is connected to the coil of the voice coil motor 30, the coil of the voice coil motor 30 is provided with the lens 40, and the position detection device 50 is installed on the voice coil motor 30.

Since the voice coil motor control device adopts all the technical solutions of all the embodiments, at least all the beneficial effects brought by the technical solutions of the embodiments are achieved, and are not repeated herein.

In addition, the embodiment of the invention also provides shooting equipment, and the shooting equipment comprises the voice coil motor control system.

Since all technical solutions of all the above embodiments of the shooting device are provided, at least all beneficial effects brought by the technical solutions of the above embodiments are provided, and are not described in detail herein.

It should be understood that the above is only an example, and the technical solution of the present invention is not limited in any way, and in a specific application, a person skilled in the art may set the technical solution as needed, and the present invention is not limited thereto.

It should be noted that the above-described work flows are only exemplary, and do not limit the scope of the present invention, and in practical applications, a person skilled in the art may select some or all of them to achieve the purpose of the solution of the embodiment according to actual needs, and the present invention is not limited herein.

In addition, the technical details that are not described in detail in this embodiment may be referred to a voice coil motor control method provided in any embodiment of the present invention, and are not described herein again.

Further, it is to be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or system that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or system. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or system that comprises the element.

The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.

Through the above description of the embodiments, those skilled in the art will clearly understand that the method of the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but in many cases, the former is a better implementation manner. Based on such understanding, the technical solution of the present invention or portions thereof that contribute to the prior art may be embodied in the form of a software product, where the computer software product is stored in a shooting device (e.g. a Read Only Memory (ROM)/RAM, a magnetic disk, an optical disk), and includes several instructions for enabling a terminal device (e.g. a mobile phone, a computer, a server, or a network device) to execute the method according to the embodiments of the present invention.

The above description is only a preferred embodiment of the present invention, and not intended to limit the scope of the present invention, and all modifications of equivalent structures and equivalent processes, which are made by using the contents of the present specification and the accompanying drawings, or directly or indirectly applied to other related technical fields, are included in the scope of the present invention.

18页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种电机驱动器

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!