Volume control method, electronic device, and related apparatus
By adjusting the volume control method in electronic devices, the problem of fluctuating volume caused by changes in audio source switching has been solved, ensuring that the audio decibel level matches the user's needs and improving the user experience.
Patent Information
- Application Number
- PCT/CN2025/099585
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2024-07-04
- Filing Date
- 2025-06-06
- Publication Date
- 2026-01-08
AI Technical Summary
When switching audio sources on electronic devices, volume changes cause the audio volume to fluctuate, affecting the user experience.
By adjusting the volume control method, electronic devices can play the same type of audio at different volumes when switching audio sources, ensuring that the decibel levels are the same or similar, and adapting to the user's preferred decibel range.
This avoids the problem of fluctuating volume when switching audio sources, thus improving the user experience.
Smart Images

Figure CN2025099585_08012026_PF_FP_ABST
Abstract
Description
Volume control method, electronic device and related apparatus
[0001] The present application claims priority to the Chinese patent application No. 202410890939.3, filed on July 4, 2024, and entitled "Volume control method, electronic device and related apparatus", the content of which is incorporated herein by reference in its entirety. TECHNICAL FIELD
[0002] Embodiments of the present application relate to the technical field of multi-device interaction, and in particular to a volume control method, an electronic device and related apparatus. BACKGROUND
[0003] With the development of electronic devices, for example, a connection can be established between a first electronic device and a second electronic device, and the second electronic device can also cast to the first electronic device or cast sound to the first electronic device, so that the first electronic device can play audio from the second electronic device. In addition, the second electronic device can also play local audio.
[0004] Currently, when the first electronic device switches the audio source, for example, the first electronic device switches from playing local audio to playing audio from the second electronic device, or the first electronic device switches from playing audio from the second electronic device to playing local audio, etc., the first electronic device plays the audio at the same local volume, which can cause the user to hear the audio at different volumes, affecting the user experience. SUMMARY
[0005] Embodiments of the present application provide a volume control method, an electronic device and related apparatus. In the scenario of audio source switching, the electronic device can play audio at different volumes, so that the decibels of the audio played by the first electronic device are the same or similar, so that the decibels of the audio heard by the user are within the user's habituated decibel range, avoiding the problem of the decibels of the audio being too large or too small when the audio source is switched.
[0006] In a first aspect, embodiments of the present application provide a volume control method. The execution subject of the method can be a first electronic device or a chip in the first electronic device, etc. The following is described by taking the first electronic device as an example. In the method, the first electronic device can play first audio from a first audio source at a first volume. When it is detected that the first audio source is switched to a second audio source, the first electronic device can play second audio from the second audio source at a second volume.
[0007] The type of the first audio is the same as the type of the second audio. The first electronic device plays the first audio at a first volume, and the first electronic device plays the second audio at a second volume. A difference between the first volume and the second volume is less than or equal to a first threshold.
[0008] In the implementation method, in a scenario of audio source switching, the first electronic device can play the same type of audio at different volumes, so that the first electronic device plays the same type of audio at the same or similar decibels, so that the user hears the same type of audio at the decibels within the user's habit range, and the problem of large or small decibels of the audio source switching is avoided.
[0009] In a possible implementation, the first audio source is the first electronic device, and the second audio source is a second electronic device. In this scenario, switching from the first audio source to the second audio source can be understood as switching from a local audio source to a remote audio source. Alternatively,
[0010] The first audio source is the second electronic device, and the second audio source is the first electronic device or a third electronic device. When the second audio source is the first electronic device, switching from the first audio source to the second audio source can be understood as switching from a remote audio source to a local audio source. When the second audio source is the third electronic device, switching from the first audio source to the second audio source can be understood as switching from one remote audio source to another remote audio source.
[0011] In this implementation, the volume control method provided by the embodiments of the present application can be applied to a variety of audio source switching scenarios, and has a wide range of applications.
[0012] In a possible implementation, after the first electronic device plays the first audio from the first audio source at a first volume, when it is detected that the first audio is switched to third audio from the first audio source, the first electronic device can play the third audio at a third volume. The type of the first audio is different from the type of the third audio.
[0013] In this implementation, when the audio source does not change and the type of the audio changes, the first electronic device can also play the audio at different volumes, which can adapt to the user's decibel requirements for different types of audio and improve the user experience.
[0014] In a possible implementation, after the first electronic device plays the first audio from the first audio source at the first volume, when it is detected that the fourth audio from the first audio source is switched from the first audio, the first electronic device can play the fourth audio at the first volume, and the type of the first audio is the same as the type of the fourth audio.
[0015] In this implementation, when the audio source does not change and the type of the audio does not change, the first electronic device can also play the audio at the same volume, which can adapt to the decibel requirement of the user for the type of audio and improve the user experience.
[0016] In a possible implementation, the first electronic device can play the first audio from the first audio source at the first volume. When it is detected that the second audio source is switched from the first audio source, the first electronic device can play the sixth audio at the sixth volume, and the type of the sixth audio is different from the type of the first audio.
[0017] In this implementation, when the audio source changes and the type of the audio changes, the first electronic device can also play the audio at different volumes, which can adapt to the decibel requirement of the user for the type of audio of the audio source and improve the user experience.
[0018] To sum up, in the embodiments of the present application, the first electronic device can adjust the volume of the first electronic device based on the audio source and the type of the audio, to enable the volume of the first electronic device to play the audio to be more adapted to the different requirements of the user for the audio source and the type of the audio, and to improve the user experience.
[0019] In a possible implementation, the first electronic device plays the fifth audio from the first audio source at the fourth volume, the type of the first audio is the same as the type of the fifth audio, the decibel of playing the fifth audio at the fourth volume is the third decibel, and the difference between the first decibel and the third decibel is greater than the first threshold. In response to the operation of the user adjusting the volume of the first electronic device, the first electronic device can adjust the fourth volume to the first volume, and the first electronic device can store the first audio source, the type of the fifth audio, and the first volume correspondingly.
[0020] In this implementation, when playing a type of audio of an audio source, the first electronic device can determine the volume corresponding to the type of audio of the audio source according to the operation of the user adjusting the volume. When the first electronic device plays the type of audio of the audio source next time, the first electronic device can play the audio at the volume, to enable the decibel of the audio to adapt to the user.
[0021] In a possible implementation, the first electronic device correspondingly storing the first audio source, the type of the fifth audio, and the first volume includes: correspondingly storing the first audio source, the type of the fifth audio, and the first volume when at least one of the following conditions is met. The conditions can include: a time length of playing audio of the same type as the fifth audio at the first volume is greater than or equal to a preset time length; or the fifth audio is played completely at the first volume.
[0022] In this implementation, in response to the operation of the user adjusting the fourth volume to the first volume, the first electronic device can determine to correspondingly store the first audio source, the type of the fifth audio, and the first volume when a certain condition is met, which can not only reduce the number of times of updating the volume of the type of the fifth audio of the first audio source by the first electronic device, reduce the workload of the first electronic device, but also enable the volume of the type of the fifth audio of the first audio source stored by the first electronic device to be more suitable for the user.
[0023] In a possible implementation, before the first electronic device plays the first audio from the first audio source at the first volume, the first electronic device can determine the first volume corresponding to the first audio source and the type of the first audio according to the correspondence between the first audio source, the type of the fifth audio, and the first volume. In this way, the first electronic device can play the first audio at the first volume.
[0024] In a possible implementation, the first electronic device can constantly update the correspondence between the audio source, the type of the audio, and the volume of the first electronic device, so that the correspondence can adapt to new needs of the user. For example, after the first electronic device plays the first audio from the first audio source at the first volume, in response to the operation of the user adjusting the volume of the first electronic device, the first electronic device can adjust the first volume to the fifth volume, and the first electronic device can update the correspondence between the first audio source, the type of the fifth audio, and the first volume to the correspondence between the first audio source, the type of the fifth audio, and the fifth volume.
[0025] After the first electronic device updates the correspondence between the first audio source, the type of the fifth audio, and the fifth volume, when the first electronic device plays the fourth audio from the first audio source, the first electronic device can play the fourth audio at the fifth volume. The type of the first audio is the same as the type of the fourth audio. In some embodiments, the decibel of the first electronic device playing the first audio at the fifth volume is the fourth decibel, and the difference between the first decibel and the fourth decibel is less than or equal to the first threshold value.
[0026] In this implementation, the first electronic device can constantly update the correspondence between the audio source, the audio type, and the volume of the first electronic device, so that the correspondence can adapt to the user's needs for decibels of different audio sources and different audio types.
[0027] In a possible implementation, because the user can adjust the volume of the first electronic device through the first electronic device, a protection strategy can be deployed in the first electronic device. In response to the user's operation of adjusting the volume of the first electronic device, when it is determined that the volume of the first electronic device reaches the protection volume of the first electronic device, the first electronic device can output prompt information for prompting the user whether to continue adjusting the volume of the first electronic device.
[0028] In this implementation, in the process of the user adjusting the volume of the first electronic device, the first electronic device can also output prompt information to prompt the user whether to continue adjusting the volume of the first electronic device when the volume of the first electronic device reaches the protection volume. The user can be timely notified, and the user experience is improved.
[0029] In a second aspect, the embodiments of the present application provide an electronic device, including a processor and a memory, the memory is used to store code instructions, and the processor is used to run the code instructions to execute the method described in the first aspect or any possible implementation of the first aspect.
[0030] In the second aspect, the electronic device is the first electronic device in the first aspect.
[0031] In a third aspect, the embodiments of the present application provide a computer readable storage medium, and the computer readable storage medium stores computer programs or instructions. When the computer programs or instructions run on a computer, the computer executes the method described in the first aspect or any possible implementation of the first aspect.
[0032] In a fourth aspect, the embodiments of the present application provide a computer program product including a computer program. When the computer program runs on a computer, the computer executes the method described in the first aspect or any possible implementation of the first aspect.
[0033] In a fifth aspect, the present application provides a chip or a chip system, which includes at least one processor and a communication interface. The communication interface and the at least one processor are interconnected through a line. The at least one processor is used to run computer programs or instructions to execute the method described in the first aspect or any possible implementation of the first aspect. The communication interface in the chip can be an input / output interface, a pin, or a circuit, etc.
[0034] In a possible implementation, the chip or the chip system described above in the application further includes at least one memory in which instructions are stored. The memory can be a storage unit inside the chip, for example, a register, a cache, etc., or a storage unit of the chip (for example, a read-only memory, a random access memory, etc.).
[0035] It should be understood that the second aspect to the fifth aspect of the application correspond to the technical solutions of the first aspect of the application, and the beneficial effects obtained by each aspect and the corresponding feasible implementation are similar, which will not be repeated. BRIEF DESCRIPTION OF DRAWINGS
[0036] FIG. 1 is a schematic diagram of a scenario to which the volume control method provided by the embodiments of the application is applicable;
[0037] FIG. 2 is a schematic diagram of a decibel of audio played by a car machine from a mobile phone;
[0038] FIG. 3 is a schematic diagram of a structure of a first electronic device and a second electronic device provided by the embodiments of the application;
[0039] FIG. 4 is a schematic diagram of a flow of an embodiment of the volume control method provided by the embodiments of the application;
[0040] FIG. 5 is a schematic diagram of a flow of another embodiment of the volume control method provided by the embodiments of the application;
[0041] FIG. 6 is a schematic diagram of the car machine playing the same type of audio when switching the audio source according to the embodiments of the application;
[0042] FIG. 7 is a schematic diagram of the car machine playing different types of audio when switching the audio source according to the embodiments of the application;
[0043] FIG. 8 is a schematic diagram of a structure of a first electronic device provided by the embodiments of the application;
[0044] FIG. 9 is a schematic diagram of a structure of a second electronic device provided by the embodiments of the application. DETAILED DESCRIPTION
[0045] For the convenience of understanding, the related terms and concepts involved in the embodiments of the application are introduced as follows:
[0046] 1. Audio source: In an audio playing scenario, the audio source refers to an electronic device used to provide audio. For example, taking a car machine as an electronic device, the car machine plays audio using an audio player built-in the car machine, and the car machine can be regarded as an audio source. For example, in a delivery scenario, taking a mobile phone as an example, the car machine can play audio from the mobile phone, although the car machine plays the audio, the audio comes from the mobile phone, and the mobile phone can be regarded as an audio source.
[0047] In some embodiments, the casting can include screen casting or sound casting. The screen casting can be understood as casting video (including audio and video pictures), and the sound casting can be understood as casting only audio.
[0048] 2. Volume: refers to the relative value of the volume on the electronic device. In some embodiments, the current volume in the electronic device can be normalized to 0-100%, for example, the volume of the electronic device can be 50%.
[0049] 3. Decibel: refers to the size of the sound of the audio played by the electronic device. The larger the decibel, the louder the sound of the audio heard by the user, and the smaller the decibel, the smaller the sound of the audio heard by the user.
[0050] For example, 40-60 decibels is the size of the sound of ordinary indoor conversation in general, and the sound is suitable when using earphones. More than 70 decibels will make people feel irritable and not concentrate. If the noise reaches more than 80 decibels, long-term stimulation of persistent noise can cause damage to the cochlea and spiral nerve, causing noise-induced hearing loss. Generally, when the sound reaches 85-90 decibels, it can affect the user's hearing.
[0051] 4. Electronic device: the electronic device in the embodiments of the present application can be referred to as a user equipment (user equipment, UE), a terminal, etc. For example, the electronic device can be a mobile phone, a tablet computer (portable android device, PAD), a personal digital assistant (personal digital assistant, PDA), a handheld device with wireless communication function, a computing device, a vehicle-mounted device, or a wearable device, a virtual reality (virtual reality, VR) terminal device, an augmented reality (augmented reality, AR) terminal device, a wireless terminal in industrial control, a wireless terminal in smart home, etc. The form of the electronic device is not limited in the embodiments of the present application.
[0052] FIG. 1 is a schematic diagram of a scenario to which the volume control method provided by the embodiments of the present application is applicable. The volume control method provided by the embodiments of the present application is applicable to a casting scenario. Referring to FIG. 1, the scenario can include a first electronic device 100 and a second electronic device 200.
[0053] In some embodiments, the second electronic device 200 can be referred to as a casting device, and the first electronic device 100 can be referred to as a castee. The second electronic device 200 can cast a video or audio to the first electronic device 100. It should be understood that the video can include audio, and the volume control method of the audio can refer to the description of the volume control method in the embodiments of the present application. In the following embodiments, the second electronic device 200 casts audio to the first electronic device 100, which can be separate audio or audio carried in a video.
[0054] In some embodiments, the second electronic device 200 can be, for example, a mobile phone, a PAD, a personal computer (PC), a wearable device, or an electronic device with a casting function. In some embodiments, the second electronic device 200 also has an audio playing function. For example, the second electronic device 200 can be provided with a speaker (or a loudspeaker) or an audio playing module to realize the audio playing function of the second electronic device 200. The embodiments of the present application do not limit the hardware related to the audio playing function of the second electronic device 200.
[0055] The first electronic device 100 can be, for example, a car machine, a sound box, a television, a VR device, an AR device, or an electronic device with an audio playing function. For example, the first electronic device 100 can be provided with a speaker (or a loudspeaker) or an audio playing module to realize the audio playing function of the first electronic device 100. The embodiments of the present application do not limit the hardware related to the audio playing function of the first electronic device 100.
[0056] The embodiments of the present application do not limit the form of the first electronic device 100 and the second electronic device 200.
[0057] In FIG. 1 and the following embodiments, the second electronic device 200 is taken as a mobile phone, and the first electronic device 100 is taken as a car machine.
[0058] In some embodiments, the first electronic device and the second electronic device can be interconnected through a communication network to realize the casting of audio and video. The communication network can be, but is not limited to, a WI-FI hotspot network, a WI-FI peer-to-peer (P2P) network, a Bluetooth network, a zigbee network, or a near field communication (NFC) network.
[0059] The following describes the current volume control method in combination with the scenario shown in FIG. 1.
[0060] The car machine can play local audio. For example, the car machine can play audio by using the audio player of the car machine. In the scenario that the mobile phone connects the car machine, the mobile phone can send audio to the car machine, and the car machine can play the audio from the mobile phone, that is, the car machine can play the audio sent by the mobile phone. In other words, the car machine can not only play local audio, but also play remote audio. In some embodiments, the remote audio can be understood as audio sent by other devices to the car machine.
[0061] Both the mobile phone and the car machine have a volume adjustment function. For example, the user can operate the physical button on the car machine or the volume bar on the interface of the car machine to adjust the volume of the audio played by the car machine to adjust the decibels of the audio. In the scenario that the mobile phone sends audio to the car machine, on the one hand, the user can operate the physical button on the mobile phone or the volume bar on the interface of the mobile phone to adjust the volume of the audio played by the car machine, and on the other hand, the user can also operate the physical button on the car machine or the volume bar on the interface of the car machine to adjust the volume of the audio played by the car machine.
[0062] It should be understood that the user can also adjust the volume of the audio played by the car machine by using voice, air gestures, etc., which are not limited in the embodiments of the present application.
[0063] In some embodiments, in order to protect the hearing of the user, the volume protection function is deployed in the electronic device (car machine, mobile phone). For example, when the volume of the car machine reaches the protection volume of the car machine, the car machine can output a prompt information to prompt the user whether to confirm to play at the volume. Or, when the volume of the car machine reaches the protection volume of the car machine and the user is still adjusting to increase the volume, the car machine can output a prompt information to prompt the user whether to confirm to continue to increase the volume.
[0064] Referring to FIG. 2, for example, the volume of the mobile phone is X%, and the volume of the car machine is Y%. In the scenario that the mobile phone sends audio to the car machine, the mobile phone can send the audio to the car machine. In response to the audio from the mobile phone, the car machine can play the audio at the volume Y%, and the decibels of the audio can be determined by the gain of the audio and the volume Y% of the car machine.
[0065] In some embodiments, the decibels of the audio can be positively correlated with the gain of the audio and the volume Y% of the car machine. For example, the higher the gain of the audio, that is, the larger the volume X% of the mobile phone, the larger the decibels of the audio. The larger the volume Y% of the car machine, the larger the decibels of the audio. Because the gain of the audio is positively correlated with the volume X% of the mobile phone, because the decibels of the audio can be positively correlated with the volume X% of the mobile phone and the volume Y% of the car machine.
[0066] In some embodiments, the decibels of the audio played by the car machine can be X% x Y%, for example.
[0067] In the scenario shown in FIG. 2, if the volume of the mobile phone is small, in order to ensure that the audio can be heard, or to enable the decibel of the audio to be in a suitable range, the user usually adjusts the volume of the car kit to be large, even exceeding the protection volume of the car kit. In this case, when switching from playing remote audio to playing local audio, because the volume of the car kit is adjusted to be large by the user, the car kit will play the local audio at a large volume, which may damage the hearing of the user, and the user experience is poor.
[0068] In some embodiments, after the mobile phone is connected with the car kit, the car kit and the mobile phone can negotiate, and the mobile phone adjusts the volume of the mobile phone to be 100%, that is, the volume X% of the mobile phone is 100%. Because the volume of the mobile phone is 100%, in this case, the user can adjust the volume of the car kit to adjust the decibel of the audio played by the car kit. For example, the volume of the car kit is Y%, and the decibel of the audio played by the car kit can be Y%.
[0069] In this example, the user can adjust the volume of the car kit to adjust the decibel of the audio played by the car kit. When the volume of the car kit exceeds the protection volume, the car kit can prompt the user not to adjust any more, so as to avoid the problem that the volume of the car kit is too large when switching from playing remote audio to playing local audio. However, the method in this example is only applicable to the scenario that the mobile phone side supports absolute volume, which is not supported by all mobile phones, and the applicable range is limited.
[0070] In the scenario that the car kit switches from playing remote audio to playing local audio, in order to avoid the problem that the volume of the car kit is too large after switching, in some embodiments, when the car kit switches from playing remote audio to playing local audio, the car kit can detect the volume of the car kit, and when the volume of the car kit is greater than the protection volume of the car kit, the car kit can automatically reduce the volume to the protection volume, and play the audio at the protection volume. In this way, the car kit can avoid playing the local audio at a large volume, avoid damaging the hearing of the user, and improve the user experience.
[0071] In this example, the mobile phone can be regarded as a first audio source, and the car kit can be regarded as a second audio source, or in other words, when switching from the first audio source to the second audio source, the car kit can start the volume protection strategy. The volume protection strategy can include that the car kit can detect the volume of the car kit, and when the volume of the car kit is greater than the protection volume of the car kit, the car kit can automatically reduce the volume to the protection volume, and play the audio at the protection volume.
[0072] In some embodiments, the volume protection strategy can further include that the car kit outputs prompt information for prompting the user that the volume of the car kit is too large and has been reduced to the protection volume. In this example, the car kit can inform the user of the volume protection strategy, and the user experience can be further improved.
[0073] As introduced in the above examples, in the scenario of switching from playing remote audio to playing local audio, the car machine can automatically reduce the volume to the protection volume through the volume protection strategy. This solution can guarantee the basic needs of users, such as the volume not being too large to damage the hearing of users. However, in some embodiments, the decibels of audio that users are accustomed to are different. For example, for some users, the protection volume is still too large, but for some users, the protection volume is relatively appropriate.
[0074] Because the decibels of audio that users are accustomed to are different, for the same type of audio, when the audio source is switched, for example, the car machine is switched from playing remote audio to playing local audio, even if the remote audio and the local audio played by the car machine are the same type of audio, but the car machine plays the audio at the same volume, which can cause the user to hear the sound (decibels) of the audio to be large or small, affecting the user experience.
[0075] For example, the volume of the mobile phone is 30%, and the volume of the car machine is 60%. When the car machine plays the audio (such as media audio) put by the mobile phone, the decibels of the audio can be 30% x 60% = 18%. When the car machine switches to play local audio (such as media audio), the car machine plays the audio at a volume of 60%, which can be regarded as the decibels of the audio being 60%. In this example, when the car machine switches the audio source, even if the types of audio played by the car machine are the same, but the decibels of the audio are different, the problem of the decibels of the audio being large or small when the audio source is switched occurs.
[0076] Based on this problem, the embodiments of the present application provide a volume control method. In the scenario of switching the audio source, even if the volumes of the audio sources are different, for the same type of audio, the first electronic device can play the same type of audio at different volumes, so that the decibels of the same type of audio played by the first electronic device are the same or similar, so that the decibels of the same type of audio heard by the user are always within the range of the decibels that the user is accustomed to, avoiding the problem of the decibels of the audio being large or small when the audio source is switched, and improving the user experience.
[0077] In addition, for different types of audio, the needs of users for the decibels of the audio are also different. For example, the types of audio are divided into soft type audio, rock type audio, and the like. For example, users demand to play soft music at a lower decibel, so as to enjoy the emotions expressed by the audio. Users demand to play rock type audio at a higher decibel, so as to experience the emotions.
[0078] For example, the types of audio are divided into media audio, navigation audio, voice audio, call audio, and alarm audio. For example, users demand to play media audio at a lower decibel, so as to enjoy the emotions expressed by the audio. Users demand to play voice audio at a higher decibel, so as to clearly communicate with the voice.
[0079] In the embodiments of the present application, other ways can also be used to divide the types of audio, and the above are two examples of division methods. It should be understood that in the following embodiments, the types of audio include media audio, navigation audio, voice audio, call audio, alarm audio, and the like are taken as examples to introduce the volume control method provided by the embodiments of the present application. For users, different types of audio require different decibels when playing.
[0080] Accordingly, in the volume control method provided by the embodiments of the present application, for different types of audio, in the scenario of audio source switching, the electronic device can also adjust the volume of the playing audio, so that the decibels of the audio of this type can be adapted to the user.
[0081] In order to facilitate understanding of the volume control method provided by the embodiments of the present application, first, the structure of the first electronic device and the second electronic device will be introduced in combination with FIG. 3.
[0082] The second electronic device can include different types of audio playing applications. Taking the second electronic device as a mobile phone as an example, referring to FIG. 3, the second electronic device can include: a media application, a telephone application, an instant messaging application, a navigation application, and the like. The media application can include but is not limited to: an audio application, a video application, an audio book application, and the like. Among them, the audio output by the media application can be referred to as media audio, the audio output by the instant messaging application can be referred to as voice audio, the audio output by the telephone application can be referred to as call audio, and the audio output by the navigation application can be referred to as navigation audio.
[0083] In some embodiments, the second electronic device can output alarm audio, which can be, for example, earthquake warning, system warning, three-party application warning, and the like. Different alarm audio can come from different applications, and it should be understood that the alarm application of the second electronic device is not shown in FIG. 3.
[0084] The first electronic device can include different types of first audio playing applications and different types of second audio playing applications. Among them, the first audio playing application can be regarded as a local audio playing application of the first electronic device, and the second audio playing application can be regarded as a remote audio playing application for interfacing with the second electronic device (or other electronic device).
[0085] Taking the first electronic device as a car machine as an example, referring to FIG. 3, the first audio playing application can include: a media application, a telephone application, a voice assistant application, a navigation application, a car alarm application, and the like. The second audio playing application can include: a media application, a telephone application, and an interconnection application, and the like. Among them, the media application in the car machine is used to interface with the media application in the mobile phone, the telephone application is used to interface with the telephone application in the mobile phone, and the interconnection application can be used to interface with the instant messaging application, the navigation application, and the like.
[0086] In some embodiments, the first electronic device can include a volume control policy. In a scenario where the second electronic device plays audio to the first electronic device, the first electronic device can play the audio based on the volume control policy. For example, refer to the steps performed by the first electronic device in the following embodiments.
[0087] In some embodiments, the first electronic device can determine the type of the audio. For example, for local audio, the first electronic device can determine the type of the audio according to the application of the source of the audio. For example, if the audio played by the first electronic device is from a first audio playing application of a media type, the first electronic device can determine that the type of the audio is media audio. For example, if the audio played by the first electronic device is from a first audio playing application of a phone type, the first electronic device can determine that the type of the audio is call audio.
[0088] For remote audio, refer to FIG. 3. For a second audio playing application of a media type and a second audio playing application of a phone type, the first electronic device can determine the type of the audio according to the application of the source of the audio.
[0089] In some embodiments, for remote audio, in a scenario where the second electronic device plays audio (e.g., media audio) to the first electronic device, the second electronic device can send the audio to the first electronic device, and carry the type of the audio. The first electronic device can determine the type of the remote audio according to the type of the audio carried by the audio.
[0090] In some embodiments, refer to FIG. 3. After determining the type of the remote audio, the first electronic device can transmit the audio to a second audio playing application of a corresponding type (e.g., a second audio playing application of a media type in a car machine), and then the second audio playing application can transmit the audio to a loudspeaker for playing. In FIG. 3, the transmission process of the media audio is represented by a dashed line.
[0091] In some embodiments, the first electronic device can also determine the audio source of the audio. When playing the audio, the first electronic device can determine whether the audio source is local or remote according to the application corresponding to the audio. For example, if the audio is from a first audio playing application, the first electronic device can determine that the audio is local audio, and the audio source is the first electronic device. For example, if the audio is from a second audio playing application, the first electronic device can determine that the audio is remote audio. After determining that the audio is remote audio, the first electronic device can further determine the audio source according to the device identifier carried by the audio.
[0092] Referring to FIG. 3, the second electronic device can send audio to the first electronic device, and the audio can carry not only the type of the audio but also the identity of the second electronic device. In this embodiment of this application, after the first electronic device determines that the audio is remote audio based on the application corresponding to the audio, the first electronic device can further determine that the audio source is the second electronic device according to the identity of the second electronic device carried by the audio.
[0093] It is conceived that, in addition to establishing a connection with the second electronic device and receiving audio from the second electronic device, the first electronic device (such as a car machine) can also establish a connection with a third electronic device and receive audio from the third electronic device. In the scenario where the third electronic device sends audio to the first electronic device, the first electronic device can determine that the audio source is the third electronic device. For details, refer to the description of the first electronic device determining that the audio source is the second electronic device.
[0094] Similarly, FIG. 3 also shows the structure of the third electronic device. For details, refer to the description of the second electronic device.
[0095] The volume control method provided in this embodiment of this application is described below in combination with specific embodiments. The following embodiments can be combined with each other, and the same or similar concepts or processes can not be described in some embodiments.
[0096] FIG. 4 is a flowchart of one embodiment of the volume control method provided in this embodiment of this application. Referring to FIG. 4, the volume control method provided in this embodiment of this application can include the following steps.
[0097] S401, the first electronic device plays first audio from a first audio source at a first volume.
[0098] S402, when detecting that the first audio source is switched to a second audio source, the first electronic device plays second audio from the second audio source at a second volume, the type of the first audio is the same as the type of the second audio, wherein the decibel of the first audio played at the first volume is a first decibel, the decibel of the second audio played at the second volume is a second decibel, and the difference between the first decibel and the second decibel is less than or equal to a first threshold.
[0099] The volume control method provided in the embodiments of the present application is applicable to a delivery scenario, and in particular to a scenario of audio source switching in the delivery scenario. In S401 and S402, the first electronic device plays audio, and the first audio source is switched to the second audio source as an example. It can be understood that, with reference to the description in FIG. 3, the first electronic device can determine the audio source, and when the audio source changes, the first electronic device can determine that the audio source is switched, that is, the first electronic device can determine the new audio source. Accordingly, the first electronic device can detect that the first audio source is switched to the second audio source.
[0100] In the embodiments of the present application, the switching of the audio source can include: switching from local to remote, switching from remote to local, or switching from remote 1 to remote 2.
[0101] For example, the first electronic device is a car machine, the first audio source can be the car machine (local), and the second audio source can be remote. For example, the second audio source can be a second electronic device or a third electronic device.
[0102] For example, the first electronic device is a car machine, the first audio source can be a second electronic device (remote 1), the second audio source can be the first electronic device (car machine local), or the second audio source can be another electronic device connected to the car machine, such as a third electronic device (remote 2).
[0103] In S401, the first electronic device can play first audio from the first audio source at a first volume. In S402, when the first electronic device detects that the first audio source is switched to the second audio source, the first electronic device can adjust the volume, and play second audio from the second audio source at a second volume.
[0104] In the embodiments of the present application, the type of the first audio is the same as the type of the second audio. The decibel at which the first electronic device plays the first audio at the first volume is the first decibel, the decibel at which the first electronic device plays the second audio at the second volume is the second decibel, and the difference between the first decibel and the second decibel is less than or equal to the first threshold. The difference between the first decibel and the second decibel being less than or equal to the first threshold can be understood as that the decibel at which the first electronic device plays the first audio and the decibel at which the first electronic device plays the second audio are within a preset range.
[0105] In other words, in the scenario of playing the same type of audio, when the audio source is switched, the first electronic device can adjust the volume to enable the decibel of the played audio to be within a preset range, which can avoid the problem that the sound of the same type of audio is large and small when the audio source is switched, and can improve the user experience.
[0106] In some embodiments, the first electronic device can store the volume of each type of audio of the first audio source and the volume of each type of audio of the second audio source. Taking the volume of each type of audio of the first audio source as an example, the volume can be understood as the volume of the first electronic device when playing each type of audio of the first audio source.
[0107] The volume of each type of audio of the first audio source and the volume of each type of audio of the second audio source can be preconfigured in the first electronic device based on empirical values or big data calculation, or be customized and set by the user on the first electronic device. Alternatively, to achieve simplicity and simplify the operation of the user, in some embodiments, the volume of each type of audio of the first audio source and the volume of each type of audio of the second audio source can also be obtained based on the user's operation of adjusting the volume when the first electronic device historically plays different types of audio.
[0108] In this embodiment, when playing the first audio, the first electronic device can query the stored "volume of each type of audio of the first audio source", determine the first volume, and play the first audio at the first volume. Similarly, when switching from the first audio source to the second audio source, the first electronic device can query the stored "volume of each type of audio of the second audio source", determine the second volume, and play the second audio at the second volume.
[0109] Regardless of how the volume of each type of audio of the first audio source and the volume of each type of audio of the second audio source are obtained, for the same type of audio, the volume of the first electronic device when playing the audio of the first audio source or the second audio source is adapted to the user, that is, the decibel of the first electronic device playing the audio is adapted to the user, so that the user does not feel the problem of the sound being too loud or too soft when the audio source is switched.
[0110] In the embodiments of the present application, in the scenario of audio source switching, for the same type of audio, the first electronic device can play the same type of audio at different volumes, so that the decibel of the first electronic device playing the same type of audio is the same or similar, so that the user hears the decibel of the same type of audio always within the user's habit decibel range, avoiding the problem of the decibel of the audio being too loud or too soft when the audio source is switched, and improving the user experience.
[0111] The method of "obtaining the volume of each type of audio of different audio sources based on the user's operation of adjusting the volume when the first electronic device historically plays different types of audio of different audio sources" will be described in detail below:
[0112] It can be understood that, for example, in a scenario where the mobile phone plays audio to the car machine, if the car machine plays audio at a large decibel, the user usually adjusts the volume of the car machine to reduce the decibel of the audio played by the car machine. If the car machine plays audio at a small decibel, the user usually adjusts the volume of the car machine to increase the decibel of the audio played by the car machine, so that the decibel of the audio played by the car machine can be adapted to the user, and the decibel of the audio heard by the user is within a suitable range. It should be understood that, for the same user, for the same type of audio, the decibel of the audio required by the user is usually within a preset range, so that after the user adjusts the volume of the car machine, the decibel of the car machine playing the type of audio is also usually within a preset range, and the user will not feel that the sound is too large or too small.
[0113] Accordingly, in the embodiments of the present application, when playing a type of audio of a certain audio source, the first electronic device can determine the volume corresponding to the type of audio of the audio source according to the operation of the user adjusting the volume. When the first electronic device plays the type of audio of the audio source next time, the first electronic device can play the audio at the volume, so that the decibel of the audio can be adapted to the user. The following will be described with reference to FIG. 5, taking a scenario where the mobile phone (second electronic device) plays audio to the car machine (first electronic device) as an example:
[0114] Referring to FIG. 5, the volume control method provided by the embodiments of the present application can include:
[0115] S501, the first electronic device plays the fifth audio from the first audio source at the fourth volume, and the type of the first audio is the same as the type of the fifth audio.
[0116] S502, in response to the operation of the user adjusting the volume of the first electronic device, the first electronic device adjusts the fourth volume to the first volume.
[0117] S503, the first electronic device stores the first audio source, the type of the fifth audio, and the first volume.
[0118] 1), in the scenario where the mobile phone plays audio to the car machine, taking the audio as a media audio for example, the car machine can play the media audio from the mobile phone at the fourth volume. For example, the decibel of the car machine playing the media audio is the third decibel at the fourth volume.
[0119] In S501, when the car machine plays the media audio (such as the fifth audio) of the mobile phone at the fourth volume, the decibel of the media audio can be too large or too small. For example, the difference between the first decibel and the third decibel is greater than the first threshold value, and the user feels uncomfortable. The user can adjust the volume of the car machine to reduce or increase the decibel of the media audio to adapt to the user.
[0120] In S502 and S503, in response to the operation of the user adjusting the volume of the car machine, for example, the user adjusts the volume of the car machine from the fourth volume to the first volume, the car machine can determine that playing the media audio at the first volume is adapted to the user. Accordingly, the car machine can store the audio source (such as a mobile phone), the type of media audio (the fifth type of audio), and the first volume corresponding. In some embodiments, the mobile phone can be used as the first audio source. The first volume is the volume of the car machine.
[0121] Similarly, in the scenario of the mobile phone playing audio to the car machine, the mobile phone can play various types of audio to the car machine, and the car machine can store the volume corresponding to the different types of audio of the mobile phone (the first audio source) in the same way as the media audio. Please refer to Table 1:
[0122] Table 1
[0123] 2), Similarly, because the car machine can be connected with different electronic devices (remote audio sources), for different remote audio sources, in the scenario of the remote audio source playing audio to the car machine, the car machine can store the volume of each type of audio of different audio sources according to the method in S501-S503. Please refer to Table 2:
[0124] Table 2
[0125] 3), Similarly, when the car machine plays local audio, the car machine can also be regarded as an audio source. In the scenario of the car machine playing local audio, the car machine can store the volume corresponding to different types of audio of the car machine according to the method in S501-S503. Please refer to Table 3:
[0126] Table 3
[0127] Referring to Table 3, the car machine stores the volume of each type of audio of different audio sources, which can be understood as the volume of the car machine when playing each type of audio of the audio source.
[0128] It can be understood that in some embodiments, after the first electronic device executes S501-S503, the first electronic device can execute S401-S402. It should be understood that S401-S402 are also shown in FIG. 5.
[0129] For example, after the first electronic device executes S501-S503, it can acquire and store the table 3 as shown above. Taking the first audio source as the mobile phone 1, the second audio source as the car machine, and the first audio and the second audio as media audio as an example. When the car machine plays the media audio from the mobile phone 1, the car machine can play the media audio at a volume 1. When switching from the first audio source to the second audio source, such as the mobile phone 1 being disconnected from the car machine, or the car machine pausing the media audio of the mobile phone 1 and playing the media audio of the car machine, the car machine can play the local media audio at a volume 1B. It can be understood that when the car machine switches to play the local media audio, the mobile phone 1 can stop playing the media audio of the mobile phone.
[0130] For example, referring to a of FIG. 6, taking the volume of the mobile phone 1 as 30% and the volume of the car machine as 60% as an example, when the car machine plays the audio (such as the media audio) of the mobile phone 1 at 60% (the first volume, such as the volume 1), the decibel of the audio can be 30% x 60% = 18%. Referring to b of FIG. 6, when the car machine switches to play the local audio (such as the media audio), the car machine can play the audio at a volume of 20% (such as the first volume, such as the volume 1B), which can be regarded as the decibel of the audio being 20%. In this example, when the car machine switches the audio source, the type of the audio played by the car machine is the same, and the difference between the decibels of the audio is within the preset range, so that the problem of the sound being too loud or too soft does not occur.
[0131] Because the volume 1 and the volume 1B are both the volumes adjusted when the user historically listens to the media audio, the volume 1 and the volume 1B are the volumes adapted to the user when the user listens to the media audio. Because the volume of the car machine is positively correlated with the decibel of the audio played by the car machine, when the car machine plays the media audio at the volume 1 and the volume 1B, the decibel of the media audio listened to by the user is also adapted to the user. For example, the decibel of the media audio of the mobile phone 1 played by the car machine at the volume 1 is a first decibel, and the decibel of the media audio of the car machine played by the car machine at the volume 1B is a second decibel, and the first decibel and the second decibel are both adapted to the user, which can also be said that the first decibel and the second decibel are within the preset range, or the difference between the first decibel and the second decibel is less than or equal to the first threshold.
[0132] Similarly, taking the third audio source as the mobile phone 2 as an example, when switching from the second audio source to the third audio source, and the audio played by the car machine is still the same type of media audio, the car machine can play the media audio of the mobile phone 2 at the volume 1B. It can be understood that the car machine plays the media audio of the mobile phone 2 at the volume 1B, and the decibel of the media audio is also adapted to the user.
[0133] In summary, in the scenario of switching the audio source and the car machine playing the same type of audio, the decibel of the audio played by the car machine is all adapted to the user, so that the user will not have the feeling of the sound being too loud or too soft, and the user experience can be improved.
[0134] During the process that the first electronic device plays the fifth audio from the first audio source at the fourth volume, the user can adjust the volume of the first electronic device for more than once to determine a suitable volume. In some embodiments, the first electronic device can update the volume of the type of the fifth audio from the first audio source for each time the user adjusts the volume of the first electronic device.
[0135] In order to reduce the number of times that the first electronic device updates the volume of the type of the fifth audio from the first audio source, i.e. reduce the workload of the first electronic device, and also in order to enable the volume of the type of the fifth audio from the first audio source stored by the first electronic device to be more suitable for the user. In some embodiments, during the process that the user adjusts the volume of the first electronic device, when at least one of the following conditions is met, the first electronic device can store the first audio source, the type of the fifth audio, and the first volume correspondingly:
[0136] 1) The duration that the first electronic device plays audio of the same type as the fifth audio at the first volume is greater than or equal to a preset duration.
[0137] In the case that the user adjusts the volume of the first electronic device, taking the first volume as an example after the first electronic device adjusts the volume, if the duration that the first electronic device plays audio of the same type as the fifth audio at the first volume is greater than or equal to a preset duration, it indicates that the user is used to listening to audio of the same type as the fifth audio at the first volume. For example, the preset duration can be 5 minutes.
[0138] In this case, in response to the operation of the user adjusting the fourth volume to the first volume, and the duration that the first electronic device plays audio of the same type as the fifth audio at the first volume is greater than or equal to a preset duration, the first electronic device can store the first audio source, the type of the fifth audio, and the first volume correspondingly for subsequent use.
[0139] 2) The first electronic device plays the fifth audio completely at the first volume.
[0140] In the case that the user adjusts the volume of the first electronic device, taking the first volume as an example after the first electronic device adjusts the volume, if the first electronic device plays the fifth audio completely at the first volume, it can also indicate that the user is used to listening to audio of the same type as the fifth audio at the first volume.
[0141] In this case, in response to the operation of the user adjusting the fourth volume to the first volume, and the first electronic device playing the fifth audio completely at the first volume, the first electronic device can store the first audio source, the type of the fifth audio, and the first volume correspondingly for subsequent use.
[0142] In this embodiment, in response to the operation of the user adjusting the fourth volume to the first volume, the first electronic device can determine to store the first audio source, the type of the fifth audio, and the first volume corresponding to a certain condition, so as to not only reduce the number of times of updating the volume of the fifth audio of the first audio source of the first electronic device, reduce the workload of the first electronic device, but also enable the volume of the fifth audio of the first audio source stored by the first electronic device to be more suitable for the user.
[0143] In some embodiments, for different types of audio, the user's demand for the decibel of the audio is also different. In this example, in the scenario where the audio source is unchanged but the type of audio changes, in order to adapt to the user's demand for the decibel, the first electronic device can play the audio of the type corresponding to the volume of the type.
[0144] For example, in the scenario where the first electronic device plays the first audio from the first audio source at the first volume, when the first electronic device detects that the audio source is unchanged but switches from the first audio to the third audio of the first audio source, the first electronic device can play the third audio at the third volume. Wherein, the third audio is different from the type of the first audio, and the third volume is the volume corresponding to the type to which the third audio belongs.
[0145] For example, referring to a in FIG. 7, taking the first audio source as a mobile phone 1, the first audio as media audio, and the third audio as call audio as an example. When the car machine plays the media audio from the mobile phone 1, the car machine can play the media audio at volume 1. During the process of the car machine playing the media audio of the mobile phone 1, referring to b in FIG. 7, the mobile phone 1 receives a call from other equipment, and the mobile phone 1 can play the call audio, i.e. the third audio, to the car machine. In this example, the car machine can play the call audio at volume 2. Wherein, the car machine can play different types of audio from the mobile phone 1 at different volumes, so that the user can hear different types of audio at different decibels, which can adapt to the different needs of the user for different types of audio.
[0146] In some embodiments, in the case of audio source switching and type change of audio, the first electronic device can also play the audio of the audio source and the type at different volumes. For example, taking the first audio source as a mobile phone 1 and the second audio source as a mobile phone 2, when the car machine plays the media audio from the mobile phone 1, the car machine can play the media audio at volume 1. When the user connects the mobile phone 2 to the car machine and plays navigation audio on the car machine, referring to Table 3, the car machine can play the navigation audio from the mobile phone 2 at volume NA. In some embodiments, the volume NA can be regarded as the sixth volume, and the navigation audio can be regarded as the sixth audio.
[0147] Exemplarily, different mobile phones can represent different users, different users have different decibel requirements for the same type of audio and different types of audio, and in the embodiment of the application, the car machine can play the audio of each type of the mobile phone at the volume (or decibel) adapted to the user.
[0148] In some embodiments, it can be understood that in the scenario where the audio source is unchanged, the audio is switched and the type of the audio is unchanged, the first electronic device can play the same type of audio at the same volume.
[0149] Exemplarily, in the scenario where the first electronic device plays the first audio from the first audio source at the first volume, when the first electronic device detects that the audio source is unchanged but the first audio is switched to the fourth audio of the first audio source, the first electronic device can play the fourth audio at the first volume. The fourth audio is of the same type as the first audio.
[0150] For example, with reference to Table Three, taking the first audio source as mobile phone 1, the first audio as media audio 1, and the fourth audio as media audio 2 as an example. When the car machine plays the media audio 1 from the mobile phone 1, the car machine can play the media audio 1 at volume 1. In the process of playing the media audio of the mobile phone 1 by the car machine, the user can switch the media audio on the mobile phone 1 or the car machine, for example, from the media audio 1 to the media audio 2. Because the types of the media audio 1 and the media audio 2 are the same, the car machine can continue to play the media audio 2 at volume 1 to adapt to the user's decibel requirement for the media audio.
[0151] In the embodiment of the application, the first electronic device can constantly update Table Three, that is, the first electronic device can constantly update the volume of each type of audio of different audio sources. The purpose of such a setting is that the user's decibel requirement for the audio is constantly changing, and constant updating can adapt to the user's requirement. For example, taking the mobile phone playing media audio to the car machine as an example, when the user is in a good mood, the user can adjust the volume to be smaller on the car machine, and when the user is in a bad mood, the user can adjust the volume to be larger on the car machine to repair the user's lost mood. In the embodiment of the application, in the scenario of the delivery or the scenario where the first electronic device plays local audio, the first electronic device can constantly update the volume of each type of audio of different audio sources according to the user's real-time operation of adjusting the volume of the first electronic device, so as to adapt to the user more and improve the user experience.
[0152] In some embodiments, in a scenario where the first electronic device plays the first audio from the first audio source at the first volume, in response to the operation of the user adjusting the volume of the first electronic device, the first volume can be adjusted to the fifth volume. The electronic device can update the historical stored correspondence of the first audio source, the type of the fifth audio, and the first volume to the correspondence of the first audio source, the type of the fifth audio, and the fifth volume. For example, the first electronic device can adjust the first volume corresponding to the first audio source and the type of the fifth audio to the fifth volume in Table Three.
[0153] After the first electronic device updates the correspondence of the first audio source, the type of the fifth audio, and the fifth volume, the first electronic device can play the first audio at the fifth volume. The decibel of the first electronic device playing the first audio at the fifth volume is the fourth decibel, and in some embodiments, the difference between the first decibel and the fourth decibel is less than or equal to the first threshold value because the operation of the user adjusting the volume is adapted to the user.
[0154] Similarly, when the audio played by the first electronic device switches from the first audio to the fourth audio of the first audio source, because the type of the first audio is the same as the type of the fourth audio, the first electronic device can continue to play the fourth audio at the fifth volume.
[0155] For example, in a scenario where the mobile phone 1 plays media audio to the car machine, the user adjusts the volume 1 (the first volume) to the volume 1C (the fifth volume) on the car machine, and the car machine can adjust the volume corresponding to the media audio of the mobile phone 1 to the volume 1C in Table Three, as shown in Table Four below:
[0156] Table Four
[0157] Referring to Table Four, the car machine can continue to play the media audio from the mobile phone 1 at the volume 1C. When the audio played by the car machine switches from the media audio 1 of the mobile phone 1 to the media audio 2, the car machine can continue to play the media audio 2 from the mobile phone 1 at the volume 1C.
[0158] In the embodiments of the present application, the user's demand for the decibel of the audio is constantly changing, and in response to the operation of the user adjusting the volume of the car machine, the first electronic device can constantly update the volume of different types of audio of each audio source, which can be more adapted to the user.
[0159] In some embodiments, when the user adjusts the volume on the first electronic device, in response to the operation of the user adjusting the volume of the first electronic device, when it is determined that the volume of the first electronic device reaches the protection volume of the first electronic device, the first electronic device can output prompt information. Wherein, the prompt information is used to prompt whether to continue adjusting the volume of the first electronic device. Wherein, the prompt information can refer to the description in the above embodiments.
[0160] For example, the above describes the process of adjusting the fourth volume to the first volume on the first electronic device, and the process of adjusting the first volume to the fifth volume on the first electronic device, both of which can be regarded as the process of adjusting the volume on the first electronic device. When the volume of the first electronic device reaches the protection volume (e.g., 60%) of the first electronic device, the first electronic device can output prompt information in response to the operation of adjusting the volume of the first electronic device.
[0161] In this embodiment, during the process of adjusting the volume of the first electronic device, the first electronic device can also output prompt information to prompt the user whether to continue adjusting the volume of the first electronic device when the volume of the first electronic device reaches the protection volume, so as to timely inform the user and improve the user experience.
[0162] It should be noted that the data (including but not limited to data for analysis, stored data, displayed data, etc.) involved in the present application are all information and data authorized by the user or authorized by all parties, and the collection, use and processing of related data need to comply with relevant laws, regulations and standards of countries and regions, and provide corresponding operation portal for user to choose authorization or refusal.
[0163] In some embodiments, a first electronic device is provided in the embodiments of the present application, for example, the first electronic device can be a car machine. Referring to FIG. 8, the car machine 800 can include a car machine central processing unit (CPU) 801, a memory 802, a display screen 803, a loudspeaker 804, and a communication module 805.
[0164] The car machine CPU 901 can be used to execute the steps executed by the first electronic device in the above embodiments, and the memory 802 can include a high-speed random-access memory (RAM) and can also include a non-volatile memory (NVM), such as at least one disk memory. The memory 802 can store various instructions for the car machine to complete various processing functions and implement the method steps executed by the car machine in the present application.
[0165] The display screen 803 is used to display the interface of the car machine. The loudspeaker 804 is used to play audio.
[0166] The communication module 805, which can include but is not limited to a Bluetooth chip, a Wi-Fi chip, etc., is configured to enable the first electronic device to communicate with other electronic devices (e.g., the second electronic device, the third electronic device).
[0167] In some embodiments, the car machine 800 can further include a microphone 806, etc.
[0168] It can be understood that the structure shown in FIG. 8 does not constitute a specific limitation on the first electronic device (the car machine). In some other embodiments of the present application, the car machine can include more or fewer components than those shown, or combine some components, or split some components, or different arrangement of components. The components shown can be implemented in hardware, software, or a combination of software and hardware.
[0169] In some embodiments, the present application provides a second electronic device, for example, the second electronic device can be a mobile phone. Referring to FIG. 9, the mobile phone 900 can include a mobile phone central processing unit (CPU) 901, a memory 902, a display screen 903, a speaker 904, and a communication module 905.
[0170] The mobile phone CPU 901 can be configured to perform the steps performed by the second electronic device in the above embodiments, for example, the mobile phone CPU 901 can enable the second electronic device to play audio to the first electronic device.
[0171] The memory 902 can include a high-speed random-access memory (RAM) and can also include a non-volatile memory (NVM), for example, at least one disk memory. The memory 902 can store various instructions for the mobile phone to complete various processing functions and implement the method steps performed by the mobile phone in the present application.
[0172] The display screen 903 is configured to display the interface of the mobile phone. The speaker 904 is configured to play audio.
[0173] The communication module 905, which can include but is not limited to a Bluetooth chip, a Wi-Fi chip, etc., is configured to enable the second electronic device to communicate with other electronic devices (e.g., the first electronic device).
[0174] It can be understood that the structure shown in FIG. 9 does not constitute a specific limitation on the second electronic device (the mobile phone). In some other embodiments of the present application, the mobile phone can include more or fewer components than those shown, or combine some components, or split some components, or different arrangement of components. The components shown can be implemented in hardware, software, or a combination of software and hardware.
[0175] It is noted that the modules or components described in the above embodiments can be one or more integrated circuits configured to implement the above methods, for example, one or more application specific integrated circuits (ASICs), or one or more digital signal processors (DSPs), or one or more field programmable gate arrays (FPGAs), etc. For another example, when a certain module above is implemented in the form of a processing element scheduling code, the processing element can be a general purpose processor, for example, a central processing unit (CPU) or other processor such as a controller that can invoke the code. For another example, these modules can be integrated together to be implemented in the form of a system-on-a-chip (SOC).
[0176] In the above embodiments, all or part of the embodiments can be implemented by software, hardware, firmware or any combination thereof. When implemented by software, all or part of the embodiments can be implemented in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions according to the embodiments of the present application are generated. The computer can be a general purpose computer, a special purpose computer, a computer network, or other programmable devices. The computer instructions can be stored in a computer readable storage medium or transmitted from one computer readable storage medium to another computer readable storage medium, for example, the computer instructions can be transmitted from one website, computer, server or data center to another website, computer, server or data center through wired (for example, coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (for example, infrared, wireless, microwave, etc.) mode. The computer readable storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server, data center, etc. integrated with one or more available media. The available media can be magnetic media (for example, floppy disk, hard disk, magnetic tape), optical media (for example, DVD), or semiconductor media (for example, solid state disk (SSD)) and the like.
[0177] The term "multiple" in the present document refers to two or more. The term "and / or" in the present document is only used to describe the relationship of associated objects, which means that there can be three relationships, for example, A and / or B can represent three cases: A exists alone, A and B exist together, and B exists alone. In addition, the character " / " in the present document generally represents an "or" relationship between the associated objects before and after it; in the formula, the character " / " represents a "division" relationship between the associated objects before and after it. In addition, it should be understood that in the description of the present application, the words "first", "second", etc. are only used for the purpose of distinguishing the description and should not be understood as indicating or implying relative importance or indicating or implying sequence.
[0178] It can be understood that various numerical numbers involved in the embodiments of the present application are only used for the purpose of distinguishing and do not limit the scope of the embodiments of the present application.
[0179] It can be understood that the size of the serial number of each process in the embodiments of the present application does not mean the order of execution, and the execution order of each process should be determined according to its function and inherent logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
Claims
1. A volume control method, characterized by, The method applied to a first electronic device comprises: playing first audio from a first audio source at a first volume; when detecting that the first audio source switches to a second audio source, playing second audio from the second audio source at a second volume, the first audio and the second audio being of the same type, wherein a decibel of the first audio played at the first volume is a first decibel, a decibel of the second audio played at the second volume is a second decibel, and a difference between the first decibel and the second decibel is less than or equal to a first threshold.
2. The method of claim 1, wherein, The first audio source is the first electronic device, and the second audio source is a second electronic device; or The first audio source is the second electronic device, and the second audio source is the first electronic device or a third electronic device.
3. The method according to claim 1 or 2, characterized in that, After the playing first audio from a first audio source at a first volume, the method further comprises: when detecting that the first audio switches to third audio from the first audio source, playing the third audio at a third volume, the first audio and the third audio being of different types.
4. The method according to claim 1 or 2, characterized in that, After the playing first audio from a first audio source at a first volume, the method further comprises: when detecting that the first audio switches to fourth audio from the first audio source, playing the fourth audio at the first volume, the first audio and the fourth audio being of the same type.
5. The method according to claim 1 or 2, characterized in that, The method further comprises: when detecting that the first audio source switches to the second audio source, playing sixth audio at a sixth volume, the sixth audio being of a different type from the first audio.
6. The method according to any one of claims 1-5, characterized in that, The method further comprises: playing fifth audio from the first audio source at a fourth volume, the first audio and the fifth audio being of the same type, a decibel of the fifth audio played at the fourth volume being a third decibel, and a difference between the first decibel and the third decibel being greater than the first threshold; in response to a user adjusting a volume of the first electronic device, adjusting the fourth volume to the first volume; storing the first audio source, the type of the fifth audio, and the first volume in correspondence.
7. The method of claim 6, wherein, The storing the first audio source, the type of the fifth audio, and the first volume in correspondence comprises: storing the first audio source, the type of the fifth audio, and the first volume in correspondence when at least one of the following conditions is met: a duration of playing audio of the same type as the fifth audio at the first volume is greater than or equal to a preset duration; or the fifth audio is played completely at the first volume.
8. The method according to claim 6 or 7, characterized in that, Before the playing first audio from a first audio source at a first volume, the method further comprises: determining the first volume corresponding to the first audio source and the type of the first audio according to a correspondence relationship among the first audio source, the type of the fifth audio, and the first volume.
9. The method according to any one of claims 6-8, characterized in that, After the playing first audio from a first audio source at a first volume, the method further comprises: in response to a user adjusting a volume of the first electronic device, adjusting the first volume to the fifth volume; update a correspondence relationship among the first audio source, the type of the fifth audio, and the first volume to a correspondence relationship among the first audio source, the type of the fifth audio, and the fifth volume; when it is detected that the fourth audio is switched from the first audio to the first audio source, playing the fourth audio at the fifth volume, the type of the first audio being the same as the type of the fourth audio.
10. The method of claim 9, wherein, a difference between the first decibel and a fourth decibel at which the first audio is played at the fifth volume is less than or equal to the first threshold value.
11. The method according to any one of claims 6-10, characterized in that, The method further includes: in response to an operation of adjusting the volume of the first electronic device by a user, when it is determined that the volume of the first electronic device reaches a protection volume of the first electronic device, outputting prompt information for prompting whether to continue adjusting the volume of the first electronic device.
12. An electronic device, comprising: The electronic device includes one or more processors and a memory; The memory is coupled to the one or more processors, and the memory is configured to store computer program codes including computer instructions, and the one or more processors are configured to invoke the computer instructions to cause the electronic device to perform the method according to any one of claims 1-11.
13. A chip system, characterized by The chip system is applied to an electronic device, and the chip system includes one or more processors configured to invoke computer instructions to cause the electronic device to perform the method according to any one of claims 1-11.
14. A computer-readable storage medium, characterized in that, The computer readable storage medium includes computer instructions configured to cause the electronic device to perform the method according to any one of claims 1-11 when the computer instructions are run on the electronic device.
15. A computer program product, characterised in that, The computer program product includes computer program codes configured to cause the electronic device to perform the method according to any one of claims 1-11 when the computer program codes are run on the electronic device.
Citation Information
Patent Citations
Volume control method and electronic equipment
CN110543289A
Volume adjustment method, device and system
CN111163226A
Volume adjusting method and terminal equipment
CN113438356A
Multimedia playing method and device and electronic equipment
CN114371823A
Volume adjustment method, electronic equipment and computer readable storage medium
CN115562611A