Vibration control method and device, electronic equipment and storage medium
By adjusting the vibration voltage signal to match the natural frequency of the electronic device in the second-order mode, the Z-axis vibration was enhanced, solving the problem of poor vibration prompting effect in the prior art and improving the user experience.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
- Filing Date
- 2023-06-30
- Publication Date
- 2026-04-21
AI Technical Summary
Existing electronic devices do not provide effective vibration alerts when placed horizontally, especially due to insufficient vibration in the Z-axis direction, which may cause users to miss incoming calls, text messages, or notifications.
By acquiring the vibration voltage signal and adjusting the vibration voltage signal based on the natural frequency of the electronic device in the second mode to match the natural frequency, the vibration motor is controlled to vibrate, thereby enhancing the vibration amount in the Z-axis direction.
It improves the vibration effect of electronic devices when placed horizontally, especially the amount of vibration in the Z-axis direction, enhancing the vibration sensation and preventing users from missing prompts.
Smart Images

Figure CN119225438B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of electronic equipment technology, and more specifically, to a vibration control method, apparatus, electronic device, and storage medium. Background Technology
[0002] With the rapid advancement of technology and living standards, electronic devices (such as smartphones and tablets) have become one of the most commonly used electronic products in people's lives. Vibration alerts, as a typical application on electronic devices, can effectively alert users to incoming calls, text messages, and notifications in certain usage scenarios (such as office settings). However, current electronic devices may experience poor vibration response in some situations. Summary of the Invention
[0003] This application proposes a vibration control method, device, electronic device, and storage medium, which can enhance the vibration amount along the Z-axis by utilizing second-order mode shapes, thereby enhancing the vibration effect of electronic devices.
[0004] In a first aspect, embodiments of this application provide a vibration control method applied to an electronic device, the electronic device including a vibration motor, the method comprising: acquiring a vibration voltage signal to be output; adjusting the vibration voltage signal based on the natural frequency of the electronic device in a second-order mode, wherein the frequency of at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency; and controlling the vibration motor to vibrate based on the adjusted vibration voltage signal.
[0005] Secondly, embodiments of this application provide a vibration control device applied to an electronic device, the electronic device including a vibration motor, and the device including: a signal acquisition module, a signal adjustment module, and a motor control module, wherein the signal acquisition module is used to acquire a vibration voltage signal to be output; the signal adjustment module is used to adjust the vibration voltage signal based on the natural frequency of the electronic device in the second-order mode, wherein the frequency of at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency; and the motor control module is used to control the vibration motor to vibrate based on the adjusted vibration voltage signal.
[0006] Thirdly, embodiments of this application provide an electronic device, including: one or more processors; a memory; and one or more application programs, wherein the one or more application programs are stored in the memory and configured to be executed by the one or more processors, and the one or more application programs are configured to perform the vibration control method provided in the first aspect above.
[0007] Fourthly, embodiments of this application provide a computer-readable storage medium storing program code, which can be invoked by a processor to execute the vibration control method provided in the first aspect above.
[0008] The solution provided in this application acquires the vibration voltage signal to be output, adjusts the vibration voltage signal based on the natural frequency of the electronic device in the second mode, and matches the frequency of at least a portion of the waveform of the adjusted vibration voltage signal with the natural frequency of the second mode. Based on the adjusted vibration voltage signal, a vibration motor is controlled to vibrate. Thus, the vibration amount along the Z-axis can be enhanced using the second-order mode shape, thereby improving the vibration effect of the electronic device. Attached Figure Description
[0009] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0010] Figure 1 A flowchart of a vibration control method according to an embodiment of this application is shown.
[0011] Figure 2 A flowchart of a vibration control method according to another embodiment of this application is shown.
[0012] Figure 3 A flowchart of a vibration control method according to yet another embodiment of this application is shown.
[0013] Figure 4 A flowchart of a vibration control method according to another embodiment of this application is shown.
[0014] Figure 5 A schematic diagram showing the variation of vibration in the Z-axis direction of an electronic device is shown.
[0015] Figure 6 A flowchart of a vibration control method according to yet another embodiment of this application is shown.
[0016] Figure 7 A block diagram of a vibration control device according to an embodiment of this application is shown.
[0017] Figure 8 This is a block diagram of an electronic device for performing a vibration control method according to an embodiment of this application.
[0018] Figure 9This is a storage unit in this application embodiment for storing or carrying program code that implements the vibration control method according to this application embodiment. Detailed Implementation
[0019] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings.
[0020] With the development of mobile internet technology and the influx of various consumer electronics products, people's lives have become more intelligent and diversified. Electronic devices often use vibration alerts to notify users of incoming calls, text messages, and notifications.
[0021] In related technologies, electronic devices typically incorporate linear motors, and vibration alerts are achieved by controlling the vibration of these motors. The free vibration of a linear system can be decomposed and coupled into N (positive integer) orthogonal single-degree-of-freedom vibration systems, corresponding to the system's N modes. Each mode has a specific natural frequency, damping ratio, and mode shape. For X-axis linear motors installed in electronic devices, related technologies usually utilize the waveform of the first-order mode (horizontal X-axis) for vibration. Therefore, the vibration in other directions is weak, resulting in insufficient vibration in the vertical Z-axis when the electronic device is placed flat on a table to alert users to incoming calls, text messages, notifications, etc., causing users to miss these notifications.
[0022] To address the aforementioned problems, the inventors have proposed a vibration control method, device, electronic device, and storage medium as provided in the embodiments of this application. These methods can enhance the vibration amplitude along the Z-axis using second-order mode shapes, thereby improving the vibration performance of the electronic device. The specific vibration control method will be described in detail in the subsequent embodiments.
[0023] The vibration control method provided in the embodiments of this application will now be described in detail with reference to the accompanying drawings.
[0024] Please see Figure 1 , Figure 1 A schematic flowchart of a vibration control method provided in one embodiment of this application is shown. In a specific embodiment, the vibration control method is applied to an electronic device, which includes a vibration motor. It is understood that the electronic device used in this embodiment can be a smartphone, tablet computer, smartwatch, e-reader, etc., and is not limited thereto. The following will focus on... Figure 1 The process shown is described in detail. The vibration control method may specifically include the following steps:
[0025] Step S110: Obtain the vibration voltage signal to be output.
[0026] In this embodiment, the vibration voltage signal to be output is a voltage signal used to excite the vibration motor to vibrate. This voltage signal continuously outputs voltage throughout its entire duration, thereby exciting the vibration motor to vibrate. The parameters of the vibration voltage signal may include frequency, amplitude, and number of vibration cycles. The frequency of the vibration voltage signal determines the vibration frequency of the vibration motor, the amplitude determines the voltage value driving the vibration motor, and the number of vibration cycles is the number of cycles generated by the vibration motor. The vibration voltage signal can be understood as the voltage signal controlling the vibration motor throughout the entire process of vibration; the frequency of the waveform of the voltage signal may differ at different times. In this embodiment, the scenarios for controlling the vibration motor to vibrate can include incoming call reminders, SMS reminders, notification reminders, touch feedback, game vibration, and warning reminders, etc. The specific scenario for controlling the vibration motor to vibrate is not limited.
[0027] In some implementations, the vibration voltage signal can be a voltage signal generated based on the current vibration duration, frequency, and intensity requirements. The vibration voltage signal includes, but is not limited to, a sine wave signal.
[0028] In one possible implementation, if the scenario in which the electronic device controls the vibration motor to vibrate is a scenario in which sound is played and vibration occurs simultaneously, then the above vibration voltage signal can be obtained by the electronic device analyzing and extracting sound source features based on the played audio through an algorithm; then, based on the extracted sound source features, a vibration waveform is generated through a corresponding vibration waveform generation algorithm, and the vibration voltage signal is obtained based on the generated vibration waveform.
[0029] For example, when an electronic device displays an incoming call notification, it can load a ringtone file, extract the audio features of the ringtone file, generate a vibration waveform based on the audio features to drive a vibration motor to vibrate in response to the ringtone, and obtain a vibration voltage signal based on the generated vibration waveform. Subsequently, the electronic device can play the ringtone file while controlling the vibration motor to vibrate based on the vibration voltage signal.
[0030] In one possible implementation, the waveform parameters of the waveform constituting the above vibration voltage signal can be pre-generated and stored by an electronic device. When it is necessary to control the vibration motor to vibrate, the electronic device can read the above waveform parameters and obtain the vibration voltage signal based on the vibration waveform corresponding to the read waveform parameters.
[0031] Step S120: Based on the natural frequency of the electronic device in the second-order mode, adjust the vibration voltage signal, and the frequency of at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency.
[0032] In this embodiment, considering that in related technologies, when controlling a vibration motor to vibrate, the vibration waveform used to control the vibration motor usually only utilizes the waveform of the first-order mode, the vibration is relatively strong only on the X-axis, while the vibration in other axis directions is small, thus affecting the vibration effect when the electronic device is placed horizontally on a plane, the electronic device can adjust the vibration voltage signal based on the natural frequency of the electronic device in the second-order mode, so that the frequency of at least a part of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency. This means that the vibration waveform used to control the vibration motor to vibrate includes the waveform of the natural frequency in the second-order mode, thereby increasing the vibration amount (i.e., amplitude) of the electronic device in the Z-axis direction, and thus improving the vibration effect when the electronic device is placed horizontally on a plane. Here, the natural frequency of the electronic device in the second-order mode refers to the natural frequency of the vibration system of the electronic device as a whole in the second-order mode, that is, the natural frequency of the vibration system formed by assembling the vibration motor into the electronic device in the second-order mode, thereby controlling the vibration of the entire vibration system more accurately.
[0033] The free vibration of a linear system can typically be decomposed and coupled into N (positive integer) orthogonal single-degree-of-freedom vibration systems, corresponding to the system's N modes. Each mode has a specific natural frequency, damping ratio, and mode shape. For vibration systems composed of electronic devices, there are usually first-order, second-order, and third-order modes. The first-order mode corresponds to the vibration on the X-axis, the second-order mode to the vibration on the Z-axis, and the third-order mode to the vibration on the Y-axis. The X and Y axes are located on the horizontal plane where the screen of the electronic device is located, and the Z-axis is perpendicular to this horizontal plane. The X, Y, and Z axes are mutually perpendicular. When the vibration frequency of the system is the natural frequency of any mode, the vibration quantity (i.e., amplitude) of the system in that mode reaches its maximum value. Therefore, when the electronic device is placed horizontally on a plane, controlling the vibration motor to vibrate using the vibration waveform of the second-order mode can increase the vibration quantity of the electronic device on the Z-axis, thereby improving the vibration effect of the electronic device when it is placed horizontally on a plane.
[0034] In some implementations, the electronic device can adjust the waveform of the vibration voltage signal to be output, so that at least a portion of the waveform corresponding to the vibration voltage signal matches the natural frequency; that is, the frequency of at least a portion of the waveform corresponding to the vibration voltage signal matches the natural frequency. Here, "at least a portion of the waveform's frequency matches the natural frequency" means that the difference between the frequency of the at least a portion of the waveform and the natural frequency is less than a target threshold, such as 1 Hz (Hertz), 3 Hz, etc. The difference between the frequency of the at least a portion of the waveform and the natural frequency is the absolute value of the difference obtained by subtracting the natural frequency from the frequency of the at least a portion of the waveform.
[0035] In one possible implementation, the electronic device, for the vibration voltage signal to be output, can adjust a target proportion of the waveform corresponding to the vibration voltage signal to a waveform whose frequency matches the aforementioned natural frequency. This target proportion can be 30%, 50%, or 70%. As a result, the proportion of waveforms whose frequency matches the aforementioned natural frequency in the adjusted vibration voltage signal reaches the target proportion. Consequently, during the vibration process, the duration of the vibration reaching its maximum value in the Z-axis direction relative to the total vibration duration reaches the target proportion, thereby increasing the vibration amplitude of the electronic device in the Z-axis direction.
[0036] Step S130: Based on the adjusted vibration voltage signal, control the vibration motor to vibrate.
[0037] In this embodiment, after obtaining the adjusted vibration voltage signal, the motor can be driven to vibrate using the vibration voltage signal, i.e., the vibration voltage signal serves as an excitation signal to excite the vibration motor to vibrate. Since at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency, compared to controlling the vibration motor to vibrate solely through the waveform in the first-order mode, the vibration amount of the entire vibration system composed of the electronic device along the Z-axis can be increased, thereby enhancing the vibration effect of the electronic device.
[0038] In some implementations, the electronic device controls the vibration motor to vibrate according to the scenario in which it does so. If the current scenario is a scenario of playing a prompt tone and vibrating, it can control the vibration motor to vibrate based on the adjusted vibration voltage signal, and at the same time control the audio playback device to play the prompt tone, thereby achieving a prompt effect that combines sound and vibration, and preventing the user from missing the relevant prompts.
[0039] The vibration control method provided in this application obtains the vibration voltage signal to be output, adjusts the vibration voltage signal based on the natural frequency of the electronic device in the second-order mode, and the frequency of at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency of the second-order mode. Based on the adjusted vibration voltage signal, the vibration motor is controlled to vibrate. Since the frequency of at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency, compared with the related technology that only controls the vibration motor to vibrate based on the waveform in the first-order mode, the vibration of the entire vibration system composed of the electronic device in the Z-axis can be increased, thereby enhancing the vibration effect of the electronic device. In particular, when the electronic device is placed horizontally on a plane, the vertical vibration can be enhanced.
[0040] Please see Figure 2 , Figure 2A schematic flowchart of another embodiment of the vibration control method provided in this application is shown. This vibration control method is applied to the aforementioned electronic device, which includes a vibration motor. The following will focus on... Figure 2 The process shown is described in detail. The vibration control method may specifically include the following steps:
[0041] Step S210: Obtain the vibration voltage signal to be output.
[0042] In this embodiment, step S210 can be referred to the content of the foregoing embodiments, and will not be repeated here.
[0043] Step S220: If the waveform corresponding to the vibration voltage signal includes a target waveform, then the target waveform in the waveform corresponding to the vibration voltage signal is adjusted to obtain the adjusted vibration voltage signal. The difference between the frequency corresponding to the target waveform and the natural frequency is less than a first frequency threshold, and the frequency of the adjusted target waveform matches the natural frequency.
[0044] In this embodiment of the application, when the electronic device obtains the vibration voltage signal to be output and adjusts the vibration voltage signal, it can adjust the vibration voltage signal according to the actual situation of the waveform corresponding to the vibration voltage signal. The electronic device can determine whether the waveform corresponding to the vibration voltage signal includes a target waveform. The difference between the frequency of the target waveform and its natural frequency is less than a first frequency threshold, such as 8Hz, 10Hz, or 12Hz, with no specific value required. The difference between the frequency of the target waveform and its natural frequency is the absolute value of the difference obtained by subtracting the natural frequency from the frequency of the target waveform. In other words, the electronic device can determine whether the waveform corresponding to the vibration voltage signal includes a waveform with a frequency close to the natural frequency of the second-order mode. If the waveform corresponding to the vibration voltage signal is found to include the target waveform, it means that the original vibration voltage signal originally contained a waveform with a frequency close to the natural frequency of the second-order mode. Therefore, adjusting the target waveform to match its corresponding frequency with the natural frequency of the second-order mode will not significantly affect the intended vibration effect. Furthermore, since the adjusted target waveform matches the natural frequency, the waveform corresponding to the vibration voltage signal can include a waveform that matches the natural frequency. When the adjusted vibration voltage signal is used to control the vibration motor, the vibration of the entire vibration system composed of the electronic device can be increased along the Z-axis, thereby enhancing the vibration effect of the electronic device.
[0045] In some embodiments, when the electronic device determines that the waveform corresponding to the above vibration voltage signal includes the target waveform, when adjusting the target waveform in the waveform corresponding to the vibration voltage signal, it can resample and frequency adjust the target waveform so that the frequency of the frequency-adjusted target waveform matches the natural frequency, thereby obtaining the adjusted vibration voltage signal. Specifically, the target waveform can be resampled according to the start time corresponding to the target waveform in the vibration voltage signal and the target sampling interval to obtain a resampled waveform, and the frequency of the resampled waveform can be shifted to adjust the target waveform so that its frequency matches the natural frequency.
[0046] In some implementations, to further improve the vibration effect of the electronic device, the electronic device can also determine whether the waveform corresponding to the vibration voltage signal includes a second waveform whose frequency difference with the natural frequency of the first mode is less than a first target threshold. If the waveform corresponding to the vibration voltage signal includes a second waveform whose frequency difference with the natural frequency of the first mode is less than the first target threshold, then the frequency of the second waveform in the waveform corresponding to the vibration voltage signal can be adjusted to match the frequency of the second waveform with the natural frequency of the first mode. If the waveform corresponding to the vibration voltage signal does not include a second waveform whose frequency difference with the natural frequency of the first mode is less than the first target threshold, then no frequency adjustment related to the natural frequency of the first mode is performed on the voltage signal. Understandably, the first mode corresponds to the vibration amount on the X-axis. When the vibration frequency of the vibration system is the natural frequency of the first mode, the vibration amount of the vibration system corresponding to the first mode (i.e., the vibration amount on the X-axis) reaches its maximum value. Although the waveform of the first mode is usually used for the vibration of the vibration motor in related technologies, in the actual vibration voltage signal, the duration of the waveform whose frequency matches the frequency of the first mode may not be long. Therefore, the waveform whose frequency is close to the natural frequency of the first mode can be adjusted to match the natural frequency of the first mode, thereby increasing the proportion of the waveform of the natural frequency of the first mode in the waveform corresponding to the vibration voltage signal, and further increasing the vibration amount of the electronic device on the X-axis without having too much impact on the original vibration effect.
[0047] In some implementations, to further improve the vibration effect of the electronic device, the electronic device can also determine whether the waveform corresponding to the vibration voltage signal includes a third waveform whose frequency difference with the natural frequency of the third mode is less than a second target threshold. If the waveform corresponding to the vibration voltage signal includes a third waveform whose frequency difference with the natural frequency of the third mode is less than the second target threshold, then the frequency of the third waveform in the waveform corresponding to the vibration voltage signal can be adjusted to match the frequency of the third waveform with the natural frequency of the third mode. If the waveform corresponding to the vibration voltage signal does not include a third waveform whose frequency difference with the natural frequency of the third mode is less than the second target threshold, then no frequency adjustment related to the natural frequency of the third mode is performed on the voltage signal. Understandably, the third mode corresponds to the vibration amount on the Y-axis. When the vibration frequency of the vibration system is the natural frequency of the third mode, the vibration amount of the vibration system in the third mode (i.e., the vibration amount on the Y-axis) reaches its maximum value. Since related technologies usually use the waveform of the first mode for the vibration of the vibration motor, that is, mainly control the vibration of the vibration motor on the X-axis, but not on the Y-axis, if the electronic device is affected by the external environment and vibrates on the X-axis (for example, the electronic device is clamped on both sides in the X-axis direction), the vibration effect of the electronic device on the plane where its screen is located will be poor. Therefore, the waveform with a frequency close to the natural frequency of the third mode can be adjusted to match the natural frequency of the third mode, thereby increasing the proportion of the waveform of the natural frequency of the third mode in the waveform corresponding to the vibration voltage signal, thereby increasing the vibration amount of the electronic device on the Y-axis, without having too much impact on the original vibration effect.
[0048] Step S230: If the waveform corresponding to the vibration voltage signal does not include the target waveform, then the first waveform in the waveform corresponding to the vibration voltage signal is replaced with the waveform of the natural frequency to obtain the adjusted vibration voltage signal. The first waveform includes at least one of the waveform gap in the waveform corresponding to the vibration voltage signal and a long vibration waveform with a duration longer than the target duration. The long vibration waveform is a vibration waveform with a vibration period greater than the target number.
[0049] In this embodiment, after determining whether the waveform corresponding to the vibration voltage signal includes a waveform with a frequency close to the natural frequency of the second-order mode, if the waveform corresponding to the vibration voltage signal does not include the target waveform, it means that the original vibration voltage signal did not originally contain a waveform with a frequency close to the natural frequency of the second-order mode. In this case, if at least a portion of the waveform of the vibration voltage signal is directly adjusted to match the natural frequency of the second-order mode, it may have too much impact on the intended vibration effect. Therefore, when it is determined that the waveform corresponding to the vibration voltage signal does not include the target waveform, the electronic device can determine at least one of the waveform gaps and long-wave waveforms with a duration longer than the target duration from the waveform of the vibration voltage signal, and use the determined waveform gaps and long-wave waveforms as the first waveform, where the target duration is [not specified]. For the first waveform, the first waveform can be replaced with a waveform with the natural frequency of the second-order mode. Understandably, if the waveform corresponding to the vibration voltage signal does not include the target waveform, at least one of the waveform gaps and long vibration waveforms with a duration longer than the target duration is replaced. This will not have too much impact on the original vibration effect, and will allow the waveform corresponding to the vibration voltage signal to include a waveform that matches the natural frequency. When the vibration motor is controlled to vibrate using the adjusted vibration voltage signal, the vibration amount of the entire vibration system composed of electronic equipment on the Z-axis can be increased, thereby enhancing the vibration effect of the electronic equipment.
[0050] In some implementations, for the determined first waveform, if the first waveform includes waveform gaps in the waveform corresponding to the vibration voltage signal, a waveform with the natural frequency in the second mode can be generated and the generated waveform can be filled into the waveform gaps; if the first waveform includes a long vibration waveform with a duration longer than the target duration, the long vibration waveform can be replaced with a waveform with the natural frequency in the second mode.
[0051] Step S240: Based on the adjusted vibration voltage signal, control the vibration motor to vibrate.
[0052] In this embodiment, step S240 can be found in other embodiments and will not be repeated here.
[0053] The vibration control method provided in this application acquires a vibration voltage signal to be output. If the waveform of the vibration voltage signal includes a target waveform whose frequency difference with the natural frequency in the second-order mode is less than a first frequency threshold, the target waveform is adjusted to match the natural frequency. If the waveform of the vibration voltage signal does not include the target waveform, at least one of the waveform gaps and long vibration waveforms with a duration longer than the target duration in the waveform of the vibration voltage signal is replaced with a waveform of the natural frequency. This not only ensures that the waveform corresponding to the vibration voltage signal includes a waveform that matches the natural frequency, but also enhances the vibration effect of the entire vibration system composed of electronic devices on the Z-axis when the vibration motor is controlled by the adjusted vibration voltage signal, thus ensuring that the original vibration effect is not significantly affected.
[0054] Please see Figure 3 , Figure 3 A schematic flowchart of another embodiment of the vibration control method provided in this application is shown. This vibration control method is applied to the aforementioned electronic device, which includes a vibration motor. The following will focus on... Figure 3 The process shown is described in detail. The vibration control method may specifically include the following steps:
[0055] Step S310: Obtain the vibration voltage signal to be output.
[0056] Step S320: Based on the natural frequency of the electronic device in the second-order mode, adjust the vibration voltage signal, and the frequency of at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency.
[0057] In the embodiments of this application, steps S310 and S320 can be referred to the content of the foregoing embodiments, and will not be repeated here.
[0058] Step S330: If the waveform of the vibration voltage signal is a long-wave waveform, then the vibration motor is controlled to vibrate based on the vibration voltage signal under the rated voltage.
[0059] In this embodiment, after adjusting the vibration voltage signal to obtain a vibration voltage signal whose frequency at least part of the waveform matches the natural frequency under the second-order mode, when controlling the vibration motor to vibrate using this vibration voltage signal, the voltage value corresponding to the vibration voltage signal can also be controlled according to the actual waveform of the vibration voltage signal. Specifically, the electronic device can determine whether the waveform of the vibration voltage signal is a long-wave or short-wave waveform. If the waveform is determined to be a long-wave waveform, the vibration motor can be controlled to vibrate based on the vibration voltage signal at the rated voltage; that is, the voltage value of the vibration voltage signal with the long-wave waveform is the rated voltage value. The long-wave waveform is a vibration waveform with a vibration period greater than a target number, which can be 2, 3, 5, etc., and the specific value is not limited.
[0060] Understandably, the stroke of a linear motor (i.e., the vertical distance between the main mass block inside the motor and the housing) is limited. When a vibration motor is driven with a voltage exceeding the rated voltage, multiple sinusoidal vibration cycles will cause the mass block to collide with the internal limit stop or housing of the vibration motor, thereby damaging the motor body. Therefore, the higher the driving voltage, the smaller the vibration cycle should be. Thus, when driving a vibration motor with a voltage signal of a long vibration waveform (i.e., a waveform exceeding the target number of vibration cycles), a safe voltage (i.e., the rated voltage) is required.
[0061] Step S340: If the waveform of the vibration voltage signal is a short vibration waveform, then the vibration motor is controlled to vibrate based on the vibration voltage signal under the short vibration voltage. The short vibration voltage is the voltage when the vibration motor reaches its maximum stroke in the Z-axis direction when the vibration motor is controlled to vibrate by the voltage signal of the short vibration waveform with the natural frequency. The short vibration waveform is a vibration waveform with a vibration period less than or equal to the target number.
[0062] In this embodiment, when the electronic device determines that the waveform of the vibration voltage signal is a short-wave waveform, it can control the vibration motor to vibrate based on the vibration voltage signal under the short-wave voltage. That is, the voltage value of the vibration voltage signal of the short-wave waveform is the voltage value of the short-wave voltage. Here, the short-wave waveform is a vibration waveform with a vibration period less than or equal to a target number, which can be 2, 3, 5, etc., and the specific value is not limited. The short-wave voltage is the voltage at which the vibration motor reaches its maximum stroke in the Z-axis direction when the vibration motor is controlled by the voltage signal of the short-wave waveform with its natural frequency.
[0063] Understandably, the stroke of a linear motor is limited. When a vibration motor is driven with a voltage exceeding its rated voltage, multiple sinusoidal vibration cycles can cause the mass block to collide with the internal limit stop or housing of the vibration motor, thereby damaging the motor body. Therefore, the higher the driving voltage, the smaller the vibration cycle should be. When the vibration cycle is less, the vibration motor can withstand a higher driving voltage to achieve the same stroke. Thus, when driving the vibration motor with a short-wavelength voltage signal (i.e., a waveform with no more than the target number of vibration cycles), the driving voltage can be increased to increase the amplitude of the vibration motor. Therefore, by controlling the vibration motor's vibration in advance with a short-wavelength voltage signal of its natural frequency, the voltage at which the vibration motor reaches its maximum stroke in the Z-axis direction can be obtained. This obtained voltage is used as the short-wavelength voltage. By controlling the vibration motor with the vibration voltage signal under this short-wavelength voltage, the vibration amount in the Z-axis direction can be further increased, thereby improving the vibration sensation.
[0064] In some implementations, based on the natural frequency of the electronic device in the second mode, a voltage signal of a short-wave waveform of the natural frequency of the electronic device in the second mode can be generated. Then, the vibration motor is controlled to vibrate by the voltage signal of the short-wave waveform, and the signal gain is gradually increased to gradually increase the stroke of the vibration motor in the Z-axis direction. When the stroke in the Z-axis direction reaches the designed maximum stroke of the vibration motor, the voltage at this time is recorded and used as the short-wave voltage. The voltage value of the obtained short-wave voltage can be stored so that when the electronic device actually controls the vibration motor to vibrate, it can control the vibration motor to vibrate according to the vibration voltage signal of this voltage value.
[0065] In one possible implementation, the vibration motor is controlled to vibrate using a voltage signal from a short-wave waveform of the natural frequency under the second-order mode. After obtaining the short-wave voltage, the second-order mode coefficients can be calculated and stored based on the short-wave voltage and the maximum instantaneous voltage that the vibration motor can withstand. When the actual vibration voltage signal waveform is a short-wave waveform, the short-wave voltage can be determined using the second-order mode coefficients and the maximum instantaneous voltage, and then the vibration motor can be controlled to vibrate based on the vibration voltage signal under the short-wave voltage. This can be achieved using the formula: c = V zmax / V max Calculate the second-order modal coefficients, where c is the second-order modal coefficient and V is the second-order modal coefficient. zmax For the above short-cycle voltage, V max This is the maximum instantaneous voltage that the vibration motor can withstand.
[0066] It should be noted that since the vibration voltage signal is a continuous voltage signal, and its waveform may contain waveform gaps (i.e., no waveform exists for a certain period of time, meaning the voltage value is 0 during that period), the waveform corresponding to the vibration voltage signal may include both long and short vibration waveforms. To address this, when the output vibration voltage signal waveform is a long vibration waveform, the voltage value of the long vibration waveform's voltage signal can be controlled to be the rated voltage value; when the output vibration voltage signal waveform is a short vibration waveform, the voltage value of the short vibration waveform's voltage signal can be controlled to be the short vibration voltage value.
[0067] The vibration control method provided in this application acquires the vibration voltage signal to be output, adjusts the vibration voltage signal based on the natural frequency of the electronic device in the second-order mode, and matches the frequency of at least a portion of the waveform corresponding to the adjusted vibration voltage signal with the natural frequency of the second-order mode. Based on the adjusted vibration voltage signal, the vibration motor is controlled to vibrate. Since the frequency of at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency, compared with the related technology that only controls the vibration motor to vibrate using the waveform in the first-order mode, the vibration amount of the entire vibration system composed of the electronic device in the Z-axis can be increased, thereby enhancing the vibration effect of the electronic device. In particular, when the electronic device is placed horizontally on a plane, the vertical vibration can be enhanced. In addition, when controlling the vibration motor to vibrate based on the vibration voltage signal, when the waveform of the vibration voltage signal is a long vibration waveform, the vibration motor is controlled to vibrate using the vibration voltage signal under the rated voltage, thereby avoiding shell breakage during vibration. When the waveform of the vibration voltage signal is a short vibration waveform, the vibration motor is controlled to vibrate using the vibration voltage signal under the short vibration voltage, thereby further increasing the vibration amount of the vibration motor in the Z-axis direction, and thus enhancing the vibration effect of the electronic device.
[0068] Please see Figure 4 , Figure 4 A schematic flowchart of a vibration control method according to another embodiment of this application is shown. This vibration control method is applied to the aforementioned electronic device, which includes a vibration motor. The following will focus on... Figure 4 The process shown is described in detail. The vibration control method may specifically include the following steps:
[0069] Step S410: Obtain the vibration voltage signal to be output.
[0070] In this embodiment, step S410 can be referred to the content of the foregoing embodiments, and will not be repeated here.
[0071] Step S420: If the attitude parameters of the electronic device do not meet the target attitude parameter conditions, then the vibration motor is controlled to vibrate based on the vibration voltage signal.
[0072] In this embodiment, considering the X-axis linear motor installed in the electronic device, primarily when the electronic device is placed flat on a table, using a first-order mode (horizontal X-axis) waveform for vibration alerts such as incoming calls, text messages, and notifications can result in poor vibration feedback, potentially causing users to miss these notifications. However, in most other usage scenarios, using a first-order mode waveform vibration voltage signal to control the vibration motor provides a better alerting effect along the X-axis. Therefore, to reduce the processing load of the electronic device and improve its vibration response speed, when vibration is required, the device's attitude parameters can be acquired. Based on these parameters, it can be determined whether the device's attitude parameters meet a target attitude parameter condition. This target attitude parameter condition is used to determine whether the electronic device is placed flat on a plane. If the device's attitude parameters meet the target attitude parameter condition, it indicates that the device is currently placed flat on a plane; if the device's attitude parameters do not meet the target attitude parameter condition, it indicates that the device is not placed flat on a plane. After determining whether the attitude parameters of the electronic device meet the target attitude parameter conditions, based on the determination result, if it is determined that the attitude parameters of the electronic device meet the target attitude parameter conditions, it means that the electronic device is not placed flat on the plane. Therefore, the vibration voltage signal does not need to be adjusted to include the waveform of the natural frequency under the second mode. Instead, the vibration voltage signal is directly used to control the vibration motor to vibrate.
[0073] In some implementations, the above attitude parameters may include linear acceleration and angular acceleration. By detecting the linear acceleration and angular acceleration of the electronic device, it can be determined whether the linear acceleration and angular acceleration meet the target attitude parameter conditions.
[0074] In one possible implementation, the electronic device is equipped with an accelerometer, which can be used to obtain the linear acceleration of the electronic device. Specifically, the accelerometer can obtain acceleration along three mutually perpendicular axes: the x-axis, y-axis, and z-axis. The plane formed by the x-axis and y-axis is the plane of the screen, and the x-axis and y-axis are perpendicular to each other. The z-axis is perpendicular to the plane formed by the x-axis and y-axis, and the z-axis can be taken as vertically downwards as the positive direction.
[0075] In one possible implementation, angular acceleration can be detected by a gyroscope, also known as an angular velocity sensor. Electronic devices typically use three-axis gyroscopes, which can track displacement changes in six directions and acquire the angular acceleration of the electronic device in the x, y, and z directions. This allows for accurate measurement of the rotation and deflection movements of the electronic device, enabling corresponding operations. Common applications of gyroscopes in electronic devices include gaming, camera image stabilization, and navigation. Of course, the specific method by which the electronic device detects these attitude parameters is not limited.
[0076] In some implementations, the target attitude parameter conditions mentioned above may include target attitude parameters obtained by testing when the electronic device is placed flat on the screen. When determining whether the electronic device is placed flat on the plane, it can match the obtained attitude parameters with the target attitude parameters. If the obtained attitude parameters match the target attitude parameters, it can be determined that the obtained attitude parameters meet the target attitude parameter conditions. If the obtained attitude parameters do not match the target attitude parameters, it can be determined that the obtained attitude parameters do not meet the target attitude parameter conditions.
[0077] In some implementations, after acquiring the above posture parameters, the electronic device can input the posture parameters into a pre-trained placement detection model to obtain the detection result output by the placement detection model. This detection result indicates whether the posture parameters meet the target posture parameter conditions. The placement detection model is trained based on the posture parameters of a sample device placed horizontally on different planes, similar to the electronic device. The placement detection model can be a Support Vector Machine (SVM), a neural network, a Naive Bayes classifier, etc., and the specific model type is not limited.
[0078] In one possible implementation, when training the placement detection model, sample posture parameters of the device placed horizontally on different planes can be obtained. These parameters are then input into the initial detection model to obtain the detection results output by the placement detection model based on the input posture parameters. Based on the detection results output by the posture parameters and the labels indicating whether the device is placed horizontally on a plane, the target loss value for the initial detection model can be determined. The model parameters of the initial detection model are then adjusted according to the target loss value until the training termination condition is met, resulting in the trained placement detection model. The initial detection model can be a neural network, a Softmax logistic regression model, a support vector machine, etc., and the specific initial detection model is not limited. The training termination condition for iterative training can include: the number of iterations reaching a target number; or the loss value determined based on the output of the initial detection model meeting a set condition.
[0079] Step S430: If the attitude parameters of the electronic device meet the target attitude parameter conditions, then based on the natural frequency of the electronic device in the second-order mode, the vibration voltage signal is adjusted, and the frequency of at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency.
[0080] In this embodiment, after determining whether the acquired attitude parameters meet the target attitude parameter conditions, the electronic device, based on the determination result, if it is determined that the attitude parameters of the electronic device meet the target attitude parameter conditions, it indicates that the electronic device is placed flat on the plane. Therefore, the vibration voltage signal can be adjusted to include the waveform of the natural frequency in the second-order mode. Thus, when the vibration motor is controlled to vibrate according to the adjusted vibration voltage signal, the vibration amount in the Z-axis direction can be increased, thereby improving the vibration effect when the electronic device is placed flat on the plane. The specific method used by the electronic device to adjust the vibration voltage signal can be referred to the content of the foregoing embodiments, and will not be repeated here.
[0081] In some implementations, considering that the electronic device is in a flat position, it may be held by the user to maintain this position, for example, when the user holds the electronic device with both hands to play a game. In this case, the posture of the electronic device may match the flat position. Therefore, after determining that the posture parameters of the electronic device meet the target posture parameter conditions, it is also possible to determine whether the electronic device is being held. If it is determined that the electronic device is being held, it means that the electronic device is currently being held by the user and is in a flat position. At this time, the vibration motor is controlled to vibrate by the vibration voltage signal of the first-order mode waveform. Its vibration on the X-axis can also provide a good prompting effect. Therefore, the vibration voltage signal does not need to be adjusted to include the waveform of the natural frequency in the second-order mode. Instead, the vibration motor is directly controlled to vibrate by using the acquired vibration voltage signal. If it is determined that the electronic device is not being held, it means that the electronic device is placed horizontally on the plane. Therefore, the vibration voltage signal can be adjusted to include the waveform of the natural frequency in the second-order mode.
[0082] In one possible implementation, touch sensors, pressure sensors, etc., can be provided on the back cover and mid-frame of the electronic device. Based on the data detected by the sensors on the back cover and mid-frame, and the touch data collected by the touchscreen of the electronic device, it can be determined whether the electronic device is in a held state or not. For example, if the touch sensors on the back cover and mid-frame do not detect touch data, and the touchscreen does not collect touch data, it can be determined that the electronic device is not being held; if the touch sensors on the back cover and mid-frame detect touch data, and / or the touchscreen collects touch data, it can be determined that the electronic device is being held.
[0083] Step S440: Based on the adjusted vibration voltage signal, control the vibration motor to vibrate.
[0084] In this embodiment, step S440 can be referred to the content of the foregoing embodiments, and will not be repeated here.
[0085] For example, please refer to Figure 5 , Figure 5 This diagram illustrates the variation in vibration magnitude of an electronic device along the Z-axis when a vibration motor is controlled to vibrate using vibration voltage signals of different frequencies. Figure 5 The horizontal axis represents the frequency of the vibration voltage signal, and the vertical axis represents the vibration amount of the electronic device in the Z-axis direction. The first-order mode frequency rated voltage signal refers to the vibration voltage signal with a voltage value of the rated voltage and a waveform frequency of the natural frequency of the first-order mode. The second-order mode frequency rated voltage signal refers to the vibration voltage signal with a voltage value of the rated voltage and a waveform frequency of the natural frequency of the second-order mode. It can be seen that compared with the vibration amount in the Z-axis direction when the vibration motor is controlled by the above first-order mode frequency rated voltage signal, the vibration amount of the electronic device in the Z-axis direction is significantly increased when the vibration motor is controlled by the above method, thereby improving the vibration sensation of the electronic device in the Z-axis direction.
[0086] The vibration control method provided in this application, when it is necessary to control the vibration of an electronic device, determines that the attitude parameters of the electronic device meet the target attitude parameter conditions, and adjusts the vibration voltage signal based on the natural frequency of the electronic device in the second-order mode. The frequency of at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency of the second-order mode. Based on the adjusted vibration voltage signal, the vibration motor is controlled to vibrate. Since the frequency of at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency, compared with the related technology that only controls the vibration motor to vibrate through the waveform in the first-order mode, it can increase the vibration amount of the entire vibration system composed of the electronic device on the Z-axis, thereby enhancing the vibration effect of the electronic device. In particular, it can enhance the vertical vibration sensation when the electronic device is placed horizontally on a plane. When the attitude parameters of the electronic device do not meet the target attitude parameter conditions, the vibration motor is directly controlled to vibrate using the acquired vibration voltage signal, thereby reducing the processing load of the electronic device, reducing the power consumption of the electronic device, and ensuring the vibration response speed.
[0087] Please see Figure 6 , Figure 6 A schematic flowchart of another embodiment of the vibration control method provided in this application is shown. This vibration control method is applied to the aforementioned electronic device, which includes a vibration motor. The following will focus on... Figure 6 The process shown is described in detail. The vibration control method may specifically include the following steps:
[0088] Step S510: Control the vibration motor to vibrate based on the sweep frequency signal of the target frequency band.
[0089] Regarding the natural frequency of the electronic device in the second-order mode in the embodiments of this application, the embodiments of this application also include a method for obtaining the natural frequency. It is worth noting that the process of obtaining the natural frequency can be performed in advance before the electronic device leaves the factory. Subsequently, each time the electronic device controls the vibration motor to vibrate, the pre-obtained natural frequency can be used to adjust the vibration voltage signal, without having to re-obtain the above natural frequency every time the vibration voltage signal is adjusted.
[0090] In this embodiment, when obtaining the natural frequency of the vibration system composed of electronic devices in the second-order mode, the vibration motor can be controlled to vibrate based on a sweep frequency signal of the target frequency band. This allows the vibration amount of the electronic device in the Z-axis direction to be determined when the sweep frequency signal is at different frequencies, thereby determining the frequency at which the vibration amount is maximum. The target frequency band can be the full frequency band comprised of the vibration frequencies supported by the vibration motor; the sweep frequency signal of the target frequency band can be a sweep frequency signal of a long-waveform under rated voltage, where the long-waveform is a waveform with a vibration period greater than the target number.
[0091] Step S520: Obtain the vibration amount of the electronic device in the Z-axis direction at different frequencies of the sweep frequency signal.
[0092] In this embodiment of the application, when the vibration motor is controlled to vibrate based on the sweep frequency signal of the target frequency band, the vibration amount of the electronic device in the Z-axis direction can be obtained when the sweep frequency signal is at different frequencies, so as to determine the frequency at which the vibration amount of the electronic device in the Z-axis direction is the largest, and then determine the natural frequency of the electronic device in the second-order mode.
[0093] Step S530: Determine the frequency corresponding to the maximum vibration as the natural frequency of the electronic device in the second-order mode.
[0094] In this embodiment, based on the vibration amount of the electronic device in the Z-axis direction at different frequencies of the swept frequency signal, the frequency corresponding to the maximum vibration amount can be determined, and this frequency can be identified as the natural frequency of the electronic device in the second-order mode. After obtaining the natural frequency of the electronic device in the second-order mode, this natural frequency can be stored. Therefore, when it is necessary to control the vibration motor to vibrate, the vibration voltage signal can be adjusted according to the stored natural frequency so that the frequency of at least a portion of the waveform of the adjusted vibration voltage signal matches the natural frequency.
[0095] In some implementations, when the vibration motor is controlled to vibrate based on a sweep signal of the target frequency band, the vibration amount of the entire electronic device in the Z-axis direction can be collected, and a Fast Fourier Transform (FFT) can be performed on the collected time-domain vibration signal. Based on the FFT signal, the frequency corresponding to the maximum vibration amount of the entire electronic device in the Z-axis direction can be obtained.
[0096] Step S540: Obtain the vibration voltage signal to be output.
[0097] Step S550: Based on the natural frequency of the electronic device in the second-order mode, adjust the vibration voltage signal, and the frequency of at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency.
[0098] Step S560: Based on the adjusted vibration voltage signal, control the vibration motor to vibrate.
[0099] In the embodiments of this application, steps S540 to S560 can be referred to the content of the foregoing embodiments, and will not be repeated here.
[0100] The vibration control method provided in this application also includes a process for obtaining the natural frequency of the electronic device in the second-order mode. This involves controlling the vibration of a vibration motor using a sweep signal based on a target frequency band, and obtaining the vibration magnitude of the vibration motor's Z-axis at different frequencies of the sweep signal. The frequency corresponding to the maximum vibration magnitude is then determined as the natural frequency of the electronic device in the second-order mode. When controlling the vibration motor to vibrate, the vibration voltage signal can be adjusted based on this predetermined natural frequency. The frequency of at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency of the second-order mode. Then, based on the adjusted vibration voltage signal, the vibration motor is controlled to vibrate. Since the frequency of at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency, compared to controlling the vibration motor using only the waveform in the first-order mode in related technologies, this method can increase the vibration magnitude of the entire vibration system composed of the electronic device along the Z-axis, thereby enhancing the vibration effect of the electronic device. In particular, it can improve the vertical vibration sensation when the electronic device is placed horizontally on a plane.
[0101] Please see Figure 7 This diagram illustrates a structural block diagram of a vibration control device 600 according to an embodiment of this application. The vibration control device 600 utilizes the aforementioned electronic device, which includes a vibration motor. The vibration control device 600 includes: a signal acquisition module 610, a signal adjustment module 620, and a motor control module 630. Specifically, the signal acquisition module 610 acquires a vibration voltage signal to be output; the signal adjustment module 620 adjusts the vibration voltage signal based on the natural frequency of the electronic device in its second-order mode, such that at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency; and the motor control module 630 controls the vibration motor to vibrate based on the adjusted vibration voltage signal.
[0102] In some embodiments, the signal adjustment module 620 can also be used to adjust the target waveform in the waveform corresponding to the vibration voltage signal if the waveform corresponding to the vibration voltage signal includes a target waveform, so as to obtain the adjusted vibration voltage signal, wherein the difference between the frequency corresponding to the target waveform and the natural frequency is less than a first frequency threshold, and the frequency of the adjusted target waveform matches the natural frequency.
[0103] In one possible implementation, the signal adjustment module 620 can also be used to replace the first waveform in the waveform corresponding to the vibration voltage signal with the waveform of the natural frequency if the waveform corresponding to the vibration voltage signal does not include the target waveform, so as to obtain the adjusted vibration voltage signal. The first waveform includes at least one of the waveform gap in the waveform corresponding to the vibration voltage signal and the long vibration waveform with a duration longer than the target duration. The long vibration waveform is a vibration waveform with a vibration period greater than the target number.
[0104] In one possible implementation, the signal adjustment module 620 can also be used to resample and frequency adjust the target waveform in the waveform corresponding to the vibration voltage signal if the waveform corresponding to the vibration voltage signal includes a target waveform, so as to obtain the adjusted vibration voltage signal, wherein the frequency of the frequency-adjusted target waveform matches the natural frequency.
[0105] In some embodiments, the signal adjustment module 620 can also be used to adjust the vibration voltage signal based on the natural frequency of the electronic device in the second-order mode if the attitude parameters of the electronic device meet the target attitude parameter conditions.
[0106] In one possible implementation, the signal adjustment module 620 can also be used to adjust the vibration voltage signal based on the natural frequency of the electronic device in the second-order mode if the attitude parameters of the electronic device meet the target attitude parameter conditions and the electronic device is not in a gripping state.
[0107] In some embodiments, the motor control module 630 can also be used to control the vibration motor to vibrate based on the vibration voltage signal at the rated voltage if the waveform of the vibration voltage signal is a long vibration waveform.
[0108] In one possible implementation, the motor control module 630 can also be used to control the vibration motor to vibrate based on the vibration voltage signal under the short vibration voltage if the waveform of the vibration voltage signal is a short vibration waveform. The short vibration voltage is the voltage when the vibration motor reaches its maximum stroke in the Z-axis direction when the vibration motor is controlled to vibrate by the voltage signal of the short vibration waveform with the natural frequency. The short vibration waveform is a vibration waveform with a vibration period less than or equal to the target number.
[0109] In some embodiments, the vibration control device 600 may further include a frequency acquisition module. The frequency acquisition module is used to control the vibration of the vibration motor based on a sweep frequency signal of a target frequency band; acquire the vibration amount of the Z-axis of the vibration motor at different frequencies of the sweep frequency signal; and determine the frequency corresponding to the maximum vibration amount as the natural frequency of the electronic device in the second-order mode.
[0110] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working process of the above-described device and module can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.
[0111] In the several embodiments provided in this application, the coupling between modules can be electrical, mechanical, or other forms of coupling.
[0112] Furthermore, the functional modules in the various embodiments of this application can be integrated into one processing module, or each module can exist physically separately, or two or more modules can be integrated into one module. The integrated modules described above can be implemented in hardware or as software functional modules.
[0113] In summary, the solution provided in this application acquires the vibration voltage signal to be output, adjusts the vibration voltage signal based on the natural frequency of the electronic device in the second-order mode, and ensures that the frequency of at least a portion of the waveform corresponding to the adjusted vibration voltage signal matches the natural frequency of the second-order mode. Based on the adjusted vibration voltage signal, the vibration motor is controlled to vibrate. Therefore, it is possible to enhance the vibration amount along the Z-axis using the second-order mode shape, thereby enhancing the vibration effect of the electronic device.
[0114] Please refer to Figure 8 This document illustrates a structural block diagram of an electronic device according to an embodiment of this application. The electronic device 100 can be a smartphone, tablet computer, smartwatch, e-reader, or other electronic device capable of running applications. The electronic device 100 in this application may include one or more of the following components: a processor 110, a memory 120, and one or more applications, wherein the one or more applications can be stored in the memory 120 and configured to be executed by the one or more processors 110, and the one or more applications are configured to perform the methods described in the foregoing method embodiments.
[0115] Processor 110 may include one or more processing cores. Processor 110 connects to various parts within the electronic device 100 using various interfaces and lines, and performs various functions and processes data of the electronic device 100 by running or executing instructions, programs, code sets, or instruction sets stored in memory 120, and by calling data stored in memory 120. Optionally, processor 110 may be implemented using at least one hardware form of Digital Signal Processing (DSP), Field-Programmable Gate Array (FPGA), or Programmable Logic Array (PLA). Processor 110 may integrate one or a combination of several of the following: Central Processing Unit (CPU), Graphics Processing Unit (GPU), and modem. The CPU primarily handles the operating system, user interface, and applications; the GPU is responsible for rendering and drawing the displayed content; and the modem handles wireless communication. It is understood that the modem may also not be integrated into processor 110 and may be implemented separately using a communication chip.
[0116] The memory 120 may include random access memory (RAM) or read-only memory (ROM). The memory 120 can be used to store instructions, programs, code, code sets, or instruction sets. The memory 120 may include a program storage area and a data storage area. The program storage area may store instructions for implementing an operating system, instructions for implementing at least one function (such as touch functionality, sound playback functionality, image playback functionality, etc.), and instructions for implementing the various method embodiments described below. The data storage area may also store data created by the electronic device 100 during use (such as phonebook data, audio and video data, chat log data, etc.).
[0117] Please refer to Figure 9 This diagram illustrates a structural block diagram of a computer-readable storage medium provided in an embodiment of this application. The computer-readable medium 800 stores program code that can be called by a processor to execute the methods described in the above method embodiments.
[0118] The computer-readable storage medium 800 may be an electronic memory such as flash memory, EEPROM (Electrically Erasable Programmable Read-Only Memory), EPROM, hard disk, or ROM. Optionally, the computer-readable storage medium 800 includes a non-transitory computer-readable storage medium. The computer-readable storage medium 800 has storage space for program code 810 that performs any of the method steps described above. This program code can be read from or written to one or more computer program products. The program code 810 may be compressed, for example, in a suitable form.
[0119] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application.
Claims
1. A vibration control method, characterized in that, Applied to an electronic device, the electronic device including a vibration motor, the method includes: Obtain the vibration voltage signal to be output; If the waveform corresponding to the vibration voltage signal includes a target waveform, the target waveform in the waveform corresponding to the vibration voltage signal is adjusted to obtain the adjusted vibration voltage signal. The frequency of the adjusted target waveform matches the natural frequency of the vibration system of the electronic device as a whole in the second-order mode. The difference between the frequency corresponding to the target waveform and the natural frequency is less than a first frequency threshold. If the waveform corresponding to the vibration voltage signal does not include the target waveform, then the first waveform in the waveform corresponding to the vibration voltage signal is replaced with the waveform of the natural frequency to obtain the adjusted vibration voltage signal. The difference between the frequency corresponding to the target waveform and the natural frequency is less than a first frequency threshold. The first waveform includes at least one of the waveform gap in the waveform corresponding to the vibration voltage signal and a long vibration waveform with a duration longer than the target duration. The long vibration waveform is a vibration waveform with a vibration period greater than the target number. The vibration motor is controlled to vibrate based on the adjusted vibration voltage signal.
2. The method according to claim 1, characterized in that, If the waveform corresponding to the vibration voltage signal includes a target waveform, then the target waveform in the waveform corresponding to the vibration voltage signal is adjusted, including: If the waveform corresponding to the vibration voltage signal includes a target waveform, then the target waveform in the waveform corresponding to the vibration voltage signal is resampled and its frequency is adjusted to obtain the adjusted vibration voltage signal. The frequency of the target waveform after frequency adjustment matches the natural frequency.
3. The method according to claim 1, characterized in that, Adjusting the vibration voltage signal based on the natural frequency of the electronic device in the second-order mode includes: If the attitude parameters of the electronic device meet the target attitude parameter conditions, then the vibration voltage signal is adjusted based on the natural frequency of the electronic device in the second-order mode.
4. The method according to claim 1, characterized in that, The step of controlling the vibration motor to vibrate based on the adjusted vibration voltage signal includes: If the waveform of the vibration voltage signal is a long-wave waveform, then the vibration motor is controlled to vibrate based on the vibration voltage signal under the rated voltage. The long-wave waveform is a vibration waveform with a vibration period greater than the target number.
5. The method according to claim 1 or 4, characterized in that, The step of controlling the vibration motor to vibrate based on the adjusted vibration voltage signal includes: If the waveform of the vibration voltage signal is a short-wave waveform, then the vibration motor is controlled to vibrate based on the vibration voltage signal under the short-wave voltage. The short-wave voltage is the voltage when the vibration motor reaches its maximum stroke in the Z-axis direction when the vibration motor is controlled to vibrate by the voltage signal of the short-wave waveform with the natural frequency. The short-wave waveform is a vibration waveform with a vibration period less than or equal to the target number.
6. A vibration control device, characterized in that, Applied to electronic devices, the electronic devices include a vibration motor, and the device includes: a signal acquisition module, a signal adjustment module, and a motor control module, wherein... The signal acquisition module is used to acquire the vibration voltage signal to be output; The signal adjustment module is used to adjust the target waveform in the waveform corresponding to the vibration voltage signal if the waveform corresponding to the vibration voltage signal includes the target waveform, to obtain the adjusted vibration voltage signal. The frequency of the adjusted target waveform matches the natural frequency of the vibration system of the electronic device as a whole in the second-order mode, and the difference between the frequency corresponding to the target waveform and the natural frequency is less than a first frequency threshold. If the waveform corresponding to the vibration voltage signal does not include the target waveform, the first waveform in the waveform corresponding to the vibration voltage signal is replaced with the waveform of the natural frequency to obtain the adjusted vibration voltage signal. The difference between the frequency corresponding to the target waveform and the natural frequency is less than the first frequency threshold. The first waveform includes at least one of the waveform gaps in the waveform corresponding to the vibration voltage signal and a long vibration waveform with a duration longer than the target duration. The long vibration waveform is a vibration waveform with a vibration period greater than the target number. The motor control module is used to control the vibration motor to vibrate based on the adjusted vibration voltage signal.
7. An electronic device, characterized in that, include: One or more processors; Memory; One or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, the one or more programs being configured to perform the method as described in any one of claims 1-5.
8. A computer-readable storage medium, characterized in that, The computer-readable storage medium contains program code that can be invoked by a processor to execute the method as described in any one of claims 1-5.
Citation Information
Patent Citations
Method and device for adjusting vibration waveform of linear motor
CN115459643A