Method for adjusting terminal volume and terminal
By detecting the terminal environment and automatically adjusting the terminal volume, the problem of cumbersome terminal volume adjustment in the prior art is solved, dynamic volume adjustment in different scenarios is realized, and user experience is improved.
Patent Information
- Application Number
- CN202210486558.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-06
- Publication Date
- 2024-12-31
- Estimated Expiration
- 2042-05-06
AI Technical Summary
Existing terminal devices require users to manually adjust the incoming call ringtone, media sound and call volume, resulting in cumbersome and untimely adjustment of the volume in different scenarios, and they cannot adapt to environmental changes.
By periodically detecting the stable state of the terminal environment, collecting sound parameters to determine the ambient sound type and spatial scene type, and automatically adjusting the reminder mode and audio mode to control the adjustment of the terminal volume.
It realizes automatic adjustment of terminal volume, dynamically adjusts reminder volume and content volume according to the environment and scene, improving user experience and reducing the cumbersomeness of manual operation.
Smart Images

Figure CN114845213B_ABST
Abstract
Description
Technical Field
[0001] Embodiments of the present application relate to the field of volume adjustment, and more particularly to a method and a terminal for adjusting the volume of a terminal. Background Art
[0002] As the functions of terminal devices continue to increase, terminal devices are widely used. In the prior art, the volume of the incoming call ringtone or vibration, media sound, receiver and loudspeaker of the terminal device needs to be manually set by the user. Whether it is the incoming call reminder volume or the video / music / call volume, the existing terminal devices all use the user to control the volume through the physical volume key or the screen virtual button (volume bar).
[0003] In terms of incoming call reminder sounds, users can choose from two modes: "ringing" or "silent". When the user uses the "ringing" mode by default, the ringing may suddenly ring in meetings or quiet occasions, causing embarrassing situations; if the user uses the "silent / do not disturb" mode on a daily basis, there may be a situation where the call / message cannot be answered in time; when playing videos / music, although the phone uses the silent mode for incoming calls, it may still record the last playback volume when playing content, causing explosive sounds in a quiet environment and causing embarrassment; during a call, in a noisy environment, the volume often needs to be manually turned up to hear the other party's voice more clearly.
[0004] When the user is in different scenarios, the user needs to manually adjust various volumes of the terminal according to the various scenarios, which is cumbersome and inconvenient. Summary of the invention
[0005] The embodiments of the present application provide a method for adjusting the volume of a terminal and a terminal, which can automatically adjust the volume of external sound of the terminal.
[0006] The present application provides a method for adjusting the volume of a terminal, including:
[0007] Periodically check whether the terminal is in a stable state;
[0008] When the terminal is in a stable state, determining an ambient sound type of an environment in which the terminal is located and determining a spatial scene type of an environment in which the terminal is located;
[0009] Determining a prompt mode of the terminal according to the ambient sound type and the spatial scene type;
[0010] When the terminal needs to perform a reminder operation, the terminal is controlled to perform the reminder operation according to the reminder mode.
[0011] Further, the determining the type of ambient sound in the environment where the terminal is located includes:
[0012] Controlling the audio acquisition module of the terminal to acquire sound parameters of the environment in which the terminal is located;
[0013] The ambient sound type of the environment in which the terminal is located is determined according to the sound parameter.
[0014] Further, the determining the spatial scene type of the environment in which the terminal is located includes:
[0015] Controlling the audio acquisition module of the terminal to acquire sound parameters of the environment in which the terminal is located;
[0016] Determining a target sound pressure amplitude of the environment in which the terminal is located according to the sound parameter;
[0017] A preset spatial scene type whose preset sound pressure amplitude corresponds to the target sound pressure amplitude among multiple preset spatial scene types is determined as the spatial scene type of the environment in which the terminal is located, wherein each preset spatial scene type has at least one corresponding preset sound pressure amplitude.
[0018] Further, the determining the ambient sound type of the environment in which the terminal is located and the determining the spatial scene type of the environment in which the terminal is located include:
[0019] Controlling the audio acquisition module of the terminal to acquire multiple sound parameters of the environment in which the terminal is located in a current acquisition cycle;
[0020] The ambient sound type and the spatial scene type are determined according to the multiple sound parameters in the current collection period.
[0021] Further, the periodic detection of whether the terminal is in a stable state includes:
[0022] Detecting whether the ambient sound type of the terminal changes according to adjacent sound parameters collected by the terminal in a current collection period;
[0023] If the ambient sound type changes, it is determined that the terminal is not in a stable state, and the step of returning to execute the step of detecting whether the ambient sound type of the terminal changes according to the adjacent sound parameters of the terminal in the next collection cycle;
[0024] If the ambient sound type has not changed, detecting whether the motion state of the terminal has changed according to the previous displacement parameter and the next displacement parameter of the terminal in the current collection period;
[0025] If the motion state of the terminal does not change, determining that the terminal is in a stable state;
[0026] If the motion state of the terminal changes, it is determined that the terminal is not in a stable state, and the process returns to the step of detecting whether the ambient sound type of the terminal changes according to adjacent sound parameters of the terminal in the next acquisition cycle.
[0027] Further, after determining the prompt mode of the terminal according to the ambient sound type and the spatial scene type, and before controlling the terminal to perform the prompt operation according to the prompt mode when the terminal needs to perform the prompt operation, the method further includes:
[0028] If the prompt mode of the terminal is a gentle disturbance mode or a reminder mode, determining whether the prompt mode of the terminal is determined to be a do not disturb mode within a preset time period before the current collection period;
[0029] If so, the prompt mode of the terminal is changed to the do not disturb mode.
[0030] Further, the determining the prompt mode of the terminal according to the ambient sound type and the spatial scene type includes:
[0031] If the ambient sound type is a single human voice environment dominated by human voices, and the spatial scene type is a conference hall or a classroom, determining that the prompt mode of the terminal is a do not disturb mode;
[0032] If the ambient sound type is a multi-voice environment dominated by human voices, and the spatial scene type is a conference hall or a classroom, determining that the prompt mode of the terminal is a gentle disturbance mode;
[0033] If the ambient sound type is a noisy environment dominated by ambient sound, and the spatial scene type is outdoor, determining that the prompt mode of the terminal is a reminder mode;
[0034] If the ambient sound type is a quiet environment, and the acceleration sensor of the terminal determines that the terminal is in a stationary state, determining that the prompt mode of the terminal is a do not disturb mode;
[0035] If the ambient sound type is a quiet environment, and the acceleration sensor of the terminal determines that the terminal is in a moving state, then the prompt mode of the terminal is determined to be a gentle disturbance mode.
[0036] The present application also provides a method for adjusting the volume of a terminal, including:
[0037] When the terminal needs to perform an audio playback operation, determining the ambient sound type of the environment in which the terminal is currently located and determining a target application for the terminal to play the audio;
[0038] Determining, according to the ambient sound type and the target application, an audio mode in which the terminal plays the audio;
[0039] The terminal is controlled to play audio according to the audio mode.
[0040] Further, the determining, according to the ambient sound type and the target application, the audio features when the terminal plays the audio includes:
[0041] If the target application is an application for playing videos or music, and the ambient sound type is a quiet environment, determining that the audio mode is a low volume mode that prioritizes sound quality;
[0042] If the target application is an application for playing videos or music, and the ambient sound type is a noisy environment, determining that the audio mode is a medium-high volume mode with volume priority;
[0043] If the target application is a voice call application, the audio mode is determined to be a high-quality, high-volume mode with noise reduction.
[0044] The present application also provides a terminal, including:
[0045] CPU, memory, input and output interfaces, wired or wireless network interfaces, and power supply;
[0046] The memory is a short-term storage memory or a persistent storage memory;
[0047] The central processing unit is configured to communicate with the memory and execute instructions in the memory to perform the above method for adjusting the terminal volume.
[0048] It can be seen from the above technical solutions that the embodiments of the present application have the following advantages:
[0049] In an embodiment of the present application, the prompt mode of the terminal is determined according to the ambient sound type and the spatial scene type; when the terminal needs to perform a reminder operation, the terminal is controlled to perform the reminder operation according to the prompt mode, and the audio mode of the terminal playing audio is determined according to the ambient sound type and the target application; the terminal is controlled to play audio according to the audio mode; and the volume of the terminal's external sound can be automatically adjusted. BRIEF DESCRIPTION OF THE DRAWINGS
[0050] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in the present application. For ordinary technicians in this field, other drawings can also be obtained based on these drawings.
[0051] Figure 1 A flow chart for adjusting terminal volume disclosed in an embodiment of the present application;
[0052] Figure 2 Another flow chart for adjusting terminal volume disclosed in an embodiment of the present application;
[0053] Figure 3 Another flow chart for adjusting terminal volume disclosed in an embodiment of the present application;
[0054] Figure 4 A logical framework diagram for adjusting the volume of a terminal disclosed in an embodiment of the present application;
[0055] Figure 5 A reminder sound detection logic diagram disclosed in an embodiment of the present application;
[0056] Figure 6 A content sound detection logic diagram disclosed in an embodiment of the present application;
[0057] Figure 7 A schematic diagram of a sound pressure range disclosed in an embodiment of the present application;
[0058] Figure 8 A schematic diagram of a terminal disclosed in an embodiment of the present application. DETAILED DESCRIPTION
[0059] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present application.
[0060] In the description of the embodiments of the present application, it should be noted that the terms "center", "up", "down", "left", "right", "vertical", "horizontal", "inside", "outside", etc. indicate orientations or positional relationships based on the orientations or positional relationships shown in the accompanying drawings. They are only for the convenience of describing the embodiments of the present application and simplifying the description, and do not indicate or imply that the referred device or element must have a specific orientation, be constructed and operated in a specific orientation. Therefore, they cannot be understood as limitations on the embodiments of the present application.
[0061] In the description of the embodiments of the present application, it should be noted that, unless otherwise clearly specified and limited, the terms "installed", "connected", and "connected" should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be indirectly connected through an intermediate medium, or it can be the internal communication of two components. For ordinary technicians in this field, the specific meanings of the above terms in the embodiments of the present application can be understood according to specific circumstances.
[0062] In the prior art, the volume of the incoming call ringtone or vibration, media sound, receiver and loudspeaker of the terminal device all need to be manually set by the user. Whether it is the incoming call reminder volume or the video / music / call volume, the existing terminal devices all use the user to control the volume through the physical volume key or the screen virtual button (volume bar). However, it is cumbersome to adjust the volume manually multiple times, and the adjustment is not timely enough. Therefore, the embodiment of the present application provides a method for adjusting the terminal volume, which can automatically adjust the terminal volume.
[0063] It is understandable that the terminal described in the embodiment of the present application can be a mobile phone or an electronic watch with a sound playing function, etc., which is not limited here, and the terminal described below will not be repeated. There are two main types of sounds played by the terminal: reminder sound and content sound. Reminder sound is mainly a sound with the main purpose of reminder, such as ringtone, key feedback sound, etc., which is not limited here; while content sound is mainly a sound with the main purpose of conveying information, such as video soundtrack, music, voice message, call, etc., which is not limited here. Therefore, based on the difference between reminder sound and content sound, when adjusting the volume of the sound, the terminal needs to first distinguish whether the current external sound is a reminder sound or a content sound. When the terminal plays the sound, it can determine whether the current external sound is a reminder sound or a content sound according to its own application. For example, if the application that currently needs to play the sound is an alarm clock, it can be determined that the current external sound is a reminder sound. If the application that currently needs to play the sound is a video player, it can be determined that the current external sound is a content sound. The reminder sound is generally preset, and the content sound is generally the sound carried by the application.
[0064] The following uses the reminder tone as an example to explain the process of adjusting the terminal volume. Figure 1 As shown, the specific steps are as follows:
[0065] 101. Periodically check whether the terminal is in a stable state.
[0066] The terminal can periodically detect through multiple sensors on the terminal to determine whether the terminal is in a stable state. It is understandable that the periodic detection can be set according to the actual situation. Since the terminal may change from position A to position B / environment / state within a period of time, the result of the detection at A and the matching feedback form may no longer be applicable to the occasion where B is located. Therefore, if the power consumption allows, periodic detection needs to be set.
[0067] The detection period can be set to perform a detection for 5 seconds every 5 seconds or a detection for 6 seconds every 8 seconds. The specific detection is not limited here. It is preferred to perform a detection for 5 seconds every 5 seconds. If in the process of a periodic detection, the information collected by the sensor on the terminal finds that the ambient sound type of the environment in which the terminal is located or the motion state of the terminal has changed, it can be considered that the terminal is not in a stable state. For example, if in a detection process lasting 5 seconds, the data collected in the 3rd second is compared with the data collected in the 4th second, and it is found that the ambient sound type of the environment in which the terminal is located or the motion state of the terminal has changed, it can be considered that the terminal is not in a stable state.
[0068] 102. Determine an ambient sound type of an environment in which the terminal is located and determine a spatial scene type of an environment in which the terminal is located.
[0069] When the terminal is in a stable state, determine the type of ambient sound of the environment in which the terminal is located and determine the type of spatial scene of the environment in which the terminal is located. Specifically, during a period of detection, if it is found that the type of ambient sound in which the terminal is located and the motion state of the terminal have not changed, it can be considered that the terminal is in a stable state in this detection cycle. At this time, the type of ambient sound in the environment in which the terminal is located can be determined according to the audio acquisition module on the terminal, and the type of spatial scene in the environment in which the terminal is located can be determined according to the audio acquisition module or other sensors on the terminal. It can be understood that the audio acquisition module can be a microphone or a device for collecting sound, which is not specifically limited here. The other sensors can be acceleration sensors, gyroscopes, distance sensors, light sensors, etc., which are not specifically limited here.
[0070] The ambient sound type refers to the type of sound in the environment where the terminal is located. The ambient sound type can be determined based on the collected ambient sound, such as noisy environment, quiet environment, etc., which is not limited here. The spatial scene type refers to the specific scene with spatial significance where the terminal is located, such as a conference room, a living room, etc., which is not limited here.
[0071] 103. Determine a prompt mode of the terminal according to the ambient sound type and the spatial scene type.
[0072] The terminal can determine the prompt mode of the terminal according to the ambient sound type and the spatial scene type determined in a stable state. The prompt mode is mainly used to determine the presentation form of the prompt sound and can be pre-set. The prompt mode can be one of the do not disturb mode, gentle disturbance mode or reminder mode.
[0073] Specifically, it can be pre-set that when the ambient sound collected by the audio acquisition module is greater than or equal to a preset sound pressure amplitude, the ambient sound type is determined to be a noisy environment dominated by ambient sound, and the spatial scene type is outdoor, then the prompt mode is determined to be a reminder mode. When the ambient sound collected by the audio acquisition module is less than the preset sound pressure amplitude, the ambient sound type is determined to be a quiet environment, and the spatial scene type is indoors, then the prompt mode is determined to be the do not disturb mode. It can be understood that the preset sound pressure amplitude can be 50dB or 60dB, which is not specifically limited here, and the preset sound pressure amplitude can be modified accordingly according to actual conditions.
[0074] 104. The control terminal performs a reminder operation according to the reminder mode.
[0075] When the terminal determines that the sound to be played externally is a prompt sound, the terminal performs a prompt operation according to the prompt mode determined in a stable state, so as to implement different prompt operations according to specific circumstances.
[0076] Specifically, when the terminal determines that the prompt mode is the do not disturb mode, the sound playing device is controlled not to play the sound, and the vibration device is controlled to perform the vibration operation, and the vibration gradually increases from weak to strong; when the terminal determines that the prompt mode is the light disturbance mode, the sound playing device is controlled to play the sound (ringtone) from weak to strong, and the vibration device is controlled to perform a strong vibration reminder; when the terminal determines that the prompt mode is the reminder mode, the sound playing device is controlled to play a loud sound (ringtone) reminder, and the vibration device is controlled to perform a strong vibration reminder.
[0077] In the embodiment of the present application, when a prompt sound needs to be played, the prompt mode of the terminal is determined by determining the ambient sound type, and the volume of the terminal's external sound can be automatically adjusted according to different prompt modes.
[0078] The present application embodiment also provides a specific process for adjusting the volume of the terminal, such as Figure 2 The specific steps are as follows:
[0079] 201. Detect whether the ambient sound type of the terminal has changed according to the adjacent sound parameters collected by the terminal. If yes, continue to execute step 201, if not, execute step 202.
[0080] According to the adjacent sound parameters collected by the terminal in the current collection cycle, detect whether the ambient sound type of the terminal has changed. Specifically, two ambient sound types can be obtained based on any two adjacent sound parameters in the current collection cycle. If there is a difference between the two ambient sound types, it can be considered that the ambient sound type of the terminal has changed. If the ambient sound type has changed, it is determined that the terminal is not in a stable state, and the adjacent sound parameters of the terminal in the next collection cycle are obtained to re-detect whether the ambient sound type of the terminal has changed.
[0081] 202. Detect whether the motion state of the terminal has changed according to the previous displacement parameter and the next displacement parameter of the terminal. If yes, execute step 201; if no, execute step 203.
[0082] If the ambient sound type has not changed, then detect whether the motion state of the terminal has changed based on the previous displacement parameter and the next displacement parameter of the terminal in the current acquisition cycle. It can be understood that the change in motion state specifically refers to whether the terminal has changed from a mobile state to a stationary state, or whether the terminal has changed from a stationary state to a mobile state. If the terminal has remained in a stationary state or has remained in a mobile state during the current acquisition cycle, it can be considered that the motion state of the terminal has not changed. The terminal can obtain multiple displacement parameters in the current acquisition cycle. Among the multiple displacement parameters, if there is a change between any two adjacent displacement parameters (i.e., the previous displacement parameter and the next displacement parameter), it is determined that the motion state of the terminal has changed.
[0083] If the motion state of the terminal changes, it is determined that the terminal is not in a stable state and adjacent sound parameters of the terminal in the next collection cycle are obtained again to detect whether the ambient sound type of the terminal has changed.
[0084] 203. Determine that the terminal is in a stable state.
[0085] If the motion state of the terminal does not change, the terminal is determined to be in a stable state. It is understandable that determining that the terminal is in a stable state requires two conditions: the ambient sound type of the first terminal has not changed, and the motion state of the second terminal has not changed. The condition for the termination of the loop is that the terminal is within a target collection period, the ambient sound type of the environment in which the terminal is located and the motion state of the terminal have not changed, and the sound parameters of the target collection period are collected.
[0086] 204. Determine the ambient sound type of the environment in which the terminal is located and determine the spatial scene type of the environment in which the terminal is located.
[0087] When determining the type of ambient sound in the environment where the terminal is located, the sound parameters of the environment where the terminal is located can be collected by controlling the audio collection module of the terminal, and the sound parameters include ambient background sound or human voice, etc., which are not specifically limited here. Determine the type of ambient sound in the environment where the terminal is located according to the sound parameters. Specifically, when the terminal is in a stable state, multiple sound parameters can be collected, and relevant sound features can be extracted from the multiple sound parameters to determine the type of ambient sound in the environment where the terminal is located.
[0088] The sound parameters of the terminal environment collected by the audio acquisition module can also be used to determine the spatial scene type of the terminal environment. Specifically, the target sound pressure amplitude of the terminal environment can be determined according to the sound parameters, and then, among multiple preset spatial scene types, the preset spatial scene type corresponding to the preset sound pressure amplitude and the target sound pressure amplitude is determined as the spatial scene type of the terminal environment. Among them, each preset spatial scene type has at least one corresponding preset sound pressure amplitude. Specifically, a mapping relationship between the preset spatial scene type and the preset sound pressure amplitude can be established to form a mapping library. Among them, at least one corresponding preset sound pressure amplitude is set for each preset spatial scene type in the mapping library. When it is determined that the target sound pressure amplitude of the terminal environment is within a certain preset sound pressure amplitude range, the preset spatial scene type corresponding to the preset sound pressure amplitude is determined as the spatial scene type of the terminal environment.
[0089] It is understandable that if Figure 7 As shown, the size of the sound can be expressed by the size of the sound pressure in dB (A). GB3096-2008 stipulates that the sound pressure of the bedroom is 45dB, the living room is 55dB, the conference room is 60dB, the cinema is 65dB, the museum is 50dB, the square road is 70dB-80dB, etc. The size of the sound pressure is different, and the type of scene can be identified by the size of the sound pressure. The sound parameters collected by the audio acquisition module are processed by algorithms such as noise reduction and remote sound pickup. The human voice and background noise are separated, and the background noise is processed by the algorithm to output an amplitude signal with a corresponding sound pressure of 0dB-100dB. In the algorithm library setting, the built-in scene feature acoustic parameter file, the scene feature sound pressure threshold is 45dB for the bedroom, 55dB for the living room, 65dB for the conference room, 65dB for the cinema, 70dB-80dB for the square road, etc. The real-time collected environmental background sound is converted into a sound pressure amplitude value, and compared one by one with the built-in scene feature sound pressure parameter file in the library, which can determine the type of space scene.
[0090] Furthermore, in order to make the collected sound parameters more accurate, the audio acquisition module needs to collect multiple sound parameters of the environment in which the terminal is located within the current acquisition cycle, and determine the ambient sound type and spatial scene type of the environment in which the terminal is located based on the multiple sound parameters within the current acquisition cycle. It can be understood that the current acquisition cycle mainly refers to the acquisition cycle in which the terminal is in a stable state, that is, the ambient sound type of the terminal and the motion state of the terminal in the current acquisition cycle have not changed. The multiple sound parameters include all the sound parameters within the current acquisition cycle as much as possible.
[0091] 205. Determine a prompt mode of the terminal according to the ambient sound type and the spatial scene type.
[0092] Step 205 is similar to the above step 103 and will not be described in detail here.
[0093] 206. If the prompt mode is the gentle disturbance mode or the reminder mode, determine whether the prompt mode of the terminal is set to the do not disturb mode within the last preset time period. If yes, execute step 208; if no, execute step 207.
[0094] Before the terminal needs to perform the reminder operation, the terminal needs to determine whether the terminal's reminder mode has been set to the do not disturb mode within the previous preset duration of the current collection cycle. It is understandable that there are multiple collection cycles in each preset duration, and the preset duration can be 5 minutes or 6 minutes, which is not limited here, preferably 5 minutes. Specifically, it can be determined whether the terminal is in do not disturb mode within the previous 5 minutes.
[0095] 207. The control terminal performs a reminder operation according to the reminder mode.
[0096] Step 207 is similar to step 104 and will not be described in detail here.
[0097] 208. Change the terminal's prompt mode to Do Not Disturb mode.
[0098] If the prompt mode of the terminal is determined to be the Do Not Disturb mode, the operation of the Do Not Disturb mode is performed. If the prompt mode of the terminal is the Gentle Disturbance mode or the Reminder mode, and the terminal determines that the prompt mode of the terminal has been determined to be the Do Not Disturb mode within the last preset time before the current collection cycle, the terminal changes the prompt mode to the Do Not Disturb mode.
[0099] Specifically, Figure 5As shown, when the terminal is a mobile phone, it can be determined whether the ambient sound type (environment) of the mobile phone has changed according to the adjacent sound parameters of the current collection cycle collected by the microphone on the mobile phone; it can be determined whether the motion state of the mobile phone has changed according to the acceleration sensor on the mobile phone, and the motion state can be understood as the state or position of the mobile phone. In the current collection cycle, it is necessary to judge whether the environment of the mobile phone and the state of the mobile phone have changed. When the environment of the mobile phone and the state or position of the mobile phone have not changed, the prompt mode is determined according to the ambient sound type and spatial scene type obtained in the current collection cycle. If the microphone detects that the environment has changed during the sound collection process of the current collection cycle, the next cycle is detected; if the environment has not changed, the acceleration sensor is used to detect whether there is a change in the state or position of the mobile phone; if there is a change, the next collection cycle is performed again to detect whether the environment has changed. If there is no change, it can be determined that the terminal is in a stable state in the corresponding collection cycle. The prompt mode of the terminal is determined according to the ambient sound type and spatial scene type obtained in the stable state. Before the terminal needs to perform a reminder operation, if the prompt mode of the terminal is determined to be the Do Not Disturb mode, the Do Not Disturb mode operation is performed; if the prompt mode of the terminal is the Gentle Disturbance Mode or the Reminder Mode, it is necessary to determine whether the prompt mode of the terminal is determined to be the Do Not Disturb mode within the preset time before the current collection cycle; if so, the prompt mode of the terminal is modified to the Do Not Disturb mode; if not, it is executed according to the Gentle Disturbance Mode or the Reminder Mode.
[0100] The process of adjusting the terminal volume is described above using the reminder sound as an example. The process of adjusting the terminal volume is described below using the content sound as an example. Figure 3 As shown, the specific steps are as follows:
[0101] 301. Determine the ambient sound type of the environment in which the terminal is currently located and determine a target application used by the terminal to play audio.
[0102] When the terminal determines that the terminal needs to perform an audio playback operation (i.e., play content audio) based on the application on the terminal, the ambient sound type of the current environment can be determined based on the audio acquisition module on the terminal, which is similar to step 102 and will not be repeated here. At the same time, the terminal can determine the target application for playing audio based on the application on the terminal. The target application can be determined based on the program being executed. The target application can be a video playback application or a call application, which is not specifically limited here.
[0103] 302. Determine an audio mode for playing audio on the terminal according to the ambient sound type and the target application.
[0104] After the terminal determines the ambient sound type and target application of the current environment, it determines the audio mode of the terminal to play the audio according to the ambient sound type and the target application. The audio mode refers to the relevant characteristics of the audio, which can be a sound quality priority mode, a volume priority mode, or a strong sound quality and strong volume mode, etc., which are not limited here. At this time, the ambient sound type is mainly divided into a noisy environment or a quiet environment, and the relevant target application can determine the audio mode of the terminal to play the audio.
[0105] 303. Control the terminal to play audio according to the audio mode.
[0106] After the audio mode of the terminal playing the audio is determined, the terminal is controlled to play the audio according to the audio mode. Figure 6 As shown, taking a mobile phone as a terminal, in a detection cycle, if the target application is a video playback application at this time, when the ambient sound type of the mobile phone is detected as being in a quiet environment, it is determined that the audio mode is the sound quality priority mode, and the volume is automatically adjusted to a low level when playing audio to ensure the sound quality of the audio; when the ambient sound type of the mobile phone is detected as being in a noisy environment, it is determined that the audio mode is the volume priority mode, and the volume is automatically adjusted to a medium-high level when playing audio. At the same time, when it is detected that the user is still pressing the volume key +, it is allowed to sacrifice a certain amount of sound quality in the short term to increase the volume to the maximum. If the target application is a microphone (MIC) broadcast or call scenario at this time, it is determined that the audio mode is a strong sound quality and strong volume mode, and noise reduction is used for receiving audio.
[0107] In the implementation of this application, when the terminal needs to play content sound, the audio mode of the terminal is determined by determining the ambient sound type and the target application, and the volume or sound quality of the terminal's external sound can be automatically adjusted according to different audio modes.
[0108] Further, the following uses the mobile phone as the terminal and combines Figure 4 Explain the process of intelligently adjusting the sound of the mobile phone:
[0109] When the sound that the mobile phone needs to play outward is a prompt sound, the type of ambient sound in the environment where the mobile phone is located can be determined based on the sound picked up by the microphone on the mobile phone. The movement state of the mobile phone can also be determined based on the acceleration sensor or displacement sensor on the mobile phone. The ambient sound type and the movement state of the mobile phone are sent to the processor (Sensor Hub) for collection and processing, with environmental detection given priority.
[0110] If the ambient sound type is a single human voice environment dominated by human voices, and the spatial scene type is a conference hall or classroom, the prompt mode of the mobile phone is determined to be the Do Not Disturb mode; if the ambient sound type is a multi-voice environment dominated by human voices, and the spatial scene type is a conference hall or classroom, the prompt mode of the mobile phone is determined to be the Light Disturb mode; if the ambient sound type is a noisy environment dominated by ambient sound, and the spatial scene type is outdoor or commuting, the prompt mode of the mobile phone is determined to be the Reminder mode; if the ambient sound type is a quiet environment, and the accelerometer of the mobile phone determines that the mobile phone is in a stationary state, the prompt mode of the mobile phone is determined to be the Do Not Disturb mode; if the ambient sound type is a quiet environment, and the accelerometer of the mobile phone determines that the mobile phone is in a moving state, the prompt mode of the mobile phone is determined to be the Light Disturb mode. Among them, the Do Not Disturb mode is a vibration reminder, and the vibration gradually increases from weak to strong; the Light Disturb mode is a strong vibration reminder, and a ringtone reminder, and the ringtone gradually increases from weak to strong; the Reminder mode is a strong vibration reminder, and a loud ringtone reminder.
[0111] When the sound that the phone needs to play outward is content sound, the ambient sound type of the phone's environment can be detected based on the sound picked up by the microphone on the phone, or the target application that needs to play content sound outward can be detected based on the program that comes with the phone, and the target application and ambient sound type are sent to the processor for collection and processing. At this time, the application is prioritized. If the target application is an application that plays videos or music, and the ambient sound type is a quiet environment, the audio mode is determined to be a low-volume mode with sound quality priority, and the sound quality is delicate; if the target application is an application that plays videos or music, and the ambient sound type is a noisy environment, the audio mode is determined to be a medium-high volume mode with volume priority, and the volume is louder; if the target application is a voice call application or a microphone call scenario, the audio mode is determined to be a high-quality, high-volume mode with noise reduction, and the background sound is filtered to make the call clear.
[0112] The present application also provides a terminal, such as Figure 8 As shown, including:
[0113] CPU 801, memory 802, input / output interface 803, wired or wireless network interface 804 and power supply 805;
[0114] The memory 802 is a temporary storage memory or a permanent storage memory;
[0115] The central processor 801 is configured to communicate with the memory 802 and execute instructions in the memory 802 to perform the above method for adjusting the terminal volume.
[0116] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0117] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0118] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0119] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0120] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, read-only memory), random access memory (RAM, random access memory), disk or optical disk and other media that can store program code.
Claims
1. A method for adjusting the volume of a terminal, characterized in that: include: Periodically check whether the terminal is in a stable state; When the terminal is in a stable state, determining an ambient sound type of an environment in which the terminal is located and determining a spatial scene type of an environment in which the terminal is located; Determining a prompt mode of the terminal according to the ambient sound type and the spatial scene type; When the terminal needs to perform a reminder operation, controlling the terminal to perform the reminder operation according to the reminder mode; The periodic detection of whether the terminal is in a stable state includes: In a detection cycle, detecting whether the ambient sound type of the environment in which the terminal is located and the motion state of the terminal have changed; If the ambient sound type and the motion state of the terminal do not change, it is determined that the terminal is in a steady state.
2. The method according to claim 1, characterized in that The determining the ambient sound type of the environment in which the terminal is located comprises: Controlling the audio acquisition module of the terminal to acquire sound parameters of the environment in which the terminal is located; The ambient sound type of the environment in which the terminal is located is determined according to the sound parameter.
3. The method according to claim 1, characterized in that The determining the spatial scene type of the environment in which the terminal is located includes: Controlling the audio acquisition module of the terminal to acquire sound parameters of the environment in which the terminal is located; Determining a target sound pressure amplitude of the environment in which the terminal is located according to the sound parameter; A preset spatial scene type whose preset sound pressure amplitude corresponds to the target sound pressure amplitude among multiple preset spatial scene types is determined as the spatial scene type of the environment in which the terminal is located, wherein each preset spatial scene type has at least one corresponding preset sound pressure amplitude.
4. The method according to claim 1, characterized in that: The determining the ambient sound type of the environment in which the terminal is located and the determining the spatial scene type of the environment in which the terminal is located include: Controlling the audio acquisition module of the terminal to acquire multiple sound parameters of the environment in which the terminal is located in a current acquisition cycle; The ambient sound type and the spatial scene type are determined according to the multiple sound parameters in the current collection period.
5. The method according to claim 1, characterized in that The periodically detecting whether the terminal is in a stable state includes: Detecting whether the ambient sound type of the terminal changes according to the adjacent sound parameters collected by the terminal in the current collection period; If the ambient sound type changes, it is determined that the terminal is not in a stable state, and the step of returning to execute the step of detecting whether the ambient sound type of the terminal changes according to the adjacent sound parameters of the terminal in the next collection cycle; If the ambient sound type has not changed, detecting whether the motion state of the terminal has changed according to the previous displacement parameter and the next displacement parameter of the terminal in the current collection period; If the motion state of the terminal does not change, determining that the terminal is in a stable state; If the motion state of the terminal changes, it is determined that the terminal is not in a stable state, and the process returns to the step of detecting whether the ambient sound type of the terminal changes according to adjacent sound parameters of the terminal in the next acquisition cycle.
6. The method according to claim 5, characterized in that After determining the prompt mode of the terminal according to the ambient sound type and the spatial scene type, and before controlling the terminal to perform the prompt operation according to the prompt mode when the terminal needs to perform the prompt operation, the method further includes: If the prompt mode of the terminal is a gentle disturbance mode or a reminder mode, determining whether the prompt mode of the terminal is determined to be a do not disturb mode within a preset time period before the current collection period; If so, the prompt mode of the terminal is changed to the do not disturb mode.
7. The method according to claim 1, characterized in that The determining, according to the ambient sound type and the spatial scene type, a prompt mode of the terminal includes: If the ambient sound type is a single human voice environment dominated by human voices, and the spatial scene type is a conference hall or a classroom, determining that the prompt mode of the terminal is a do not disturb mode; If the ambient sound type is a multi-voice environment dominated by human voices, and the spatial scene type is a conference hall or a classroom, determining that the prompt mode of the terminal is a gentle disturbance mode; If the ambient sound type is a noisy environment dominated by ambient sound, and the spatial scene type is outdoor, determining that the prompt mode of the terminal is a reminder mode; If the ambient sound type is a quiet environment, and the acceleration sensor of the terminal determines that the terminal is in a stationary state, determining that the prompt mode of the terminal is a do not disturb mode; If the ambient sound type is a quiet environment, and the acceleration sensor of the terminal determines that the terminal is in a moving state, then the prompt mode of the terminal is determined to be a gentle disturbance mode.
8. A method for adjusting the volume of a terminal, characterized in that: include: When the terminal needs to perform an audio playback operation, periodically detecting whether the terminal is in a stable state; When the terminal is in a stable state, determining the ambient sound type of the environment in which the terminal is currently located and determining a target application for the terminal to play audio; Determining, according to the ambient sound type and the target application, an audio mode in which the terminal plays the audio; Controlling the terminal to play audio according to the audio mode; The periodic detection of whether the terminal is in a stable state includes: In a detection cycle, detecting whether the ambient sound type of the environment in which the terminal is located and the motion state of the terminal have changed; If the ambient sound type and the motion state of the terminal do not change, it is determined that the terminal is in a steady state.
9. The method according to claim 8, characterized in that The determining, according to the ambient sound type and the target application, the audio feature when the terminal plays the audio includes: If the target application is an application for playing videos or music, and the ambient sound type is a quiet environment, determining that the audio mode is a low volume mode that prioritizes sound quality; If the target application is an application for playing videos or music, and the ambient sound type is a noisy environment, determining that the audio mode is a medium-high volume mode with volume priority; If the target application is a voice call application, the audio mode is determined to be a high-quality, high-volume mode with noise reduction.
10. A terminal, characterized in that: include: CPU, memory, input and output interfaces, wired or wireless network interfaces, and power supply; The memory is a short-term storage memory or a persistent storage memory; The central processing unit is configured to communicate with the memory and execute instructions in the memory to perform the method according to any one of claims 1 to 9.
