Anti-shake method and device and electronic equipment

By employing different image stabilization compensation modes in electronic devices based on shooting conditions and motion parameters, combined with the adjustment of electromagnetic coils and micro-spring-damping composite layers, the problem of lens component wear in non-shooting states in existing technologies has been solved, achieving a more efficient image stabilization compensation effect and improving image quality.

CN121603780APending Publication Date: 2026-03-03VIVO MOBILE COMM HANGZHOU CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511798103.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-12-01
Publication Date
2026-03-03

AI Technical Summary

Technical Problem

Existing optical image stabilization technologies are effective in compensating for image loss when the camera module is in shooting mode, but lack effective image stabilization solutions when not shooting. This leads to easy wear and displacement of lens components in complex motion environments, affecting image quality.

Method used

By acquiring motion parameters and shooting status information of the electronic device, image stabilization compensation is performed using the first compensation mode in non-shooting mode and the second compensation mode in shooting mode. Combined with the adjustment of the electromagnetic coil and the micro-spring-damping composite layer, precise image stabilization compensation for the lens assembly is achieved.

Benefits of technology

It improves the image stabilization compensation effect of electronic devices when not shooting, avoids damage to lens components, improves image stability and clarity, and adapts to complex motion environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121603780A_ABST
    Figure CN121603780A_ABST
Patent Text Reader

Abstract

The invention discloses an anti-shake method and device and electronic equipment, and belongs to the technical field of electronic equipment. The method comprises the following steps: acquiring motion parameters of the electronic equipment and shooting state information of a camera module of the electronic equipment; under the condition that the shooting state information indicates that the camera module is in a non-shooting mode, executing anti-shake compensation on the electronic equipment by utilizing a first compensation mode; and / or under the condition that the shooting state information indicates that the camera module is in the shooting mode, executing anti-shake compensation on the electronic equipment by using a second compensation mode.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application belongs to the field of electronic equipment technology, and specifically relates to a stabilization method, device and electronic equipment. Background Technology

[0002] With the rapid development of imaging capabilities in electronic devices, high-precision optical image stabilization systems have become a key component of the lens assembly. Their core objective is to counteract hand shake by real-time activation of moving parts within the lens assembly when the electronic device is being held, thereby improving image sharpness and success rate during shooting. However, current optical image stabilization technologies offer limited effectiveness. Summary of the Invention

[0003] The purpose of this application is to provide a stabilization method, apparatus, and electronic device to improve the stabilization compensation effect of the electronic device.

[0004] In a first aspect, embodiments of this application provide a stabilization method, the method comprising: Acquire motion parameters of the electronic device and shooting status information of the camera module of the electronic device; When the shooting status information indicates that the camera module is in non-shooting mode, and the motion parameters indicate that the motion intensity of the electronic device is greater than a first threshold, image stabilization compensation is performed on the electronic device using a first compensation mode; and / or, When the shooting status information indicates that the camera module is in shooting mode, the second compensation mode is used to perform image stabilization compensation on the electronic device.

[0005] Secondly, embodiments of this application provide a shake stabilization device, which includes: The acquisition module is used to acquire the motion parameters of the electronic device and the shooting status information of the camera module of the electronic device; The image stabilization compensation module is configured to perform image stabilization compensation on the electronic device using a first compensation mode when the shooting status information indicates that the camera module is in a non-shooting mode and the motion parameters indicate that the motion intensity of the electronic device is greater than a first threshold; and / or, when the shooting status information indicates that the camera module is in a shooting mode, perform image stabilization compensation on the electronic device using a second compensation mode.

[0006] Thirdly, embodiments of this application provide an electronic device, which includes a processor and a memory, wherein the memory stores programs or instructions that can run on the processor, and the programs or instructions, when executed by the processor, implement the method as described in the first aspect.

[0007] Fourthly, embodiments of this application provide a readable storage medium on which a program or instructions are stored, which, when executed by a processor, implement the method described in the first aspect.

[0008] Fifthly, embodiments of this application provide a chip, the chip including a processor and a communication interface, the communication interface being coupled to the processor, the processor being used to run programs or instructions to implement the method as described in the first aspect.

[0009] In a sixth aspect, embodiments of this application provide a computer program product stored in a storage medium, which is executed by at least one processor to implement the method described in the first aspect.

[0010] In this embodiment, by acquiring the motion parameters of the electronic device and the shooting status information of the camera module, when the shooting status information indicates that the camera module is in non-shooting mode, a first compensation mode is used to perform image stabilization compensation on the electronic device; when the shooting status information indicates that the camera module is in shooting mode, a second compensation mode is used to perform image stabilization compensation on the electronic device. Thus, different compensation methods are used to perform image stabilization compensation on the electronic device according to the different states of the camera module, rather than using a uniform image stabilization compensation method, thereby improving the accuracy of image stabilization compensation and thus improving the image stabilization compensation effect of the electronic device. Furthermore, the solution of this embodiment also compensates for image stabilization when the camera module is in non-shooting mode, filling the gap in existing solutions that cannot perform image stabilization compensation for non-shooting modes. Attached Figure Description

[0011] Figure 1 This is a flowchart illustrating some embodiments of the anti-shake method provided in this application; Figure 2 This is a flowchart illustrating some embodiments of the anti-shake method provided in this application; Figure 3 These are schematic diagrams illustrating the structure of the image stabilization device according to some embodiments of this application; Figure 4 These are schematic diagrams illustrating the structure of an electronic device according to some embodiments of this application; Figure 5 These are schematic diagrams illustrating the hardware structure of an electronic device according to some embodiments of this application. Detailed Implementation

[0012] The technical solutions of the embodiments of this application will be clearly described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this application. All other embodiments obtained by those skilled in the art based on the embodiments of this application are within the scope of protection of this application.

[0013] The terms "first," "second," etc., used in the specification and claims of this application are used to distinguish similar objects and not to describe a specific order or sequence. It should be understood that such use of data can be interchanged where appropriate so that embodiments of this application can be implemented in orders other than those illustrated or described herein, and the objects distinguished by "first," "second," etc., are generally of the same class and are not limited in number; for example, a first object can be one or N objects. Furthermore, in the specification and claims, "and / or" indicates at least one of the connected objects, and the character " / " generally indicates that the preceding and following objects are in an "or" relationship.

[0014] The terminology used in the embodiments of this invention will be explained below.

[0015] Optical image stabilization (OIS) relies on the structure of special lenses or charge-coupled device (CCD) image sensors to minimize image instability caused by operator shake. OIS technology works by having a gyroscope within the lens detect minute movements, sending a signal to a microprocessor to calculate the amount of displacement that needs compensation. Then, a compensation lens group applies this compensation based on the direction and amount of lens shake, effectively overcoming image blur caused by camera vibration.

[0016] The micro-spring-damping composite layer in the camera module is a key vibration reduction component for optical image stabilization. Through the synergistic action of the elastic support of the spring and the energy dissipation of the damping material, it suppresses minor vibrations of the camera during handheld shooting and improves imaging stability.

[0017] Gyroscope: A gyroscope is an instrument that uses the properties of a gyroscope to keep a carrier relatively stable in its original direction. This device is classified into single-axis, dual-axis, and tri-axis gyroscopes according to its degrees of freedom.

[0018] In current optical image stabilization (OIS) technologies, the focus is primarily on image compensation during camera module operation. That is, current OIS mainly addresses image compensation when the camera module is in shooting mode, and there are no feasible solutions for image compensation outside of shooting mode. However, when electronic devices are in standby, portable, or non-shooting operation mode, the lens components within the camera module are typically in a free-moving state without power, lacking effective mechanical restraint. In everyday use, such as walking, running, or the shaking and impact when carrying a backpack, these moving parts will repeatedly collide with surrounding fixed limiting structures due to inertia. This can lead to wear and tear on the lens's delicate structure, displacement, or even malfunction of the focusing function.

[0019] While physical restraints or simple cushioning pads can be used to mitigate the problem, these solutions are ineffective in complex motion environments due to fixed buffer boundaries, low energy absorption efficiency of the materials, and inability to adapt to multi-dimensional impact trajectories. Furthermore, while optical image stabilization technology currently performs well for simple movements, it is less effective for complex activities such as running.

[0020] The following section details the working principle of optical image stabilization and explains why the lens assembly might slide back and forth in a user's pocket during activities such as running when the camera module is powered off: The key to preventing components in a camera module from "wobbling" in electronic devices lies in the limiting device and an invisible "electronic rope" within the camera module. This is not a simple physical latch, but a sophisticated electromagnetic control system, which can be understood as "magnetic levitation limiting." This system mainly consists of three parts: a) Mechanical limiting structure: The image stabilization components (whether lens assemblies or complementary metal-oxide-semiconductor (CMOS) sensors) are not entirely "free." They are supported on the frame by extremely precise slide rails, ball bearings, or flexible suspension wires. These structures serve two purposes: firstly, they allow minute movements: they allow the image stabilization components to translate within a tiny range (typically only a fraction of a millimeter) in the X and Y axes parallel to the sensor plane. Secondly, they provide restoring force and limit travel: these mechanical structures are inherently elastic, pulling the image stabilization components back to their centered position when no external force is applied. More importantly, their physical structure itself sets boundaries for movement, preventing components from moving too far and colliding with other parts or detaching. This is the most basic physical limiting mechanism.

[0021] b) Electromagnetic drive and locking system: This is the core principle of image stabilization, and the intelligent part that achieves "movement without erratic shaking." Its working principle is as follows: a permanent magnet is attached to the image stabilization component, and coils (electromagnets) are arranged around it on the camera module frame. When the phone's gyroscope detects shaking, the processor calculates the compensation path in real time and sends a precisely controlled current to the corresponding coil, generating a magnetic field. This magnetic force "pushes" or "pushes" the permanent magnet, thus moving the image stabilization component in the direction that counteracts the shaking. When image stabilization is enabled or the camera is working, the system sends a fixed, weak current to the coil. The magnetic force generated by this current acts like an invisible "hand," firmly holding the image stabilization component in the center. This state is called "closed-loop motor" mode or locked mode. In this state, even if the phone is shaken forcefully, the image stabilization component will be firmly "held" by the magnetic force and will not shake freely, its stability being far superior to simple mechanical restraint.

[0022] c) Sensor feedback: Advanced OIS systems also incorporate position sensors (such as Hall effect sensors) to monitor the position of the stabilization components in real time and feed the information back to the processor. The processor uses algorithms to ensure precise movement that does not exceed the system's predefined electronic safety range, forming a closed-loop control.

[0023] When the camera is off, the OIS system does indeed lose power. The electromagnetic locking force that previously "holds" the components in place disappears. At this point, the image stabilization component relies solely on the mechanical limiting structures mentioned above (such as flexible suspension wires, slide rails, and ball bearings). It is no longer in a "locked" state, but rather in a "suspended" or "suspended" state. This mechanical structure itself allows the component to move within a limited range. Therefore, when a user runs, the phone shakes and impacts frequently in their pocket, and the image stabilization component will sway back and forth with inertia within the gaps allowed by its mechanical structure.

[0024] To address the aforementioned issues, this application provides a stabilization method, apparatus, electronic device, and storage medium. By acquiring the motion parameters of the electronic device and the shooting status information of its camera module, when the shooting status information indicates the camera module is in non-shooting mode and the motion parameters indicate the motion intensity of the electronic device is greater than a first threshold, stabilization compensation is performed on the electronic device using a first compensation mode. When the shooting status information indicates the camera module is in shooting mode, stabilization compensation is performed on the electronic device using a second compensation mode. Thus, different compensation methods are used to perform stabilization compensation based on the different states of the camera module, rather than using a uniform stabilization compensation method, improving the accuracy of stabilization compensation and thereby enhancing its effectiveness. Furthermore, the solution in this application also compensates for stabilization when the camera module is in non-shooting mode, filling the gap in existing solutions that cannot perform stabilization compensation for non-shooting modes.

[0025] The technical solution of this application embodiment can be applied to how to compensate for the shaking of components in the camera module of a mobile phone during the user's movement while carrying the mobile phone, so as to avoid the components shaking and causing damage to the components, and to the scenario where the image captured by the camera is blurry during the shooting process.

[0026] The information processing method provided in this application will be described in detail below with reference to the accompanying drawings, through specific embodiments and application scenarios.

[0027] Figure 1 This is a flowchart illustrating a stabilization method provided in an embodiment of this application. The subject executing the stabilization method can be an electronic device, specifically the controller of the electronic device. The electronic device can be, but is not limited to, a personal computer (PC), a smartphone, a tablet computer, or a personal digital assistant (PDA).

[0028] like Figure 1 As shown, the image stabilization method provided in this application embodiment may include steps 110-120.

[0029] Step 110: Obtain the shooting status information of the camera module of the electronic device.

[0030] The shooting status information can be used to characterize the camera module's shooting state, such as whether the camera module is in shooting mode or not. This shooting status information can be obtained by monitoring the interrupt request signal of the camera module's driver and the status register of the image signal processor, as well as detecting changes in the level of the physical shutter button. This shooting status information can be a binary status flag; for example, a value of "1" can indicate that shooting is in progress, i.e., the camera module is in shooting mode, and a value of "0" can indicate that shooting is not in progress.

[0031] Step 120: When the shooting status information indicates that the camera module is in non-shooting mode, perform image stabilization compensation on the electronic device using the first compensation mode; and / or, when the shooting status information indicates that the camera module is in shooting mode, perform image stabilization compensation on the electronic device using the second compensation mode.

[0032] The first compensation mode can be a method of performing image stabilization compensation on the electronic device when the shooting status information indicates that the camera module is in non-shooting mode. This first compensation mode will be described in more detail in later embodiments.

[0033] The second compensation mode can be a mode that performs image stabilization compensation on electronic devices when the shooting status information indicates that the camera module is in shooting mode.

[0034] In some embodiments of this application, in order to save the resource consumption of the electronic device and reduce the computing power of the electronic device, the above-mentioned method may further include the following before performing image stabilization compensation on the electronic device using the first compensation mode: Acquire motion parameters of electronic devices; Step 120 may specifically include: When the shooting status information indicates that the camera module is in non-shooting mode, and the motion parameters indicate that the motion intensity of the electronic device is greater than a first threshold, the first compensation mode is used to perform image stabilization compensation on the electronic device.

[0035] The motion parameters can be the parameters of the electronic device's movement when the user holds the electronic device. Specifically, these motion parameters can be the electronic device's first acceleration and first angular velocity. The first acceleration can be the acceleration during the electronic device's movement, and the first angular velocity can be the angular velocity during the electronic device's movement. These first acceleration and first angular velocity can be acquired using a high-precision motion sensor array within the electronic device. For example, the first acceleration can be acquired using a three-axis micro-electro-mechanical system (MEMS) gyroscope at a sampling frequency of 1024Hz, and the first angular velocity can be acquired using a three-axis MEMS accelerometer at a sampling frequency of 1024Hz.

[0036] The motion intensity can be the intensity of the movement of the electronic device. This motion intensity can be determined based on the motion parameters of the electronic device. The specific method for obtaining the motion intensity of the electronic device based on its motion parameters will be described in detail in the following embodiments.

[0037] The first threshold can be a pre-set threshold for exercise intensity. The value of the first threshold can be greater than or equal to 3. For example, the first threshold can be 3. The specific value of the first threshold can be set by the user according to their needs. This application embodiment does not limit it.

[0038] In some embodiments of this application, when the electronic device is in non-shooting mode, there is no impact of the user's hand tremor on the electronic device. The shaking of the electronic device is generated by the user's movement when carrying the electronic device. That is, the shaking of the electronic device is generated by the motion parameters of the electronic device. If the motion intensity of the electronic device reaches a certain intensity, then it is necessary to perform image stabilization compensation on the electronic device.

[0039] In this way, the camera module can be in non-shooting mode when the shooting status information indicates that the electronic device is in shooting mode. The motion intensity of the electronic device can be determined according to the motion parameters of the electronic device. If the motion intensity of the electronic device is greater than the first threshold, the first compensation mode can be used to perform image stabilization compensation on the electronic device.

[0040] In the embodiments of this application, when the shooting status information indicates that the camera module is in non-shooting mode, the electronic device is not directly subjected to image stabilization compensation. Instead, image stabilization compensation is only performed when the motion parameters of the electronic device indicate that the motion intensity of the electronic device is greater than a first threshold. This avoids unnecessary image stabilization compensation, saves the resource consumption of the electronic device, and reduces the computing power of the electronic device.

[0041] In some embodiments of this application, in order to improve computational efficiency and save computing power, after step 110, the method described above may further include: The first acceleration and the first angular velocity are filtered to obtain the second angular velocity and the second acceleration. By transforming the second angular velocity and the second acceleration into the same coordinate system, we can obtain the third angular velocity and the third acceleration. The motion intensity of the electronic device is obtained by weighted fusion of the third angular velocity and the third acceleration.

[0042] The second angular velocity can be the angular velocity obtained by filtering the first angular velocity. The second acceleration can be the acceleration obtained by filtering the first acceleration.

[0043] The third angular velocity can be the angular velocity obtained by converting the second angular velocity and the second acceleration to the same coordinate system. The third acceleration can be the acceleration obtained by converting the second angular velocity and the second acceleration to the same coordinate system.

[0044] In some embodiments of this application, the first acceleration and the first angular velocity can be filtered separately. Specifically, Kalman filtering can be used to filter the first acceleration and the first angular velocity to eliminate noise and temperature drift effects, thereby obtaining the second angular velocity and the second acceleration. Then, the second angular velocity and the second acceleration are transformed into the same coordinate system to obtain the third angular velocity and the third acceleration. Finally, the third angular velocity and the third acceleration are weighted and fused to obtain a scalar value that reflects the overall motion intensity, i.e., the motion intensity of the electronic device.

[0045] In the embodiments of this application, by quantifying the motion parameters of the electronic device into scalar values ​​that reflect the overall motion intensity of the electronic device, it is convenient to perform subsequent calculations based on the motion intensity of the electronic device, without having to perform subsequent calculations based on the angular velocity and acceleration of the electronic device sequentially, thereby improving computational efficiency and saving computational power.

[0046] In some embodiments of this application, before performing image stabilization compensation on the electronic device, it is first necessary to determine the buffer zone for performing image stabilization compensation on the electronic device, that is, the range of shaking of the shaking components in the camera module of the electronic device. In other words, the buffer zone is the area where the camera module shakes, so that image stabilization compensation can be performed on the camera module within the buffer zone.

[0047] In some embodiments of this application, prior to step 120, the method described above may further include: Based on the motion parameters and historical swaying pattern database, determine the target swaying pattern corresponding to the motion parameters; Based on the correspondence between the target swaying pattern and the buffer, determine the buffer corresponding to the target swaying pattern.

[0048] The historical swaying pattern database can be a pre-built database that stores the correspondence between the motion parameters of electronic devices and swaying patterns.

[0049] The target sway mode can be the sway mode that the electronic device is currently in under that motion parameter.

[0050] In some embodiments of this application, a target sway pattern corresponding to the motion parameters is determined based on motion parameters and a historical sway pattern database. Then, based on the correspondence between the target sway pattern and the buffer, the buffer corresponding to the target sway pattern can be quickly determined so that subsequent image stabilization compensation can be performed on the electronic device based on the buffer.

[0051] In some embodiments of this application, image stabilization compensation for the electronic device using the first compensation mode can be achieved through two aspects of compensation. The first is the current of each electromagnetic coil in the electronic device. By controlling the current of each electromagnetic coil, a magnetic field can be generated in the electromagnetic coil. The magnetic force "pushes" or "pulls" the permanent magnet, thereby driving the image stabilization component to move in the direction of canceling the shake, thus preventing the lens assembly from shaking erratically. The other is the deformation stiffness of the micro-spring-damping composite layer in the electronic device. By adjusting the deformation stiffness of the micro-spring-damping composite layer in the electronic device, the lens assembly can be compressed in the opposite direction of the shake when the lens assembly shakes, thereby preventing the lens assembly from shaking.

[0052] Therefore, the process of performing image stabilization compensation on the electronic device using the first compensation mode may specifically include: Obtain the position vector information of the lens components in the camera module; Based on the position vector information and motion parameters, determine the first current of the target electromagnetic coil in the electronic device; Determine the instantaneous rate of change of the first angular velocity of the electronic device in the motion parameters; Adjust the deformation stiffness of the micro-spring-damping composite layer in the electronic device based on the instantaneous rate of change of the first angular velocity; Anti-shake compensation for electronic devices is performed based on the first current of the target electromagnetic coil in the electronic device and the deformation stiffness of the micro-spring-damping composite layer.

[0053] The position vector information can be the vector information of the position of the lens assembly in the camera module, that is, the position information and orientation information of the lens module. This position vector information can be obtained based on the displacement sensor in the electronic device. Specifically, it can be obtained by using four sets of laser triangulation rangefinders to monitor the two-dimensional plane offset (X, Y axes) and deflection angle of the lens assembly relative to the base of the electronic device in real time at a sampling frequency of 5000 Hz, thereby generating high-precision position vector information.

[0054] The target electromagnetic coil can be an electromagnetic coil in the camera assembly of an electronic device. The number of electromagnetic coils in the camera assembly can be one or more, depending on the specific electronic device, and is not limited in the embodiments of this application.

[0055] The first current of the target electromagnetic coil can be the current of the target electromagnetic coil.

[0056] The instantaneous rate of change can be the instantaneous rate of change of the first angular velocity of an electronic device. Specifically, it can be calculated by comparing the first angular velocity of the electronic device at the current moment with the angular velocity at the previous moment to obtain the instantaneous rate of change of the angular velocity of the electronic device at the current moment.

[0057] In some embodiments of this application, the first current of the target electromagnetic coil in the electronic device can be determined by a distributed excitation strategy based on the position vector information and motion parameters of the lens assembly in the camera module. The specific electromagnetic force formula can be shown in the following formula (1):

[0058] In the above formula (1), For the purpose of constraint, The electromagnetic force coefficient, The first current of the target electromagnetic coil, The maximum magnetic flux density of the target electromagnetic coil. It is the angle between the direction of the magnetic field and the direction of the target constraint force.

[0059] The aforementioned target constraint force is achieved by dynamically adjusting the current through the H-bridge drive circuit in the camera module, so that the vector of the target constraint force always points to the center of the image stabilization compensation buffer, thus maintaining the magnetic levitation balance of the lens assembly.

[0060] It should be noted that when the number of electromagnetic coils in the camera assembly of an electronic device is one, the above formula (1)... This is the magnetic flux density of the electromagnetic coil. In the case of multiple electromagnetic coils in the camera assembly of an electronic device, the above formula (1)... That is, the maximum value of the magnetic induction intensity among all electromagnetic coils, corresponding to the solution... This represents the first current in each electromagnetic coil.

[0061] Then, by calculating the instantaneous rate of change of the first angular velocity of the electronic device in the motion parameters, the deformation stiffness of the micro-spring-damping composite layer in the electronic device can be adjusted according to the instantaneous rate of change of the first angular velocity. Thus, anti-shake compensation of the electronic device can be achieved based on the first current of the target electromagnetic coil in the electronic device and the deformation stiffness of the micro-spring-damping composite layer.

[0062] In the embodiments of this application, when the camera module is in a non-shooting state, the image stabilization compensation of the electronic device can be achieved by controlling the first current of the target electromagnetic coil in the electronic device and adjusting the deformation stiffness of the micro-spring-damping composite layer in the electronic device, thus filling the gap in the existing solutions that cannot perform image stabilization compensation for non-shooting modes.

[0063] In some embodiments of this application, the deformation stiffness of the microspring-damping composite layer may include the compression of the microspring in the microspring-damping composite layer and the compression of the damping material in the microspring-damping composite layer.

[0064] To improve the accuracy of image stabilization compensation in electronic devices, adjusting the deformation stiffness of the micro-spring-damping composite layer in the electronic device based on the instantaneous rate of change of the first angular velocity may specifically include: When the rate of change of the first angular velocity is greater than the second threshold, the compression amount of the microspring in the microspring-damping composite layer is determined as the first compression amount, and the compression amount of the damping material in the microspring-damping composite layer is determined as the second compression amount.

[0065] The second threshold can be a pre-set threshold for the rate of change of the first angular velocity. The value of the second threshold can be greater than or equal to 5 g / s. For example, the second threshold can be 5 g / s. The specific value of the second threshold can be set by the user according to their needs. This application embodiment does not limit it.

[0066] The first compression amount can be the compression amount of the microspring in the microspring-damping composite layer. The second compression amount can be the compression amount of the damping material in the microspring-damping composite layer. Here, the first and second compression amounts correspond to the motion parameters; that is, the specific amount of compression that the microspring and damping material in the microspring-damping composite layer should have is matched to the motion parameters of the electronic device.

[0067] In some embodiments of this application, the instantaneous rate of change of the first angular velocity can be calculated first. Then, if the instantaneous rate of change of the first angular velocity is greater than a second threshold, the compression of the microspring in the microspring-damping composite layer can be set to a first compression, which matches the motion trajectory.

[0068] When adjusting the compression of the damping material in the microspring-damping composite layer, the position of the constraint ring in the microspring-damping composite layer is adjusted. This compresses the damping material in the microspring-damping composite layer, allowing the damping material to enter the nonlinear deformation region, thereby increasing the deformation resistance of the damping material and making the compression of the damping material the second compression amount.

[0069] In some embodiments of this application, if the instantaneous rate of change of the first angular velocity is less than or equal to the second threshold, it indicates that the camera module of the electronic device is not shaking much, so there is no need to perform image stabilization compensation. Image stabilization compensation is only performed on the camera module of the electronic device when the instantaneous rate of change of the first angular velocity is greater than the second threshold.

[0070] In the embodiments of this application, when the rate of change of the first angular velocity is greater than the second threshold, the compression of the microspring in the microspring-damping composite layer is adjusted to the first compression, and the compression of the damping material in the microspring-damping composite layer is adjusted to the second compression. The first compression and the second compression are matched with the motion parameters of the electronic device. In this way, the deformation stiffness of the microspring-damping composite layer can be adjusted according to the motion of the electronic device, thereby improving the accuracy of the anti-shake compensation of the electronic device.

[0071] In some embodiments of this application, to improve the accuracy of image stabilization compensation for electronic devices, the image stabilization compensation based on the first current of each electromagnetic coil in the electronic device and the deformation stiffness of the micro-spring-damping composite layer may specifically include: Obtain the collision risk index and spectral energy distribution of motion parameters of the lens assembly that are affected by shaking. Based on the spectral energy distribution and collision risk index, the first weight of the first current of each electromagnetic coil in the electronic device and the second weight of the deformation stiffness of the micro-spring-damping composite layer are determined. Anti-shake compensation is performed on the electronic device based on the first current of the electromagnetic coil in the electronic device, the deformation stiffness of the micro-spring-damping composite layer, and the first and second weights.

[0072] Among them, the spectral energy distribution can be information used to describe the spectral distribution of motion, which is obtained by performing spectral analysis on the motion parameters.

[0073] The first weight can be the weight of the first current of each electromagnetic coil in the electronic device. The second weight can be the weight of the deformation stiffness of the micro-spring-damping composite layer.

[0074] In some embodiments of this application, when the electronic device is not in a shooting state, image stabilization compensation is performed by adjusting the current of each electromagnetic coil and the deformation stiffness of the micro-spring-damping composite layer in the electronic device. However, how the current of each electromagnetic coil and the deformation stiffness of the micro-spring-damping composite layer in the electronic device are coordinated, that is, how the weights of the current of each electromagnetic coil and the deformation stiffness of the micro-spring-damping composite layer in the electronic device are, is the key to realizing image stabilization compensation of the electronic device.

[0075] Therefore, in this embodiment, the weight allocation of the magnetic-elastic dual channel can be calculated by the collision risk index of the lens assembly caused by shaking and the spectral energy distribution of the motion parameters. That is, based on the spectral energy distribution and the collision risk index, the first weight of the first current of each electromagnetic coil in the electronic device and the second weight of the deformation stiffness of the micro-spring-damping composite layer are determined. Then, based on the first current of the electromagnetic coil in the electronic device, the deformation stiffness of the micro-spring-damping composite layer, and the first and second weights, the electronic device is subjected to image stabilization compensation.

[0076] Specifically, when calculating the weight allocation of the magnetic-elastic dual-channel based on the collision risk index and the spectral energy distribution of motion parameters caused by shaking in the lens assembly, in high-frequency micro-vibration scenarios, the magnetic field strength can be increased first to provide rapid constraint, i.e., the weight of the current in the electromagnetic coils can be increased. Under low-frequency large-amplitude impacts, the initial current of each electromagnetic coil and the deformation stiffness of the micro-spring-damping composite layer can be simultaneously increased to form orthogonal energy-dissipating channels. During the above adjustment process, PID closed-loop control can be used to ensure that the ratio of the initial current of each electromagnetic coil and the deformation stiffness of the micro-spring-damping composite layer changes smoothly with the motion trajectory, avoiding overshoot or oscillation.

[0077] The aforementioned high-frequency micro-vibration scenarios and low-frequency large-amplitude impact scenarios can be determined based on the spectral energy distribution of motion parameters. For example, a displacement amplitude greater than 50µm in the 80-130Hz spectrum indicates a high-frequency micro-vibration scenario. A displacement amplitude greater than 50µm in the 0-10Hz spectrum indicates a low-frequency large-amplitude impact scenario.

[0078] In the embodiments of this application, the weight allocation of the magnetic-elastic dual channels is calculated based on the collision risk index and the spectral energy distribution of motion parameters caused by shaking in the lens assembly, rather than by allocating the weights of the magnetic-elastic dual channels according to a fixed proportion, thereby improving the accuracy of image stabilization compensation for electronic devices.

[0079] In some embodiments of this application, to facilitate subsequent calculations of image stabilization compensation for the electronic device, obtaining the collision risk index of the lens assembly collision may specifically include: Acquire the pressure values ​​at each pressure detection point of the lens assembly during shaking; The collision risk index of the lens assembly due to shaking is determined based on the pressure values ​​at each pressure detection point.

[0080] In some embodiments of this application, carbon nanotubes may be embedded in the boundary layer of the buffer zone. These carbon nanotubes are doped with polymer pressure-sensitive materials, which can be distributed in a matrix form to detect the pressure values ​​at each pressure detection point in real time. The pressure values ​​at each pressure detection point can then be converted into a collision risk index by a multi-channel analog-to-digital converter.

[0081] In the embodiments of this application, the collision risk index of the lens assembly due to shaking is determined by the pressure values ​​of each pressure detection point of the polymer pressure-sensitive material during the shaking process. This quantifies the risk of the lens assembly colliding due to shaking, which is helpful for subsequent calculation of image stabilization compensation for electronic devices.

[0082] It should be noted that the controller can retrieve the historical swaying pattern database every preset time interval based on the current motion parameters of the electronic device. For example, it could retrieve the historical swaying pattern database every 100 milliseconds, and then use a k-nearest neighbor algorithm (e.g., k=5, based on Euclidean distance) to match the current motion parameters, and dynamically adjust the spatial configuration and electromagnetic-elastic parameters of the buffer zone accordingly. For example, when a reciprocating motion pattern is detected, the system automatically reduces the rate of change of magnetic field strength and increases the damping preload to optimize the energy dissipation path. Through the synergy of the above sensor feedback and control algorithm, the system achieves real-time and precise adjustment of the electromagnetic coil current and the micro-spring-damping preload, effectively suppressing mechanical collision noises in non-shooting states and adapting to complex motion trajectories.

[0083] In some embodiments of this application, in order to improve the accuracy of image stabilization compensation of the electronic device and avoid damage to the lens assembly, the image stabilization compensation performed on the electronic device using the second compensation mode may specifically include: The displacement of the lens assembly after the target time period is obtained based on the offset vector and deflection angle of the lens assembly. Anti-shake compensation is performed on electronic devices based on displacement, offset vector, and deflection angle.

[0084] The target time period can be a pre-set period of time after the current time, such as within 5 seconds after the current time.

[0085] In some embodiments of this application, the offset vector and deflection angle of the lens assembly can be monitored in real time by a displacement sensor array, and then sent to a controller. Based on the offset vector and deflection angle of the lens assembly, the controller can predict the displacement of the lens assembly after a target time period, such as predicting the displacement of the lens assembly 20 milliseconds later. Then, based on the displacement, offset vector, and deflection angle, image stabilization compensation can be performed on the electronic device.

[0086] In the embodiments of this application, the displacement of the lens assembly after a preset time period is predicted by the offset vector and deflection angle of the lens assembly. Then, based on the current offset vector and deflection angle of the lens assembly and the predicted displacement of the lens assembly after the target time period, image stabilization compensation can be performed on the electronic device. In this way, by comprehensively performing image stabilization compensation on the electronic device based on the information of the lens assembly at the current time and the predicted displacement of the lens assembly in the future time period, the accuracy of image stabilization compensation of the electronic device can be improved. Moreover, by performing image stabilization compensation on the electronic device in advance based on the predicted displacement of the lens assembly in the future time period, damage to the lens assembly caused by insufficient time for image stabilization compensation in the future time period can be avoided.

[0087] In some embodiments of this application, the step of performing image stabilization compensation on the electronic device based on displacement, offset vector, and deflection angle may specifically include: Based on the displacement, determine the driving voltage of each piezoelectric actuator in the lens assembly; The offset vector and deflection angle are corrected based on the driving voltage.

[0088] In some embodiments of this application, each component in the lens assembly has its corresponding piezoelectric actuator to drive the component's operation. When performing image stabilization compensation on the electronic device, a feedforward-feedback composite control strategy can be used to generate a reverse driving torque based on the current offset vector and deflection angle of the lens assembly, and the predicted displacement of the lens assembly after the target time period. Specifically, the feedforward part can calculate the driving voltage of each piezoelectric actuator in the lens assembly based on the predicted displacement of the lens assembly after the target time period. The feedback part can correct the offset vector and deflection angle in real time through the driving voltage; this cycle can be continuously repeated to achieve real-time image stabilization compensation for the electronic device.

[0089] In the embodiments of this application, the driving voltage of each piezoelectric actuator in the lens assembly can be calculated based on the displacement of the lens assembly after the predicted target time period. Then, the offset vector and deflection angle can be corrected in real time through the driving voltage, thus realizing real-time image stabilization compensation for electronic devices.

[0090] In some embodiments of this application, when the camera module is in shooting mode, to ensure the rapid response and stable performance of the piezoelectric actuator assembly under high-frequency shaking environment, the system also implements the following specific optimization measures: 1. High-frequency drive voltage regulation strategy: Voltage-frequency adaptive mapping: The driving voltage range (0–60V) of the piezoelectric actuator group is not fixed, but dynamically subdivided and adjusted according to the main frequency band characteristics of the jitter frequency spectrum. For example, for high-frequency jitter above 50Hz, a low-voltage high-frequency driving strategy can be adopted, such as setting the upper limit of the driving voltage to 30V, while increasing the modulation frequency of the driving signal of the piezoelectric ceramic to more than 1 / 2 of its mechanical resonant frequency (typically 1-2kHz), to avoid the actuator entering the saturation region and ensure its ability to quickly track high-frequency signals.

[0091] Phase lead compensation: In the high-frequency range, the piezoelectric material itself and the mechanical structure introduce phase lag. The controller algorithm integrates a phase lead correction module, which injects a phase lead into the control signal based on the real-time identified system frequency response, effectively offsetting the actual delay and improving the stability and compensation accuracy of the closed-loop system at high frequencies.

[0092] 2. Material and structural optimization to improve response speed and stability: Piezoelectric ceramic material selection: The core piezoelectric ceramic element of the piezoelectric actuator is made of hard lead zirconate titanate (PZT) piezoelectric ceramic material with low hysteresis and high mechanical quality factor. This material has low internal loss and low heat generation when subjected to high-frequency alternating electric fields, and good displacement repeatability, which ensures fast response and long-term stability under high-frequency drive from a physical perspective.

[0093] Actuator structure design: A stacked piezoelectric actuator structure is adopted, which is composed of dozens to hundreds of thin-layer piezoelectric ceramic sheets. This structure can generate greater output force under the same driving voltage, and its equivalent stiffness is high. The first-order mechanical resonant frequency can usually reach several kHz, which is much higher than the high-frequency oscillation frequency to be compensated (usually <500Hz), thus avoiding the influence of the actuator's own resonance on the system stability.

[0094] Integrated stress sensors: Each piezoelectric actuator integrates a miniature stress sensor to monitor the stress state inside the ceramic sheet in real time. When the system detects that continuous high-frequency driving causes the stress to approach the material fatigue limit, it triggers a dynamic load balancing algorithm to temporarily redistribute some driving tasks to adjacent actuators, preventing overload of a single actuator and improving the system's reliability under high-intensity operation.

[0095] Through the above-mentioned driving strategy and hardware-level synergistic optimization, the piezoelectric actuator group can maintain a sub-millisecond response time (e.g., less than 1ms) under high-frequency shaking environment, and ensure the stability and accuracy of the compensation process, effectively improving the imaging quality of electronic devices in violent motion scenarios.

[0096] In some embodiments of this application, regardless of whether the electronic device is in shooting or non-shooting mode, abnormal vibrations may occur in the components of the electronic device during shaking, which could damage the camera module. Therefore, throughout the entire process of this application embodiment, it is necessary to monitor the vibration of the electronic device in real time. When abnormal vibrations may occur in the components of the electronic device, corresponding compensation strategies are adopted to perform image stabilization compensation to eliminate the impact of abnormal vibrations. That is, image stabilization compensation for abnormal vibrations in the components of the electronic device can be considered as secondary image stabilization compensation in addition to the shooting and non-shooting modes mentioned above.

[0097] To improve the accuracy of image stabilization compensation in electronic devices and to maintain camera modules, the methods mentioned above may also include: Obtain the spectral energy distribution of motion parameters; Based on the spectral energy distribution, image stabilization compensation is applied to electronic devices.

[0098] In some embodiments of this application, it can be determined whether there is abnormal vibration in the components of an electronic device based on the spectral energy distribution of motion parameters. If so, anti-shake compensation can be performed on the electronic device based on the spectral energy distribution.

[0099] In the embodiments of this application, when it is determined that there is abnormal vibration in the components of an electronic device based on the spectral energy distribution of motion parameters, anti-shake compensation can be performed on the electronic device, thereby further improving the accuracy of anti-shake compensation of the electronic device.

[0100] In some embodiments of this application, in order to improve the accuracy of image stabilization compensation for electronic devices, the step of performing image stabilization compensation on the electronic device based on the spectral energy distribution may specifically include: When the proportion of spectral energy within the first spectral energy range in the spectral energy distribution is greater than the third threshold and continues for a preset duration, an anti-phase resonant cancellation wave is generated. When the displacement amplitude corresponding to the spectral energy within the second spectral energy range in the spectral energy distribution is greater than the fourth threshold, the initial compression of the microspring in the microspring-damping composite layer in the electronic device is increased by a preset compression, and the initial current of each electromagnetic coil in the electronic device is adjusted to the second current.

[0101] The first spectral energy range can be a pre-set spectral energy range, such as a high-frequency spectral energy range of 80-130Hz.

[0102] The third threshold can be a pre-set threshold representing the proportion of spectral energy within the first spectral energy range in the spectral energy distribution. The value of the third threshold can be greater than or equal to 15%, for example, the value of the third threshold can be 15%. The specific value of the third threshold can be set by the user according to their needs, and is not limited in this embodiment.

[0103] The anti-phase resonant cancellation wave can be a sine wave with the same amplitude but opposite phase as the band corresponding to the first spectral energy range. That is, the anti-phase resonant cancellation wave can be used to eliminate the vibration of the band corresponding to the first spectral energy range on the camera module's shaking effect. Therefore, the anti-phase resonant cancellation wave needs to have the same amplitude as the band corresponding to the first spectral energy range, but with opposite phase. This can destroy the resonance condition of the component and thus suppress the vibration of the band corresponding to the first spectral energy range on the camera module's shaking effect.

[0104] The second spectral energy range can be a pre-set spectral energy range, such as a low-frequency spectral energy range of 0-10Hz.

[0105] The fourth threshold can be a pre-set threshold for the displacement amplitude corresponding to the spectral energy within the second spectral energy range. The value of the fourth threshold can be greater than or equal to 50um. For example, the value of the fourth threshold can be 50um. The specific value of the fourth threshold can be set by the user according to their needs, and is not limited in this embodiment.

[0106] The initial compression amount can be the compression amount before adjusting the compression amount of the microspring in the microspring-damping composite layer of the electronic device at the current moment.

[0107] The preset compression amount can be the amount of compression that increases the initial compression amount of the microspring in the microspring-damping composite layer of the electronic device. For example, the preset compression amount can be 20%.

[0108] The initial current can be the current value before the current values ​​of each electromagnetic coil in the electronic device are adjusted at the current moment.

[0109] The second current can be the current adjusted from the initial current of each electromagnetic coil in the electronic device. This second current corresponds to the preset compression amount.

[0110] In some embodiments of this application, when the proportion of spectral energy within the first spectral energy range in the spectral energy distribution is greater than the third threshold and continues for a preset duration, it indicates that the electronic device has high-frequency micro-vibrations exceeding the normal range of hand tremors during shooting. Once this abnormal resonance is detected, an anti-phase resonance cancellation wave can be generated. That is, when the proportion of high-frequency micro-vibration energy exceeds the third threshold and continues for a preset duration, such as more than 5ms, it can be determined that the electronic device has high-frequency micro-vibrations exceeding the normal range of hand tremors. At this time, an anti-phase resonance cancellation wave can be generated to destroy the resonance condition. That is, a high-frequency, small-amplitude fine adjustment is superimposed on the second compensation mode of the shooting state, which is specifically used for "fixed-point clearing" of resonance, thereby further improving the image clarity.

[0111] If the displacement amplitude corresponding to the spectral energy within the second spectral energy range in the spectral energy distribution is greater than the fourth threshold, it indicates a sudden increase in the energy of low-frequency large-amplitude swaying in the electronic device, which foreshadows a strong impact. At this time, a magnetoelastic mechanism can be triggered. Specifically, the initial compression of the microspring in the microspring-damping composite layer of the electronic device can be increased by a preset compression amount, such as by 20%. At the same time, the initial current of each electromagnetic coil in the electronic device can be adjusted to the second current, which can generate an asymmetric magnetic field gradient and guide the impact kinetic energy to the area of ​​dense damping material.

[0112] In some embodiments of this application, when increasing the initial compression of the microspring in the microspring-damping composite layer of the electronic device by a preset compression amount, and adjusting the initial current of each electromagnetic coil in the electronic device, a step-by-step approach can be used to increase the initial compression of the microspring in the microspring-damping composite layer of the electronic device by a preset compression amount, and adjust the initial current of each electromagnetic coil in the electronic device. This can avoid abrupt changes in the rigid deformation of the microspring-damping composite layer.

[0113] In the embodiments of this application, the image stabilization compensation of the electronic device is dynamically performed based on the spectrum energy distribution, thereby improving the accuracy of the image stabilization compensation of the electronic device.

[0114] In some embodiments of this application, to verify the actual effect of the above-mentioned abnormal vibration suppression mechanism under different environmental conditions, a system simulation model was constructed and a series of tests were conducted. The experimental data are as follows: The effect of anti-phase resonant wave injection on suppressing high-frequency micro-vibrations: Test conditions: In a laboratory environment, a single-frequency sinusoidal vibration with a frequency of 125Hz and an amplitude of 0.5μm was applied to the mobile phone module using a vibrator to simulate a high-frequency micro-vibration scenario.

[0115] Test results: As shown in Table 1 below, after activating the anti-phase resonant wave injection mechanism, the resonance amplitude of the lens assembly at this frequency is significantly reduced.

[0116] Table 1

[0117] The experimental data above show that the anti-phase resonant wave injection mechanism can effectively disrupt the resonance condition and suppress specific high-frequency micro-vibrations by more than 85%, ensuring the stability of the imaging system in a high-frequency vibration environment.

[0118] The dissipation effect of magnetoelastic mechanisms on low-frequency impacts: Test conditions: Simulate the impact of an electronic device falling freely from a height of 10cm onto a wooden tabletop (measurements show that the main impact frequency components are concentrated in the 5-8Hz range, with a peak acceleration of approximately 8g). Compare the two scenarios of having the magnetic-elastic mechanism turned on and off (i.e., the microsprings in the microspring-damping composite layer working in coordination with the electromagnetic coils in the electronic device).

[0119] Test results: The internal impact response was measured by an accelerometer mounted on the lens mount assembly, and the specific results are shown in Table 2 below.

[0120] Table 2

[0121] The data above shows that the magnetoelastic mechanism reduces the impact acceleration transmitted to the lens assembly by about 49% by actively enhancing the compression of the microspring in the microspring-damping composite layer and the current of each electromagnetic coil in the electronic device. This significantly optimizes the dissipation path of the impact energy and effectively protects the precision structure.

[0122] Composite Environment Testing: Under simulated vehicle vibration conditions (wideband random vibration, main frequency band 0.5-200Hz), both suppression mechanisms (anti-phase resonant wave injection for high-frequency micro-vibrations and magneto-elastic mechanism) were simultaneously activated. Test results show that, compared to using only basic optical image stabilization, the solution in this embodiment can suppress the overall vibration energy of the lens assembly by approximately 40%, demonstrating its comprehensive effectiveness under complex mixed vibration conditions.

[0123] The experimental data above fully verify the effectiveness of the above-mentioned schemes in generating anti-phase resonant cancellation waves when the proportion of spectral energy in the first spectral energy range in the spectral energy distribution is greater than the third threshold and continues for a preset duration; and in the case where the displacement amplitude corresponding to the spectral energy in the second spectral energy range in the spectral energy distribution is greater than the fourth threshold, increasing the initial compression of the microspring in the microspring-damping composite layer in the electronic device by a preset compression and adjusting the initial current of each electromagnetic coil in the electronic device to the second current under different frequencies and scenarios. Whether for high-frequency resonance or low-frequency impact, it can achieve active and forward-looking vibration suppression.

[0124] In some embodiments of this application, in order to further improve the accuracy of image stabilization compensation of electronic devices, the methods described above may further include: If the difference between the target swaying pattern corresponding to the motion parameters and the swaying pattern in the historical swaying pattern database is greater than the fifth threshold, the motion parameters and the target swaying pattern are stored in the historical swaying pattern database.

[0125] The fifth threshold can be a threshold for the difference between the target swaying pattern corresponding to the preset motion parameters and the swaying pattern in the historical swaying pattern database. The value of the fifth threshold can be greater than or equal to 15%, for example, the value of the fifth threshold can be 15%. The specific value of the fifth threshold can be set by the user according to their needs, and is not limited in this embodiment.

[0126] In some embodiments of this application, after detecting a complete specific motion event, the target swaying pattern corresponding to the motion parameters can be compared with the swaying patterns in the historical swaying pattern database. If the difference between the target swaying pattern corresponding to the motion parameters and the swaying patterns in the historical swaying pattern database is greater than a fifth threshold, it indicates that the motion event corresponding to the motion parameters is a new event, and the motion parameters and the target swaying pattern can be stored in the historical swaying pattern database.

[0127] It should be noted that comparing the target swaying pattern corresponding to the motion parameters with the swaying patterns in the historical swaying pattern database can be done by calculating the Euclidean distance between the target swaying pattern corresponding to the motion parameters and the swaying patterns in the historical swaying pattern database.

[0128] In the embodiments of this application, when the difference between the target sway pattern corresponding to the motion parameters and the sway pattern in the historical sway pattern database is greater than a fifth threshold, the motion parameters and the target sway pattern are stored in the historical sway pattern database. This allows for continuous updates to the historical sway pattern database, enabling more accurate and comprehensive image stabilization compensation for electronic devices based on the database, thereby further improving the accuracy of image stabilization compensation for electronic devices.

[0129] In some embodiments of this application, the controller may evaluate the current motion characteristics every 100 milliseconds. If the difference between the current motion pattern and all existing patterns in the historical swaying pattern database exceeds a fifth threshold, and the pattern has lasted for at least 300 milliseconds, it is stored as a new pattern sample in the historical swaying pattern database to enrich the diversity of the historical swaying pattern database.

[0130] Each motion pattern in the historical swaying pattern database records the timestamp of the motion pattern, the motion feature vector (such as the maximum displacement amplitude, the unit vector of the main motion direction, and the frequency distribution histogram of the motion pattern), and the optimal control parameter set used by the system at that time (such as the buffer configuration and the magnetic field-preload ratio).

[0131] It should be noted that the historical fluctuation pattern database can use a circular storage structure with a capacity of 1000 records. When the historical fluctuation pattern database is full, new records will overwrite the oldest records. However, for "high-quality" pattern records with high control effectiveness evaluation indicators (such as suppression efficiency > 90%), the system will give them a longer retention priority.

[0132] Specifically, when comparing the target swaying pattern corresponding to the motion parameters with the swaying patterns in the historical swaying pattern database, the k-nearest neighbor (k-NN) matching algorithm can be used. The specific parameters and optimization process of the k-nearest neighbor (k-NN) matching algorithm are as follows: After extensive testing, k=5 was found to be the optimal value. This value strikes the best balance between the accuracy and computational complexity of pattern recognition, avoiding sensitivity to noise due to an excessively small k value or pattern blurring due to an excessively large k value.

[0133] The optimization process of the proposed scheme using the k-nearest neighbor algorithm described above is as follows: The controller extracts key vectors from the current motion features every 100 milliseconds and performs a k-nearest neighbor search in the historical swaying pattern database. The algorithm calculates the weighted Euclidean distance between the current vector and all records in the historical swaying pattern database, and selects the five nearest neighbors with the smallest distance.

[0134] By combining the historical best control parameters corresponding to these 5 nearest neighbor samples, a set of adaptive control parameters suitable for the current motion mode is generated through a weighted average, and immediately applied to the real-time adjustment of the electromagnetic coil, micro-spring preload, and buffer boundary configuration.

[0135] The controller records the control effect (such as the final collision risk index and energy dissipation efficiency) after each use of k-nearest neighbor recommended parameters. If the control effect is significantly better than the historical record, the weight of the current mode will be strengthened; otherwise, it may trigger a fine-tuning of the weight coefficients in the k-nearest neighbor algorithm formula, or use the result as a negative case to reduce its similarity score in subsequent matching, thereby achieving continuous optimization of the algorithm.

[0136] Through the specific update strategies and refined algorithm settings described above, the historical swaying pattern database and the k-nearest neighbor algorithm together constitute an efficient and adaptive learning system, ensuring that buffering and compensation control can accurately match complex and ever-changing actual motion scenarios.

[0137] In some embodiments of this application, in order to reduce the power consumption of the electronic device, when the electronic device determines that the camera module has been stationary for a long time (e.g., continuously for 30 seconds) (synthetic acceleration continuously below 0.05g) and is not in a shooting state, the electronic device automatically enters a deep low-power mode to save power. In this mode, the electronic device significantly reduces overall power consumption through fine power domain management.

[0138] Specifically, after the electronic device enters deep low-power mode, the power consumption values ​​of each component are shown in Table 3 below: Table 3

[0139] As shown in Table 3 above, through targeted optimization, the total static power consumption of electronic devices in deep low power mode can be significantly reduced from approximately 46mA during normal operation to approximately 4.16mA, achieving a power saving of over 90%.

[0140] In some embodiments of this application, the wake-up time of the electronic device can also be optimized to improve the efficiency of the electronic device in performing image stabilization compensation. The aforementioned wake-up time is the time required for the electronic device to recover from receiving a wake-up signal (such as detecting motion or a shooting command) to all core functions resuming full-power operation and being ready to perform compensation.

[0141] The specific test plan is as follows: When the electronic device is in a stable deep low power mode, a motion signal with a synthetic acceleration of more than 0.1g is simulated by a vibration table, and the physical shutter button is triggered at the same time. A high-precision oscilloscope is used to measure the time interval from signal input to the piezoelectric driver receiving the first valid control command.

[0142] From signal input to the piezoelectric actuator receiving the first valid control command, the working process of each module is as follows: Sensor and Status Recognition Wake-up: The single-axis accelerometer responsible for motion sensing and the unit module that detects the shooting status information of the camera module are activated first, and this process takes less than 2ms.

[0143] Main controller wake-up and initialization: The main controller resumes full-speed operation from hibernation and completes basic initialization, which takes ~3ms.

[0144] Powering on the peripheral drive circuit and sensors: Powering on modules such as the gyroscope, displacement sensor array, and piezoelectric actuator and completing self-test, taking ~4ms.

[0145] Total system readiness time: Based on the above stages, the total wake-up time test result from the triggering of the wake-up signal to the system being fully ready (i.e., the second compensation mode or the first compensation mode can work normally) is <10ms.

[0146] Therefore, the above experiments demonstrate that the deep low-power management strategy designed in this application successfully reduces static power consumption to the 4.16mA level while still ensuring a fast wake-up capability within 10 milliseconds. This performance indicator ensures that the image stabilization and noise reduction systems are ready the moment the user takes the electronic device out of their pocket and raises it to take a picture, achieving the optimal balance between low power consumption and high performance.

[0147] To better understand the image stabilization method provided in the embodiments of this application, the image stabilization method provided in the embodiments of this application is described below with specific scenarios.

[0148] like Figure 2 As shown, the image stabilization method provided in this application embodiment may include steps 21-31.

[0149] Step 21: Obtain the motion parameters of the electronic device and the shooting status information of the camera module of the electronic device.

[0150] In step 21, the motion parameters of the electronic device and the shooting status information of the camera module of the electronic device can be obtained first.

[0151] Step 22: Determine if the camera module is in shooting mode. If yes, proceed to step 23; otherwise, proceed to step 25.

[0152] In step 22, determining whether the camera module is in shooting mode can be based on the shooting mode information of the camera module. Specifically, the shooting mode information of the camera module can be a binary value, such as "1" for shooting mode and "0" for non-shooting mode.

[0153] Step 23: Based on the offset vector and deflection angle of the lens assembly, obtain the displacement of the lens assembly after the target time period.

[0154] Step 24: Perform anti-shake compensation on the electronic device based on the displacement, offset vector, and deflection angle.

[0155] In steps 23-24, the displacement of the lens assembly after the target time period can be predicted based on the offset vector and deflection angle of the lens assembly. Then, image stabilization compensation can be performed on the electronic device based on the displacement, offset vector, and deflection angle. The specific process of steps 23-24 is consistent with the process in the above embodiment of obtaining the displacement of the lens assembly after the target time period based on the offset vector and deflection angle of the lens assembly, and performing image stabilization compensation on the electronic device based on the displacement, offset vector, and deflection angle. It will not be described again here.

[0156] Step 25: Adjust the first current of the target electromagnetic coil in the electronic device.

[0157] In step 25, the position vector information of the lens assembly in the camera module can be obtained first. Then, based on the position vector information and motion parameters, the first current of the target electromagnetic coil in the electronic device can be determined. In this step, the process of determining the first current of the target electromagnetic coil in the electronic device based on the position vector information and motion parameters is the same as the process of determining the first current of the target electromagnetic coil in the electronic device based on the position vector information and motion parameters in the above embodiment, and will not be described again here.

[0158] Step 26: Adjust the deformation stiffness of the micro-spring-damping composite layer in the electronic device.

[0159] In step 26, the instantaneous rate of change of the first angular velocity of the electronic device in the motion parameters can be calculated first. Then, the deformation stiffness of the micro-spring-damping composite layer in the electronic device can be adjusted according to the instantaneous rate of change of the first angular velocity. The specific process of adjusting the deformation stiffness of the micro-spring-damping composite layer in the electronic device according to the instantaneous rate of change of the first angular velocity can be referred to the relevant process in the above embodiment, and will not be repeated here.

[0160] Step 27: Based on the first current of the target electromagnetic coil in the electronic device and the deformation stiffness of the micro-spring-damping composite layer, perform anti-shake compensation on the electronic device.

[0161] In step 27, anti-shake compensation of the electronic device can be achieved based on the first current of the target electromagnetic coil in the electronic device and the deformation stiffness of the micro-spring-damping composite layer. That is, anti-shake compensation can be performed through a magnetic-elastic dual-channel. Specifically, the process of anti-shake compensation of the electronic device based on the first current of the target electromagnetic coil in the electronic device and the deformation stiffness of the micro-spring-damping composite layer is the same as the process of anti-shake compensation of the electronic device based on the first current of the target electromagnetic coil in the electronic device and the deformation stiffness of the micro-spring-damping composite layer in the above embodiment, and will not be repeated here.

[0162] Step 28: Obtain the spectral energy distribution of motion parameters.

[0163] Step 29: Based on the spectral energy distribution, determine whether the electronic device has abnormal vibration. If yes, proceed to steps 30 and 31; otherwise, return to step 28.

[0164] In step 29, the presence of abnormal vibration in the electronic device can be determined based on the spectral energy distribution. Specifically, it can be determined whether the proportion of spectral energy within the first spectral energy range in the spectral energy distribution is greater than a third threshold and continues for a preset duration. If so, the electronic device will vibrate abnormally due to resonance. Once it is determined that the electronic device is vibrating abnormally due to resonance, step 30 is executed.

[0165] It also determines whether the displacement amplitude corresponding to the spectral energy within the second spectral energy range in the spectral energy distribution is greater than the fourth threshold. If so, it is determined that the device is in a low-frequency large-amplitude vibration scenario, which will also cause abnormal vibration of the electronic device. If it is determined that the abnormal vibration of the electronic device is caused by low-frequency large-amplitude vibration, then step 31 is executed.

[0166] Step 30: Generate an anti-phase resonant canceling wave.

[0167] In step 30, if the proportion of spectral energy within the first spectral energy range in the spectral energy distribution is greater than the third threshold and continues for a preset duration, an anti-phase resonant cancellation wave can be generated to suppress jitter.

[0168] Step 31: Trigger the magnetic-elastic dual-channel mechanism.

[0169] In step 31, the magnetic-elastic dual-channel mechanism is triggered, which means increasing the initial compression of the microspring in the microspring-damping composite layer of the electronic device by a preset compression amount and adjusting the initial current of each electromagnetic coil in the electronic device to the second current.

[0170] Compared to existing technologies, the embodiments of this application utilize a high-precision motion sensor group and a multi-source signal recognition unit to collaboratively collect and fuse the device's motion parameters and shooting status commands in real time, generating precise multi-dimensional motion feature vectors and binary status flags representing the shooting status information of the camera module. This achieves refined and low-latency discrimination of the device's intended use (shooting or not shooting) and motion intensity (stationary, micro-motion, shaking, impact), providing a reliable decision basis for switching between the first compensation mode for anti-collision noise and the optical image stabilization mode for high-definition shooting, fundamentally avoiding protection failures or functional conflicts caused by misjudgment of status.

[0171] Compared to existing technologies that rely solely on passive physical restraint or a single buffer material, this application's embodiment generates a dynamically adjustable centripetal constraint magnetic field through an electromagnetic coil array and a soft magnetic material layer. This allows the lens assembly to be magnetically levitated at the center of the buffer zone. Simultaneously, a micro-spring-damping composite layer provides gradient deformation resistance. The combined effect of the magnetic-elastic orthogonal dual channels efficiently converts impact kinetic energy into heat dissipation, thereby completely eliminating mechanical collision noises from the lens assembly when not in use and reducing the risk of long-term wear.

[0172] Compared to existing technologies, this application's embodiments utilize a displacement sensor array to provide real-time feedback of the lens offset vector, and a piezoelectric actuator group to predict the lens assembly's displacement over future time periods. Based on this displacement, a phase-adaptive reverse driving torque is generated to achieve image stabilization compensation for the electronic device. The displacement feedback and motion sensor data are fused and optimized through a closed-loop coupled computing engine, forming a self-improving compensation accuracy mechanism. This enables fast and accurate OIS compensation under multi-axis, multi-frequency shaking conditions, effectively improving imaging stability and image success rate.

[0173] Compared to existing technologies that are insensitive to or have a delayed response to high-frequency vibrations, the embodiments of this application analyze the energy distribution of the motion spectrum and inject anti-phase resonant waves into the piezoelectric actuator to disrupt the resonance condition for specific high-frequency micro-vibrations. For low-frequency large-amplitude swaying, the buffer preload and magnetic field gradient are adjusted in conjunction to optimize the energy dissipation path. This approach achieves proactive identification and forward-looking suppression of abnormal vibrations across the entire frequency band, enhancing the system's adaptability and reliability in complex environments.

[0174] In existing technologies, when using optical image stabilization (OIS) for image compensation, in non-shooting mode, the system simply cuts off power to the camera components, causing the lens assembly to be locked by a physical limiter. Once shooting mode is entered, power is immediately restored, unlocking the lens assembly and allowing it to function. This switching action typically occurs the instant the user turns on the camera, raises the phone to take a precise photo, or the instant the user finishes shooting, locks the screen, and puts the phone down. Thus, in non-shooting mode, the lens is locked to the limiter. The instant the user switches to shooting mode, the control system outputs a simple "power on" command, causing the locking mechanism (such as an electromagnet or a simple mechanical latch) to release instantly. This abrupt change in control command causes the lens assembly, which was initially held firmly in place, to spring open under its own elasticity or the initial force of the actuator, impacting the other side of the limiter or generating a period of unstable oscillation. Therefore, the new noise and vibration generated at the moment of mode switching create "secondary impact noise."

[0175] Compared to the secondary impact caused by mode switching in existing technologies, the embodiments of this application, when detecting the need to switch from the first compensation mode to the second compensation mode, do not simply remove the magnetic field and activate the piezoelectric actuator. Instead, they first analyze the current motion trend of the electronic device to determine whether it is accelerating or decelerating, i.e., obtain the acceleration of the electronic device. Then, based on this, a smooth transition control sequence for a continuous target duration is calculated, i.e., the displacement of the lens assembly after the target duration is predicted. Within this sequence, the ratio between the magnetic attraction strength and the buffer preload of the microspring in the microspring-damping composite layer is gradually and collaboratively adjusted. For example, at the beginning of the switching phase, the magnetic field strength is slowly reduced to 90%, while a slight pre-voltage of the piezoelectric actuator is introduced; in the middle phase, the weights of the two forces continue to transition smoothly with an S-shaped curve; finally, the second compensation mode is fully entered. This approach eliminates additional noise caused by abrupt changes in control commands and improves the user experience.

[0176] The image stabilization method provided in this application can be implemented by an image stabilization device. This application uses an image stabilization device to implement the image stabilization method as an example to illustrate the image stabilization device provided in this application.

[0177] Figure 3 This is a schematic diagram illustrating the structure of a shake stabilization device according to an exemplary embodiment. For example... Figure 3 As shown, the image stabilization device 300 may include: The acquisition module 310 is used to acquire the shooting status information of the camera module of the electronic device; The image stabilization compensation module 320 is used to perform image stabilization compensation on the electronic device using a first compensation mode when the shooting status information indicates that the camera module is in a non-shooting mode; and / or, to perform image stabilization compensation on the electronic device using a second compensation mode when the shooting status information indicates that the camera module is in a shooting mode.

[0178] In this embodiment, by acquiring the motion parameters of the electronic device and the shooting status information of the camera module, when the shooting status information indicates that the camera module is in non-shooting mode, a first compensation mode is used to perform image stabilization compensation on the electronic device; when the shooting status information indicates that the camera module is in shooting mode, a second compensation mode is used to perform image stabilization compensation on the electronic device. Thus, different compensation methods are used to perform image stabilization compensation on the electronic device according to the different states of the camera module, rather than using a uniform image stabilization compensation method, thereby improving the accuracy of image stabilization compensation and thus improving the image stabilization compensation effect of the electronic device. Furthermore, the solution of this embodiment also compensates for image stabilization when the camera module is in non-shooting mode, filling the gap in existing solutions that cannot perform image stabilization compensation for non-shooting modes.

[0179] In some embodiments of this application, the acquisition module is further configured to: Obtain the motion parameters of the electronic device; The image stabilization compensation module is specifically used for; When the shooting status information indicates that the camera module is in non-shooting mode, and the motion parameters indicate that the motion intensity of the electronic device is greater than a first threshold, the electronic device is subjected to image stabilization compensation using the first compensation mode.

[0180] In some embodiments of this application, the image stabilization compensation module is specifically used for: Obtain the position vector information of the lens components in the camera module; Based on the position vector information and the motion parameters of the electronic device, the first current of the target electromagnetic coil of the electronic device is determined; Determine the instantaneous rate of change of the first angular velocity of the electronic device among the motion parameters; The deformation stiffness of the micro-spring-damping composite layer in the electronic device is adjusted according to the instantaneous rate of change of the first angular velocity. Anti-shake compensation is performed on the electronic device based on the first current of the target electromagnetic coil in the electronic device and the deformation stiffness of the micro-spring-damping composite layer.

[0181] In some embodiments of this application, the image stabilization compensation module is specifically used for: The displacement of the lens assembly after the target time period is obtained based on the offset vector and deflection angle of the lens assembly. Based on the displacement, the offset vector, and the deflection angle, anti-shake compensation is performed on the electronic device.

[0182] In some embodiments of this application, the acquisition module is further configured to acquire the spectral energy distribution of the motion parameters; The image stabilization compensation module is also used to perform image stabilization compensation on the electronic device according to the spectral energy distribution.

[0183] The image stabilization device in this application embodiment can be an electronic device or a component within an electronic device, such as an integrated circuit or a chip. The electronic device can be a terminal or other devices besides a terminal. For example, the electronic device can be a mobile phone, tablet computer, laptop computer, PDA, in-vehicle electronic device, mobile internet device (MID), augmented reality (AR) / virtual reality (VR) device, robot, wearable device, ultra-mobile personal computer (UMPC), netbook, or personal digital assistant (PDA), etc. It can also be a server, network attached storage (NAS), personal computer (PC), television (TV), ATM, or self-service machine, etc. This application embodiment does not specifically limit the device.

[0184] The image stabilization device in this application embodiment can be a device with an operating system. This operating system can be Android, iOS, or other possible operating systems; this application embodiment does not specifically limit the specific operating system used.

[0185] The image stabilization device provided in this application embodiment can achieve... Figure 1 The various processes implemented in the method implementation examples will not be described again here to avoid repetition.

[0186] Optionally, such as Figure 4 As shown, this application embodiment also provides an electronic device 400, including a processor 401 and a memory 402. The memory 402 stores a program or instructions that can run on the processor 401. When the program or instructions are executed by the processor 401, they implement the various steps of the above-described anti-shake method embodiment and can achieve the same technical effect. To avoid repetition, they will not be described again here.

[0187] It should be noted that the electronic devices in the embodiments of this application include the mobile electronic devices and non-mobile electronic devices described above.

[0188] Figure 5 A schematic diagram of the hardware structure of an electronic device to implement an embodiment of this application.

[0189] The electronic device 500 includes, but is not limited to, components such as: radio frequency unit 501, network module 502, audio output unit 503, input unit 504, sensor 505, display unit 506, user input unit 507, interface unit 508, memory 509, and processor 510.

[0190] Those skilled in the art will understand that the electronic device 500 may also include a power supply (such as a battery) for supplying power to various components. The power supply may be logically connected to the processor 510 through a power management system, thereby enabling functions such as managing charging, discharging, and power consumption through the power management system. Figure 5 The electronic device structure shown does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown, or combine certain components, or have different component arrangements, which will not be elaborated here.

[0191] The processor 510 is configured to acquire shooting status information of the camera module of the electronic device; when the shooting status information indicates that the camera module is in a non-shooting mode, perform image stabilization compensation on the electronic device using a first compensation mode; and / or, when the shooting status information indicates that the camera module is in a shooting mode, perform image stabilization compensation on the electronic device using a second compensation mode.

[0192] Thus, by acquiring the motion parameters of the electronic device and the shooting status information of the camera module, when the shooting status information indicates that the camera module is in non-shooting mode, a first compensation mode is used to perform image stabilization compensation on the electronic device; when the shooting status information indicates that the camera module is in shooting mode, a second compensation mode is used to perform image stabilization compensation on the electronic device. This approach uses different compensation methods depending on the state of the camera module, rather than a uniform method, improving the accuracy and effectiveness of image stabilization compensation. Furthermore, the solution in this application also compensates for image stabilization when the camera module is in non-shooting mode, filling the gap in existing solutions that cannot perform image stabilization compensation in non-shooting modes.

[0193] Optionally, the processor 510 is configured to acquire motion parameters of the electronic device; and when the shooting status information indicates that the camera module is in a non-shooting mode and the motion parameters indicate that the motion intensity of the electronic device is greater than a first threshold, perform image stabilization compensation on the electronic device using a first compensation mode.

[0194] Optionally, the processor 510 is further configured to acquire position vector information of the lens assembly in the camera module; determine a first current of the target electromagnetic coil in the electronic device based on the position vector information and the motion parameters of the electronic device; determine the instantaneous rate of change of the first angular velocity of the electronic device in the motion parameters; adjust the deformation stiffness of the micro-spring-damping composite layer in the electronic device based on the instantaneous rate of change of the first angular velocity; and perform image stabilization compensation on the electronic device based on the first current of the target electromagnetic coil in the electronic device and the deformation stiffness of the micro-spring-damping composite layer.

[0195] Optionally, the processor 510 is further configured to obtain the displacement of the lens assembly after the target time period based on the offset vector and the deflection angle of the lens assembly; and to perform image stabilization compensation on the electronic device based on the displacement, the offset vector and the deflection angle.

[0196] Optionally, the processor 510 is further configured to acquire the spectral energy distribution of the motion parameters; and to perform image stabilization compensation on the electronic device based on the spectral energy distribution.

[0197] It should be understood that, in this embodiment, the input unit 504 may include a graphics processing unit (GPU) 5041 and a microphone 5042. The GPU 5041 processes image data of still images or videos obtained by an image capture device (such as a color camera) in video capture mode or image capture mode. The display unit 506 may include a display panel 5061, which may be configured in the form of a liquid crystal display, an organic light-emitting diode, or the like. The user input unit 507 includes at least one of a touch panel 5071 and other input devices 5072. The touch panel 5071 is also called a touch screen. The touch panel 5071 may include a touch detection device and a touch controller. Other input devices 5072 may include, but are not limited to, physical keyboards, function keys (such as volume control buttons, power buttons, etc.), trackballs, mice, and joysticks, which will not be described in detail here.

[0198] The memory 509 can be used to store software programs and various data. The memory 509 may primarily include a first storage area for storing programs or instructions and a second storage area for storing data. The first storage area may store the operating system, application programs or instructions required for at least one function (such as sound playback, image playback, etc.). Furthermore, the memory 509 may include volatile memory or non-volatile memory, or both. The non-volatile memory may be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), or flash memory. Volatile memory can be random access memory (RAM), static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDRSDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM), and direct memory bus RAM (DRRAM). The memory 509 in this embodiment includes, but is not limited to, these and any other suitable types of memory.

[0199] Processor 510 may include one or more processing units; optionally, processor 510 integrates an application processor and a modem processor, wherein the application processor mainly handles operations involving the operating system, user interface, and applications, and the modem processor mainly handles wireless communication signals, such as a baseband processor. It is understood that the aforementioned modem processor may also not be integrated into processor 510.

[0200] This application also provides a readable storage medium storing a program or instructions. When the program or instructions are executed by a processor, they implement the various processes of the above-described anti-shake method embodiments and achieve the same technical effect. To avoid repetition, they will not be described again here.

[0201] The processor is the processor in the electronic device described in the above embodiments. The readable storage medium includes computer-readable storage media, such as computer read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk.

[0202] This application embodiment also provides a chip, which includes a processor and a communication interface. The communication interface is coupled to the processor. The processor is used to run programs or instructions to implement the various processes of the above-described anti-shake method embodiments and can achieve the same technical effect. To avoid repetition, it will not be described again here.

[0203] It should be understood that the chip mentioned in the embodiments of this application may also be referred to as a system-on-a-chip, system chip, chip system, or system-on-a-chip, etc.

[0204] This application provides a computer program product, which is stored in a storage medium and executed by at least one processor to implement the various processes of the anti-shake method embodiments described above, and can achieve the same technical effect. To avoid repetition, it will not be described again here.

[0205] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element. Furthermore, it should be noted that the scope of the methods and apparatuses in the embodiments of this application is not limited to performing functions in the order shown or discussed, but may also include performing functions substantially simultaneously or in the reverse order, depending on the functions involved. For example, the described methods may be performed in a different order than described, and various steps may be added, omitted, or combined. Additionally, features described with reference to certain examples may be combined in other examples.

[0206] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a computer software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods described in the various embodiments of this application.

[0207] The embodiments of this application have been described above with reference to the accompanying drawings. However, this application is not limited to the specific embodiments described above. The specific embodiments described above are merely illustrative and not restrictive. Those skilled in the art can make many other forms under the guidance of this application without departing from the spirit and scope of the claims, and all of these forms are within the protection scope of this application.

Claims

1. A method for stabilizing image quality, characterized in that, The method includes: Obtain the shooting status information of the camera module of the electronic device; When the shooting status information indicates that the camera module is in non-shooting mode, image stabilization compensation is performed on the electronic device using a first compensation mode; and / or, When the shooting status information indicates that the camera module is in shooting mode, the second compensation mode is used to perform image stabilization compensation on the electronic device.

2. The method according to claim 1, characterized in that, Before performing image stabilization compensation on the electronic device using the first compensation mode, the method further includes: Obtain the motion parameters of the electronic device; When the shooting status information indicates that the camera module is in non-shooting mode, performing image stabilization compensation on the electronic device using a first compensation mode includes: When the shooting status information indicates that the camera module is in non-shooting mode, and the motion parameters indicate that the motion intensity of the electronic device is greater than a first threshold, the electronic device is subjected to image stabilization compensation using the first compensation mode.

3. The method according to claim 1, characterized in that, The step of performing image stabilization compensation on the electronic device using the first compensation mode includes: Obtain the position vector information of the lens components in the camera module; Based on the position vector information and the motion parameters of the electronic device, the first current of the target electromagnetic coil in the electronic device is determined; Determine the instantaneous rate of change of the first angular velocity of the electronic device among the motion parameters; The deformation stiffness of the micro-spring-damping composite layer in the electronic device is adjusted according to the instantaneous rate of change of the first angular velocity. Anti-shake compensation is performed on the electronic device based on the first current of the target electromagnetic coil in the electronic device and the deformation stiffness of the micro-spring-damping composite layer.

4. The method according to claim 1, characterized in that, The step of performing image stabilization compensation on the electronic device using the second compensation mode includes: The displacement of the lens assembly after the target time period is obtained based on the offset vector and deflection angle of the lens assembly. Based on the displacement, the offset vector, and the deflection angle, anti-shake compensation is performed on the electronic device.

5. The method according to claim 1, characterized in that, The method further includes: Obtain the spectral energy distribution of the motion parameters of the electronic device; Based on the spectral energy distribution, image stabilization compensation is performed on the electronic device.

6. A shake-stabilizing device, characterized in that, The device includes: The acquisition module is used to acquire the shooting status information of the camera module of the electronic device; The image stabilization compensation module is used to perform image stabilization compensation on the electronic device using a first compensation mode when the shooting status information indicates that the camera module is in a non-shooting mode; and / or, to perform image stabilization compensation on the electronic device using a second compensation mode when the shooting status information indicates that the camera module is in a shooting mode.

7. The apparatus according to claim 6, characterized in that, The acquisition module is also used for: Obtain the motion parameters of the electronic device; The image stabilization compensation module is specifically used for; When the shooting status information indicates that the camera module is in non-shooting mode, and the motion parameters indicate that the motion intensity of the electronic device is greater than a first threshold, the electronic device is subjected to image stabilization compensation using the first compensation mode.

8. The apparatus according to claim 6, characterized in that, The image stabilization compensation module is specifically used for: Obtain the position vector information of the lens components in the camera module; Based on the position vector information and the motion parameters of the electronic device, the first current of the target electromagnetic coil in the electronic device is determined; Determine the instantaneous rate of change of the first angular velocity of the electronic device among the motion parameters; The deformation stiffness of the micro-spring-damping composite layer in the electronic device is adjusted according to the instantaneous rate of change of the first angular velocity. Anti-shake compensation is performed on the electronic device based on the first current of the target electromagnetic coil in the electronic device and the deformation stiffness of the micro-spring-damping composite layer.

9. The apparatus according to claim 6, characterized in that, The image stabilization compensation module is specifically used for: The displacement of the lens assembly after the target time period is obtained based on the offset vector and deflection angle of the lens assembly. Based on the displacement, the offset vector, and the deflection angle, anti-shake compensation is performed on the electronic device.

10. The apparatus according to claim 6, characterized in that, The acquisition module is also used to acquire the spectral energy distribution of the motion parameters of the electronic device; The image stabilization compensation module is also used to perform image stabilization compensation on the electronic device according to the spectral energy distribution.

11. An electronic device, characterized in that, It includes a processor and a memory, the memory storing a program or instructions that can run on the processor, the program or instructions being executed by the processor to implement the steps of the anti-shake method as described in any one of claims 1-5.