Vibration control method and electronic equipment
By adjusting vibration parameters based on usage status and battery information, the problem of inconsistent vibration feedback in foldable screen electronic devices under different states was solved, achieving consistent vibration feedback under different states, improving user experience and reducing hardware costs.
Patent Information
- Application Number
- CN202410698141.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-30
- Publication Date
- 2025-12-02
AI Technical Summary
The physical structure of foldable screen electronic devices differs between their folded and unfolded states, resulting in different vibration feedback and affecting the user experience.
By integrating the usage status and power information of electronic devices, vibration parameters are obtained, and vibration feedback is adaptively adjusted. This includes configuring gain flags and vibration waveforms, using Hall sensors and power information to match the corresponding vibration parameters, and adjusting motor vibration to provide consistent vibration feedback.
It provides consistent vibration feedback under different usage conditions and battery levels, improving the user experience, avoiding device noise issues, and reducing hardware costs.
Smart Images

Figure CN121055818A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of terminal technology, and in particular to a vibration control method and electronic device. Background Technology
[0002] Vibration functionality can be achieved by using motors in electronic devices (such as mobile phones) to provide tactile feedback when users perform touch operations on the device, thus confirming the operation; or, the electronic device can vibrate when it receives a call or notification to promptly alert the user.
[0003] With the development of terminal technology, more and more users are using foldable screen electronic devices. However, due to the difference in physical structure between the folded and unfolded states of foldable screen electronic devices, the vibration feedback provided to users differs in these two usage scenarios, affecting the user experience. Summary of the Invention
[0004] To address the aforementioned technical problems, this application provides a vibration control method and electronic device. The technical solution provided by this application obtains motor vibration parameters by comprehensively considering the usage status and power information of the electronic device, enabling adaptive adjustment of the vibration parameters and improving the user experience.
[0005] To achieve the above-mentioned technical objectives, this application provides the following technical solution:
[0006] Firstly, a vibration control method is provided for use in foldable screen electronic devices. The method includes: acquiring the usage status of the electronic device; acquiring the battery level information of the electronic device; acquiring vibration parameters based on the usage status and battery level information; and driving a motor to vibrate according to the vibration parameters.
[0007] In this way, electronic devices can obtain corresponding vibration parameters based on usage status and battery level. By adjusting these vibration parameters, adaptive vibration feedback can be achieved, thereby improving the user experience.
[0008] According to the first aspect, the vibration parameters include a gain flag. Driving the motor to vibrate according to the vibration parameters includes: acquiring the gain corresponding to the gain flag; acquiring a first vibration waveform; using an audio codec chip to correct the first vibration waveform based on the gain to acquire a second vibration waveform; and driving the motor to vibrate according to the second vibration waveform.
[0009] According to the first aspect, or any implementation of the first aspect above, obtaining the first vibration waveform includes: obtaining the first vibration waveform output by the motor service through the first path of the audio codec chip, wherein the first path corresponds to the gain, and the first vibration waveform is the default vibration waveform.
[0010] In some examples, the motor driving method of an electronic device may include audio data driving. Audio data driving involves the motor driving based on the underlying path selected by the audio service. A digital signal processor sends a vibration waveform to the audio codec chip, where different underlying paths correspond to different gains. The audio codec chip then sends the gain-corrected vibration waveform to the motor, instructing the motor to vibrate according to this corrected waveform.
[0011] Thus, in audio data-driven scenarios, electronic devices can obtain the required gain based on usage status and power information, thereby correcting the default waveform based on the gain and adjusting the vibration feedback.
[0012] According to the first aspect, or any implementation of the first aspect above, vibration parameters are obtained based on the usage status and power information, including: matching the corresponding gain flag bit based on the usage status and power information.
[0013] In some examples, electronic devices are configured with vibration parameters, such as gain flags, corresponding to different usage states and power information.
[0014] Thus, by pre-configuring vibration parameters corresponding to different usage states and power information in electronic devices, the efficiency of vibration parameter acquisition can be improved.
[0015] According to the first aspect, or any implementation of the first aspect above, the vibration parameters include a third vibration waveform. Driving the motor to vibrate according to the vibration parameters includes: acquiring the third vibration waveform output by the motor service chip; and driving the motor to vibrate according to the third vibration waveform via the motor chip.
[0016] In some examples, the motor driving method of an electronic device may include chip driving. Here, motor driving involves a motor service sending vibration waveforms of different amplitudes to a motor chip, which then instructs the motor to vibrate according to these different waveforms.
[0017] Thus, in chip-driven scenarios, electronic devices can obtain the required motor vibration waveform based on usage status and power information, and adjust the vibration feedback by adjusting the motor vibration waveform.
[0018] According to the first aspect, or any implementation of the first aspect above, vibration parameters are obtained based on usage status and power information, including: matching the corresponding third vibration waveform based on usage status and power information.
[0019] In some examples, electronic devices are configured with vibration parameters, such as vibration waveforms, corresponding to different usage states and power information.
[0020] Thus, by pre-configuring vibration parameters corresponding to different usage states and power information in electronic devices, the efficiency of vibration parameter acquisition can be improved.
[0021] According to the first aspect, or any implementation thereof, the electronic device is equipped with a Hall sensor to obtain the usage status of the electronic device, including: obtaining Hall parameters detected by the Hall sensor; and obtaining the usage status based on the Hall parameters.
[0022] In some examples, the Hall sensor reports Hall parameters triggered by an interrupt. This interrupt triggering could include a change in the usage state of the electronic device, prompting the Hall sensor to report Hall parameters. For instance, the Hall sensor reports Hall parameters when the usage state of the electronic device changes from an unfolded state to a folded state. Or, the Hall sensor reports Hall parameters when the usage state of the electronic device changes from a folded state to an unfolded state.
[0023] Optionally, the electronic device is equipped with one or more Hall sensors. Then, the electronic device can obtain its operating status based on one or more sets of Hall parameters.
[0024] In this way, electronic devices can obtain their current operating status by using the Hall parameters reported by the Hall sensor.
[0025] According to the first aspect, or any implementation of the first aspect above, vibration parameters are obtained based on the usage status and battery information, including: obtaining a first voltage indicated by the battery information. When the first voltage is less than or equal to a voltage threshold, the electronic device is in a low battery state. When the first voltage is greater than the voltage threshold, the electronic device is in a high battery state.
[0026] Optionally, by combining the usage status and power information of the electronic device, the electronic device can be in one of four states: high power unfolded state, low power unfolded state, high power folded state, and low power folded state.
[0027] In this way, by judging the voltage value, the electronic device can determine whether it is in a high-power state or a low-power state, and thus determine the direction of vibration parameter adjustment.
[0028] Alternatively, the electronic device can also determine its power status by measuring the current value.
[0029] According to the first aspect, or any of the above implementations of the first aspect, the usage state also includes intermediate states.
[0030] For example, during the process of an electronic device changing from an unfolded state to a folded state, the state that is not fully folded can be defined as an intermediate state.
[0031] Optionally, the electronic device may also be equipped with an accelerometer and a gyroscope. By using the detection data from the accelerometer and gyroscope, the electronic device can obtain its folding angle, thereby determining whether it is in an intermediate state.
[0032] Secondly, a vibration control method is provided, applied to a foldable screen electronic device. The method includes: the electronic device being in a first usage state; responding to a vibration event; acquiring a first vibration parameter based on the first usage state and first battery level information of the electronic device; driving a motor to vibrate according to the first vibration parameter; during vibration, responding to a user operation; the electronic device switching to a second usage state, wherein the second usage state is different from the first usage state; acquiring a second vibration parameter based on the second usage state and second battery level information of the electronic device; driving the motor to vibrate according to the second vibration parameter; wherein the vibration feedback corresponding to the first vibration parameter and the second vibration parameter is the same or has a first deviation.
[0033] In this way, the electronic device combines its usage status and battery information to make a comprehensive judgment to obtain vibration parameters suitable for the current usage scenario. This allows the electronic device to provide the same or similar vibration feedback to the user in different usage scenarios, thereby improving the user experience.
[0034] According to the second aspect, the vibration feedback includes vibration acceleration, and the vibration feedback corresponding to the first vibration parameter and the second vibration parameter is the same or has a first deviation, including: driving the motor to vibrate according to the first vibration parameter to generate a first vibration acceleration, driving the motor to vibrate according to the second vibration parameter to generate a second vibration acceleration, and the first vibration acceleration and the second vibration acceleration are the same or have a first deviation.
[0035] In some examples, vibration feedback is measured by the vibrational acceleration generated after the motor vibrates.
[0036] Optionally, vibration feedback can be measured by vibration acceleration (unit: g). For example, the vibration acceleration generated by the motor vibration when the electronic device is in a high-charge deployed state can be obtained and set as the target vibration acceleration. Then, vibration parameters corresponding to different states of the electronic device can be pre-configured, ensuring that the vibration acceleration generated by the motor vibration is the same as the target vibration acceleration in different states. Here, "same" does not mean absolutely identical; there can be deviations between the vibration accelerations generated by the motor vibration in different states of the electronic device, for example, this deviation can be ±30%. For example, when the target vibration acceleration is 1g, the vibration acceleration generated by the motor vibration in different states of the electronic device can be [0.7, 1.3]g. (For example...)
[0037] Optionally, the vibration feedback generated when the electronic device is in a high-charge unfolded state can be used as a reference. By adjusting the vibration parameters, the vibration feedback when the electronic device is in other states can be adjusted to be the same as or similar to the vibration feedback generated when the electronic device is in a high-charge unfolded state.
[0038] It should be understood that the vibration feedback corresponding to other states of the electronic device can also be used as a benchmark to obtain the vibration parameters corresponding to different usage states and power information of the electronic device.
[0039] Thus, by pre-configuring vibration parameters corresponding to different usage states and power information in electronic devices, the efficiency of vibration parameter acquisition can be improved.
[0040] Furthermore, since the motor is located on the motherboard of the electronic device, the vibration feedback provided in the deployed state is relatively weak. Therefore, using the vibration feedback in the high-charge deployed state as the vibration feedback benchmark for different states can ensure that the electronic device provides the same or similar vibration feedback to the user in different states, while also solving the problem of abnormal noise caused by excessive vibration.
[0041] According to the second aspect, or any implementation thereof, the first vibration parameter includes a gain flag. Driving the motor to vibrate according to the first vibration parameter includes: acquiring the gain corresponding to the gain flag; acquiring a first vibration waveform; obtaining a second vibration waveform by correcting the first vibration waveform based on the gain using an audio codec chip; and driving the motor to vibrate according to the second vibration waveform.
[0042] According to the second aspect, or any implementation of the second aspect above, obtaining the first vibration waveform includes: obtaining the first vibration waveform output by the motor service through the first path of the audio codec chip, wherein the first path corresponds to the gain, and the first vibration waveform is the default vibration waveform.
[0043] According to the second aspect, or any implementation of the second aspect above, the first vibration parameter is obtained based on the first usage state and the first power information, including: matching the corresponding gain flag bit based on the first usage state and the first power information.
[0044] According to the second aspect, or any implementation thereof, the first vibration parameter includes a third vibration waveform. Driving the motor to vibrate according to the first vibration parameter includes: acquiring the third vibration waveform output by the motor via a motor chip; and driving the motor to vibrate according to the third vibration waveform via the motor chip.
[0045] According to the second aspect, or any implementation of the second aspect above, the first vibration parameter is obtained based on the first usage state and the first power information, including: matching the corresponding third vibration waveform based on the first usage state and the first power information.
[0046] According to the second aspect, or any implementation thereof, the electronic device is equipped with a Hall sensor to obtain a first usage state of the electronic device, including: obtaining Hall parameters detected by the Hall sensor; and obtaining the first usage state based on the Hall parameters.
[0047] According to the second aspect, or any implementation thereof, the vibration parameters are obtained based on the first usage state and the first battery level information, including: obtaining a first voltage indicated by the first battery level information. When the first voltage is less than or equal to a voltage threshold, the electronic device is in a low battery state. When the first voltage is greater than the voltage threshold, the electronic device is in a high battery state.
[0048] According to the second aspect, or any implementation of the second aspect above, the first usage state also includes an intermediate state.
[0049] For the technical effects of the second aspect and any of its implementation methods, please refer to the technical effects of the first aspect and any of its implementation methods mentioned above, which will not be repeated here.
[0050] Thirdly, an electronic device is provided. This electronic device includes: a processor and a memory, the memory being coupled to the processor. The memory stores computer program code, which includes computer instructions. When the processor reads the computer instructions from the memory, the electronic device executes: acquiring the usage status of the electronic device; acquiring the battery level information of the electronic device; acquiring vibration parameters based on the usage status and battery level information; and driving a motor to vibrate according to the vibration parameters.
[0051] According to the third aspect, the electronic device is a foldable screen electronic device.
[0052] According to the third aspect, or any implementation thereof, the vibration parameters include a gain flag. Driving the motor to vibrate according to the vibration parameters includes: acquiring the gain corresponding to the gain flag; acquiring a first vibration waveform; obtaining a second vibration waveform by correcting the first vibration waveform based on the gain using an audio codec chip; and driving the motor to vibrate according to the second vibration waveform.
[0053] According to the third aspect, or any implementation of the third aspect above, the first vibration waveform is obtained, including: obtaining the first vibration waveform output by the motor service through the first path of the audio codec chip, wherein the first path corresponds to the gain, and the first vibration waveform is the default vibration waveform.
[0054] According to the third aspect, or any of the above implementations of the third aspect, vibration parameters are obtained based on usage status and power information, including: matching the corresponding gain flag bit based on usage status and power information.
[0055] According to the third aspect, or any implementation of the third aspect above, the vibration parameters include a third vibration waveform. Driving the motor to vibrate according to the vibration parameters includes: acquiring the third vibration waveform output by the motor through a motor chip; and driving the motor to vibrate according to the third vibration waveform through the motor chip.
[0056] According to the third aspect, or any of the above implementations of the third aspect, vibration parameters are obtained based on usage status and power information, including: matching the corresponding third vibration waveform based on usage status and power information.
[0057] According to the third aspect, or any implementation thereof, the electronic device is equipped with a Hall sensor to obtain the usage status of the electronic device, including: obtaining Hall parameters detected by the Hall sensor; and obtaining the usage status based on the Hall parameters.
[0058] According to the third aspect, or any implementation of the third aspect above, vibration parameters are obtained based on the usage status and battery information, including: obtaining a first voltage indicated by the battery information. When the first voltage is less than or equal to a voltage threshold, the electronic device is in a low battery state. When the first voltage is greater than the voltage threshold, the electronic device is in a high battery state.
[0059] According to the third aspect, or any of the above-mentioned third aspects, the usage state also includes intermediate states.
[0060] Fourthly, an electronic device is provided. The electronic device includes a processor and a memory, with the memory and a display screen coupled to the processor. The memory stores computer program code, including computer instructions. When the processor reads the computer instructions from the memory, the electronic device executes the following: the electronic device is in a first usage state; in response to a vibration event, it acquires a first vibration parameter based on the first usage state and first battery level information of the electronic device; and drives a motor to vibrate according to the first vibration parameter. During vibration, in response to a user operation, the electronic device switches to a second usage state, wherein the second usage state is different from the first usage state. It acquires a second vibration parameter based on the second usage state and second battery level information of the electronic device; and drives the motor to vibrate according to the second vibration parameter; wherein the vibration feedback corresponding to the first vibration parameter and the second vibration parameter is the same or has a first deviation.
[0061] According to the fourth aspect, the electronic device is a foldable screen electronic device.
[0062] According to the fourth aspect, or any implementation of the fourth aspect above, the vibration feedback includes vibration acceleration, and the vibration feedback corresponding to the first vibration parameter and the second vibration parameter is the same or has a first deviation, including: driving the motor to vibrate according to the first vibration parameter to generate a first vibration acceleration, driving the motor to vibrate according to the second vibration parameter to generate a second vibration acceleration, and the first vibration acceleration and the second vibration acceleration are the same or have a first deviation.
[0063] According to the fourth aspect, or any implementation of the fourth aspect above, the first vibration parameter includes a gain flag. Driving the motor to vibrate according to the first vibration parameter includes: acquiring the gain corresponding to the gain flag; acquiring the first vibration waveform; obtaining a second vibration waveform by correcting the first vibration waveform based on the gain using an audio codec chip; and driving the motor to vibrate according to the second vibration waveform.
[0064] According to the fourth aspect, or any implementation of the fourth aspect above, the first vibration waveform is obtained, including: obtaining the first vibration waveform output by the motor service through the first path of the audio codec chip, wherein the first path corresponds to the gain, and the first vibration waveform is the default vibration waveform.
[0065] According to the fourth aspect, or any implementation of the fourth aspect above, the first vibration parameter is obtained based on the first usage state and the first power information, including: matching the corresponding gain flag bit based on the first usage state and the first power information.
[0066] According to the fourth aspect, or any implementation of the fourth aspect above, the first vibration parameter includes a third vibration waveform. Driving the motor to vibrate according to the first vibration parameter includes: acquiring the third vibration waveform output by the motor through a motor chip; and driving the motor to vibrate according to the third vibration waveform through the motor chip.
[0067] According to the fourth aspect, or any implementation of the fourth aspect above, the first vibration parameter is obtained based on the first usage state and the first power information, including: matching the corresponding third vibration waveform based on the first usage state and the first power information.
[0068] According to the fourth aspect, or any implementation thereof, the electronic device is equipped with a Hall sensor to obtain a first usage state of the electronic device, including: obtaining Hall parameters detected by the Hall sensor; and obtaining the first usage state based on the Hall parameters.
[0069] According to the fourth aspect, or any implementation of the fourth aspect above, vibration parameters are obtained based on the first usage state and the first battery level information, including: obtaining a first voltage indicated by the first battery level information. When the first voltage is less than or equal to a voltage threshold, the electronic device is in a low battery state. When the first voltage is greater than the voltage threshold, the electronic device is in a high battery state.
[0070] According to the fourth aspect, or any of the above implementations of the fourth aspect, the first usage state also includes an intermediate state.
[0071] Fifthly, an electronic device is provided that has the function of implementing the vibration control method as described in the first aspect and any of its possible implementations; or, the electronic device has the function of implementing the vibration control method as described in the second aspect and any of its possible implementations. This function can be implemented in hardware or by hardware executing corresponding software. The hardware or software includes one or more modules corresponding to the above-described function.
[0072] Sixthly, a computer-readable storage medium is provided. The computer-readable storage medium stores a computer program (also referred to as instructions or code) that, when executed by an electronic device, causes the electronic device to perform the method of the first aspect or any embodiment thereof; or causes the electronic device to perform the method of the second aspect or any embodiment thereof.
[0073] In a seventh aspect, a computer program product is provided that, when the computer program product is run on an electronic device, causes the electronic device to perform the method of the first aspect or any one of the embodiments of the first aspect; or causes the electronic device to perform the method of the second aspect or any one of the embodiments of the second aspect.
[0074] Eighthly, a circuit system is provided, the circuit system including a processing circuit configured to perform the method of the first aspect or any embodiment of the first aspect; or, the processing circuit is configured to perform the method of the second aspect or any embodiment of the second aspect.
[0075] A ninth aspect provides a chip system including at least one processor and at least one interface circuit, wherein the at least one interface circuit is configured to perform transceiver functions and send instructions to the at least one processor, wherein when the at least one processor executes instructions, the at least one processor executes the method of the first aspect or any embodiment thereof; or, the at least one processor executes the method of the second aspect or any embodiment thereof.
[0076] The technical effects of the aforementioned aspects can be referenced from each other, and will not be elaborated further here. Attached Figure Description
[0077] Figure 1A A schematic diagram of an electronic device with an inwardly folding screen provided for an embodiment of this application;
[0078] Figure 1B A schematic diagram of another electronic device with an inwardly folding screen provided in an embodiment of this application;
[0079] Figure 1C This is a schematic diagram of a three-fold folding screen electronic device provided in an embodiment of this application;
[0080] Figure 2 A schematic diagram of the hardware structure of the electronic device provided in the embodiments of this application;
[0081] Figure 3 A schematic diagram of the software structure of an electronic device provided in an embodiment of this application;
[0082] Figure 4 A schematic flowchart of the vibration control method provided in this application embodiment is shown below;
[0083] Figure 5 This is a schematic diagram of an audio data-driven scenario provided in an embodiment of this application;
[0084] Figure 6 This is a schematic diagram of a motor drive scenario provided in an embodiment of this application;
[0085] Figure 7 This is a schematic diagram illustrating the usage state of a bi-foldable screen electronic device provided in an embodiment of this application;
[0086] Figure 8 This is a schematic diagram illustrating the usage state of a tri-fold screen electronic device provided in an embodiment of this application;
[0087] Figure 9 Schematic diagram of the vibration control method provided in the embodiments of this application Figure 2 ;
[0088] Figure 10 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation
[0089] The technical solutions of the embodiments of this application are described below with reference to the accompanying drawings. In the description of the embodiments of this application, the terminology used in the following embodiments is for the purpose of describing specific embodiments only and is not intended to be a limitation of this application. As used in the specification and appended claims of this application, the singular expressions “a,” “an,” “the,” “the,” “the,” and “this” are intended to include expressions such as “one or more,” unless the context clearly indicates otherwise. It should also be understood that in the following embodiments of this application, “at least one” and “one or more” refer to one or more (including two).
[0090] In the embodiments of this application, "and / or" is used to describe the association relationship between related objects, indicating that three relationships can exist. For example, "A and / or B" can represent three cases: only A exists, only B exists, and both A and B exist simultaneously, where A and B can be singular or plural. The character " / " generally indicates that the related objects before and after are in an "or" relationship. "At least one of the following" or similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one of a, b, or c can represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, and c can be single or multiple. It should be understood that in the embodiments of this application, "B corresponding to A" means that B is associated with A. For example, B can be determined based on A. It should also be understood that determining B based on A does not mean determining B solely based on A; B can also be determined based on A and / or other information.
[0091] References to "one embodiment" or "some embodiments" in this specification mean that one or more embodiments of this application include a specific feature, structure, or characteristic described in connection with that embodiment. Therefore, the phrases "in one embodiment," "in some embodiments," "in other embodiments," "in still other embodiments," etc., appearing in different parts of this specification do not necessarily refer to the same embodiment, but rather mean "one or more, but not all, embodiments," unless otherwise specifically emphasized. The terms "comprising," "including," "having," and variations thereof mean "including but not limited to," unless otherwise specifically emphasized. The term "connection" includes direct connections and indirect connections, unless otherwise stated. "First" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated.
[0092] In the embodiments of this application, the words "exemplarily" or "for example" are used to indicate examples, illustrations, or explanations. Any embodiment or design described as "exemplarily" or "for example" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or design solutions. Specifically, the use of the words "exemplarily" or "for example" is intended to present the relevant concepts in a specific manner.
[0093] In some embodiments, the foldable screen electronic device has two usage states: a folded state and an unfolded state. Due to the differences in physical structure between these two states, the relative positions of the motors differ, resulting in differences in the actual vibration waveform propagation. Consequently, the vibration feedback provided to the user differs between the two states, affecting the user experience. For example, in some models, the vibration in the folded state may be significantly greater than that in the unfolded state, greatly impacting the user's experience.
[0094] For example, such as Figure 1A The diagram shown is a product form illustration of an electronic device with an inwardly folding screen according to an embodiment of this application. Wherein, Figure 1A Image (a) is a schematic diagram of the fully unfolded inward-folding screen. At this point, the inward-folding screen is in its unfolded state. The inward-folding screen can be folded along the folding axis... Figure 1A The directions 101a and 101b shown in (a) are folded outwards (that is, folded towards the displayable user interface). Figure 1A Figure (b) shows a schematic diagram of the fully folded inward-folding screen. At this point, the screen is in a folded state. It can be seen that the relative positions of the motors located near the folding axis change depending on the physical structure of the electronic device in the unfolded and folded states. For example, in the unfolded state, the motors are located at the bottom center of the display screen; while in the folded state, the motors are located at the corners of the display screen. Therefore, the vibration feedback provided to the user by the same motors differs between the unfolded and folded states.
[0095] For example, such as Figure 1B The diagram shown is a product form illustration of another electronic device with an inwardly folding screen provided in an embodiment of this application. Wherein, Figure 1B Image (a) is a schematic diagram of the fully unfolded inward-folding screen. At this point, the inward-folding screen is in its unfolded state. The inward-folding screen can be folded along the folding axis... Figure 1B As shown in (a), directions 102a and 102b are folded inwards (that is, folded towards the displayable user interface). Figure 1BFigure (b) shows a schematic diagram of the inward-folding screen when fully folded, in which case the screen is in a folded state. It can be seen that the motors located near the bottom corners of the display change their relative positions due to the change in physical structure between the unfolded and folded states, resulting in different vibration feedback from the same motors to the user.
[0096] For example, such as Figure 1C The image shown is a schematic diagram of a tri-fold folding screen electronic device provided in an embodiment of this application. Wherein, Figure 1C Image (a) is a schematic diagram of the fully unfolded tri-fold screen electronic device. In this unfolded state, the tri-fold screen electronic device is equipped with two folding axes, allowing it to fold along these axes. Figure 1C As shown in (a), direction 103a folds outward and direction 103b folds inward. For example... Figure 1C Figure (b) shows a schematic diagram of the tri-fold foldable screen electronic device when fully folded. At this time, the tri-fold foldable screen electronic device is in the folded state. It can be seen that the motors located near the middle display area change their relative positions due to the change in physical structure when the electronic device is in the unfolded and folded states. This results in different vibration feedback from the same motors to the user.
[0097] In some embodiments, electronic devices address the issue of varying vibration feedback due to changes in usage status by configuring a larger number of motors. For example, ... Figure 1A The bi-folding electronic device shown in Figure (a) includes a display area A and a display area B. When the screen is folded, display areas A and B can be displayed independently. Motor 1 can be configured on display area A, and motor 2 can be configured on display area B. Thus, the vibration waveforms of the two motors can be adjusted according to the usage state of the electronic device, providing the user with the same vibration feedback in both the unfolded and folded states. For example, when the electronic device is in the folded state, motor 1 or motor 2 is controlled to vibrate with amplitude 1; when the electronic device is in the unfolded state, both motors are controlled to vibrate with amplitude 2, where amplitude 2 is smaller than amplitude 1.
[0098] While the above solution addresses the issue of inconsistent vibration feedback under different usage conditions by configuring a corresponding number of motors based on the number of folded display areas, a larger number of motors increases the hardware cost of the electronic device. Furthermore, if only one motor is configured in the electronic device, the above solution still cannot resolve the issue of inconsistent vibration feedback under different usage conditions. Additionally, the vibration feedback of some types of motors varies with the battery level of the electronic device, and the above solution does not consider the impact of battery level on vibration feedback. For example, when the battery level is low, the vibration feedback provided by the electronic device's motor is weak, while when the battery level is high, the vibration feedback provided by the electronic device's motor is strong.
[0099] In some embodiments, the electronic device acquires the folding parameters of the foldable screen and adjusts the vibration parameters of the motor accordingly. This ensures that the vibrational energy emitted by the motor is not completely absorbed by the foldable screen when the folding parameters differ. The folding parameters may include, for example, the number of folds.
[0100] In the above solution, although the vibration feedback of the electronic device can be adaptively adjusted under different usage conditions by adjusting the vibration parameters, the calculation process for calculating the vibration parameters based on the number of folds is complex. Furthermore, this solution does not consider the impact of battery power on the vibration feedback.
[0101] In response, this application provides a vibration control method that adaptively adjusts the motor vibration waveform by comprehensively considering the usage status and power information of the electronic device, thereby providing the same vibration feedback to the user in different usage scenarios and improving the user experience.
[0102] Optionally, the vibration control method provided in this application embodiment can be applied to electronic device 100. Optionally, electronic device 100 can be, for example, a mobile phone, tablet computer, ultra-mobile personal computer (UMPC), netbook, personal digital assistant (PDA), wearable device, artificial intelligence (AI) device, or other terminal device. The operating system installed on electronic device 100 includes, but is not limited to, […]. Alternatively, other operating systems may be used. This application does not limit the specific type of electronic device 100 or the operating system installed on it.
[0103] Optionally, the electronic device 100 is equipped with a foldable screen, and the electronic device 100 has two states of use: folded and unfolded.
[0104] For example, Figure 2 A schematic diagram of an electronic device 100 is shown.
[0105] Electronic device 100 may include processor 110, external memory interface 120, internal memory 121, universal serial bus (USB) interface 130, charging management module 140, power management module 141, battery 142, antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, audio module 170, sensor module 180, button 190, motor 191, indicator 192, camera 193, display screen 194, subscriber identification module (SIM) card interface 195, audio codec chip 196, and digital signal processor 197, etc.
[0106] It is understood that the structures illustrated in the embodiments of this application do not constitute a specific limitation on the electronic device 100. In other embodiments of this application, the electronic device 100 may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
[0107] Processor 110 may include one or more processing units, such as application processors (APs), modem processors, graphics processing units (GPUs), image signal processors (ISPs), controllers, video codecs, digital signal processors (DSPs), baseband processors, and / or neural network processing units (NPUs). These different processing units may be independent devices or integrated into one or more processors.
[0108] The controller can generate operation control signals based on the instruction opcode and timing signals to complete the control of instruction fetching and execution.
[0109] The processor 110 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. This memory can store instructions or data that the processor 110 has just used or that are used repeatedly. If the processor 110 needs to use the instruction or data again, it can retrieve it directly from the memory. This avoids repeated accesses, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.
[0110] In some embodiments, the processor 110 may include one or more interfaces. Interfaces may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.
[0111] The charging management module 140 receives charging input from a charger. The charger can be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 receives charging input from the wired charger via the USB interface 130. In some wireless charging embodiments, the charging management module 140 receives wireless charging input via the wireless charging coil of the electronic device 100. While charging the battery 142, the charging management module 140 can also supply power to the electronic device via the power management module 141.
[0112] The power management module 141 connects the battery 142, the charging management module 140, and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140, providing power to the processor 110, internal memory 121, display screen 194, camera 193, and wireless communication module 160, etc. The power management module 141 can also monitor parameters such as battery capacity, battery cycle count, and battery health status (leakage current, impedance). In some other embodiments, the power management module 141 may also be located within the processor 110. In other embodiments, the power management module 141 and the charging management module 140 may be located in the same device.
[0113] In some embodiments, the electronic device 100 can obtain the battery power information of the battery 142 through the power management module 141. For example, the electronic device 100 can obtain the voltage of the battery 142 through the power management module 141. When the voltage is greater than a voltage threshold, the battery 142 in the electronic device 100 has sufficient power; when the voltage is less than the voltage threshold, the battery 142 in the electronic device 100 is in a low-power state. As another example, the electronic device 100 can directly obtain the battery power of the battery 142 through the power management module 141. When the power level is greater than a power threshold, the battery 142 in the electronic device 100 has sufficient power; when the power level is less than the power threshold, the battery 142 in the electronic device 100 is in a low-power state.
[0114] In some embodiments, the electronic device 100 adaptively adjusts the vibration parameters of the motor based on the battery power status of the battery 142.
[0115] Internal memory 121 can be used to store computer executable program code, which includes instructions. Internal memory 121 may include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function (such as sound playback, image playback, etc.), etc. The data storage area may store data created during the use of electronic device 100 (such as audio data, phonebook, etc.). Furthermore, internal memory 121 may include high-speed random access memory, and may also include non-volatile memory, such as at least one disk storage device, flash memory device, universal flash storage (UFS), etc. Processor 110 executes various functional applications and data processing of electronic device 100 by running instructions stored in internal memory 121 and / or instructions stored in memory located in the processor.
[0116] The audio module 170 is used to convert digital audio information into analog audio signals for output, and also to convert analog audio input into digital audio signals. The audio module 170 can also be used for encoding and decoding audio signals. In some embodiments, the audio module 170 may be located in the processor 110, or some functional modules of the audio module 170 may be located in the processor 110. The electronic device 100 can use the audio module 170 for functions such as music playback and recording. The audio module 170 may include a speaker, receiver, microphone, headphone jack, and application processor to implement audio functions.
[0117] The sensor module 180 may include pressure sensors, gyroscope sensors, barometric pressure sensors, magnetic sensors, accelerometers, distance sensors, proximity sensors, fingerprint sensors, temperature sensors, touch sensors, ambient light sensors, bone conduction sensors, etc.
[0118] The magnetic sensor includes a Hall sensor. The electronic device 100 can utilize the Hall sensor to detect its operating state. In some embodiments, the electronic device 100 receives Hall parameters reported by the Hall sensor and can determine whether the electronic device 100 is currently in an unfolded or folded state based on these Hall parameters. Optionally, the Hall parameters may include, for example, a Hall coefficient.
[0119] Motor 191 can generate vibration alerts. Motor 191 can be used for incoming call vibration alerts or for touch vibration feedback. For example, different vibration feedback effects can correspond to touch operations performed on different applications (such as taking photos, playing audio, etc.). Motor 191 can also correspond to different vibration feedback effects for touch operations performed on different areas of the display screen 194. Different application scenarios (such as time reminders, receiving messages, alarm clocks, games, etc.) can also correspond to different vibration feedback effects. The touch vibration feedback effect can also be customized.
[0120] The software system of electronic device 100 can adopt a layered architecture, event-driven architecture, microkernel architecture, microservice architecture, or cloud architecture. This application embodiment uses the layered architecture Android system as an example to exemplify the software structure of electronic device 100.
[0121] Figure 3 This is a software structure block diagram of an electronic device 100 according to an embodiment of this application.
[0122] A layered architecture divides software into several layers, each with a clear role and function. Layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into four layers, from top to bottom: the application layer, the application framework layer, the hardware abstraction layer (HAL) layer, and the kernel layer.
[0123] The application layer can include a series of application packages.
[0124] like Figure 3 As shown, the application package can include applications such as telephone and audio.
[0125] The application framework layer provides application programming interfaces (APIs) and a programming framework for applications in the application layer. The application framework layer includes some predefined functions.
[0126] like Figure 3 As shown, the application framework layer may include motor services, audio services, etc.
[0127] The motor service is used to determine the motor vibration waveform and send the motor vibration waveform to the motor via the motor drive to drive the motor to vibrate according to the motor vibration waveform.
[0128] The audio service is used to acquire, process, and transmit audio data, as well as refresh the underlying paths for the corresponding scenario. Optionally, different underlying paths correspond to different volume levels or motor vibration gains. In some examples, the audio service is also used to acquire vibration events sent by the motor service, Hall parameters reported by the Hall sensor, power information reported by the power supply driver, and other messages. Based on the acquired messages, the audio service can trigger an underlying path refresh.
[0129] The HAL layer is a wrapper around Linux kernel drivers, providing interfaces to higher-level systems and shielding them from the implementation details of the underlying hardware.
[0130] The kernel layer is the layer between hardware and software. Examples of kernel layer components include motor drivers, audio drivers, and power drivers.
[0131] The following example, using a phone call vibration scenario, illustrates the workflow of the software and hardware of electronic device 100.
[0132] like Figure 3 As shown, when the phone application in the application layer receives an incoming call notification, it determines that the notification method includes vibration. The phone application sends a vibration instruction to the motor service to trigger the vibration process of the electronic device 100. In response to this instruction, the motor service determines that it needs to forward the acquired Hall parameters to the audio service. The motor driver can acquire the Hall parameters uploaded by the Hall sensor. The motor service can then instruct the motor driver to forward the acquired Hall parameters to the audio driver, so that the audio driver reports the Hall parameters to the audio service. Subsequently, the audio service, based on the Hall parameters, can obtain the current usage state of the electronic device, such as whether the electronic device is in an unfolded state or a folded state. Furthermore, the power driver can obtain the battery level information of the electronic device and report this information to the audio service. The audio service can then combine the usage state and battery level information of the electronic device to obtain the required gain. The audio service then sends this gain to the audio codec chip via the audio driver. Finally, in response to the instruction sent by the phone application, the motor service sends a vibration waveform to the digital signal processor via the motor driver, which then forwards it to the audio codec chip. Then, the audio codec chip corrects the vibration waveform by adjusting the gain and sends the corrected vibration waveform to the motor, driving the motor to vibrate according to the vibration waveform.
[0133] Among them, the electronic device adaptively corrects the vibration waveform by combining the usage status and power information. The amplitude of the corrected vibration waveform meets the needs of the current usage scenario, so that the electronic device can provide the same vibration feedback to the user in different usage scenarios.
[0134] The following section provides a detailed description of the specific implementation process of adaptively adjusting the vibration waveform.
[0135] Figure 4 This is a schematic flowchart illustrating a vibration control method provided in an embodiment of this application. It should be noted that this method is not based on... Figure 4 The specific order described below is a limitation. It should be understood that in other embodiments, the order of some steps in the method can be interchanged according to actual needs, or some steps can be omitted or deleted. The method includes the following steps:
[0136] S401. Electronic device obtains the usage status of electronic device.
[0137] The usage state of an electronic device can include an unfolded state and a folded state.
[0138] Optionally, the usage state of the electronic device may also include intermediate states. For example, an intermediate state may include a state where the electronic device is not fully folded. For instance, such as... Figure 1A The illustrated bi-folding screen electronic device folds inward in response to user input. When the folding angle reaches 90 degrees, the user stops the folding operation, and the electronic device is currently in an intermediate state. For example, the electronic device is as follows... Figure 1C The illustrated tri-fold screen electronic device, in response to a user operation, folds display area A outward along folding axis 1 in direction 103a, so that display areas A and B face away from each other, while display area C remains folded. The current usage state of the electronic device is, for example, an intermediate state.
[0139] In some embodiments, an electronic device can obtain its usage status through sensor detection data. For example, the electronic device can obtain its usage status through Hall parameters uploaded by a Hall sensor. Optionally, the electronic device can also combine detection data from multiple sensors such as a distance sensor and a light sensor to obtain its usage status.
[0140] In some embodiments, the Hall sensor can report Hall parameters triggered by an interrupt. Interrupt triggering includes, for example, a change in the usage state of the electronic device prompting the Hall sensor to report Hall parameters. For instance, the Hall sensor reports Hall parameters after the electronic device changes from an unfolded state to a folded state. Or, the Hall sensor reports Hall parameters when the electronic device changes from a folded state to an unfolded state. To avoid the electronic device being unable to obtain its current usage state due to the Hall sensor not reporting Hall parameters if the usage state of the electronic device has not changed, optionally, the electronic device can obtain the initial Hall parameters of the Hall sensor during the power-on initialization process. For example, the electronic device can obtain these initial Hall parameters by reading a device file, thereby determining the usage state of the electronic device at the time of initialization. Then, if the electronic device does not detect the latest reported Hall parameters when it subsequently needs to obtain its usage state, it can be determined that the current usage state of the electronic device is the usage state at the time of power-on initialization, and the usage state at the time of power-on initialization can be determined based on these initial Hall parameters.
[0141] In some embodiments, the electronic device is equipped with a vibration unit for triggering vibration of the electronic device. For example, the vibration unit is a motor. Optionally, the electronic device is equipped with at least one motor.
[0142] In some embodiments, the motor driving method of an electronic device may include chip driving and audio data driving. Motor driving involves a motor service sending vibration waveforms of different amplitudes to a motor chip, which instructs the motor to vibrate according to these waveforms. Audio data driving involves the motor drive sending vibration waveforms to an audio codec chip via a digital signal processor (DSP) based on the underlying path selected by the audio service. Different underlying paths correspond to different gains, and the DSP sends the gain-corrected vibration waveforms to the motor, instructing it to vibrate according to these corrected waveforms. The underlying path selection process includes the audio service sending path information to the audio codec chip via the audio drive, which indicates the underlying path. The audio service also sends interface information to the DSP via the audio drive, including an interface identifier for transmitting audio data and an interface identifier for transmitting motor data. The interface identifier indicates the interface for subsequent transmission of audio or motor data. Optionally, this interface information corresponds to the underlying path indicated by the aforementioned path information. Thus, during subsequent motor data transmission, after the motor drive sends motor data to the corresponding interface of the DSP, the DSP can then transmit the motor data to the underlying path corresponding to the audio codec chip.
[0143] In some embodiments, the module for determining the usage state of the electronic device differs depending on the motor driving method. For example, in an audio data-driven motor driving method, the audio service can determine the usage state of the electronic device and perform multi-information fusion. Similarly, in a chip-driven motor driving method, a motor service can determine the usage state of the electronic device and perform multi-information fusion.
[0144] Optionally, the multi-information fusion indicator obtains vibration parameters based on the usage status and power information of the electronic device. The specific process of multi-information fusion is detailed in step S403 below.
[0145] For example, such as Figure 5 In the audio data-driven scenario shown, the application detects a vibration event and sends the vibration event to the motor service. For example, a phone application responds to an incoming call notification and determines that vibration needs to be triggered based on the incoming call event, thus confirming that a vibration event has been detected. After receiving the vibration event, the motor service instructs the motor driver to report the Hall parameters. In the audio data-driven scenario, the audio service performs multi-information fusion to determine the gain. Therefore, the motor service instructs the motor driver to forward the acquired Hall parameters to the audio service and sends an indication message to the audio service, indicating that the audio service has detected the vibration event and needs to perform multi-information fusion (e.g., step ①). Optionally, after acquiring the Hall parameters, the Hall sensor uploads the Hall parameters to the motor driver (e.g., step ②). Then, the motor driver forwards the Hall parameters to the audio service via the audio driver (e.g., steps ③ and ④).
[0146] For example, such as Figure 6 In the chip-driven scenario shown, the motor service performs multi-information fusion to obtain vibration parameters. In response to a vibration event, the motor service instructs the motor driver to report Hall parameters. Optionally, after acquiring the Hall parameters, the Hall sensor uploads them to the motor driver (e.g., step ①). Then, the motor driver reports the Hall parameters to the motor service (e.g., step ②).
[0147] Optionally, the vibration events in different vibration scenarios are different. For example, in addition to the aforementioned incoming call event, vibration events may also include alarm clock events, message notification events, etc. This application embodiment does not limit the specific vibration scenario.
[0148] S402. Electronic devices acquire battery power information.
[0149] In some embodiments, when the electronic device has sufficient power, it can drive a motor to vibrate with a large amplitude waveform, providing a strong vibration sensation to the user. However, when the electronic device has insufficient power, it needs to reduce the amplitude of the vibration waveform to conserve power, thus reducing the vibration sensation felt by the user. Therefore, the electronic device needs to obtain its power level information, and subsequently, based on this information, obtain vibration parameters to ensure consistent vibration feedback to the user regardless of power levels.
[0150] For example, such as Figure 5 In the audio data-driven scenario shown, the audio service, in response to an indication message sent by the motor service to indicate a vibration event, can request power information from the power driver. Accordingly, after obtaining the power information, the power driver reports the power information to the audio service (e.g., step ⑤).
[0151] For example, such as Figure 6 As shown in step ③, in response to a vibration event, the motor service obtains the power information reported by the power driver.
[0152] It should be understood that Figure 5 or Figure 6 The dashed arrows indicate the direction in which the underlying hardware passes messages to the upper-layer services. The messages passed are, for example, the Hall parameters and power information mentioned above.
[0153] In some embodiments, the power information includes at least one of the battery's voltage, power level, and current.
[0154] In some embodiments, the execution order of steps S401 and S402 is not limited. For example, the electronic device may first obtain the usage status of the electronic device, and then obtain the battery information of the electronic device, that is, execute step S401 first, and then execute step S402. Alternatively, the electronic device may first obtain the battery information of the electronic device, and then obtain the usage status of the electronic device, that is, execute step S402 first, and then execute step S401. Alternatively, the electronic device may simultaneously obtain the usage status and battery information of the electronic device, that is, execute steps S401 and S402 simultaneously.
[0155] S403. The electronic device obtains vibration parameters based on its usage status and power information.
[0156] In some embodiments, the electronic device is pre-configured with vibration parameters corresponding to different usage states and battery levels. Therefore, after obtaining the usage state and battery level information through steps S401 and S402, the electronic device can match the corresponding vibration parameters based on the usage state and battery level information.
[0157] Optionally, taking the usage state as including unfolded state and folded state, and the power state of the electronic device as including high power and low power, by combining the usage state and power information of the electronic device, the state of the electronic device can include high power unfolded state, low power unfolded state, high power folded state, and low power folded state.
[0158] Optionally, the vibration feedback generated when the electronic device is in a high-charge unfolded state can be used as a reference. By adjusting the vibration parameters, the vibration feedback when the electronic device is in other states can be adjusted to be the same as or similar to the vibration feedback generated when the electronic device is in a high-charge unfolded state.
[0159] Optionally, vibration feedback can be measured by vibration acceleration (unit: g). For example, the vibration acceleration generated by the motor vibration when the electronic device is in a high-charge deployed state can be obtained and set as the target vibration acceleration. Then, vibration parameters corresponding to different states of the electronic device can be pre-configured, ensuring that the vibration acceleration generated by the motor vibration is the same as the target vibration acceleration in different states. It should be noted that "same" does not mean absolutely identical; there can be deviations between the vibration accelerations generated by the motor vibration in different states of the electronic device, for example, this deviation can be ±30%. For instance, when the target vibration acceleration is 1g, the vibration acceleration generated by the motor vibration in different states of the electronic device can be [0.7, 1.3]g.
[0160] It should be understood that the vibration feedback corresponding to other states of the electronic device can also be used as a benchmark to obtain vibration parameters corresponding to different usage states and power information of the electronic device. Furthermore, the aforementioned target vibration acceleration and deviation are merely illustrative examples.
[0161] Thus, by pre-configuring vibration parameters corresponding to different usage states and power information in electronic devices, the efficiency of vibration parameter acquisition can be improved.
[0162] Furthermore, since the motor is located on the motherboard of the electronic device, the vibration feedback provided in the deployed state is relatively weak. Therefore, using the vibration feedback in the high-charge deployed state as the vibration feedback benchmark for different states can ensure that the electronic device provides the same or similar vibration feedback to the user in different states, while solving the problem of abnormal noise caused by excessive vibration.
[0163] In some embodiments, in an audio data-driven scenario, vibration parameters may include a vibration waveform and a gain. Optionally, the gain includes analog gain and digital gain, wherein analog gain amplifies the analog signal; and digital gain amplifies the signal after analog-to-digital conversion. Optionally, the gain is used to adjust the frequency and amplitude of data points in the vibration waveform. Optionally, the electronic device acquires the vibration waveform through a motor drive and acquires the gain through an audio drive. Optionally, after acquiring the vibration parameters, the audio codec chip corrects the vibration waveform using the gain, thereby achieving adaptive adjustment of the vibration waveform based on usage status and power information, realizing adaptive adjustment of vibration feedback.
[0164] In some examples, in audio data-driven scenarios, the motor service determines the default vibration waveform.
[0165] In some examples, in audio data-driven scenarios, the audio service can obtain the corresponding gain based on the electronic device's usage status and / or battery information. For instance, when the device is in a folded state, a smaller amplitude is needed to provide a greater vibration feedback to the user. Therefore, when the electronic device is in a folded state, the audio service can match a smaller gain. Similarly, when the device is in an unfolded state, a larger amplitude is needed to provide a normal vibration feedback to the user. Therefore, when the electronic device is in an unfolded state, the audio service can match a larger gain. Furthermore, battery information can include voltage; when the battery is low, the amplitude of the vibration waveform will be smaller. Therefore, if the current voltage of the electronic device is less than or equal to a voltage threshold, it indicates that the electronic device is in a low-battery state, and the amplitude of the vibration waveform needs to be increased. Therefore, the audio service can match a larger gain. Moreover, generally, when the battery is high, the amplitude of the vibration waveform will be larger. Therefore, after obtaining the voltage from the battery information, if the current voltage of the electronic device is greater than a voltage threshold, it indicates that the electronic device is in a high-battery state, and the amplitude of the vibration waveform needs to be decreased. Therefore, the audio service can match a smaller gain. Combining these four examples, the audio service can match an appropriate gain. For example, battery information can include current. When the battery is low, the amplitude of the vibration waveform will be smaller. Therefore, if the current of the electronic device is less than or equal to the current threshold, it indicates that the electronic device is in a low battery state, and the amplitude of the vibration waveform needs to be increased. Thus, the audio service can match a larger gain. As another example, generally, when the battery is high, the amplitude of the vibration waveform will be larger. Therefore, after obtaining the current from the battery information, if the current of the electronic device is greater than the current threshold, it indicates that the electronic device is in a high battery state, and the amplitude of the vibration waveform needs to be decreased. Thus, the audio service can match a smaller gain. Electronic devices can also directly obtain battery power. When the battery power is less than or equal to the power threshold, it indicates that the electronic device is in a low battery state, and the amplitude of the vibration waveform needs to be increased. Therefore, the audio service can match a larger gain. Again, generally, when the battery power is high, the amplitude of the vibration waveform will be larger. Therefore, when the battery power is greater than the power threshold, it indicates that the electronic device is in a high battery state, and the amplitude of the vibration waveform needs to be decreased. Thus, the audio service can match a smaller gain.
[0166] Optionally, the power threshold can be 10%, the voltage threshold can be, for example, the voltage value corresponding to 10% battery power, and the current threshold can be, for example, the current value corresponding to 10% battery power.
[0167] Optionally, the electronic device is pre-configured with gain flags corresponding to different conditions, and the electronic device can automatically match the appropriate gain flag according to the actual situation. For example: Condition A, high battery unfolded state corresponds to gain flag 1; Condition B, low battery unfolded state corresponds to gain flag 2; Condition C, high battery folded state corresponds to gain flag 3; Condition D, low battery folded state corresponds to gain flag 4.
[0168] The gain flag is different for different situations. In this way, different vibration parameters (such as the gain flag) can be obtained when the electronic device is in different usage states and with different power information. These vibration parameters are used to drive the motor vibration and can provide the user with the same or similar vibration feedback.
[0169] For example, such as Figure 5 In the audio data-driven scenario shown, the audio service obtains the Hall parameters reported by the audio driver in step ④ to determine the usage status of the electronic device. Furthermore, the audio service obtains the power information reported by the power driver in step ⑤ to determine the power status of the electronic device. Therefore, the audio service can match the corresponding gain flag bit by combining the usage status and power status of the electronic device.
[0170] It should be understood that different gains corresponding to different conditions can also be directly configured in electronic devices. During operation, the electronic device can directly match the corresponding gain based on the actual situation. For example: Condition A, high battery unfolded state corresponds to gain 1; Condition B, low battery unfolded state corresponds to gain 2; Condition C, high battery folded state corresponds to gain 3; Condition D, low battery folded state corresponds to gain 4. In an example scenario, when the electronic device is in Condition A, high battery unfolded state, it can directly match gain 1 without first matching the corresponding gain flag, thus improving gain acquisition efficiency.
[0171] In some embodiments, vibration parameters may include vibration waveforms. The electronic device acquires the vibration waveforms via a motor service.
[0172] In some examples, the motor service can combine the electronic device's usage status and battery level information to match the corresponding vibration waveform. For instance, when the device is in a folded state, a smaller amplitude is needed to provide a greater vibration feedback to the user. Therefore, the motor service can match a smaller amplitude vibration waveform based on the folded state. Similarly, when the device is in an unfolded state, a larger amplitude is needed to provide normal vibration feedback. Therefore, the motor service can match a larger amplitude vibration waveform based on the unfolded state. Furthermore, when the battery level is low, the default triggered vibration waveform has a smaller amplitude. Therefore, after obtaining the voltage from the battery level information, the motor service can determine that the electronic device is in a low-battery state and requires a larger amplitude vibration waveform if the current voltage is less than or equal to a voltage threshold. Likewise, when the battery level is high, the default triggered vibration waveform has a larger amplitude. Therefore, after obtaining the voltage from the battery level information, the motor service can determine that the electronic device is in a high-battery state and requires a smaller amplitude vibration waveform if the current voltage is greater than a voltage threshold. Therefore, by combining the four scenarios described above, the motor service can match a suitable vibration waveform.
[0173] Optionally, the electronic device is pre-configured with vibration waveforms corresponding to different conditions. These vibration waveforms have different amplitudes, and the electronic device can automatically match the appropriate vibration waveform according to the actual situation. For example: Condition A, high charge unfolded state corresponds to vibration waveform 1; Condition B, low charge unfolded state corresponds to vibration waveform 2; Condition C, high charge folded state corresponds to vibration waveform 3; Condition D, low charge folded state corresponds to vibration waveform 4.
[0174] The vibration waveforms differ depending on the situation. Thus, depending on the electronic device's usage state and battery level, different vibration parameters (e.g., vibration waveforms) can be obtained. These vibration parameters are used to drive the motor vibration, providing the user with the same or similar vibration feedback.
[0175] It should be noted that the usage state of an electronic device can also include intermediate states. Combining the usage state and power information of the electronic device, the state of the electronic device can also include high power intermediate state, low power intermediate state, etc. In this case, the vibration parameters or vibration waveforms corresponding to the state of the electronic device are matched. For the description of the vibration parameters or vibration waveforms corresponding to other states of the electronic device in the embodiments of this application, it will not be repeated here.
[0176] For example, such as Figure 6In the chip-driven scenario shown, the motor service obtains the Hall parameters reported by the motor driver in step ② to determine the usage status of the electronic device. Furthermore, the motor service obtains the power information reported by the power driver in step ③ to determine the power status of the electronic device. Therefore, by combining the usage status and power status of the electronic device, the motor service can match the corresponding vibration waveform.
[0177] In some embodiments, the electronic device sets the truth values of different bits through bit operations to represent the various cases described above. Thus, based on the bit values, the electronic device can map the final gain flag bit or vibration waveform sequence number.
[0178] In some examples, electronic devices use bitwise operations to set the truth value of the 0th bit to indicate the device's battery status. For example, 0 indicates a high battery status, and 1 indicates a low battery status. It should be understood that 1 can also represent a high battery status, and 0 can represent a low battery status.
[0179] In some examples, electronic devices use bitwise operations to set the truth value of the first bit to indicate the device's usage state. For example, 0 indicates the device is in an unfolded state, and 1 indicates it is in a folded state. It should be understood that 1 can also represent the unfolded state, and 0 can represent the folded state.
[0180] For example, such as Figure 7 The dual-folding screen electronic device shown in (a) obtains its usage status and battery information through steps S401 and S402. Then, based on the usage status and battery information, the electronic device determines that it is currently in state A (high battery unfolded state) and sets the corresponding bit value to 00.
[0181] For example, such as Figure 7 The dual-folding screen electronic device shown in (b) obtains its usage status and battery information through steps S401 and S402. Then, based on the usage status and battery information, the electronic device determines that it is currently in state C, the high-battery folded state, and sets the corresponding bit value to 10.
[0182] In some examples, the electronic device may be equipped with a display capable of multiple folds, such as a tri-fold folding screen device. In this case, the electronic device can use bitwise operations to set the truth values of more bits to represent the folding state. For example, as... Figure 8As shown, for a tri-fold foldable screen electronic device, the display screen includes a first display area, a second display area, and a third display area. A folding axis 1 exists between the first and second display areas, and a folding axis 2 exists between the second and third display areas. The electronic device can set the truth value of the first bit through bitwise operations to indicate the folding state of the first and second display areas (or, in other words, the folding state of folding axis 1), and set the truth value of the second bit through bitwise operations to indicate the folding state of the second and third display areas. For example, 0 represents the unfolded state, and 1 represents the folded state.
[0183] It should be understood that 1 can also represent the unfolded state, and 0 can represent the folded state (or it can be described as representing the folded state of the electronic device's folding axis 2). Furthermore, Figure 8 Taking the second display area as the intermediate display area between folding axis 1 and folding axis 2, and the first display area and the third display area as the display areas on both sides of the second display area, the process of indicating the folding state of the electronic device through the bit truth value is explained. It should be understood that the connection order of the three display areas is not limited in the embodiments of this application.
[0184] For example, such as Figure 8 The three-fold folding screen electronic device shown in Figure (a) obtains the usage status and battery information of the electronic device through the above steps S401 and S402. Then, based on the usage status and battery information, the electronic device determines that it is currently in the fully unfolded state with high battery, and sets the corresponding bit value to 000.
[0185] For example, such as Figure 8 The three-fold foldable screen electronic device shown in (b) obtains the usage status and battery information of the electronic device through the above steps S401 and S402. Then, based on the usage status and battery information, the electronic device determines that the current electronic device is in a high battery state, the first display area and the second display area are in a folded state, and the second display area and the third display area are in an unfolded state, and the corresponding bit value can be set to 010.
[0186] For example, such as Figure 8 The three-fold folding screen electronic device shown in (c) obtains the usage status and battery information of the electronic device through the above steps S401 and S402. Then, based on the usage status and battery information, the electronic device determines that the current electronic device is in a high battery state, the first display area and the second display area are in an unfolded state, and the second display area and the third display area are in a folded state, and the corresponding bit value can be set to 100.
[0187] For example, such as Figure 8 The three-fold foldable screen electronic device shown in (d) obtains its usage status and battery information through steps S401 and S402. Then, based on the usage status and battery information, the electronic device determines that it is currently in a fully folded state with high battery, and sets the corresponding bit value to 110.
[0188] In some examples, in audio data-driven scenarios, the audio service determines bit values based on the electronic device's usage status and battery level. The audio service can then match these bit values to the corresponding gain flag.
[0189] In other examples, in chip-driven scenarios, the motor service determines bit values based on the electronic device's usage status and power information. The motor service can then match these bit values to the corresponding vibration waveform.
[0190] In this way, by setting different bit values, the electronic device can adaptively match the corresponding vibration parameters, so as to drive the motor to vibrate according to the matched vibration parameters in subsequent steps.
[0191] It should be understood that the electronic device can set more bits to match the electronic device for potentially more folded axes. Optionally, if more bits are not used, the electronic device can set these bits to 0 (or 1).
[0192] S404. Electronic devices drive motors to vibrate according to vibration parameters.
[0193] In some embodiments, after acquiring vibration parameters, the electronic device can send the vibration parameters to the motor to drive the motor to vibrate according to the corresponding vibration parameters.
[0194] For example, such as Figure 5In the audio data-driven scenario shown, after acquiring vibration parameters (e.g., a gain flag), the audio service sends the gain flag to the audio driver (e.g., step ⑥). The audio driver then forwards the gain flag to the audio codec chip to trigger the chip's underlying path selection, where the selected path corresponds to the gain flag. Optionally, the audio service sends interface information to the digital signal processor (DSP) via the audio driver. This interface information may include an interface identifier for transmitting audio data and an interface identifier for transmitting motor data (e.g., steps ⑥ and ⑦). The interface identifier indicates the interface for subsequent transmission of audio or motor data. In some examples, the motor service sends a default vibration waveform to the DSP via the motor driver (e.g., steps ⑨ and ⑩). The DSP forwards the acquired default vibration waveform to the audio codec chip based on the motor data interface identifier (e.g., step ⑧). Optionally, the DSP may be, for example, a high-fidelity (HiFi) DSP. It should be understood that in usage scenarios where vibration is accompanied by audio playback, the information sent by the audio service also includes audio. The audio driver can send this audio to a digital signal processor (DSP). The DSP, based on the interface identifier of the audio data, forwards the audio to the audio module (e.g., a speaker) through an audio codec chip to trigger audio playback (e.g., steps ⑦ and ⑧). Afterward, the audio codec chip can obtain the corresponding gain based on the gain flag and correct the default vibration waveform using this gain. For example, after inputting the default waveform and gain to the audio codec chip, the chip can output the corresponding corrected vibration waveform. Optionally, the correction of the vibration waveform may include, for example, correcting parameters affecting the vibration sensation, such as the amplitude and frequency of the vibration waveform. Then, the audio codec chip can send the corrected vibration waveform to the motor to drive the motor to vibrate according to the corrected waveform (e.g., step ⑧). ).
[0195] It should be understood that Figure 5 The solid arrows indicate the direction in which the audio service transmits audio data to the lower-level hardware. This audio data may include, for example, the gain flag and the corrected motor vibration waveform. The dotted arrows indicate the direction in which the motor service transmits motor data to the lower-level hardware. This motor data may include, for example, the motor vibration waveform.
[0196] For example, such as Figure 6 In the chip-driven scenario shown, the motor service can obtain vibration parameters, such as a matching vibration waveform. Then, the motor service sends this vibration waveform to the motor chip via the motor driver, and the motor chip drives the motor to vibrate according to the vibration waveform (e.g., steps ④, ⑤, and ⑥).
[0197] It should be understood that Figure 6The dotted horizontal arrow indicates the direction in which the motor service transmits motor data to the lower-level hardware, such as the motor vibration waveform described above.
[0198] Optionally, the motor service can send a vibration waveform or a vibration waveform sequence number. If the motor service sends a vibration waveform sequence number, the audio codec chip or the motor can match the corresponding vibration waveform according to the vibration waveform sequence number.
[0199] Because the motor drives the electronic device to vibrate using the same waveform regardless of the device's usage state, the vibration feedback provided to the user varies. For example, when a foldable screen electronic device is folded, the relative position of the motor changes, thus altering the user's vibration perception. Another example is that the motor in an electronic device is typically mounted near the center, meaning that when the device is folded, the motor is encased within a multi-layered flexible screen. When the device vibrates, the flexibility of the screen causes the vibration energy generated by the motor with its set vibration parameters to be absorbed by the multi-layered flexible screen, resulting in a weaker vibration perceived from the outside of the device compared to its unfolded state, leading to a significant difference in vibration feedback. Therefore, by combining the device's usage state and battery level information, the vibration parameters can be comprehensively determined to suit the current usage scenario, allowing the electronic device to provide the same or similar vibration feedback to the user in different usage scenarios, thereby improving the user experience.
[0200] In some embodiments, the electronic device responds to a vibration event, acquires vibration parameters, and drives the motor to vibrate using these parameters. During motor vibration, the electronic device will not dynamically adjust the vibration waveform based on its usage status and battery level. This avoids frequent jumps in motor vibration during folding and unfolding, which could negatively impact the user experience.
[0201] In some embodiments, the electronic device may also obtain vibration parameters based solely on the electronic device's usage status or battery level information.
[0202] For example, in an audio data-driven scenario, the audio service determines the current battery status of the electronic device based on the battery information reported by the power driver. Then, the audio service matches the corresponding gain flag based on this battery status and sends the gain flag to the digital signal processor (DSP) via the audio driver. Additionally, the motor service sends a default vibration waveform to the DSP via the motor service. The DSP then sends the acquired vibration parameters, such as the default vibration waveform and the gain flag, to the audio codec chip. The audio codec chip can obtain the corresponding gain based on the gain flag and correct the default vibration waveform accordingly. For example, after inputting the default waveform and gain to the audio codec chip, the chip can output the corresponding corrected vibration waveform. The audio codec chip can then send the corrected vibration waveform to the motor to drive it to vibrate according to the corrected waveform.
[0203] For example, in a chip driver scenario, the motor service receives power information reported by the power driver to determine the current power status of the electronic device. Based on the power status, the motor service can then match a corresponding vibration waveform. The vibration parameters determined by the motor service may include, for example, the matched vibration waveform. Subsequently, the motor service sends this vibration waveform to the motor via the motor driver to drive the motor to vibrate according to that waveform.
[0204] For example, in an audio data-driven scenario, the audio service determines the current usage status of the electronic device based on the Hall parameters forwarded by the audio driver. Then, the audio service matches the corresponding gain flag based on this usage status and sends the gain flag to the digital signal processor (DSP) via the audio driver. Additionally, the motor service sends a default vibration waveform to the DSP via the motor service. The DSP then sends the acquired vibration parameters, such as the default vibration waveform and the gain flag, to the audio codec chip. The audio codec chip can obtain the corresponding gain based on the gain flag and correct the default vibration waveform accordingly. For instance, after inputting the default waveform and gain to the audio codec chip, the chip can output the corresponding corrected vibration waveform. The audio codec chip can then send the corrected vibration waveform to the motor to drive it to vibrate according to the corrected waveform.
[0205] For example, in a chip-driven scenario, the motor service obtains Hall parameters reported by the Hall sensor through the motor driver to determine the current usage status of the electronic device. Based on this status, the motor service can match a corresponding vibration waveform. The vibration parameters determined by the motor service may include, for example, the matched vibration waveform. Then, the motor service sends this vibration waveform to the motor through the motor driver to drive the motor to vibrate according to that waveform.
[0206] In this way, electronic devices can obtain vibration parameters through their usage status or power information, and drive the motor to vibrate according to these vibration parameters, thereby reducing the computational power consumption of the electronic devices.
[0207] In some embodiments, the electronic device is equipped with at least one Hall sensor or other sensor for detecting the usage status of the electronic device.
[0208] Optionally, when the display screen is attached or detached, the Hall sensor triggers a report of Hall parameters to the upper layer. The electronic device can then determine the change in its operating status based on these Hall parameters. Optionally, to improve the accuracy of Hall parameter detection, the Hall sensor is installed near the folding axis.
[0209] For example, such as Figure 7 The illustrated scenario of a bi-foldable screen electronic device includes a folding axis, and a Hall sensor is configured near this folding axis. Figure 7 (Not shown in the image). Optionally, when the relationship between the first display area and the second display area changes to being flush, the Hall sensor sends Hall parameters to the upper layer via an interrupt trigger. Based on these Hall parameters, the electronic device can determine that its usage state is folded. Alternatively, when the relationship between the first display area and the second display area changes to being separated, the Hall sensor sends Hall parameters to the upper layer via an interrupt trigger. Based on these Hall parameters, the electronic device can determine that its usage state is unfolded.
[0210] For example, such as Figure 8 The illustrated three-fold screen electronic device scenario includes two folding axes, and a Hall sensor is configured near each of these two folding axes. Figure 8 (Not shown in the image). When the relationship between the first and second display areas changes from being joined to being separated, or from being separated to being joined, Hall sensor 1, located near folding axis 1, sends Hall parameter 1 to the upper layer via an interrupt trigger. Similarly, when the relationship between the second and third display areas changes from being joined to being separated, or from being separated to being joined, Hall sensor 2, located near folding axis 2, sends Hall parameter 2 to the upper layer via an interrupt trigger. Therefore, the electronic device needs to combine Hall parameter 1 and Hall parameter 2 to determine its operating status.
[0211] In other words, when an electronic device is equipped with one Hall sensor, the audio service or motor service acquires one set of Hall parameters; when the electronic device is equipped with multiple Hall sensors, the audio service or motor service acquires multiple sets of Hall parameters. Then, the audio service or motor service determines the operating status of the electronic device based on all the acquired Hall parameters.
[0212] In this way, the electronic device adaptively determines the number of parameters needed to judge the usage status of the electronic device based on the actual Hall sensor configuration.
[0213] In some embodiments, the electronic device is equipped with at least one motor. For example, such as Figure 7 or Figure 8 In the scenario shown, the electronic device is equipped with at least one motor.
[0214] Thus, even if an electronic device is equipped with only one motor, it can adaptively adjust vibration feedback by fusing multiple information sources, combining the device's usage status and battery level information. Compared to existing technologies where the number of motors needs to match the number of display areas, the vibration control method provided in this application effectively reduces hardware costs.
[0215] In some embodiments, the electronic device can optionally disable the dynamic vibration adjustment function based on user operation. Optionally, the dynamic vibration adjustment function can be uniformly disabled or enabled to allow the electronic device to dynamically adjust vibration based on usage status and battery information. Alternatively, the dynamic vibration adjustment function can be individually disabled or enabled to allow the electronic device to dynamically adjust vibration based on usage status or battery information.
[0216] For example, if a user believes that sacrificing vibration feedback when the electronic device's battery is low can extend its usage time, then the user can choose to disable the device's ability to dynamically adjust vibration based on battery level. Alternatively, the user can also directly disable the device's ability to dynamically adjust vibration based on usage status and battery level.
[0217] Figure 9 This is a schematic flowchart illustrating another vibration control method provided in an embodiment of this application. It should be noted that this method does not rely on... Figure 9 The specific order described below is a limitation. It should be understood that in other embodiments, the order of some steps in the method can be interchanged according to actual needs, or some steps can be omitted or deleted. The method includes the following steps:
[0218] S901. When the electronic device is in a first usage state, in response to a vibration event, it obtains a first vibration parameter based on the first usage state and the first power information of the electronic device.
[0219] In some embodiments, the motor vibration event can be, for example, an incoming call event. When the electronic device detects an incoming call, it needs to trigger motor vibration. The electronic device can obtain the current first usage state and first battery level information, and then obtain the first vibration parameters based on the first usage state and first battery level information.
[0220] For example, based on Figure 5In the audio data driven scenario shown, the electronic device can match the first gain flag corresponding to the first usage state and the first power information, and obtain the vibration waveform 1 by correcting the default vibration waveform through the gain indicated by the first gain flag.
[0221] For example, based on Figure 6 In the chip-driven scenario shown, the electronic device can match the vibration waveform A corresponding to the first usage state and the first power information.
[0222] S902. The electronic device drives the motor to vibrate according to the first vibration parameter.
[0223] For example, based on Figure 5 In the audio data driven scenario shown, the electronic device can drive the motor to vibrate according to the first vibration parameter, for example, drive the motor to vibrate according to the vibration waveform 1 after gain correction.
[0224] For example, based on Figure 6 In the chip-driven scenario shown, the electronic device can drive the motor to vibrate according to the first vibration parameter, for example, drive the motor to vibrate according to vibration waveform A.
[0225] S903. During vibration, in response to user operation, the electronic device switches to a second usage state.
[0226] The second usage state is different from the first usage state.
[0227] In some embodiments, the user operation is, for example, an operation that changes the usage state of the electronic device. For example, the user operation is the operation of folding or unfolding the foldable screen of the electronic device.
[0228] S904. The electronic device obtains the second vibration parameter based on the second usage state and the second power information of the electronic device.
[0229] In some embodiments, during vibration, when the electronic device detects an operation by the user that changes the usage state of the electronic device, in response to this operation, the electronic device can acquire a second usage state and second battery level information. A second vibration parameter can then be acquired based on this second usage state and second battery level information.
[0230] For example, based on Figure 5 In the audio data driven scenario shown, the electronic device matches the second gain flag corresponding to the second usage state and the second power information, and obtains the vibration waveform 2 by correcting the default vibration waveform through the gain indicated by the second gain flag.
[0231] For example, based on Figure 6In the chip-driven scenario shown, the electronic device matches the vibration waveform B corresponding to the second usage state and the second power information.
[0232] S905. The electronic device drives the motor to vibrate according to the second vibration parameter, and the vibration feedback corresponding to the first vibration parameter and the second vibration parameter is the same or has a first deviation.
[0233] In some embodiments, vibration feedback includes vibration acceleration. Exemplarily, a motor is driven to vibrate according to a first vibration parameter to generate a first vibration acceleration, and a second vibration parameter is driven to vibrate to generate a second vibration acceleration, wherein the first and second vibration accelerations are the same or have a first deviation.
[0234] For example, based on Figure 5 In the audio data-driven scenario shown, the electronic device can drive the motor to vibrate according to the second vibration parameters, for example, driving the motor to vibrate according to vibration waveform 2. The first and second vibration parameters are different (e.g., the first gain flag and the second gain flag are different), but the vibration feedback provided to the user by driving the motor is the same or similar. It should be noted that "same" does not mean absolutely identical. The vibration acceleration generated by the motor vibration can deviate in different states of the electronic device. For example, there can be a deviation between the first vibration acceleration generated by driving the motor according to the first vibration parameters and the second vibration acceleration generated by driving the motor according to the second vibration parameters; for example, this first deviation can be ±30%. Thus, in the audio data-driven scenario, the electronic device can adaptively adjust the gain of the default vibration waveform based on the usage status and battery information, thereby providing the user with the same or similar vibration feedback.
[0235] For example, based on Figure 6 In the chip-driven scenario shown, the electronic device can drive the motor to vibrate according to a second vibration parameter, for example, driving the motor to vibrate according to vibration waveform B. The first and second vibration parameters are different (e.g., vibration waveforms A and B are different), but the vibration feedback provided to the user by the driven motor is the same or similar. Thus, in the chip-driven scenario, the electronic device can adaptively match the corresponding vibration waveform based on usage status and power information, thereby providing the user with the same or similar vibration feedback.
[0236] In the above example scenario, the process of the electronic device acquiring the usage status (e.g., the first usage status or the second usage status), the process of acquiring power information (e.g., the first power information or the second power information), the process of acquiring vibration parameters (e.g., the first vibration parameter or the second vibration parameter) based on the usage status and power information, and the process of driving the motor to vibrate according to the vibration parameters can be referred to the relevant content of steps S401-S404 above, and will not be repeated here.
[0237] In some embodiments, in response to a vibration event, the electronic device acquires a first vibration parameter based on a first usage state and a first battery level. After driving a motor to vibrate using this first vibration parameter, if the electronic device switches from a first usage state to a second usage state during the motor vibration process, the electronic device will not dynamically adjust the vibration waveform based on the usage state and battery level during the switch. When the electronic device switches to the second usage state, it acquires a second vibration parameter based on the second usage state and the second battery level, and drives the motor to vibrate using this second vibration parameter. This avoids frequent jumps in motor vibration during the folding and unfolding process, which could negatively impact the user experience.
[0238] It should be understood that the above description of the adaptive adjustment process of vibration feedback uses multi-information fusion analysis based on the usage status and power information of electronic devices as an example. Furthermore, electronic devices can also incorporate more parameters affecting their vibration feedback for multi-information fusion analysis, providing users with a more accurate and consistent vibration experience.
[0239] In some solutions, multiple embodiments of this application can be combined, and the combined solution can be implemented. Optionally, some operations in the processes of each method embodiment may be combined, and / or the order of some operations may be changed. Furthermore, the execution order between the steps of each process is merely exemplary and does not constitute a limitation on the execution order between steps; other execution orders are also possible. It is not intended to indicate that the execution order is the only possible order in which these operations can be performed. Those skilled in the art will conceive of various ways to reorder the operations described herein. In addition, it should be noted that the process details involved in one embodiment of this document are similarly applicable to other embodiments, or different embodiments may be combined.
[0240] Furthermore, some steps in the method embodiments can be equivalently replaced with other possible steps. Alternatively, some steps in the method embodiments may be optional and can be deleted in certain use cases. Or, other possible steps may be added to the method embodiments.
[0241] Furthermore, the various method embodiments can be implemented individually or in combination.
[0242] The above combination Figures 4-9 The vibration control method provided in the embodiments of this application is described in detail below. Figure 10 This application provides a detailed description of the electronic device provided in its embodiments.
[0243] In one possible design, Figure 10 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Figure 10 As shown, the electronic device 1000 may include a transceiver unit 1001 and a processing unit 1002. The electronic device 1000 can be used to implement the functions of the electronic device involved in the above method embodiments.
[0244] Optionally, the transceiver unit 1001 is used to support the electronic device 1000 in performing... Figure 4 S401 and S402 in the above; and / or, for supporting electronic device 1000 to perform Figure 9 S901 and S904 in the example.
[0245] Optionally, the processing unit 1002 is used to support the electronic device 1000 in performing operations. Figure 4 S403 and S404 in the above; and / or, for supporting electronic device 1000 to perform Figure 9 The S902, S903, and S905 in the series.
[0246] The transceiver unit may include a receiving unit and a transmitting unit, and may be implemented by a transceiver or transceiver-related circuit components, and may be a transceiver or transceiver module. The operation and / or function of each unit in the electronic device 1000 are respectively for implementing the corresponding process of the vibration control method described in the above method embodiments. All relevant content of each step involved in the above method embodiments can be referred to the functional description of the corresponding functional unit, and for the sake of brevity, it will not be repeated here.
[0247] Optionally, Figure 10 The illustrated electronic device 1000 may also include a storage unit ( Figure 10 (Not shown in the image), this storage unit stores a program or instruction. When the transceiver unit 1001 and the processing unit 1002 execute the program or instruction, it causes... Figure 10 The electronic device 1000 shown can perform the vibration control method described in the above method embodiments.
[0248] Figure 10 The technical effects of the electronic device 1000 shown can be referred to the technical effects of the vibration control method described in the above method embodiments, and will not be repeated here.
[0249] In addition to being in the form of electronic device 1000, the technical solution provided in this application can also be a functional unit or chip in an electronic device, or a device used in conjunction with an electronic device.
[0250] This application also provides a chip system, including: a processor coupled to a memory, the memory being used to store programs or instructions, wherein when the program or instructions are executed by the processor, the chip system implements the methods in any of the above method embodiments.
[0251] Optionally, the chip system may contain one or more processors. These processors can be implemented in hardware or software. When implemented in hardware, the processor can be a logic circuit, an integrated circuit, etc. When implemented in software, the processor can be a general-purpose processor, implemented by reading software code stored in memory.
[0252] Optionally, the chip system may contain one or more memories. The memory may be integrated with the processor or disposed separately from it; this application embodiment does not limit this. For example, the memory may be a non-transient processor, such as a read-only memory (ROM), which may be integrated with the processor on the same chip or disposed separately on different chips. This application embodiment does not specifically limit the type of memory or the arrangement of the memory and processor.
[0253] For example, the chip system may be a field programmable gate array (FPGA), an application specific integrated circuit (ASIC), a system on chip (SoC), a central processor unit (CPU), a network processor (NP), a digital signal processor (DSP), a micro controller unit (MCU), a programmable logic device (PLD), or other integrated chips.
[0254] It should be understood that each step in the above method embodiments can be completed by integrated logic circuits in the processor hardware or by instructions in software form. The method steps disclosed in the embodiments of this application can be directly manifested as being executed by a hardware processor, or being executed by a combination of hardware and software modules in the processor.
[0255] This application also provides a computer-readable storage medium storing a computer program. When the computer program is run on a computer, it causes the computer to perform the aforementioned steps to implement the vibration control method described in the above embodiments.
[0256] This application also provides a computer program product that, when run on a computer, causes the computer to perform the aforementioned steps to implement the vibration control method described in the above embodiments.
[0257] In addition, this application also provides an apparatus. This apparatus may specifically be a component or module, and may include one or more processors and a memory connected together. The memory stores a computer program. When the computer program is executed by one or more processors, the apparatus performs the vibration control methods described in the above-described method embodiments.
[0258] The apparatus, computer-readable storage medium, computer program product, or chip provided in the embodiments of this application are all used to execute the corresponding methods provided above. Therefore, the beneficial effects they can achieve can be referred to the beneficial effects of the corresponding methods provided above, and will not be repeated here.
[0259] The steps of the methods or algorithms described in conjunction with the embodiments of this application can be implemented in hardware or by a processor executing software instructions. The software instructions can consist of corresponding software modules, which can be stored in random access memory (RAM), flash memory, read-only memory (ROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), registers, hard disks, portable hard disks, CD-ROMs, or any other form of storage medium well known in the art. An exemplary storage medium is coupled to a processor, enabling the processor to read information from and write information to the storage medium. Of course, the storage medium can also be a component of the processor. The processor and the storage medium can reside in an application-specific integrated circuit (ASIC).
[0260] Through the above description of the embodiments, those skilled in the art will clearly understand that, for the sake of convenience and brevity, the division of the above functional modules is only used as an example. In practical applications, the above functions can be assigned to different functional modules as needed; that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. The specific working process of the system, device, and unit described above can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.
[0261] In the several embodiments provided in this application, it should be understood that the disclosed methods can be implemented in other ways. The device embodiments described above are merely illustrative. For example, the division of modules or units is only a logical functional division, and there may be other division methods in actual implementation; for example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces, and the indirect coupling or communication connection of modules or units may be electrical, mechanical or other forms.
[0262] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0263] Computer-readable storage media include, but are not limited to, any of the following: USB flash drive, portable hard drive, read-only memory (ROM), random access memory (RAM), magnetic disk or optical disk, and other media capable of storing program code.
[0264] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A vibration control method, characterized in that, Applied to an electronic device, wherein the electronic device is a foldable screen electronic device, the method includes: To obtain the usage status of electronic devices; Obtain battery information for electronic devices; Based on the usage status and the battery level information, vibration parameters are obtained; The motor is driven to vibrate according to the vibration parameters.
2. The method according to claim 1, characterized in that, The vibration parameters include a gain flag, and driving the motor to vibrate according to the vibration parameters includes: Obtain the gain corresponding to the gain flag bit; Obtain the first vibration waveform; The second vibration waveform is obtained by correcting the first vibration waveform based on the gain using an audio codec chip. The motor is driven to vibrate according to the second vibration waveform.
3. The method according to claim 2, characterized in that, The acquisition of the first vibration waveform includes: The first vibration waveform output by the motor service is obtained through the first path of the audio codec chip, the first path corresponding to the gain, and the first vibration waveform is the default vibration waveform.
4. The method according to claim 2 or 3, characterized in that, The step of obtaining vibration parameters based on the usage status and the battery level information includes: Based on the usage status and the power information, the corresponding gain flag is matched.
5. The method according to claim 1, characterized in that, The vibration parameters include a third vibration waveform, and driving the motor to vibrate according to the vibration parameters includes: The third vibration waveform output by the motor service is obtained through the motor chip; The motor is driven to vibrate by the motor chip according to the third vibration waveform.
6. The method according to claim 5, characterized in that, The step of obtaining vibration parameters based on the usage status and the battery level information includes: Based on the usage status and the power information, the corresponding third vibration waveform is matched.
7. The method according to any one of claims 1-6, characterized in that, The electronic device is equipped with a Hall sensor, and the acquisition of the usage status of the electronic device includes: Obtain the Hall parameters detected by the Hall sensor; The usage status is obtained based on the Hall parameters.
8. A vibration control method, characterized in that, Applied to an electronic device, wherein the electronic device is a foldable screen electronic device, the method includes: When the electronic device is in a first usage state, in response to a vibration event, it obtains a first vibration parameter based on the first usage state and the first power information of the electronic device. The motor is driven to vibrate according to the first vibration parameters; During vibration, in response to user operation, the electronic device switches to a second usage state, wherein the second usage state is different from the first usage state; Based on the second usage state and the second power information of the electronic device, the second vibration parameter is obtained; The motor is driven to vibrate according to the second vibration parameter; wherein the vibration feedback corresponding to the first vibration parameter and the second vibration parameter is the same or has a first deviation.
9. The method according to claim 8, characterized in that, The vibration feedback includes vibration acceleration. The vibration feedback corresponding to the first vibration parameter and the second vibration parameter is the same or has a first deviation. It includes: driving the motor to vibrate according to the first vibration parameter to generate a first vibration acceleration, and driving the motor to vibrate according to the second vibration parameter to generate a second vibration acceleration. The first vibration acceleration and the second vibration acceleration are the same or have a first deviation.
10. The method according to claim 8 or 9, characterized in that, The first vibration parameter includes a gain flag, and driving the motor to vibrate according to the first vibration parameter includes: Obtain the gain corresponding to the gain flag bit; Obtain the first vibration waveform; The second vibration waveform is obtained by correcting the first vibration waveform based on the gain using an audio codec chip. The motor is driven to vibrate according to the second vibration waveform.
11. The method according to claim 10, characterized in that, The acquisition of the first vibration waveform includes: The first vibration waveform output by the motor service is obtained through the first path of the audio codec chip, the first path corresponding to the gain, and the first vibration waveform is the default vibration waveform.
12. The method according to claim 10 or 11, characterized in that, The step of obtaining the first vibration parameter based on the first usage state and the first battery level information includes: Based on the first usage state and the first power information, match the corresponding gain flag bit.
13. The method according to claim 8 or 9, characterized in that, The first vibration parameter includes a third vibration waveform, and driving the motor to vibrate according to the first vibration parameter includes: The third vibration waveform output by the motor service is obtained through the motor chip; The motor is driven to vibrate by the motor chip according to the third vibration waveform.
14. The method according to claim 13, characterized in that, The step of obtaining the first vibration parameter based on the first usage state and the first battery level information includes: Based on the first usage state and the first power information, the corresponding third vibration waveform is matched.
15. The method according to any one of claims 8-14, characterized in that, The electronic device is equipped with a Hall sensor, and the acquisition of the first usage state of the electronic device includes: Obtain the Hall parameters detected by the Hall sensor; The first usage state is obtained based on the Hall parameters.
16. An electronic device, characterized in that, include: A processor and a memory, the memory being coupled to the processor, the memory being used to store computer program code, the computer program code including computer instructions, which, when the processor reads the computer instructions from the memory, cause the electronic device to perform the method as described in any one of claims 1-7; or cause the electronic device to perform the method as described in any one of claims 8-15.
17. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes a computer program that, when executed on an electronic device, causes the electronic device to perform the method as described in any one of claims 1-7; or causes the electronic device to perform the method as described in any one of claims 8-15.
18. A computer program product, characterized in that, When the computer program product is run on a computer, it causes the computer to perform the method as described in any one of claims 1-7; or causes the computer to perform the method as described in any one of claims 8-15.
Citation Information
Patent Citations
Motor vibration control method and electronic equipment
CN112532145A
Vibration adjusting method and device, storage medium and electronic equipment
CN112637422A
Method for controlling vibration of electronic equipment, audio compiling and decoding module and electronic equipment
CN113765445A
Vibration control method and electronic equipment
CN115473961A
Cited By
Vibration control method and electronic device
EP4765621A1
Vibration control method and electronic device
WO2025246372A1