Motor drive circuit, motor system, motor control method, and electronic device

By introducing high-frequency PWM current into the motor drive circuit and adjusting the duty cycle, frequency, and amplitude of the PWM voltage, the static friction problem during motor startup was solved, thereby increasing motor thrust with low power consumption and ensuring efficient operation of zoom and image stabilization functions.

CN119254057BActive Publication Date: 2026-02-06HONOR DEVICE CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202410231458.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-02-29
Publication Date
2026-02-06
Estimated Expiration
2044-02-29

Smart Images

  • Figure CN119254057B_ABST
    Figure CN119254057B_ABST
Patent Text Reader

Abstract

Embodiments of the present application provide a motor driving circuit, a motor system, a motor control method and an electronic device. The motor system can be applied to a camera module and used for zoom and / or anti-shake functions of the camera module. The motor system can include a motor driving circuit (driver IC) and a motor connected thereto. The driver IC introduces a high-frequency PWM wave circuit for outputting a high-frequency PWM current to the motor to improve the instantaneous thrust of the motor without increasing power consumption.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of electronics, and in particular to a motor driving circuit, a motor system, a motor control method and an electronic device. BACKGROUND

[0002] With the development of electronic technology, electronic devices such as mobile phones and tablet computers are generally equipped with cameras. As an important component of the camera, the motor can be used to push the lens to move to change the focal length, thereby realizing the zoom and anti-shake functions in terminal image technology. The motor thrust improvement has always been a problem for technical personnel. However, the internal space of mobile phones and other electronic devices is very limited, and it is difficult to increase the motor size to improve the motor thrust. SUMMARY

[0003] In a first aspect, an embodiment of the present application provides a motor driving circuit, which can include a conversion circuit and a first pulse width modulation (PWM) wave circuit. The conversion circuit is coupled to the first PWM wave circuit. Wherein:

[0004] The conversion circuit is also coupled to a power supply module (such as a power management circuit) of the motor driving circuit to receive a power supply voltage output by the power supply module. The conversion circuit can also be connected to a processor, such as an application processor (AP), for receiving a travel instruction from the processor, the travel instruction including a target position of the motor.

[0005] The conversion circuit can also be used to convert the power supply voltage into a first PWM voltage with a first frequency, a first amplitude and a first duty cycle according to a target travel of the motor, the target travel being determined by the conversion circuit according to the target position and an actual position of the motor.

[0006] The conversion circuit can also output the first PWM voltage to the first PWM wave circuit.

[0007] The first PWM wave circuit can be used to convert the first PWM voltage into a first PWM current. The frequency of the first PWM current is close to or equal to the first frequency, and the duty cycle of the first PWM current is close to or equal to the first duty cycle. Here, close to the frequency can mean that the difference between the frequency of the first PWM current and the frequency of the first PWM voltage is very small, for example, the frequency difference is within the order of hundreds of hertz (Hz). Close to the duty cycle can mean that the difference between the duty cycle of the first PWM current and the duty cycle of the first PWM voltage is very small, for example, the duty cycle difference is within 2%. In addition, the amplitude A i of the first PWM current is close to the amplitude A u of the first PWM voltage, and there is the following relationship: A i = A u / R, where R represents the resistance of the circuit, which can include the resistance of the load, such as the resistance of the VCM motor coil, and can also include the resistance of the transmission line of the circuit.

[0008] The first PWM wave circuit can also be connected to the motor for outputting a first PWM current to the motor to control the motor to generate a motor thrust.

[0009] The motor driving circuit provided by the first aspect improves the instantaneous thrust of the motor by introducing a high-frequency pulse width modulation (PWM) current to the motor to achieve fast overcoming of static friction when the motor starts without increasing power consumption.

[0010] In combination with the first aspect, in some embodiments, a correspondence between the duty cycle, amplitude or frequency of the first PWM voltage and the motor displacement can be used to record the motor travel when the third parameter takes different values while the other two parameters are fixed. The mapping relationship includes a first mapping relationship, a second mapping relationship and a third mapping relationship. The first mapping relationship can be used to record the respective motor displacements corresponding to different duty cycles of the first PWM voltage when the frequency and amplitude are fixed. The second mapping relationship can be used to record the respective motor displacements corresponding to different amplitudes of the first PWM voltage when the frequency and duty cycle are fixed. The third mapping relationship can be used to record the respective motor displacements corresponding to different frequencies of the first PWM voltage when the amplitude and duty cycle are fixed.

[0011] In combination with the first aspect, in some embodiments, the conversion circuit can be specifically configured to determine that the frequency of the first PWM voltage is fixed at a first frequency and the amplitude is fixed at a first amplitude, and determine that the target travel corresponds to a first duty cycle based on the first mapping relationship. The first mapping relationship records the respective motor travels corresponding to different duty cycles of the first PWM voltage when the frequency is fixed at the first frequency and the amplitude is fixed at a second amplitude, and the respective motor travels corresponding to different duty cycles include the target travel.

[0012] In combination with the first aspect, in some embodiments, the second mapping relationship records the respective motor travels corresponding to different amplitudes of the first PWM voltage when the frequency is fixed at the first frequency and the duty cycle is fixed at a first duty cycle, and the respective motor travels corresponding to different amplitudes include the target travel.

[0013] The conversion circuit can be specifically configured to determine that the frequency of the first PWM voltage is fixed at a first frequency and the duty cycle is fixed at a first duty cycle, and determine that the target travel corresponds to a first amplitude based on the second mapping relationship.

[0014] In combination with the first aspect, in some embodiments, the third mapping relationship records the respective motor travels corresponding to different frequencies of the first PWM voltage when the amplitude is fixed at a first amplitude and the duty cycle is fixed at a first duty cycle, and the respective motor travels corresponding to different frequencies include the target travel.

[0015] In conjunction with the first aspect, in some implementations, the conversion circuit may be specifically used to determine that the amplitude of the first PWM voltage is fixed as a first amplitude, the duty cycle is fixed as a first duty cycle, and to determine the frequency corresponding to the target stroke as a first frequency based on the third mapping relationship.

[0016] Furthermore, to reduce storage costs, a segment of data that is close to linear in the mapping relationship can be selected for storage, such as the correspondence between a duty cycle of 20% to 40% and the motor stroke. Moreover, this linear portion of the data can be expressed as a linear function, allowing only the linear function expression and its linear range to be recorded, thus significantly reducing data storage requirements.

[0017] In some embodiments, the duty cycle and motor stroke can have a linear relationship in the first mapping relationship.

[0018] In some embodiments, the amplitude and motor stroke in the second mapping relationship can exhibit a linear relationship.

[0019] In some embodiments, in the third mapping relationship, frequency and motor stroke can exhibit a linear relationship.

[0020] In conjunction with the first aspect, in some embodiments, the motor drive circuit may further include a control circuit. This control circuit is coupled to a conversion circuit and can be used to output a target stroke to the conversion circuit. The control circuit may also be coupled to a processor to receive a stroke command transmitted by the processor, the stroke command carrying the target position of the motor. The control circuit may also be coupled to a position detection circuit in the motor to receive the actual position of the motor mover transmitted by the position detection circuit, which detects the actual position of the motor mover. The target stroke can be determined based on the target position and the actual position of the motor mover; the closer the actual position is to the target position, the smaller the target stroke. Thus, by adding a feedback loop and a closed-loop control loop, unnecessary motion oscillations are eliminated, allowing the motor mover to move to the designated position more quickly.

[0021] In conjunction with the first aspect, in some embodiments, the conversion circuit may be specifically used to convert the target stroke into a first frequency, a first amplitude, and a first duty cycle using a proportional-integral-derivative (PID) control algorithm, and then generate a first PWM voltage based on the first frequency, the first amplitude, and the first duty cycle.

[0022] In conjunction with the first aspect, in some embodiments, the motor drive circuit may further include a voltage multiplier circuit. The input terminal of the voltage multiplier circuit is coupled to the conversion circuit, and the output terminal of the voltage multiplier circuit is coupled to the first PWM wave circuit. The voltage multiplier circuit is used to boost the first PWM voltage generated by the conversion circuit and then output it to the first PWM wave circuit to convert it into a first PWM current.

[0023] In some embodiments of the first aspect, the voltage doubling circuit can include a capacitor C1, a first unidirectional conducting device, a second unidirectional conducting device, and a switch S1, and a first input terminal, a second input terminal, a first output terminal, and a second output terminal. The first terminal of the capacitor C1 is coupled to the first input terminal, the second terminal of the capacitor C1 is coupled to the first output terminal, and the second output terminal is coupled to the second input terminal. One terminal of the first unidirectional conducting device is coupled to the second terminal of the capacitor C1, and the other terminal of the first unidirectional conducting device is coupled to the first movable terminal of the switch S1. One terminal of the second unidirectional conducting device is also coupled to the second terminal of the capacitor C1, and the other terminal of the second unidirectional conducting device is coupled to the second movable terminal of the switch S1. The immovable terminal of the switch S1 is coupled to the second input terminal. The conducting directions of the first unidirectional conducting device and the second unidirectional conducting device are opposite.

[0024] In some embodiments of the first aspect, the voltage doubling circuit is an n-stage voltage doubling circuit, where n is a positive integer and n≥2. The two terminals of the capacitor Cn in the n-th stage charge-discharge circuit are connected in parallel with the switch S1, and the switch S1 is used to adjust the voltage polarity of the output voltage of the voltage doubling circuit.

[0025] In the second aspect, an embodiment of the present application provides a motor system, which can include a motor driving circuit and a motor. The output circuit of the motor driving circuit is coupled to the motor, and the motor driving circuit can be the motor driving circuit described in the first aspect or any possible implementation manner of the first aspect.

[0026] In some embodiments of the second aspect, the motor system can further include a position detection circuit, and the motor driving circuit can further include a control circuit. The position detection circuit is coupled to the control circuit in the motor driving circuit, and the position detection circuit is used to detect the actual position of the motor mover and output the detected actual position to the control circuit.

[0027] In the third aspect, an embodiment of the present application provides an electronic device, which can include a motor system and a processor. The motor system can be the motor system described in the second aspect or any possible implementation manner of the second aspect. The processor is coupled to the motor driving circuit in the motor system, and the processor is used to transmit a stroke instruction to the motor driving circuit in the motor system, where the stroke instruction includes a target position of the motor.

[0028] In some embodiments of the third aspect, the motor system is arranged in a camera module of the electronic device.

[0029] In the fourth aspect, an embodiment of the present application provides a motor control method, which can be applied to an electronic device. The electronic device can be the electronic device described in the third aspect or any possible implementation manner of the third aspect.

[0030] The method provided in the fourth aspect can include: converting, by the electronic device, the target stroke of the motor into a first frequency, a first amplitude, and a first duty cycle; generating, by the electronic device, a first PWM voltage according to the first frequency, the first amplitude, and the first duty cycle; converting, by the electronic device, the first PWM voltage into a first PWM current; and outputting, by the electronic device, the first PWM current to the motor.

[0031] In combination with the fourth aspect, in some embodiments, before the electronic device converts the target stroke of the motor into the first frequency, the first amplitude, and the first duty cycle, the method can further include: detecting, by the electronic device, an operation of changing an optical zoom ratio of the camera module; and determining, by the electronic device, the target stroke according to the optical zoom ratio.

[0032] In combination with the fourth aspect, in some embodiments, the electronic device can store a first mapping relationship, which records motor strokes corresponding to different duty cycles of the first PWM voltage when the frequency of the first PWM voltage is fixed at the first frequency and the amplitude of the first PWM voltage is fixed at a second amplitude, the motor strokes including the target stroke. The electronic device can convert the target stroke of the motor into the first frequency, the first amplitude, and the first duty cycle, which can specifically include: determining, by the electronic device, that the frequency of the first PWM voltage is fixed at the first frequency and the amplitude of the first PWM voltage is fixed at the first amplitude, and determining, by the electronic device, that the duty cycle corresponding to the target stroke is the first duty cycle based on the first mapping relationship.

[0033] In combination with the fourth aspect, in some embodiments, the electronic device can store a second mapping relationship, which records motor strokes corresponding to different amplitudes of the first PWM voltage when the frequency of the first PWM voltage is fixed at the first frequency and the duty cycle of the first PWM voltage is fixed at the first duty cycle, the motor strokes including the target stroke. The electronic device can convert the target stroke of the motor into the first frequency, the first amplitude, and the first duty cycle, which can specifically include: determining, by the electronic device, that the frequency of the first PWM voltage is fixed at the first frequency and the duty cycle of the first PWM voltage is fixed at the first duty cycle, and determining, by the electronic device, that the amplitude corresponding to the target stroke is the first amplitude based on the second mapping relationship.

[0034] In combination with the fourth aspect, in some embodiments, the electronic device can store a third mapping relationship, which records motor strokes corresponding to different frequencies of the first PWM voltage when the amplitude of the first PWM voltage is fixed at the first amplitude and the duty cycle of the first PWM voltage is fixed at the first duty cycle, the motor strokes including the target stroke. The electronic device can convert the target stroke of the motor into the first frequency, the first amplitude, and the first duty cycle, which can specifically include: determining, by the electronic device, that the amplitude of the first PWM voltage is fixed at the first amplitude and the duty cycle of the first PWM voltage is fixed at the first duty cycle, and determining, by the electronic device, that the frequency corresponding to the target stroke is the first frequency based on the third mapping relationship.

[0035] In some embodiments, the electronic device converts the target stroke of the motor into the first frequency, the first amplitude, and the first duty cycle, which can include: the electronic device converts the target stroke into the first frequency, the first amplitude, and the first duty cycle through a PID control algorithm.

[0036] In some embodiments, the motor system can further include a position detection circuit and a control circuit. The method provided by the fourth aspect can further include: after the electronic device outputs the first PWM current to the motor, the electronic device determines whether the rotor of the motor is at the target position; if not, the electronic device determines a re-determined target stroke according to a position deviation between the actual position of the rotor of the motor and the target position, the electronic device converts the re-determined target stroke into a second frequency, a second amplitude, and a second duty cycle through a PID algorithm; the electronic device generates a second PWM voltage according to the second frequency, the second amplitude, and the second duty cycle; the electronic device converts the second PWM voltage into a second PWM current; and the electronic device outputs the second PWM current to the motor.

[0037] In the fifth aspect, the embodiments of the present application provide a computer readable storage medium, including a coded instruction sequence, when the coded instruction sequence is run on an electronic device, the coded instruction sequence causes the method described in the fourth aspect or any possible implementation manner of the fourth aspect to be executed. BRIEF DESCRIPTION OF DRAWINGS

[0038] Figure 1 A typical motor driving system is shown;

[0039] Figure 2 A motor system provided by the embodiments of the present application is shown;

[0040] Figure 3 A motor system provided by the embodiments of the present application is shown; Figure 2 The input and output of the high-frequency PWM wave circuit in the motor driving circuit shown;

[0041] Figure 4 The input and output of the high-frequency PWM wave circuit in the motor driving circuit shown; Figure 2 The waveform of the first PWM voltage input to the high-frequency PWM wave circuit in the motor driving circuit shown;

[0042] Figure 5 The waveform of the first PWM voltage input to the high-frequency PWM wave circuit in the motor driving circuit shown; Figure 2 The circuit composition of the high-frequency PWM wave circuit input to the high-frequency PWM wave circuit in the motor driving circuit shown;

[0043] Figure 6 The waveform of the first PWM current generated by the high-frequency PWM wave circuit when the frequency and amplitude of the first PWM voltage take fixed values and the duty cycle takes three different values (20%, 30%, and 40%) is shown;

[0044] Figure 7 Exemplary shows the corresponding motor stroke time curve when the duty cycle takes three different values (20%, 30%, 40%) in the case of the frequency and amplitude of the first PWM voltage taking fixed values;

[0045] Figure 8 Exemplary shows the corresponding curve of the duty cycle and the motor stroke in the case of fixed frequency and amplitude;

[0046] Figure 9 Exemplary shows a motor system simulation model of an embodiment of the present application;

[0047] Figure 10 Exemplary shows a closed-loop motor system provided by an embodiment of the present application;

[0048] Figure 11 Exemplary shows an open-loop motor system provided by an embodiment of the present application, which contains a voltage doubler circuit;

[0049] Figure 12A Exemplary shows a two-stage voltage doubler circuit provided by an embodiment of the present application;

[0050] Figure 12B Exemplary shows the connection relationship of the two-stage voltage doubler circuit provided by an embodiment of the present application in a motor driving circuit;

[0051] Figure 13A Exemplary shows a charging process of the voltage doubler circuit;

[0052] Figure 13B Exemplary shows a discharging process of the voltage doubler circuit;

[0053] Figure 13C Exemplary shows another charging process of the voltage doubler circuit;

[0054] Figure 13D Exemplary shows another discharging process of the voltage doubler circuit;

[0055] Figure 14A Exemplary shows another two-stage voltage doubler circuit provided by an embodiment of the present application;

[0056] Figure 14B Exemplary shows a two-stage voltage doubler circuit provided by an embodiment of the present application;

[0057] Figure 15A Exemplary shows an n-stage voltage doubler circuit provided by an embodiment of the present application;

[0058] Figure 15B Exemplary shows Figure 15A Exemplary shows the structure of switch S1 in the n-stage voltage doubler circuit;

[0059] Figure 16 Exemplary shows Figure 12BThe waveform timing curves of the voltage of capacitor C1 and the coil current in the circuit shown;

[0060] Figure 17 An electronic device 100 provided in an embodiment of this application is shown;

[0061] Figure 18 Several motor thrust directions of the camera are shown;

[0062] Figure 19 This application illustrates a motor control method provided by an embodiment of the present application;

[0063] Figure 20 This application illustrates another motor control method provided by an embodiment of the present application. Detailed Implementation

[0064] The terminology used in the following embodiments of this application is for the purpose of describing particular embodiments only and is not intended to be a limitation of this application.

[0065] The motor is a crucial component of a camera, used to move the lens and change the focal length. Motors can be categorized based on whether they are used for image stabilization: motors used solely for auto focus (AF) and motors that also provide optical image stabilization (OIS). Zooming is achieved by the motor moving the lens along the optical axis, while image stabilization is achieved by the motor moving the lens in the plane perpendicular to the optical axis.

[0066] Based on the different driving forces, motors can be classified into: voice coil motors (VCM), shape memory alloy (SMA) motors, and ultrasonic motors, among others. VCMs utilize the Lorentz force between an energized coil and a magnet to drive lens movement, achieving zoom or image stabilization. SMA motors utilize the unique deformation capabilities of shape memory metals to pull the lens, achieving zoom or image stabilization. Ultrasonic motors control the phase difference between two AC voltages to achieve a preset resonant motion state for a piezoelectric ceramic plate, and then convert this resonant motion into a designed motion state (e.g., linear motion) through structural components, driving lens movement to achieve zoom or image stabilization.

[0067] Figure 1 A typical motor drive system is shown. For example... Figure 1As shown, the motor and its connected driver IC constitute the most basic motor drive system. The driver IC outputs DC current to the VCM, driving the VCM to operate and thus moving the lens. By adjusting the current amplitude, the driving force output by the motor can be controlled to varying degrees. Additionally, as... Figure 1 As shown, the driver IC can also be connected to a power management circuit (PMC) to receive power from the PMC (voltage is shown as VDD); the driver IC can also connect to a bus (such as I...) 2 The C-bus connects to the processor, receives control signals from the processor, and then controls the magnitude of the DC current supplied to the motor.

[0068] When starting the motor, it first needs to overcome the static friction force *f*. The motor can only start when the instantaneous thrust (i.e., the Lorentz force on the energized coil) is greater than the static friction force *f*. Referring to the formula for calculating the Lorentz force *F* = *B* *L* *I*, it can be seen that, with the number of coil turns and the magnet size remaining constant, increasing the instantaneous thrust of the motor requires increasing the current. In the above formula, *B* represents the magnetic flux density (magnetic induction intensity), *L* represents the length of the wire in the magnetic field, and *I* represents the magnitude of the current in the coil. Secondly, during movement, the Lorentz force on the motor also needs to overcome the restoring force *F1*, the damping force *F2*, and the kinetic friction force *f'* caused by the deformation of the reed. The remaining force is the actual acceleration force acting on the lens movement.

[0069] Therefore, in DC-driven motor solutions, if the current is too small, in one scenario, the instantaneous thrust of the motor may be less than the static friction force *f* that the motor needs to overcome during startup, thus preventing the lens from achieving zoom and / or image stabilization. In another scenario, the Lorentz force on the motor may overcome the static friction force *f*, but the actual acceleration force acting on the lens after overcoming *f* is small, resulting in poor fast zoom or image stabilization, impacting the user experience. Overcoming this problem by increasing the instantaneous thrust of the motor requires increasing the current, leading to higher overall power consumption and potential overheating issues, which also negatively affect the user experience.

[0070] To address the aforementioned issues, embodiments of this application introduce high-frequency pulse width modulation (PWM) current into the motor to enhance its instantaneous thrust, thereby enabling rapid overcoming of static friction during motor startup without increasing power consumption.

[0071] Example 1

[0072] Figure 2An embodiment of this application illustrates a motor system that can be applied to a camera module for zoom and / or image stabilization functions.

[0073] like Figure 2 As shown, the motor system may include a motor drive circuit (driver IC) and a motor, which are connected together. The driver IC incorporates a high-frequency PWM wave circuit to output a high-frequency PWM current to the motor, thereby increasing the motor's instantaneous thrust without increasing power consumption. The motor type may be a reed motor, a ball motor, etc.

[0074] Specifically, such as Figure 2 As shown, the driver IC may include: a conversion circuit and a high-frequency PWM wave circuit. Among them,

[0075] The conversion circuit can be connected to the power supply module (such as a power management circuit) of the driver IC to receive the supply voltage VDD output by the power supply module. It is not limited to a power management circuit; other modules can also supply power to the driver IC. The conversion circuit can be used to convert the supply voltage VDD into a high-frequency periodic voltage with a specific frequency (referred to as a first frequency), a specific amplitude (referred to as a first amplitude), and a specific duty cycle (referred to as a first duty cycle) based on the motor's target stroke (referred to as target displacement). This high-frequency periodic voltage is a PWM voltage, referred to as a first PWM voltage. In some embodiments, the conversion circuit can also be connected to a processor, such as an application processor (AP), to receive stroke instructions from the processor, which may include the motor's target position. The target position can be determined by the processor based on the user's zoom operation or by jitter compensation calculated based on the device jitter amplitude detected by sensors in the electronic device. The conversion circuit can be used to determine the motor's target stroke, i.e., the direction and distance of movement, based on the target position and the motor's actual position.

[0076] To accurately drive the motor to a specified position, a correspondence can be established between the duty cycle, amplitude, or frequency of the first PWM voltage and the motor displacement. This correspondence is stored in the driver IC as a table or other data format for the conversion circuit to access. This correspondence can be linear or non-linear. The details of this correspondence and its applications will be discussed later; they will not be elaborated upon here.

[0077] The conversion circuit can also be connected to a high-frequency PWM wave circuit to output the first PWM voltage to the high-frequency PWM wave circuit.

[0078] A high-frequency PWM circuit can be used to convert a first PWM voltage into a high-frequency PWM current. This PWM current can be referred to as the first PWM current. The high-frequency PWM circuit can also be connected to a motor, and can be used to output the first PWM current to the motor, such as outputting the first PWM current to the coil of the VCM, to generate a corresponding driving force to drive the motor.

[0079] In this embodiment of the application, the high-frequency PWM wave circuit can be referred to as the first PWM wave circuit.

[0080] like Figure 3 As shown, the input of the high-frequency PWM circuit is a high-frequency PWM voltage, and the output is a high-frequency PWM current. The frequency of the first PWM current can be equal to or close to the frequency of the first high-frequency PWM voltage, and the duty cycle of the first PWM current can be equal to or close to the duty cycle of the first high-frequency PWM voltage. Here, "close to" means that the difference between the frequency of the first PWM current and the frequency of the first PWM voltage is very small, for example, within the 100 Hz range. "Close to" means that the difference between the duty cycle of the first PWM current and the duty cycle of the first PWM voltage is very small, for example, within 2%. Additionally, the amplitude A of the first PWM current... i The amplitude A of the first PWM voltage u The following relationship exists: A i =A u / R, where R represents the circuit resistance, which may include load resistance, such as the VCM motor coil resistance, and may also include circuit transmission line resistance.

[0081] By adjusting the duty cycle, frequency, and amplitude of the first PWM voltage, the waveform of the first PWM voltage can be controlled, which in turn controls the waveform of the first PWM current output to the motor, ultimately controlling the motor thrust. During the zoom and image stabilization processes of the camera, the conversion circuit receives travel commands from the processor. The target position included in these travel commands changes due to variations in zoom ratio and image stabilization displacement. Correspondingly, the duty cycle, frequency, or amplitude of the first PWM voltage output by the conversion circuit will also change, thereby altering the frequency, amplitude, and duty cycle of the first PWM current output by the first PWM waveform circuit, ultimately changing the motor thrust.

[0082] The waveform of the first PWM voltage input to the high-frequency PWM circuit can be as follows: Figure 4 As shown, in Figure 4 Middle,U max T represents the voltage amplitude of the first PWM voltage, and T represents the period of the first PWM voltage. work This represents the duration of the high-level signal in one cycle. The duty cycle of the first PWM voltage is the high-level duration T. work The proportion within a period T can be calculated using the following formula: T workThe frequency of the first PWM voltage is the inverse of the period T, i.e., 1 / T.

[0083] A circuit composition of the high-frequency PWM wave circuit can be as shown in Figure 5 As shown in the example, the high-frequency PWM wave circuit can be composed of a resistor R1, a capacitor C1, an inductor L1, a diode D1, and a resistor R2. The voltage input end of the high-frequency PWM wave circuit can be coupled to the voltage output end of the conversion circuit to receive the first PWM voltage output by the conversion circuit. One end of the resistor R1 can be coupled to the voltage input end, and the other end of the resistor R1 can be coupled to the capacitor C1. The resistor R1, the capacitor C1, the inductor L1, and the resistor R2 are connected in series. The diode D1 can be connected in parallel between the middle position of the capacitor C1 and the inductor L1 and a reference point (such as ground). The current flowing through the resistor R2 is used as the output current of the high-frequency PWM wave circuit, i.e., the first PWM current. Without being limited Figure 5 The circuit composition of the example, the circuit structure of the high-frequency PWM wave circuit can also be other forms, the embodiments of the present application do not limit this.

[0084] Since the first PWM current output to the motor has a certain duty cycle, the driver IC can output a larger instantaneous current to the motor under the same power consumption, thereby improving the instantaneous thrust of the motor and successfully overcoming the static friction of the motor during startup.

[0085] In the embodiments of the present application, high frequency can mean a frequency greater than 1000 Hz.

[0086] In the embodiments of the present application, the corresponding relationship between the duty cycle, amplitude, or frequency of the first PWM voltage and the motor displacement can be used to record the motor stroke when the third parameter takes different values under the condition that any two parameters of the frequency, amplitude, and duty cycle are fixed.

[0087] Specifically, the mapping relationship includes a first mapping relationship, a second mapping relationship, and a third mapping relationship. The first mapping relationship can be used to record the respective motor displacements corresponding to different values of the duty cycle of the first PWM voltage under the condition that the frequency and amplitude of the first PWM voltage take fixed values. The second mapping relationship can be used to record the respective motor displacements corresponding to different values of the amplitude of the first PWM voltage under the condition that the frequency and duty cycle of the first PWM voltage take fixed values. The third mapping relationship can be used to record the respective motor displacements corresponding to different values of the frequency of the first PWM voltage under the condition that the amplitude and duty cycle of the first PWM voltage take fixed values.

[0088] Taking a certain VCM reed motor as an example, Figure 6 As shown in the example, the first PWM current waveform generated by the high-frequency PWM wave circuit when the frequency and amplitude of the first PWM voltage take fixed values and the duty cycle takes three different values (20%, 30%, and 40%) is shown. In Figure 6In this configuration, the amplitude of the first PWM voltage is fixed at 3.2*2 volts, the frequency of the first PWM voltage is fixed at 30000Hz, and the waveform of the first PWM current varies with the duty cycle. Again, taking this VCM reed motor as an example... Figure 7 An example is shown illustrating the motor stroke-time curves corresponding to three different duty cycles (20%, 30%, and 40%) when the frequency and amplitude of the first PWM voltage are fixed. Figure 7 In this circuit, the amplitude of the first PWM voltage is fixed at 3.2*2 volts, the frequency of the first PWM voltage is fixed at 30000Hz, and the motor displacement changes with the duty cycle. When the duty cycle is 20%, the corresponding motor stroke is 70 micrometers, when the duty cycle is 30%, the corresponding motor stroke is 190 micrometers, and when the duty cycle is 40%, the corresponding motor stroke is 335 micrometers.

[0089] Taking the first correspondence as an example, in order to more comprehensively cover the correspondence between duty cycle and motor stroke, with the frequency and amplitude fixed, the motor stroke corresponding to more different duty cycles of the first PWM voltage can be obtained, thus forming... Figure 8 The example shows the curve corresponding to the duty cycle and motor stroke. The more different values ​​of the duty cycle there are, the smoother the curve becomes.

[0090] In some embodiments, the conversion circuit converts the power supply voltage into a first PWM voltage with a first frequency, a first amplitude, and a first duty cycle according to the target stroke of the motor. Specifically, the conversion circuit determines that the frequency of the first PWM voltage is fixed to a first frequency, the amplitude is fixed to a first amplitude, and determines the duty cycle corresponding to the target stroke as the first duty cycle based on a first mapping relationship.

[0091] In some embodiments, the conversion circuit converts the power supply voltage into a first PWM voltage with a first frequency, a first amplitude, and a first duty cycle according to the target stroke of the motor. Specifically, the conversion circuit determines that the amplitude of the first PWM voltage is fixed to a first amplitude, the duty cycle is fixed to a first duty cycle, and determines the frequency corresponding to the target stroke as the first frequency based on a third mapping relationship.

[0092] In some embodiments, the conversion circuit converts the power supply voltage into a first PWM voltage with a first frequency, a first amplitude, and a first duty cycle according to the target stroke of the motor. Specifically, the conversion circuit determines that the frequency of the first PWM voltage is fixed as the first frequency, the duty cycle is fixed as the first duty cycle, and determines the amplitude corresponding to the target stroke as the first amplitude based on the second mapping relationship.

[0093] Furthermore, to reduce storage costs, one can choose... Figure 8The data in the linear section is stored, such as the corresponding relationship between the duty cycle in the range of 20% to 40% and the motor stroke. Moreover, the data in the linear section can be expressed in the form of a linear function, and only the linear function expression and the linear range can be recorded to significantly reduce the data storage amount. For example, Figure 8 The linear section of the first mapping relationship shown can be expressed as s(x) = 1300x - 190, where x represents the duty cycle, the value range of x is 20%-40%, and s(x) represents the motor stroke. When the target stroke of the motor is determined to be 70 microns, the duty cycle of the first PWM voltage can be set to 20%; when the target stroke of the motor is determined to be 330 microns, the duty cycle of the first PWM voltage can be set to 40%.

[0094] In some embodiments, in the first mapping relationship, the duty cycle and the motor stroke can present a linear relationship.

[0095] In some embodiments, in the second mapping relationship, the amplitude and the motor stroke can present a linear relationship.

[0096] In some embodiments, in the third mapping relationship, the frequency and the motor stroke can present a linear relationship.

[0097] When the two input parameters originally taking fixed values change, the mapping relationship between the originally changed third parameter and the motor stroke also changes. In the above example, when the originally fixed frequency changes from 30000 Hz to 20000 Hz, if the target stroke of the motor is still 70 um, the duty cycle needs to be changed to a value greater than 20%, not 20%. In practical applications, the developer can adjust the fixed values of the two parameters to obtain or maximize the linear section or approximate linear section between the third parameter and the motor stroke. For example, when the amplitude and the frequency of the first PWM voltage are fixed at 3.2*2 volts and 10000 Hz respectively, the duty cycle of the first PWM current can present a linear corresponding relationship with the motor stroke in the range of 40%-50%; when the amplitude and the frequency of the first PWM voltage are fixed at 3.2*2 volts and 40000 Hz respectively, the duty cycle of the first PWM current can present a linear corresponding relationship with the motor stroke in the range of 5%-20%. In this way, multiple sets of linear corresponding relationships between the duty cycle and the motor stroke can be stored in the driver IC for the conversion circuit to call, so as to realize that the duty cycle presents a linear or approximate linear corresponding relationship with the motor stroke in a larger range of 5%-50%.

[0098] In the embodiments of the present application, when the target stroke is not in the linear part of the first mapping relationship (such as the motor stroke range of 70um-335um corresponding to the duty cycle of 20%-40%), the conversion circuit can check whether the target stroke is in the linear part of the second mapping relationship or the third mapping relationship, and if so, the second mapping relationship or the third mapping relationship can be used to generate the PWM voltage. For example, assuming that the target stroke is 10 microns, it is not in the linear part as shown; however, when the amplitude and duty cycle of the first PWM voltage are fixed at 3.2*3 volts and 15% respectively, the frequency of the first PWM current can be in a linear corresponding relationship with the motor stroke in the range of 20000Hz-45000Hz, and the linear part includes the target stroke of 10 microns. That is, the first mapping relationship, the second mapping relationship, and the third mapping relationship can be used to maximize the linear mapping relationship of the motor stroke. In some embodiments, the passage in which the entire motor stroke is in the linear part of which mapping relationship can also be measured in advance through experiments and the like, so that when the target stroke of the motor is determined, the amplitude, frequency, and duty cycle of the high-frequency PWM voltage can be directly determined using the linear part corresponding to the target stroke, without the need to find the linear mapping relationship in which the target stroke is located. Figure 8

[0099] The corresponding relationship between the duty cycle, amplitude, or frequency of the first PWM voltage and the motor displacement can be obtained through simulation or actual measurement.

[0100] The above simulation means can be implemented based on the motor system simulation model as shown. Figure 9

[0101] As shown in Figure 9 The simulation model of the motor system can be divided into three parts: circuit part, electromagnetic part, and mechanical part. Among them, the circuit part is used to simulate the high-frequency PWM wave circuit described above, and the input is the high-frequency PWM voltage with different parameters (duty cycle, amplitude, frequency), and the output is the high-frequency PWM current. The circuit part outputs the high-frequency PWM current signal to the electromagnetic part. The coil in the electromagnetic part can be used to simulate the electromagnetic device in the motor, which generates a magnetic field when the high-frequency PWM current is passed. The mechanical part can be used to simulate the mechanical device in the motor, which generates a magnetic force under the action of the magnetic field, thereby driving the upper and lower spring modules to move, and finally driving the driven component (such as the lens of the camera) to move. The mechanical part can also include a displacement sensor, which can be used to record the movement stroke of the driven component.

[0102] Embodiment two

[0103] Figure 2 The motor system as shown is an open-loop motor system. The open-loop motor system refers to adjusting the motor system through the feedback information of the system during operation, that is, Figure 2 ​​The motor system lacks a feedback mechanism to adjust the first PWM voltage generated by the conversion circuit according to the actual position of the lens driven by the motor during operation.

[0104] The open-loop motor system has the advantages of simplicity and easy operation. However, in some examples, the motor system needs to be applied to some high-precision devices, such as camera modules. These high-precision devices further require the movement precision and speed of the motor mover. The open-loop motor system lacks the above feedback mechanism, so it cannot adjust the possible errors of the system (such as the lens not being driven to the target position) according to the movement state of the motor, and the precision is poor.

[0105] The embodiment of the present application adds a feedback link and a closed-loop control link on the basis of open-loop control, eliminates unnecessary movement oscillation, and enables the motor to move to the specified position more quickly.

[0106] Figure 10 A closed-loop motor system provided by an embodiment of the present application is shown.

[0107] As shown in Figure 10 In addition to the components of the open-loop motor system shown in Figure 2 , the closed-loop motor system can further include a control circuit and a position detection circuit. The position detection circuit can be used to detect the actual position of the motor mover and output the actual position to the control circuit. The control circuit can also receive the travel instruction from the processor and extract the target position contained in the travel instruction. The control circuit can also be used to calculate the position deviation between the actual position and the target position and output the position deviation to the conversion circuit. The position deviation is used as the target travel of the motor. Then, the conversion circuit can generate the first PWM voltage input to the high-frequency PWM wave circuit according to the target travel, and then the high-frequency PWM wave circuit outputs the first PWM current to continue driving the motor to generate the motor thrust to drive the driven component closer to the target position.

[0108] The target travel can be determined according to the target position carried in the travel instruction from the processor and the actual position of the motor mover, specifically the difference between the two. The closer the actual position is to the target position, the smaller the target travel.

[0109] At the beginning, the motor mover is at the initial position, the conversion circuit can directly determine the target stroke according to the target position carried in the stroke instruction from the processor, and generate a corresponding PWM voltage according to the target stroke, and then output the PWM voltage to the high-frequency PWM wave circuit, and then the high-frequency PWM wave circuit outputs the PWM current, and finally drives the motor to generate the motor thrust. However, due to the fact that the correspondence between the duty cycle, amplitude or frequency of the PWM voltage recorded in the mapping relationship and the motor displacement is not accurate enough, there are deviations in the size and other quality parameters of the motor during manufacturing, or voltage fluctuations in the actual work of the motor, etc. The driven component (such as the lens of the camera) may not be accurately pushed to the target position by the motor, that is, there is a position deviation between the actual position of the motor mover (detected by the position detection circuit) and the target position. The control circuit can also be used to calculate the position deviation between the actual position and the target position and output the position deviation to the conversion circuit. The position deviation can be used as a new target stroke of the motor. Then, the conversion circuit can regenerate the PWM voltage input to the high-frequency PWM wave circuit according to the new target stroke, and then the high-frequency PWM wave circuit re-outputs the PWM current to continue driving the motor to generate the motor thrust to push the driven component closer to the target position. This goes back and forth several times until the position detection circuit detects that the driven component is actually at the target position.

[0110] The position detection circuit in the closed-loop motor system can include a Hall sensor and / or an infrared sensor and other sensors used to detect the position of the object pushed by the motor, and the embodiments of the present application do not limit this.

[0111] The control circuit in the closed-loop motor system can be located in the driver IC. The control circuit can be provided in the conversion circuit. Without limitation, the control circuit can also be a separate circuit independent of the driver IC, and the embodiments of the present application do not limit the location of the control circuit.

[0112] In some embodiments, the conversion circuit can also implement the conversion between the target position and the frequency, amplitude, and duty cycle of the PWM voltage (which can be referred to as input parameters) through a proportional-integral-derivative (PID) control algorithm, so that the motor mover can be stabilized to the target position more quickly, and the motion shock of the camera module during the implementation of the anti-shake and zoom functions can be reduced.

[0113] The conversion circuit can be used to convert the target stroke into a first frequency, a first amplitude, and a first duty cycle through a proportional-integral-derivative (PID) control algorithm, and generate a first PWM voltage according to the first frequency, the first amplitude, and the first duty cycle.

[0114] The PID control algorithm can determine the value of the third input parameter according to the target stroke on the premise that two of the input parameters have fixed values. For example, the amplitude and frequency of the first PWM voltage are fixed at 3.2*2 volts and 30000 Hz, respectively. If the target stroke is 190 um at this time, the conversion circuit can calculate that the duty cycle of the first PWM voltage should be set to 25% according to the PID control algorithm, and then generate a PWM voltage with an amplitude, frequency, and duty cycle of 3.2*2 volts, 30000 Hz, and 25%, respectively, and output the PWM voltage to the high-frequency PWM wave circuit.

[0115] Specifically, calculating the value of an input parameter using the PID control algorithm includes three control terms: the proportional term P, the integral term I, and the derivative term D. When the above PID control algorithm is applied to control the stroke of the motor, the three control terms are calculated based on the deviation error(t) between the actual position and the target position of the object (e.g., the lens) driven by the motor at time t. Taking the motor system applied to a camera module as an example, the proportional term P is proportional to the position deviation (i.e., the third stroke), which is used to generate a fast response of the motor system to make the lens move to the target position as soon as possible; the integral term I is proportional to the cumulative position deviation, which is used to eliminate steady-state error so that the deviation between the actual position and the target position of the lens is small enough to accurately stay near the target position; and the derivative term D is proportional to the change rate of the position deviation, which is used to suppress oscillation and improve the stability of the motor system to ensure that the lens can quickly and smoothly adjust to the target position.

[0116] The output output of the PID control is determined by the combination of the three control terms and can be represented as:

[0117]

[0118] where Kp is the proportional gain, Ki is the integral gain, and Kd is the derivative gain. The values of the above gain parameters determine the value of each control term, thereby affecting the PID output result and further affecting the performance of the system. Therefore, training the PID control algorithm actually involves adjusting the above gain parameters to appropriate values.

[0119] The three gain parameters are parameters that are adjusted according to actual requirements and performance indicators during system design. Different PID parameter settings are required in different application scenarios and systems, so in actual applications, the gain parameters can be manually adjusted through testing and adjustment to determine appropriate gain parameter values, thereby achieving stable, fast, and accurate control of the system.

[0120] The PID control algorithm executed by the conversion circuit should be an accurate control algorithm obtained after a large amount of training. The accurate control algorithm refers to a control algorithm in which the appropriate gain parameters are determined in the training process. The training of the PID control algorithm can be based on Figure 10 as shown in the closed-loop motor system.

[0121] The developer can first determine the input voltage amplitude and current frequency values, and then empirically set the initial values of Kp, Ki, and Kd. After the setting is completed, the conversion circuit can generate a corresponding duty cycle value according to the given target position and the PID control algorithm. The duty cycle, together with the voltage amplitude and current frequency, constitutes a set of input parameters (frequency, amplitude, duty cycle). The conversion circuit outputs the input parameters to the conversion circuit. The high-frequency PWM voltage generated by the conversion circuit is converted into a high-frequency PWM current acting on both ends of the motor coil to drive the motor to move. The position detection module can detect the position of the object driven by the motor in real time. The developer can correct the values of the gain parameters according to the position deviation between the actual position and the target position of the object driven by the motor. After the correction, the above steps are repeated until the actual position of the object driven by the motor coincides with the target position or there is a reasonable error (for example, within ±0.5 um error), and the gain parameters are considered to be appropriate gain parameters, and the PID control algorithm is considered to be an accurate control algorithm.

[0122] Taking the above example, the developer can first determine that the input voltage amplitude is set to 3.2*2 volts, the current frequency is 30000 Hz, and the target position is 190 um. The initial values of Kp, Ki, and Kd are set to 0.1, 0.01, and 0.001, respectively. Then, the corresponding duty cycle value of 25% is obtained using the PID control algorithm, and the set of input parameters is input into the driver IC to generate a high-frequency PWM current to drive the motor and thereby move the lens. Then, the value of Kp is increased and the above process is repeated until overshoot (for example, the motor stroke is 200 um) or oscillation (for example, the motor stroke oscillates between 180 um and 195 um) occurs. If the position deviation between the actual position and the target position of the lens (i.e., the third stroke) is large during this process, the value of Ki can be appropriately increased to reduce the position deviation. If the motor movement exhibits overshoot or oscillation during this process, the value of Kd can be appropriately increased to increase the stability of the system.

[0123] After the iterative optimization of each gain parameter according to the above operation, the appropriate gain parameters can be found, and an accurate PID control algorithm can be obtained.

[0124] The gain parameter changes when the frequency and the voltage amplitude of the input parameter change. Correspondingly, the gain parameter changes when the fixed parameter of the input parameter is the frequency and the duty cycle, or the fixed parameter is the voltage amplitude and the duty cycle.

[0125] The driver IC in the closed-loop motor system can also use the method in Embodiment 1 and Embodiment 2 to generate a high-frequency PWM voltage.

[0126] For example, after receiving the target position indicated by the processor, the conversion circuit can first use the method in Embodiment 1 to determine the duty cycle, amplitude, or frequency of the high-frequency PWM voltage corresponding to the target stroke according to the corresponding relationship between the duty cycle, amplitude, or frequency of the first PWM voltage and the displacement of the motor, generate a high-frequency PWM voltage, and output it to the motor, and then convert it into a high-frequency PWM current to drive the motor to quickly move the lens to the target position. Then the position detection circuit can detect the actual position of the lens in real time and output it to the control circuit. The control circuit calculates the third stroke according to the actual position of the lens and the target position and inputs it to the conversion circuit. At this time, the conversion circuit can convert the third stroke into a corresponding high-frequency PWM' voltage according to the PID control algorithm, and then generate a high-frequency PWM' current, so as to realize accurate control of the lens near the target position.

[0127] In some embodiments, in order to further solve the problem of static friction when the motor starts, in addition to the circuit structure mentioned earlier, the open-loop motor system or the closed-loop motor system can also include a voltage doubler circuit.

[0128] Taking the open-loop motor system as an example, Figure 11 An open-loop motor system including a voltage doubler circuit is shown.

[0129] As Figure 11 shown, the input end of the voltage doubler circuit is coupled to the conversion circuit, and the output end of the voltage doubler circuit is coupled to the first PWM wave circuit. The voltage doubler circuit can be used to multiply the first PWM voltage generated by the conversion circuit, and then output the multiplied PWM voltage to the first PWM wave circuit to generate a first PWM current, and finally output the first PWM current to the motor, such as to the VCM coil load across the two ends, thereby multiplying the instantaneous current flowing through the VCM coil, and then significantly increasing the instantaneous thrust of the motor, so that the motor can overcome the static friction force faster when starting. When this motor system is applied to a camera, users can have faster zoom speed and better anti-shake performance.

[0130] In the embodiments of the present application, the voltage doubling circuit can be partially or entirely integrated in the driver IC and connected with the conversion circuit and the first PWM wave circuit. The partial integration in the driver IC can mean that the logic devices such as switches in the voltage doubling circuit are integrated in the IC. The voltage doubling circuit can also be integrated in an application module (such as a camera module, a key module, etc.) or even in the VCM, for example, etched on the flexible printed circuit board (FPCB) part or metal part of the VCM.

[0131] The conventional voltage doubling circuit is usually a combination of multiple capacitors and multiple diodes, which generates an average voltage boost by periodically charging and discharging the capacitors. However, this solution can cause the motor size to increase, which is not suitable for electronic devices 100 with limited space.

[0132] Therefore, the embodiments of the present application provide a voltage doubling circuit with a more compact circuit structure to solve this problem.

[0133] The voltage doubling circuit provided by the embodiments of the present application will be described in detail from multiple aspects as follows.

[0134] The voltage doubling circuit mentioned in this document can include a two-stage voltage doubling circuit, a three-stage voltage doubling circuit, or even a more-stage voltage doubling circuit.

[0135] Two-stage voltage doubling circuit

[0136] The embodiments of the present application provide a two-stage voltage doubling circuit, which further reduces the circuit size and can change the polarity of the output voltage. When the voltage doubling circuit is applied to a motor system, for example, when the input end of the voltage doubling circuit is connected with the conversion circuit and the output end is connected with the first PWM wave circuit, it can change the current direction in the final coil, thereby supporting the motor to output two-direction motor thrust, and finally controlling the object (such as the lens of the camera) driven by the motor to move in two directions.

[0137] For example, the voltage doubling circuit can be applied to a motor system, for example, a VCM system. Figure 12AAs shown, the secondary voltage doubler circuit 11 can include a capacitor C1, a diode D1, a diode D2, a switch S1, an input terminal 08A, 08B, and an output terminal 09A, 09B. The switch S1 can be a single-pole double-throw switch, including a fixed terminal P1 and two movable terminals T1, T2, and can be used to switch between conducting D1 and conducting D2. Among them, one end of the capacitor C1 is coupled to the input terminal 08A, and the other end is coupled to the output terminal 09A. Among the two ends of the capacitor C1, the end coupled to the input terminal 08A can be referred to as the first end of the capacitor C1, and the other end coupled to the output terminal 09A can be referred to as the second end of the capacitor C1. The negative electrode of the diode D1 is coupled to the second end of the capacitor C1, and the positive electrode is coupled to the movable terminal T1 of the switch S1; the positive electrode of the diode D2 is also coupled to the second end of the capacitor C1, and the negative electrode is coupled to the movable terminal T2 of the switch S1; the fixed terminal P1 of the switch S1 is coupled to the input terminal 08B; the input terminal 08B is also coupled to the output terminal 09B.

[0138] In the voltage doubler circuit 11, C1 and D1 form a charge-discharge circuit, and C1 also forms a charge-discharge circuit with D2. The two charge-discharge circuits share the same capacitor C1, so that the improved secondary voltage doubler circuit 11 does not require two capacitors, and the circuit size can be further reduced.

[0139] In the voltage doubler circuit 11, the two charge-discharge circuits do not work at the same time, and the switch S1 can be used to select which charge-discharge circuit to work. Specifically, the switch S1 can also include two control terminals C1, C2 to receive control signals from a control unit such as a processor or a controller. Whether the switch S1 selectively conducts D1 or D2 (i.e., which charge-discharge circuit to work) can be controlled by the control signal input to the control terminal. The control signal can be generated due to the user's zoom action. For example, the action of increasing the zoom ratio can trigger the control unit such as a processor to generate a control signal to select D1 to be conducted, thereby driving the lens to move in a first direction. For another example, the action of reducing the zoom ratio can trigger the control unit such as a processor to generate a control signal to select D2 to be conducted, thereby driving the lens to move in a second direction. The first direction can be, for example, the direction of approaching the photographed object, and the second direction can be, for example, the direction of moving away from the photographed object.

[0140] The diodes D1, D2 are only an example of a one-way conduction device, and the voltage doubler circuit 11 can also use other types of one-way conduction devices. In the voltage doubler circuit 11, the diodes D1, D2 can be replaced by two one-way conduction devices with opposite conduction directions. Herein, the one-way conduction device can be a one-way conduction device or a one-way conduction circuit that forms a small conduction voltage drop (less than 1V).

[0141] As Figure 12BAs shown, the two-stage voltage doubling circuit 11 provided by the embodiment of the present application can be connected between the conversion circuit 12 and the first PWM wave circuit 13 (circuit structure details are not shown), and can be used to increase the output voltage of the conversion circuit 12 and then further output to the first PWM wave circuit 13, so that the instantaneous current size output to the coil 14 load is increased. The output end of the first PWM wave circuit 13 is coupled with the coil 14. The coil is essentially a series connection of inductance and resistance, and "R Z " in the figure can represent the equivalent load of the coil 14. Specifically, one input end of the voltage doubling circuit 11 is coupled with the output end 10A of the conversion circuit 12, and the other input end is coupled with the output end 10B of the conversion circuit 12; one output end of the voltage doubling circuit 11 is coupled with one end of the first PWM wave circuit 13, and the other output end is coupled with the other end of the first PWM wave circuit 13.

[0142] In this article, coupling includes direct electrical connection, and indirect electrical connection with intermediate series of conductive devices (such as resistors) or conductive circuits. Since the first PWM wave circuit 13 does not affect the working principle of the charging and discharging of the voltage doubling circuit, in order to simplify the charging and discharging process of the improved voltage doubling circuit, the output end of the voltage doubling circuit 11 is coupled with the coil 14 in the subsequent description.

[0143] Charging and discharging of the improved two-stage voltage doubling circuit

[0144] Figure 13A - Figure 13B A charging and discharging of the voltage doubling circuit is shown. In Figure 13A - Figure 13B , the switch S1 selectively conducts D1.

[0145] As Figure 13A shown, when the input voltage signal is in the first half cycle, the voltage polarity of the input end 08A, 08B is negative and positive respectively, the capacitor C1 is charged, and the voltage polarity is right positive and left negative. It is charged to the capacitor voltage close to the input voltage soon. In this article, this charging process can be referred to as "one-time capacitor charging".

[0146] As Figure 13B shown, when the input voltage signal is switched to the second half cycle, the voltage polarity of the input end 08A, 08B is positive and negative respectively, D1 is not conductive, and the capacitor C1 is discharged. The voltage on the capacitor C1 superimposes the input voltage to form the output voltage, and the polarity of the output voltage is the first polarity (such as the upper positive and lower negative shown in the figure), which supplies power to the coil. The current flowing through the coil is approximately 2*I. Where I represents the coil current when the voltage doubling circuit is not used under the same input voltage, I = U in / R z . The above U in is the voltage input to the voltage doubling circuit, that is, the PWM voltage generated by the conversion circuit. In this article, this discharging process can be referred to as "one-time capacitor superimposes input voltage discharge".

[0147] Figure 13B In the embodiment, the direction of the coil current is from the first end of the coil 14 to the second end of the coil 14. The first end of the coil 14 is one end of the coupling output end 09A, and the second end of the coil 14 is one end of the coupling output end 09B.

[0148] When the input voltage signal comes to the next period, the voltage doubling circuit 11 repeats the charging process shown in Figure 13A the discharging process shown in Figure 13B .

[0149] Unlike the conventional two-stage voltage doubling circuit, the two-stage voltage doubling circuit provided by the embodiment can approximately double the VCM supply voltage in one half cycle, without the long time of one cycle. The two-stage voltage doubling circuit provided by the embodiment only needs one capacitor C1, without two capacitors, and can save size.

[0150] Figure 13C - Figure 13D Another charging and discharging of the voltage doubling circuit is shown. In the embodiment, the switch S1 selectively turns on the D2. Figure 13C - Figure 13D

[0151] As shown in Figure 13C , when the input voltage signal is in the second half cycle, the voltage polarities of the input ends 08A and 08B are positive and negative respectively, the capacitor C1 is charged, and the voltage polarity is left positive and right negative. The capacitor voltage is approximately the input voltage after a short time, and the "one-time capacitor charging" is completed.

[0152] As shown in Figure 13D , when the input voltage signal is switched to the first half cycle in turn, the voltage polarities of the input ends 08A and 08B are negative and positive respectively, the D2 is not turned on, the capacitor C1 is discharged, the voltage on the capacitor C1 is superimposed with the input voltage to form the output voltage, the polarity of the output voltage is the second polarity (as shown in the figure, negative above and positive below), the output voltage is used to supply power to the coil, the current flowing through the coil is approximately 2*I, and the "one-time capacitor superimposed input voltage discharging" is completed.

[0153] Figure 13D In the embodiment, the direction of the coil current is from the second end of the coil 13 to the first end of the coil 13.

[0154] When the input voltage signal comes to the next period, the voltage doubling circuit 11 repeats the charging process shown in Figure 13C the discharging process shown in Figure 13D .

[0155] In addition, according to the right-hand screw rule, when the current flows through the coil, the coil can generate an attractive force or a repulsive force relative to its matched magnet, thereby driving the lens or other to-be-driven components to move. Figure 13B In the embodiment, the direction of the coil current is from the second end of the coil 13 to the first end of the coil 13. Figure 13D ​The coil current directions shown in the figure are opposite, thus they will generate two opposite driving forces, which can drive the lens to move in the two directions.

[0156] The first half cycle and the second half cycle can be a negative half cycle and a positive half cycle respectively, or a positive half cycle and a negative half cycle respectively, that is, the input voltage shown in the figure as positive in the upper part and negative in the lower part can be a positive half cycle input voltage or a negative half cycle input voltage.

[0157] Add a bias resistor

[0158] Further, a resistor can be connected in series in the charging and discharging circuit to adjust the charging and discharging time of the capacitor C1. Because the time constant τ of the charging and discharging circuit is R*C, where R represents the resistance of the circuit, including the internal resistance of the power supply, the resistance of the diode when it is turned on, and the resistance of the transmission line, further connecting resistors of different sizes can change the charging and discharging time constant of the circuit.

[0159] As shown in Figure 14A The secondary voltage doubling circuit 11 can further include a bias resistor R1 connected in series between the fixed terminal P1 of the switch S1 and the output terminal 10B of the driver IC, that is, the bias resistor R1 is a bias resistor shared by the charging and discharging circuits of the diodes D1 and D2, and adjusts the charging and discharging time of the two charging and discharging circuits together. That is, the fixed terminal P1 of the switch S1 in the voltage doubling circuit 11 is not directly coupled to the output terminal 10B of the driver IC, but is indirectly coupled to the output terminal 10B of the driver IC through the series-connected bias resistor R1.

[0160] As shown in Figure 14B The secondary voltage doubling circuit 11 can further include two bias resistors R1 and R2 connected in series in the charging and discharging circuits of the diodes D1 and D2, respectively, to independently adjust the charging and discharging time of the charging and discharging circuits of D1 or D2. Specifically, the bias resistor R1 can be connected in series between the positive electrode of the diode D1 and the moving terminal T1 of the switch S1, and the bias resistor R2 can be connected in series between the negative electrode of the diode D2 and the moving terminal T1 of the switch S1. That is, the positive electrode of the diode D1 in the voltage doubling circuit 11 is not directly coupled to the moving terminal T1 of the switch S1, and the negative electrode of the diode D2 is not directly coupled to the moving terminal T2 of the switch S1.

[0161] More stages of voltage doubling circuit

[0162] Figure 15A An n-stage voltage doubling circuit is shown, where n≥2. As shown in Figure 15AAs shown, the n-stage voltage doubler circuit can be formed by a conventional n-stage voltage doubler circuit (including a conventional two-stage voltage doubler circuit) and a switch S1, which is electrically connected between the output terminal of the conventional n-stage voltage doubler circuit and the coil load, and can be used to control the voltage polarity across the coil load to change the direction of the current flowing through the coil, thereby changing the direction of the motor thrust.

[0163] As shown in Figure 15B , the switch S1 can be a double-pole double-throw switch or formed by two single-pole double-throw switches, and can include two fixed terminals P1, P2, four movable terminals T1, T2, T3, T4, and two control terminals C1, C2. Among them, P1 and P2 are respectively electrically connected to the two ends of the capacitor Cn, T1 and T4 are electrically connected to the first end of the coil, and T2 and T3 are electrically connected to the second end of the coil.

[0164] When the voltage polarity of the output terminal of the n-stage voltage doubler circuit (i.e. the two ends of the capacitor Cn) is positive on the top and negative on the bottom, the switch can be controlled to switch so that P1 is connected to T1 and P1 is disconnected from T2, P2 is connected to T3 and P2 is disconnected from T4, thereby controlling the voltage polarity of the coil to be positive on the top and negative on the bottom, and the current direction of the coil is from the first end to the second end of the coil. When the voltage polarity of the output terminal of the n-stage voltage doubler circuit is positive on the top and negative on the bottom, the switch can be controlled to switch so that P1 is connected to T2 and P1 is disconnected from T1, P2 is connected to T4 and P2 is disconnected from T3, thereby controlling the voltage polarity of the coil to be negative on the top and positive on the bottom, and the current direction of the coil is from the second end to the first end of the coil. In this way, the selective conduction of S1 can adjust the current direction of the coil, thereby controlling the direction of the motor thrust.

[0165] Similarly, when the voltage polarity of the output terminal of the n-stage voltage doubler circuit is negative on the top and positive on the bottom, the selective conduction of S1 can also adjust the current direction of the coil, thereby controlling the direction of the motor thrust.

[0166] The control signal for switch switching can be transmitted by the control unit such as a controller or a processor through the two control terminals C1 and C2.

[0167] In addition, in order to independently control the time constant τ of each charging circuit, a bias resistor can be connected in series in each charging circuit, such as R1, R2, R3... Rn in Figure 15A .

[0168] Figure 16 The voltage of capacitor C1 and the waveform timing curve of coil current in the circuit shown in Figure 12B are shown. Among them, U C1 represents the capacitor voltage of capacitor C1, I coil represents the current flowing through the coil. As shown in Figure 16 , when the above-mentioned two-stage voltage doubler circuit is introduced, U C1 is approximately equal to U in, I coil approximately equal to 2I.

[0169] By introducing the above-mentioned voltage doubling circuit, the instantaneous thrust of the motor is nearly doubled at the moment of discharging the capacitor C1, which can significantly increase the acceleration of lens movement and improve the efficiency of lens movement to the target position. Moreover, since the PWM voltage generated by the conversion circuit is a high-frequency voltage, generally 10KHz, 20KHz, or even higher, this also makes the output of the motor thrust very dense in a short time, such as 20,000 times of large thrust output in 1 second, thereby making the smoothness of focus or anti-shake very high and the user experience better.

[0170] Figure 17 An electronic device 100 provided by an embodiment of the present application is shown.

[0171] As shown in Figure 17 , the electronic device 100 can include a processor 110, a memory 120, a motor system 130, a power management circuit 140, a camera 150, a button 160, and a display screen 170. Among them:

[0172] The processor 110 can include an application processor (AP) and an image signal processor (ISP). The processor 110 can also include a modem processor, a graphics processing unit (GPU), a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), etc. Among them, different processing units can be independent devices, or can be integrated in one or more processors.

[0173] The processor 110 can include one or more interfaces. The interface can include an inter-integrated circuit (I 2 C) interface, an inter-integrated circuit sound (I 2Interfaces include: S) interface, Pulse Code Modulation (PCM) interface, Universal Asynchronous Receiver / Transmitter (UART) interface, Mobile Industry Processor Interface (MIPI) interface, General-Purpose Input / Output (GPIO) interface, Subscriber Identity Module (SIM) interface, and / or Universal Serial Bus (USB) interface, etc.

[0174] I 2 The C interface is a bidirectional synchronous serial bus, including a serial data line (SDA) and a serial clock line (SCL). Processor 110 can contain multiple I / O pins. 2 C bus. Processor 110 can be accessed via different I... 2 The C-bus is coupled to the memory 120, power management circuit 140, camera 150, button 160, display screen 170, etc.

[0175] For example, processor 110 can be accessed via I 2 The C-bus couples with the camera 150 to control the driver IC in the camera 150 to adjust the amplitude, duty cycle, and frequency of the voltage signal (the aforementioned high-frequency PWM voltage) it generates, thereby adjusting the current output to the VCM coil and ultimately adjusting the motor thrust. For example, the processor 110 can also adjust the current output to the VCM coil via I-bus. 2 The C-bus couples the camera 150 to control the controller in the camera 150 to output a switch selection signal, thereby adjusting the current direction of the VCM coil and generating motor thrust in the specified direction.

[0176] I 2 The S-interface can be used for audio communication. The processor 110 can contain multiple I / O pins. 2 The S-bus. Processor 110 can be accessed via I... 2 The S-bus is coupled to the audio module in electronic device 100, enabling communication between processor 110 and the audio module. The audio module can communicate via I... 2 The S-interface transmits audio signals to the wireless communication module in the electronic device 100, enabling the function of answering phone calls through a Bluetooth headset.

[0177] The PCM interface can also be used for audio communication, sampling, quantizing and encoding analog signals. The audio module can be coupled to the wireless communication module through the PCM bus interface. The audio module can also transmit audio signals to the wireless communication module through the PCM interface to realize the function of answering a phone through a Bluetooth headset.

[0178] The UART interface is a general-purpose serial data bus that converts data to be transmitted between serial communication and parallel communication. The UART interface is usually used to connect the processor 110 and the wireless communication module. For example, the processor 110 communicates with the Bluetooth module in the wireless communication module through the UART interface to realize the Bluetooth function.

[0179] The MIPI interface can be used to connect the processor 110 and peripheral devices such as a display screen and a camera 150. The MIPI interface includes a camera serial interface (CSI), a display screen serial interface (DSI), etc.

[0180] The GPIO interface can be configured by software. The GPIO interface can be configured as a control signal or as a data signal. The GPIO interface can be used to connect the processor 110 and the camera 150, the display screen, the wireless communication module, the audio module, and various sensors, etc. The GPIO interface can also be configured as an I 2 C interface, I 2 S interface, UART interface, MIPI interface, etc.

[0181] The USB interface can include a Mini USB interface, a Micro USB interface, a USB Type C interface, etc. The USB interface can be used to connect a charger to charge the electronic device 100, or to transmit data between the electronic device 100 and a peripheral device. The interface can also be used to connect other electronic devices, such as AR devices, etc.

[0182] The memory 120 can include one or more random access memories (RAMs) and one or more non-volatile memories (NVMs). The random access memory can be directly read and written by the processor 110, and can be used to store executable programs (such as machine instructions) of an operating system or other programs running in the background, and can also be used to store data of users and application programs, etc. The non-volatile memory can also store executable programs and store data of users and application programs, etc., which can be loaded into the random access memory in advance for direct reading and writing by the processor 110.

[0183] The processor 110 can also be provided with a memory for storing instructions and data. The memory in the processor 110 is a cache memory. The memory can hold instructions or data that the processor 110 has just used or recycled. If the processor 110 needs to use the instructions or data again, it can be directly called from the memory. This avoids repeated access and reduces the waiting time of the processor 110, thereby improving the efficiency of the electronic device 100.

[0184] The motor system 130 can include a driver IC and a VCM.

[0185] The input end of the driver IC is connected to the power management circuit 140, and the output end is connected to the VCM. In the embodiment of the present application, the driver IC can generate a high-frequency PWM voltage, and then convert the high-frequency PWM voltage into a high-frequency PWM current and load it to both ends of the VCM coil. Adjusting the amplitude, frequency, and duty cycle of the high-frequency PWM voltage generated in the driver IC can change the instantaneous current size loaded to the VCM coil, thereby changing the instantaneous thrust of the motor, and further solving the problem that the instantaneous thrust of the motor is too small to overcome the static friction. Specifically, the driver IC can adjust the amplitude, frequency, and duty cycle of the high-frequency PWM voltage by receiving the power adjustment signal from the power management circuit 140. 2 The C bus communicates with the processor 110 (such as an AP), receives a power adjustment signal, and then changes the voltage signal generated by it accordingly.

[0186] The motor system 130 can be applied to one or some components of the electronic device 100, such as the camera 150, the key 160, and the display screen 170. The dashed arrows in the figure represent a kind of hardware implementation dependency, that is, the camera 150, the key 160, and the display screen 170 can be implemented by relying on the motor system 130.

[0187] When the motor system 130 is applied to the camera 150, the VCM generates mechanical force to drive the lens to move to change the zoom ratio; when the motor system 130 is applied to the key 160, the VCM generates mechanical force to drive the rebound mechanism in the key to rebound; when the motor system 130 is applied to the display screen 170 (specifically, a touch screen), the VCM generates mechanical force to form force feedback and simulate force touch.

[0188] The following will be described taking the motor system 130 applied to the camera 150 as an example.

[0189] The camera 150 can include a lens, a VCM, a photosensitive sensor, and a controller. The camera 150 can also include a driver IC (not shown) connected with the VCM. The driver IC and the controller can be disposed on a flexible printed circuit board (FPCB). The FPCB can also be responsible for connecting some components in the camera 150 to the processor 110, such as transmitting raw data output by the photosensitive sensor to the processor 110 (specifically, an ISP).

[0190] When taking a photo, the shutter of the camera 150 is opened, and light enters and falls on the photosensitive sensor. The photosensitive sensor converts the light signal into an electrical signal, and further converts the electrical signal into a digital signal through analog digital conversion (ADC) to deliver to the ISP for processing. The ISP can perform the following processing on the output data of the photosensitive sensor: auto exposure control (AEC), auto gain control (AGC), auto white balance (AWB), color correction, bad point removal, and the like. The ISP can also be integrated in the camera 150.

[0191] Depending on whether the VCM is used for anti-shake, it can be divided into a motor only used for auto focus (AF) and a motor with both optical image stabilization (OIS) functions (also known as "optical anti-shake") functions. The AF VCM can be used to drive the lens to move in the optical axis direction. The OIS VCM can be used to drive the lens to move in the plane perpendicular to the optical axis. The controller can be used to adjust the current direction of the VCM coil to generate a motor thrust in a specified direction to achieve the zoom function of the AF VCM and the anti-shake function of the OIS VCM.

[0192] Generally, as shown in Figure 18 OIS requires at least four directions of shake compensation in the plane perpendicular to the optical axis: x1, x2, y1, y2. z1 and z2 in the figure represent the optical axis direction. When the above voltage doubling circuit is included in the motor system, a VCM provided by an embodiment of the present application can generate a bidirectional motor thrust, and can also reduce the number of OIS VCMs.

[0193] In the camera 150, a driver IC can be provided for the AF VCM and the OIS VCM to independently power the AF VCM and the OIS VCM. The driver ICs of the AF VCM and the OIS VCM can be connected through I 2The C bus communicates with the processor 110 (such as an AP), receives a power supply adjustment signal of the AFVCM and the OIS VCM, and then adaptively changes the amplitude, duty cycle, and frequency of the voltage signal generated by the conversion circuit in the respective driver IC. The driver IC also includes a high-frequency PWM first PWM wave circuit, which is used to introduce a high-frequency PWM current, thereby increasing the instantaneous current size across the coil load of the VCM under the same power consumption, and driving the motor to drive the lens to achieve fast zoom and anti-shake functions.

[0194] In a motor system including a voltage doubler circuit, the driver IC described above can be integrated with the improved voltage doubler circuit described in the foregoing embodiments, which can multiply the PWM voltage, increase the instantaneous current of the coil, and ultimately multiply the instantaneous thrust of the motor.

[0195] In this motor system, the controller can be used to control the selective conduction of the switch S1 in the voltage doubler circuit, thereby adjusting the current direction of the VCM coil to generate a motor thrust in a specified direction. Specifically, the controller can output an I 2 The C bus communicates with the processor 110 (such as an AP), receives an automatic zoom instruction and an optical anti-shake instruction, and then adaptively outputs a switch control signal to the control terminals C1 and C2 of the switch S1 in the voltage doubler circuit, adjusts the current direction of the VCM coil, and generates a motor thrust in a specified direction to achieve the automatic zoom and optical anti-shake objectives.

[0196] The camera 150 can have only one controller for controlling the current direction of the coils of multiple VCMs, thereby controlling the motor thrust direction of the multiple VCMs. That is, this one controller can be electrically connected to the switches S1 in the voltage doubler circuits of the multiple VCMs, and specifically connected to the control terminals C1 and C2 of the switches S1. Of course, the camera 150 can also have multiple controllers, one controller for each VCM to independently control the motor thrust direction of each VCM.

[0197] The key 160 can be a power key, a volume key, etc. The motor system 130 can be applied in the key 160 to drive the rebound mechanism to rebound and provide a clear rebound force, thereby improving the user's key experience.

[0198] The display screen 170 can be used to display images, videos, etc. The display screen 170 can be a touch screen with a touch panel, and the motor system 130 can be applied in the display screen 170 to generate a vibration prompt (such as a vibration prompt for incoming calls, alarms, etc.) or provide a touch force feedback to the user.

[0199] The power management circuit 140 can be used to connect the battery in the electronic device 100, the charging management module and the processor 110. The power management circuit 140 receives the input of the battery and / or the charging management module, and supplies power for the processor 110, the memory 120, the camera 150, the display screen, the wireless communication module, etc. Specifically, the power management circuit 140 can be connected to the driver IC matched with each VCM in the camera 150, so as to control the power supply for the camera through the driver IC. The power management circuit 140 can also be used to monitor the parameters such as the battery capacity, the battery cycle number, the battery health state (leakage, impedance), etc. The power management circuit 140 can also be arranged in the processor 110. The power management circuit 140 can also be integrated with the charging management module.

[0200] The electronic device 100 can also include a wireless communication module. The wireless communication module can provide a wireless communication solution applied to the electronic device 100, including wireless local area networks (WLAN) (such as a wireless fidelity (Wi-Fi) network), Bluetooth (BT), a global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared technology (IR), etc. The wireless communication module can also provide a wireless communication solution applied to the electronic device 100, including 2G / 3G / 4G / 5G, etc. The wireless communication module receives electromagnetic waves via an antenna, performs frequency modulation and filtering processing on the electromagnetic wave signals, and sends the processed signals to the processor 110. The wireless communication module can also receive signals to be sent from the processor 110, perform frequency modulation, amplification, and convert the signals to electromagnetic wave radiation via an antenna.

[0201] The electronic device 100 can also include an audio module, a speaker, a receiver, a microphone, and a headphone interface.

[0202] The electronic device can implement an audio function through an audio module, a speaker, a receiver, a microphone, a headset interface, an application processor (AP), and the like. For example, music playback, recording, and the like. The audio module is used to convert digital audio information into an analog audio signal output, and is also used to convert an analog audio input into a digital audio signal. The audio module can also be used to encode and decode audio signals. The audio module can be disposed in the processor 110, or part of the functions of the audio module can be disposed in the processor 110. The speaker, also known as the "loudspeaker", is used to convert an audio electrical signal into a sound signal. The electronic device can listen to music or listen to a hands-free call through the speaker. The receiver, also known as the "earpiece", is used to convert an audio electrical signal into a sound signal. When the electronic device answers a call or a voice message, the voice can be heard by placing the receiver close to the ear. The microphone, also known as the "microphone", "sound transducer", is used to convert a sound signal into an electrical signal. When making a call or sending a voice message, the user can speak into the microphone by placing the mouth close to the microphone to input the sound signal into the microphone. The headset interface is used to connect a wired headset. The headset interface can be a USB interface, or a 3.5mm open mobile terminal platform (OMTP) standard interface, a cellular telecommunications industry association of the USA (CTIA) standard interface.

[0203] The electronic device 100 can further include sensors such as a gyroscope, an accelerometer, a pressure sensor, a distance sensor, a proximity light sensor, an ambient light sensor, a Hall sensor, and the like. Among them, the gyroscope and the accelerometer are very necessary for OIS. The distance sensor, the Hall sensor, and the like can be sensors that directly or indirectly reflect the actual position of the object pushed by the motor, and can be used in the position detection circuit of the motor system 130.

[0204] Figure 17 The schematic structure does not constitute a specific limitation on the electronic device, and the electronic device can include more or fewer components than the schematic, or combine certain components, or split certain components, or different component arrangements. The components shown in the schematic can be implemented in hardware, software, or a combination of software and hardware.

[0205] In addition, based on the foregoing Figure 2 The open-loop motor system described in the embodiments is applied to the camera 150, and the embodiments of the present application further provide a motor control method.

[0206] As Figure 19 indicated, the method can include:

[0207] S103, the electronic device 100 converts the target stroke of the motor into a first frequency, a first amplitude, and a first duty cycle.

[0208] S104, the electronic device 100 generates a first PWM voltage according to the first frequency, the first amplitude, and the first duty cycle.

[0209] S105, the electronic device 100 converts the first PWM voltage into a first PWM current.

[0210] S106, the electronic device 100 outputs the first PWM current to the motor.

[0211] Further, as shown in FIG. 1, before the electronic device converts the target stroke of the motor into a first frequency, a first amplitude, and a first duty cycle, the motor control method can further include: Figure 19

[0212] S101, the electronic device 100 detects an operation of changing an optical zoom ratio of a camera module;

[0213] S102, the electronic device 100 determines a target stroke according to the optical zoom ratio.

[0214] In some embodiments, the electronic device can store a first mapping relationship. As described above, the first mapping relationship can record the motor strokes corresponding to different duty cycles of the first PWM voltage when the frequency is fixed at the first frequency and the amplitude is fixed at the second amplitude, and the motor strokes corresponding to different duty cycles include the target stroke.

[0215] The electronic device converts the target stroke of the motor into a first frequency, a first amplitude, and a first duty cycle, which can specifically include: the electronic device determines that the frequency of the first PWM voltage is fixed at the first frequency, the amplitude is fixed at the first amplitude, and the duty cycle corresponding to the target stroke is the first duty cycle based on the first mapping relationship.

[0216] In some embodiments, the electronic device can store a second mapping relationship. As described above, the second mapping relationship records the motor strokes corresponding to different amplitudes of the first PWM voltage when the frequency is fixed at the first frequency and the duty cycle is fixed at the first duty cycle, and the motor strokes corresponding to different amplitudes include the target stroke.

[0217] The electronic device converts the target stroke of the motor into a first frequency, a first amplitude, and a first duty cycle, which can specifically include: the electronic device determines that the frequency of the first PWM voltage is fixed at the first frequency, the duty cycle is fixed at the first duty cycle, and the amplitude corresponding to the target stroke is the first amplitude based on the second mapping relationship.

[0218] ​In some embodiments, the electronic device can store a third mapping relationship. As before, the third mapping relationship records the motor stroke corresponding to each frequency of the first PWM voltage when the amplitude is fixed at the first amplitude and the duty cycle is fixed at the first duty cycle, and the motor stroke corresponding to each frequency includes the target stroke.

[0219] The electronic device converts the target stroke of the motor into the first frequency, the first amplitude, and the first duty cycle, which can specifically include: the electronic device determines that the amplitude of the first PWM voltage is fixed at the first amplitude and the duty cycle is fixed at the first duty cycle, and determines that the frequency corresponding to the target stroke is the first frequency based on the third mapping relationship.

[0220] In some embodiments, the electronic device can also convert the target stroke into the first frequency, the first amplitude, and the first duty cycle for generating the first PWM through a PID control algorithm.

[0221] Further, on the premise that the motor system further includes a position detection circuit and a control circuit to constitute a closed-loop motor system, the motor control method can further include:

[0222] S107, after the electronic device 100 outputs the first PWM current to the motor, the electronic device determines whether the rotor of the motor is at the target position;

[0223] S108, if not, the electronic device 100 determines the target stroke according to the position deviation between the actual position of the rotor of the motor and the target position, and the electronic device 100 converts the re-determined target stroke into the second frequency, the second amplitude, and the second duty cycle through a PID algorithm;

[0224] S109, the electronic device 100 generates a second PWM voltage according to the second frequency, the second amplitude, and the second duty cycle;

[0225] S110, the electronic device 100 converts the second PWM voltage into a second PWM current;

[0226] S111, the electronic device 100 outputs the second PWM current to the motor.

[0227] In addition, based on the foregoing Figure 12B 、 Figure 15A - Figure 15B Embodiments of the motor system described are applied to the camera 150, and the present application further provides another motor control method to control the motor to output a motor thrust in a specified direction.

[0228] As Figure 20 shown, the method can include:

[0229] S201, the electronic device 100 detects an operation of increasing the optical zoom ratio of the camera 150.

[0230] S202, the electronic device 100 turns on the switch S1 in the AF VCM voltage doubler circuit in the camera 150 to the first active terminal.

[0231] When the switch S1 is turned on to the first active terminal, the direction of the AF VCM coil current is from the first end of the coil to the second end of the coil. At this time, the lens of the camera 150 moves in the optical axis to the direction away from the photographed object.

[0232] S203, the electronic device detects an operation of reducing the optical zoom ratio of the camera 150.

[0233] S204, the electronic device 100 turns on the switch S1 in the AF VCM voltage doubler circuit in the camera 150 to the second active terminal.

[0234] When the switch S1 is turned on to the second active terminal, the direction of the AF VCM coil current is from the second end of the coil to the first end of the coil. At this time, the lens of the camera 150 moves in the optical axis to the direction close to the photographed object.

[0235] In the case of the AF VCM voltage doubler circuit as described in the embodiments, the first active terminal can refer to the active terminal T1, and the second active terminal can refer to the active terminal T2. Figure 12A - Figure 12B In the case of the AF VCM voltage doubler circuit as described in the embodiments, the first active terminal can refer to the group of active terminals T1, T3, and the second active terminal can refer to the group of active terminals T2, T4. Figure 15A - Figure 15B In the case of the AF VCM voltage doubler circuit as described in the embodiments, the first active terminal can refer to the group of active terminals T1, T3, and the second active terminal can refer to the group of active terminals T2, T4.

[0236] Further, the method can further include:

[0237] S205, when the camera 150 is turned on to collect images, the electronic device 100 detects device jitter in a third direction.

[0238] The third direction can be one OIS direction of the camera 150. In this paper, the OIS direction refers to the direction in which the OIS VCM provides jitter compensation. The OIS VCM can provide jitter compensation in Figure 11 four directions represented by x1, y1, x2, y2, which are the OIS directions. Of course, the OIS VCM can also provide jitter compensation in more (such as 8) directions, i.e. have more OIS directions. This embodiment is described with the camera 150 having four OIS directions as an example.

[0239] S206, the electronic device 100 turns on the switch S1 in the OIS VCM voltage doubler circuit in the camera 150 to the first active terminal.

[0240] When switch S1 is switched to the first active terminal, the direction of the OIS VCM coil current is from the first end of the coil to the second end of the coil. At this time, the lens of camera 150 moves in the fourth direction on the optical axis plane. The fourth direction is the opposite direction of the third direction, and is another OIS direction of camera 150. The third direction and the fourth direction can be x1 and x2, or y1 and y2 in FIG. 1, respectively. Figure 18

[0241] S207, when starting image acquisition by camera 150, electronic device 100 detects device jitter in the fourth direction.

[0242] S208, electronic device 100 switches switch S1 in the OIS VCM voltage doubling circuit in camera 150 to the second active terminal.

[0243] When switch S1 is switched to the second active terminal, the direction of the OIS VCM coil current is from the second end of the coil to the first end of the coil. At this time, the lens of camera 150 moves in the third direction on the optical axis plane.

[0244] An actual device jitter may not be simply a device jitter in a certain OIS direction. In this case, the actual device jitter can be decomposed into device jitters in two perpendicular OIS directions, for example, x1 and y1 directions in FIG. 1. After performing the decomposition, the device jitters in the single OIS direction are compensated for. Figure 11

[0245] In the above method, the execution order of S201-S202, S203-S204, S205-S206, and S207-S208 is not particularly limited. S203-S204 can be executed before S201-S202, for example, the user first reduces the zoom ratio and then increases the zoom ratio. S207-S208 can also be executed before S205-S206. S205-S206 and S207-S208 can be executed before S201-S202 and S203-S204, for example, the device jitter occurs before the user focuses. S205-S206 and S207-S208 can also be executed simultaneously with S201-S202 and S203-S204, for example, the device jitter occurs when the user focuses.

[0246] The VCM control method provided in the embodiments of the present application is further described in detail below based on the internal architecture of electronic device 100.

[0247] S301, after detecting an operation of increasing the optical zoom ratio of camera 150 through a touch screen or other input device, the processor can send a first automatic focusing instruction to the controller in camera 150. The instruction can indicate that the lens moves away from the photographed object.​​

[0248] S302, the controller outputs a first control signal to the control end of switch S1 in the AF VCM voltage doubler circuit.

[0249] S303, in response to the first control signal, switch S1 in the AF VCM voltage doubler circuit is switched to the first active end to conduct. The first control signal can be a level signal.

[0250] S304, after detecting an operation of reducing the optical zoom ratio of camera 150 through a touch screen or other input device, the processor can send a second autofocus instruction to the controller in camera 150, which can indicate that the lens moving direction is to move close to the photographed object.

[0251] S305, the controller outputs a second control signal to the control end of switch S1 in the AF VCM voltage doubler circuit.

[0252] S306, in response to the second control signal, switch S1 in the AF VCM voltage doubler circuit is switched to the second active end to conduct. The second control signal can be a level signal.

[0253] In addition, when detecting device jitter, the processor can also send an OIS instruction to OIS VCM 1 or OIS VCM 2, which can indicate the direction of anti-shake compensation. Details are as follows.

[0254] S307, after detecting x1 direction device jitter through a gyroscope, accelerometer or other input device, the processor can send an OIS instruction to the controller in camera 150, which can indicate that the direction of anti-shake compensation is x2 direction.

[0255] S308, the controller outputs a first control signal to the control end of switch S1 in the voltage doubler circuit of OIS VCM 1.

[0256] S309, in response to the first control signal, switch S1 in the voltage doubler circuit of OIS VCM 1 is switched to the first active end to conduct.

[0257] S310, after detecting x2 direction device jitter through a gyroscope, accelerometer or other input device, the processor can send an OIS instruction to the controller in camera 150, which can indicate that the direction of anti-shake compensation is x1 direction.

[0258] S311, the controller outputs a second control signal to the control end of switch S1 in the voltage doubler circuit of OIS VCM 1.

[0259] S312, in response to the second control signal, switch S1 in the voltage doubler circuit of OIS VCM 1 is switched to the second active end to conduct.

[0260] By controlling the conduction of switch S1 in the voltage doubler circuit of OIS VCM 1, the movement of the lens in the anti-shake compensation direction can be controlled, and the anti-shake compensation can be realized.

[0261] Similarly, after detecting the device jitter in the y1 or y2 direction through the gyroscope, accelerometer, or other input devices, the processor can also send an OIS instruction to the controller in the camera 150 and indicate the anti-shake compensation direction; the controller can control the conduction of switch S1 in the voltage doubler circuit of OIS VCM 2 according to the OIS instruction, so as to control the movement of the lens in the anti-shake compensation direction, and realize the anti-shake compensation.

[0262] The steps in the above method embodiments provided by the present application can be completed by integrated logic circuits of hardware in the processor or instructions in the form of software. The method steps disclosed in the embodiments of the present application can be directly embodied as hardware processor execution completion, or executed by a combination of hardware and software modules in the processor.

[0263] The present application also provides an electronic device, which can include a memory and a processor. The memory can be used to store a computer program, and the processor can be used to call the computer program in the memory to enable the electronic device to execute the method in any one of the above embodiments.

[0264] The present application also provides a chip system, which includes at least one processor for realizing the functions involved in the method executed by the electronic device in any one of the above embodiments.

[0265] In a possible design, the chip system further includes a memory for saving program instructions and data, and the memory is located in the processor or outside the processor.

[0266] The chip system can be composed of a chip, or can include a chip and other discrete devices.

[0267] Optionally, the processor in the chip system can be one or more. The processor can be implemented by hardware or software. When implemented by hardware, the processor can be a logic circuit, an integrated circuit, or the like. When implemented by software, the processor can be a general-purpose processor, which realizes by reading software codes stored in the memory.

[0268] Optionally, the memory in the chip system can also be one or more. The memory can be integrated with the processor, or can be arranged separately from the processor, and the embodiments of the present application are not limited. Exemplarily, the memory can be a non-transient processor, for example, a read-only memory (ROM), which can be integrated on the same chip as the processor, or can be arranged separately on different chips, and the embodiments of the present application do not make specific limitations on the type of memory and the arrangement of the memory and the processor.

[0269] Exemplarily, the chip system can be a field programmable gate array (FPGA), can be an application specific integrated circuit (ASIC), can also be a system on chip (SoC), can also be a central processor unit (CPU), can also be a network processor (NP), can also be a digital signal processor (DSP), can also be a micro controller unit (MCU), can also be a programmable logic device (PLD) or other integrated chip.

[0270] The present application also provides a computer program product, which comprises a computer program (also referred to as code or instructions). When the computer program is executed, the computer executes the method performed by the electronic device in any one of the above embodiments.

[0271] The present application also provides a computer readable storage medium, which stores a computer program (also referred to as code or instructions). When the computer program is executed, the computer executes the method performed by the electronic device in any one of the above embodiments.

[0272] The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on the computer, all or part of the processes or functions according to the present application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer instructions can be stored in a computer-readable storage medium or transferred from one computer-readable storage medium to another, for example, the computer instructions can be transferred from one website, computer, server or data center to another website, computer, server or data center through wired (such as coaxial cable, optical fiber, digital subscriber line) or wireless (such as infrared, wireless, microwave, etc.) mode. The computer-readable storage medium can be any available medium that the computer can access or a data storage device such as a server, data center, etc. that includes one or more available media sets. The available media can be a magnetic medium (for example, a floppy disk, a hard disk, a magnetic tape), an optical medium (for example, a DVD), or a semiconductor medium (for example, a solid state disk), etc.

[0273] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be implemented by a computer program instructing the relevant hardware, which can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the above-mentioned method embodiments. The aforementioned storage medium includes ROM or random access memory (RAM), magnetic disk or optical disk, and various media that can store program codes.

[0274] In summary, the above is only an embodiment of the technical scheme of the present application, and is not used to limit the protection scope of the present application. Any modification, equivalent replacement, improvement, etc. made according to the disclosure of the present application shall be included in the protection scope of the present application.

Claims

1. A motor drive circuit, characterized in that, The motor drive circuit includes: a conversion circuit and a first pulse width modulation (PWM) wave circuit; wherein, the conversion circuit is coupled to the first PWM wave circuit, the conversion circuit is also coupled to the power supply module of the motor drive circuit for receiving power from the power supply module, and the conversion circuit is also connected to a processor for receiving travel instructions from the processor, the travel instructions including the target position of the motor; The conversion circuit is used to convert the power supply voltage into a first PWM voltage with a first frequency, a first amplitude, and a first duty cycle according to the target stroke of the motor. The target stroke is determined by the conversion circuit based on the target position and the actual position of the motor. Specifically, the conversion circuit is used to determine the value of the third parameter corresponding to the target stroke based on the mapping relationship between the duty cycle, amplitude, or frequency of the first PWM voltage and the motor stroke, when any two of the three parameters of the first PWM voltage are fixed. The mapping relationship is used to record the correspondence between the duty cycle, amplitude, or frequency of the first PWM voltage and the motor displacement, and can be used to record the motor stroke when the third parameter takes different values ​​when any two of the three parameters of the frequency, amplitude, and duty cycle are fixed. The conversion circuit is also used to output the first PWM voltage to the first PWM wave circuit; The first PWM wave circuit is used to convert the first PWM voltage into a first PWM current; the frequency of the first PWM current is close to or equal to the first frequency, and the duty cycle of the first PWM current is close to or equal to the first duty cycle. The first PWM wave circuit is also connected to the motor, and is used to output the first PWM current to the motor to control the motor to generate motor thrust.

2. The motor drive circuit according to claim 1, characterized in that, The conversion circuit is used to convert the supply voltage into a first PWM voltage with a first frequency, a first amplitude, and a first duty cycle according to the target stroke of the motor. Specifically, it includes: The conversion circuit is used to determine that the frequency of the first PWM voltage is fixed to the first frequency, the amplitude is fixed to the first amplitude, and to determine the duty cycle corresponding to the target stroke as the first duty cycle based on the first mapping relationship. The first mapping relationship records the motor travel corresponding to different duty cycles when the first PWM voltage has a fixed frequency and a fixed amplitude. The motor travel corresponding to different duty cycles includes the target travel.

3. The motor drive circuit according to claim 2, characterized in that, In the first mapping relationship, the duty cycle and motor stroke exhibit a linear relationship.

4. The motor drive circuit according to claim 1, characterized in that, The second mapping relationship records the motor travel corresponding to different amplitudes of the first PWM voltage when the frequency and duty cycle are fixed at the first frequency and the duty cycle are fixed at the first duty cycle. The motor travel corresponding to different amplitudes includes the target travel. The conversion circuit is used to convert the supply voltage into a first PWM voltage with a first frequency, a first amplitude, and a first duty cycle according to the target stroke of the motor. Specifically, it includes: The conversion circuit is used to determine that the frequency of the first PWM voltage is fixed at the first frequency, the duty cycle is fixed at the first duty cycle, and the amplitude corresponding to the target stroke is determined to be the first amplitude based on the second mapping relationship.

5. The motor drive circuit according to claim 4, characterized in that, In the second mapping relationship, the amplitude and motor stroke exhibit a linear relationship.

6. The motor drive circuit according to claim 1, characterized in that, The third mapping relationship records the motor travel corresponding to different frequencies when the amplitude and duty cycle of the first PWM voltage are fixed at the first amplitude and the first duty cycle, respectively. The motor travel corresponding to different frequencies includes the target travel. The conversion circuit is used to convert the supply voltage into a first PWM voltage with a first frequency, a first amplitude, and a first duty cycle according to the target stroke of the motor. Specifically, it includes: The conversion circuit is used to determine that the amplitude of the first PWM voltage is fixed at the first amplitude, the duty cycle is fixed at the first duty cycle, and to determine the frequency corresponding to the target stroke as the first frequency based on the third mapping relationship.

7. The motor drive circuit according to claim 6, characterized in that, In the third mapping relationship, frequency and motor stroke exhibit a linear relationship.

8. The motor drive circuit according to any one of claims 1-7, characterized in that, The motor drive circuit further includes a control circuit; the control circuit is coupled to the conversion circuit and is used to output the target stroke to the conversion circuit; the control circuit is also coupled to a processor and is used to receive a stroke command transmitted by the processor, the stroke command carrying the target position of the motor; the control circuit is also coupled to a position detection circuit in the motor and is used to receive the actual position of the motor mover in the motor transmitted by the position detection circuit. The position detection circuit is used to detect the actual position of the motor actuator; The target stroke is determined based on the target position and the actual position of the motor actuator. The closer the actual position is to the target position, the smaller the target stroke.

9. The motor drive circuit according to claim 8, characterized in that, The conversion circuit is used to convert the supply voltage into a first PWM voltage with a first frequency, a first amplitude, and a first duty cycle according to the target stroke of the motor. Specifically, it includes: The conversion circuit is used to convert the target stroke into the first frequency, the first amplitude, and the first duty cycle using a proportional-integral-derivative (PID) control algorithm. The conversion circuit is also used to generate the first PWM voltage according to the first frequency, the first amplitude, and the first duty cycle.

10. The motor drive circuit according to claim 1, characterized in that, The motor drive circuit further includes a voltage multiplier circuit, the input terminal of which is coupled to the conversion circuit, and the output terminal of which is coupled to the first PWM wave circuit. The voltage multiplier circuit is used to boost the first PWM voltage generated by the conversion circuit and then output it to the first PWM wave circuit to convert it into the first PWM current.

11. The motor drive circuit according to claim 10, characterized in that, The voltage multiplier circuit includes: a capacitor C1, a first unidirectional conduction device, a second unidirectional conduction device, and a switch S1, as well as a first input terminal, a second input terminal, a first output terminal, and a second output terminal; wherein: the first end of the capacitor C1 is coupled to the first input terminal, the second end of the capacitor C1 is coupled to the first output terminal, and the second output terminal is coupled to the second input terminal; one end of the first unidirectional conduction device is coupled to the second end of the capacitor C1, and the other end is coupled to the first moving end of the switch S1; one end of the second unidirectional conduction device is also coupled to the second end of the capacitor C1, and the other end is coupled to the second moving end of the switch S1; the stationary end of the switch S1 is coupled to the second input terminal; the first unidirectional conduction device and the second unidirectional conduction device have opposite conduction directions.

12. The motor drive circuit according to claim 11, characterized in that, The voltage multiplier circuit is an n-stage voltage multiplier circuit, where n ≥ 2 and n is a positive integer; a switch S1 is connected in parallel across the capacitor Cn in the nth stage charging and discharging circuit of the voltage multiplier circuit, and the switch S1 is used to adjust the voltage polarity of the output voltage of the voltage multiplier circuit.

13. A motor system, characterized in that, It includes a motor drive circuit and a motor; wherein the output circuit of the motor drive circuit is coupled to the motor, and the motor drive circuit is the motor drive circuit according to any one of claims 1-12.

14. The motor system according to claim 13, characterized in that, The motor system also includes a position detection circuit, and the motor drive circuit also includes a control circuit. The position detection circuit is coupled to the control circuit in the motor drive circuit. The position detection circuit is used to detect the actual position of the motor mover and output the detected actual position to the control circuit.

15. An electronic device, characterized in that, include: A motor system and a processor; wherein the motor system is the motor system according to claim 13 or 14; The processor is coupled to the motor drive circuit in the motor system, and the processor is used to transmit a travel command to the motor drive circuit in the motor system, the travel command including the target position of the motor.

16. The electronic device according to claim 15, characterized in that, The motor system is located in the camera module of the electronic device.

17. A motor control method, said method being applied to an electronic device, characterized in that, The electronic device is the electronic device according to claim 15 or 16; The method includes: The electronic device converts the target stroke of the motor into the first frequency, the first amplitude, and the first duty cycle. Specifically, when any two of the three parameters of the first PWM voltage (frequency, amplitude, and duty cycle) are fixed, the electronic device determines the value of the third parameter corresponding to the target stroke based on the mapping relationship between the duty cycle, amplitude, or frequency of the first PWM voltage and the motor stroke. The mapping relationship is used to record the correspondence between the duty cycle, amplitude, or frequency of the first PWM voltage and the motor displacement, and can be used to record the motor stroke when the third parameter takes different values ​​when any two of the three parameters (frequency, amplitude, and duty cycle) are fixed. The electronic device generates the first PWM voltage based on the first frequency, the first amplitude, and the first duty cycle. The electronic device converts the first PWM voltage into a first PWM current; The electronic device outputs the first PWM current to the motor.

18. The method according to claim 17, characterized in that, Before the electronic device converts the target stroke of the motor into the first frequency, the first amplitude, and the first duty cycle, the method further includes: The electronic device detects an operation that changes the optical zoom ratio of the camera module. The electronic device determines the target travel distance based on the optical zoom ratio.

19. The method according to claim 17 or 18, characterized in that, The electronic device stores a first mapping relationship, which records the motor stroke corresponding to different duty cycles when the first PWM voltage has a fixed frequency and a fixed amplitude. The motor stroke corresponding to different duty cycles includes the target stroke. The electronic device converts the target stroke of the motor into the first frequency, the first amplitude, and the first duty cycle, specifically including: The electronic device determines that the frequency of the first PWM voltage is fixed at the first frequency, the amplitude is fixed at the first amplitude, and determines the duty cycle corresponding to the target stroke as the first duty cycle based on the first mapping relationship.

20. The method according to claim 17 or 18, characterized in that, The electronic device stores a second mapping relationship, which records the motor stroke corresponding to different amplitudes of the first PWM voltage when the frequency and duty cycle are fixed at the first frequency and the duty cycle is fixed at the first duty cycle. The motor stroke corresponding to different amplitudes includes the target stroke. The electronic device converts the target stroke of the motor into the first frequency, the first amplitude, and the first duty cycle, specifically including: The electronic device determines that the frequency of the first PWM voltage is fixed at the first frequency, the duty cycle is fixed at the first duty cycle, and determines the amplitude corresponding to the target stroke as the first amplitude based on the second mapping relationship.

21. The method according to claim 17 or 18, characterized in that, The electronic device stores a third mapping relationship, which records the motor stroke corresponding to different frequencies when the amplitude and duty cycle of the first PWM voltage are fixed at the first amplitude and the first duty cycle, respectively. The motor stroke corresponding to different frequencies includes the target stroke. The electronic device converts the target stroke of the motor into the first frequency, the first amplitude, and the first duty cycle, specifically including: The electronic device determines that the amplitude of the first PWM voltage is fixed at the first amplitude value, the duty cycle is fixed at the first duty cycle value, and determines the frequency corresponding to the target stroke as the first frequency based on the third mapping relationship.

22. The method according to claim 17 or 18, characterized in that, The electronic device converts the target stroke of the motor into the first frequency, the first amplitude, and the first duty cycle, specifically including: The electronic device uses a PID control algorithm to convert the target stroke into the first frequency, the first amplitude, and the first duty cycle.

23. The method according to claim 17, characterized in that, The motor system further includes a position detection circuit and a control circuit, and the method further includes: After the electronic device outputs the first PWM current to the motor, the electronic device determines whether the motor mover is in the target position; If not, the electronic device determines the target stroke again based on the positional deviation between the actual position of the motor mover and the target position. The electronic device then uses a PID algorithm to convert the re-determined target stroke into a second frequency, a second amplitude, and a second duty cycle. The electronic device generates a second PWM voltage based on the second frequency, the second amplitude, and the second duty cycle. The electronic device converts the second PWM voltage into a second PWM current; The electronic device outputs the second PWM current to the motor.

24. A computer-readable storage medium comprising a coded instruction sequence, characterized in that, When the coded instruction sequence is run on an electronic device, it causes the method described in any one of claims 17-23 to be performed.

Citation Information

Patent Citations

  • Piezoelectric driving circuit and camera module

    CN115425868A