CN112118506A - Earphone noise reduction mode control method, system, equipment and storage medium - Google Patents

Earphone noise reduction mode control method, system, equipment and storage medium Download PDF

Info

Publication number
CN112118506A
CN112118506A CN202011055090.6A CN202011055090A CN112118506A CN 112118506 A CN112118506 A CN 112118506A CN 202011055090 A CN202011055090 A CN 202011055090A CN 112118506 A CN112118506 A CN 112118506A
Authority
CN
China
Prior art keywords
noise reduction
reduction mode
sound signal
earphone
value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202011055090.6A
Other languages
Chinese (zh)
Other versions
CN112118506B (en
Inventor
沈炜
蔡世光
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Inventec Appliances Shanghai Corp
Original Assignee
Inventec Appliances Shanghai Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Inventec Appliances Shanghai Corp filed Critical Inventec Appliances Shanghai Corp
Priority to CN202011055090.6A priority Critical patent/CN112118506B/en
Priority to TW109142845A priority patent/TWI753685B/en
Publication of CN112118506A publication Critical patent/CN112118506A/en
Application granted granted Critical
Publication of CN112118506B publication Critical patent/CN112118506B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R1/00Details of transducers, loudspeakers or microphones
    • H04R1/10Earpieces; Attachments therefor ; Earphones; Monophonic headphones
    • H04R1/1041Mechanical or electronic switches, or control elements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R1/00Details of transducers, loudspeakers or microphones
    • H04R1/10Earpieces; Attachments therefor ; Earphones; Monophonic headphones
    • H04R1/1083Reduction of ambient noise
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R2430/00Signal processing covered by H04R, not provided for in its groups
    • H04R2430/01Aspects of volume control, not necessarily automatic, in sound systems
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R2460/00Details of hearing devices, i.e. of ear- or headphones covered by H04R1/10 or H04R5/033 but not provided for in any of their subgroups, or of hearing aids covered by H04R25/00 but not provided for in any of its subgroups
    • H04R2460/01Hearing devices using active noise cancellation

Landscapes

  • Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Acoustics & Sound (AREA)
  • Signal Processing (AREA)
  • Headphones And Earphones (AREA)
  • Soundproofing, Sound Blocking, And Sound Damping (AREA)

Abstract

The invention provides a method, a system, equipment and a storage medium for controlling a noise reduction mode of an earphone, wherein the method comprises the following steps: the noise reduction mode of the earphone is in an open state, and an ambient sound signal is collected; judging whether the amplitude deviation value of the environmental sound signal is larger than a first preset threshold value or not, and if so, closing the noise reduction mode of the earphone; collecting the environment sound signal, judging whether the amplitude deviation value of the environment sound signal is smaller than a second preset threshold value, and if so, executing a noise reduction mode of opening the earphone; if not, keeping the noise reduction mode of the earphone in a closed state; the first preset threshold is greater than the second preset threshold; the method and the device enable the user to pay attention to the abnormal sound of the surrounding environment in time, and can avoid accidents caused by the fact that the external environment sound cannot be known in time.

Description

Earphone noise reduction mode control method, system, equipment and storage medium
Technical Field
The present invention relates to the field of noise reduction technologies, and in particular, to a method, a system, a device, and a storage medium for controlling a noise reduction mode of an earphone.
Background
More and more users use noise reduction earphones in life, that is, earphones with a noise reduction mode play audio. However, since the noise reduction earphone reduces the external noise, when the user wears the noise reduction earphone to play the audio, the user hardly notices the external sound, which may cause many situations that are not good for the user's safety. For example, when a user wears a noise reduction earphone to listen to a song, if a car whistles around and the user does not hear, a traffic accident may occur.
Disclosure of Invention
Aiming at the problems in the prior art, the invention aims to provide a method, a system, equipment and a storage medium for controlling a noise reduction mode of an earphone, which solve the problem that in the related art, when a user uses a noise reduction earphone, accidents may occur due to the fact that dangerous warning sounds in external environment sounds cannot be known in time.
In order to achieve the above object, the present invention provides a method for controlling a noise reduction mode of an earphone, the method comprising the steps of:
s10, the noise reduction mode of the earphone is in an open state, and an environment sound signal is collected;
s20, judging whether the amplitude deviation value of the environment sound signal is larger than a first preset threshold value, if so, executing a step S30; if not, returning to the step S10;
s30, closing the noise reduction mode of the earphone;
s40, collecting the environment sound signal, judging whether the amplitude deviation value of the environment sound signal is smaller than a second preset threshold value, if so, executing a step S50; if not, go to step S60; the first preset threshold is greater than the second preset threshold;
s50, opening a noise reduction mode of the earphone;
s60, the noise reduction mode of the headphone is kept off, and the process returns to step S40.
Preferably, the amplitude deviation value is obtained according to a first amplitude value corresponding to the ambient sound signal at the current time and an average value of the first amplitude values of the ambient sound signal x seconds before the current time; x is a predetermined parameter, and x is a positive number.
Preferably, the amplitude deviation value of the ambient sound signal is calculated according to the following formula:
D(t)=|[As(t)-Aavg(x)]|/[Aavg(x)]
wherein D (t) represents an amplitude deviation value of the ambient sound signal, As(t) represents a first amplitude value, A, corresponding to the ambient sound signal at the current timeavg(x) An average value of the first amplitude value representing the ambient sound signal x seconds before the current time.
Preferably, the first amplitude value corresponding to the current-time environmental sound signal is calculated according to the following formula:
Figure BDA0002710629880000021
wherein t represents the current time, N represents the number of sampling points in the current time, Ap(r) represents the amplitude value of the r-th sample point.
Preferably, the average value of the first amplitude value of the ambient sound signal x seconds before the current time is calculated according to the following formula:
Figure BDA0002710629880000022
wherein A iss(m) represents a first amplitude value corresponding to the ambient sound signal at the m-th time.
Preferably, the step S70 is included between the step S30 and the step S40:
when the signal of the speaking of the earphone wearer is collected, the earphone wearer is indicated to speak, and the step S30 is returned; if not, go to step S40.
Preferably, the step S30 further includes: reducing the output volume of the earphone from a first volume value to a second volume value;
the step S50 further includes:
and restoring the output volume of the earphone to the first volume value.
Preferably, the first preset threshold is 2.
Preferably, the second preset threshold is 0.5.
The invention also provides a system for controlling the noise reduction mode of the earphone, which is used for realizing the method for controlling the noise reduction mode of the earphone and comprises the following steps:
the state acquisition module is used for acquiring the working state of the noise reduction mode of the earphone and an ambient sound signal;
the first judgment module is used for judging whether the amplitude deviation value of the environmental sound signal is larger than a first preset threshold value or not, and if so, sending a noise reduction closing instruction to the noise reduction closing module;
the noise reduction closing module is used for closing the noise reduction mode of the earphone after receiving the noise reduction closing instruction;
the second judgment module continues to collect the environmental sound signal and judges whether the amplitude deviation value of the environmental sound signal is smaller than a second preset threshold value, and if yes, a noise reduction starting instruction is sent to the noise reduction starting module; if not, the noise reduction is kept closed;
and the noise reduction starting module is used for starting the noise reduction mode of the earphone after receiving the noise reduction starting instruction.
Preferably, the system further comprises a third judging module, configured to judge whether the acquired signal is a signal of speaking of the earphone wearer; if so, sending a noise reduction closing instruction to the noise reduction closing module.
The present invention also provides a noise reduction mode control device for an earphone, comprising:
a processor;
a memory having stored therein executable instructions of the processor;
wherein the processor is configured to perform the steps of any of the above-described headphone noise reduction mode control methods via execution of the executable instructions.
The present invention also provides a computer-readable storage medium storing a program which, when executed by a processor, implements the steps of any of the above-described headphone noise reduction mode control methods.
Compared with the prior art, the invention has the following advantages and prominent effects:
the method, the system, the equipment and the storage medium for controlling the noise reduction mode of the earphone collect environmental sound signals, and when the amplitude deviation value is judged to be larger than a first preset threshold value, namely high noise exists in the environment, the noise reduction mode is closed; the user can pay attention to the abnormal sound of the surrounding environment in time, and accidents caused by the fact that the external environment sound cannot be known in time can be avoided. And after the ambient sound is stable, the earphone is controlled to resume the starting of the noise reduction mode, the user does not need to manually start the noise reduction again, and better use experience is provided for the user.
Drawings
Other features, objects and advantages of the present invention will become more apparent upon reading of the following detailed description of non-limiting embodiments thereof, with reference to the accompanying drawings.
Fig. 1 is a schematic diagram of a noise reduction mode control method for an earphone according to an embodiment of the present invention;
fig. 2 is a schematic diagram of a noise reduction mode control method for an earphone according to another embodiment of the present invention;
fig. 3 is a schematic structural diagram of a noise reduction mode control system of an earphone according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of a noise reduction mode control device of an earphone according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of a computer-readable storage medium according to an embodiment of the disclosure.
Detailed Description
Example embodiments will now be described more fully with reference to the accompanying drawings. Example embodiments may, however, be embodied in many different forms and should not be construed as limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the concept of example embodiments to those skilled in the art. The same reference numerals in the drawings denote the same or similar structures, and thus their repetitive description will be omitted.
As shown in fig. 1, an embodiment of the present invention discloses a method for controlling a noise reduction mode of an earphone, including the following steps:
s10, the noise reduction mode of the headphone is in an on state, and an ambient sound signal is collected. That is, the working state of the noise reduction mode of the headphone and the ambient sound signal are respectively collected, and the step S20 is executed only when the noise reduction mode of the headphone is determined to be turned on.
S20, determining whether the amplitude deviation of the ambient sound signal is greater than a first predetermined threshold. If yes, go to step S30. If not, the process returns to step S10. Specifically, when the amplitude deviation value of the collected environment sound signal is greater than a first preset threshold, it indicates that high noise occurs in the surrounding environment, such as a dangerous warning sound in the external environment sound or a sudden call of a friend. At this time, the noise reduction mode needs to be turned off, so that the user can pay attention to the abnormal sound of the surrounding environment in time.
The present invention is not limited to the determination method of high noise of the environmental sound signal. For example, the magnitude relation between the difference between the amplitude of the ambient sound signal at the current moment and the average value of the amplitudes of the ambient sound signals of the previous x seconds and a preset threshold value can be compared; the difference value may be compared with the average value of the previous x seconds of the ambient sound signal amplitude, and a preset threshold value may be used.
S30, turning off the noise reduction mode of the earphone. Namely, the noise reduction mode of the earphone is switched from the on state to the off state. Therefore, the user can hear the external sound more clearly and respond in time. The user is prevented from possibly making an accident because the dangerous warning sound is not heard in time.
And S40, continuously collecting the environmental sound signal, and judging whether the amplitude deviation value of the environmental sound signal is smaller than a second preset threshold value. If yes, go to step S50. If not, step S60 is executed. For example, if the environmental sound signal is collected at the current time in step S10, it is determined in step S40 that the environmental sound signal continues to be collected during a period subsequent to the current time.
If the amplitude deviation value of the continuously collected environmental sound signal is smaller than a second preset threshold, it indicates that the environmental sound signal reaches a steady state, for example: after the user moves from a quieter environment to a noisy environment, the high noise achieves a continuous state; alternatively, after the danger warning sound (high noise) of the previous burst-card is stopped, the surrounding environment is not otherwise dangerous and the collected environmental sound signal is reduced to a steady state.
The amplitude deviation values are obtained according to the first amplitude value corresponding to the environmental sound signal at the current moment and the average value of the first amplitude values of the environmental sound signal x seconds before the current moment. Wherein x is a preset parameter and x is a positive number. The first preset threshold is greater than the second preset threshold.
Specifically, the amplitude deviation value of the above-described ambient sound signal is calculated according to the following formula:
D(t)=|[As(t)-Aavg(x)]|/[Aavg(x)]
wherein D (t) represents the amplitude deviation value of the environmental sound signal at the current time t, As(t) represents a first amplitude value, A, corresponding to the ambient sound signal at the current timeavg(x) An average value of the first amplitude value representing the ambient sound signal x seconds before the current time. For example, when the current time is 20 seconds, x may take a value of 10. Then Aavg(x) It represents the average value of the first amplitude value of the ambient sound signal 10 seconds before the current time, that is, the average value of the first amplitude value of the ambient sound signal from the 10 th to 19 th seconds. A. thes(t) represents the first amplitude value corresponding to the 20 th second ambient sound signal.
In this embodiment, the first amplitude value a corresponding to the current environmental sound signals(t) is calculated according to the following formula:
Figure BDA0002710629880000051
where t represents the current time. For example, when t is 20, As(t) represents the first amplitude value corresponding to the ambient sound signal collected at the 20 th second, i.e. equal to the sum of the absolute values of the amplitudes of the ambient sound signals collected at all the sampling points in the 20 th second. N represents the number of sampling points at the current moment, r represents the sampling points, Ap(r) watchAnd displaying the amplitude value of the environmental sound signal collected by the r-th sampling point in the current moment. N is a predetermined parameter, in this embodiment, N is 44100, and the value of N is not limited in this application.
In this embodiment, the average value a of the first amplitude values of the environmental sound signal x seconds before the current time is described aboveavg(x) Calculated according to the following formula:
Figure BDA0002710629880000061
wherein A iss(m) represents a first amplitude value corresponding to the ambient sound signal at the m-th time. Illustratively, when t is 20, x is 10,
Figure BDA0002710629880000062
it represents the sum of the amplitudes of the ambient sound signals collected from the 10 th to 19 th seconds.
S50, turning on the noise reduction mode of the earphone. That is, when it is determined that the high noise reaches a sustained state, that is, the amplitude deviation value of the ambient sound signal is smaller than a second preset threshold value, that is, in an environment where external noise is stable, the safety of the user itself has been confirmed. Noise reduction may be performed again to isolate external noise. Namely, the noise reduction mode of the earphone is switched from the off state to the on state. Therefore, the user does not need to manually start the noise reduction again, user operation is saved, and the earphone use experience of the user is improved. Of course, the user may also manually turn on the noise reduction mode again.
S60, the noise reduction mode of the headphone is kept off, and the process returns to step S40.
In this embodiment, through a large number of experimental tests, the first preset threshold is set to be 2, and when the second preset threshold is set to be 0.5, the first preset threshold is reasonable, so that the user can fully and timely hear the dangerous warning sound in the sound of the surrounding environment. This is not limited by the present application.
As shown in fig. 2, in another embodiment of the present invention, on the basis of the above embodiment, the step S30 further includes: the output volume of the earphone is reduced from the first volume value to the second volume value. Therefore, the user can hear the external environment sound more clearly, the method is particularly suitable for scenes in which the user is called by friends and needs to talk, and the user can talk conveniently and hear the sound of the other party without manually turning down the volume.
The step S50 further includes: and restoring the output volume of the earphone to the first volume value. That is, the user may use the earphone to continue listening to the song, so that the output volume of the earphone is recovered, the volume can be recovered according to the song listening habit of the user, and the use experience is better.
As shown in fig. 2, in this embodiment, a step S70 is further included between step S30 and step S40:
when the collected signal is the signal of the earphone wearer speaking, the step S30 is returned, otherwise, the step S40 is executed. In specific implementation, it may be determined that the acquired signal is the signal of the earphone wearer speaking in a manner that the earphone wearer is speaking through bone voiceprint signal recognition and/or dual microphone beamforming, and then the process returns to step S30, that is, the noise reduction mode of the earphone is kept in the off state. If not, go to step S40. Specifically, when the user is speaking, the user may be talking with a friend, and the noise reduction mode of the earphone is kept in the off state, so that the user can hear the voice of the other party more clearly, and the user experience is improved.
As shown in fig. 3, the embodiment of the present invention further discloses a noise reduction mode control system 3 for an earphone, which includes:
and the state acquisition module 31 is used for acquiring the working state of the noise reduction mode of the earphone and an ambient sound signal.
The first determining module 32 is configured to determine whether the amplitude deviation value of the ambient sound signal is greater than a first preset threshold when the earphone is in the open noise reduction mode. If so, sending a noise reduction closing instruction to the noise reduction closing module to inform the noise reduction closing module to start executing internal operation so as to close the noise reduction mode of the earphone. If not, a cyclic operation instruction is sent to the state acquisition module, namely the state acquisition module is informed to execute the internal operation again.
And a noise reduction closing module 33, configured to close the noise reduction mode of the earphone after receiving the noise reduction closing instruction.
The second determining module 34 is configured to determine whether the amplitude deviation value of the ambient sound signal is smaller than a second preset threshold when the earphone is in the noise reduction off mode. If so, sending a noise reduction starting instruction to the noise reduction starting module to inform the noise reduction starting module to start executing internal operation so as to start the noise reduction mode of the earphone. If not, the noise reduction is kept closed.
And the noise reduction starting module 35 is configured to turn on the noise reduction mode of the earphone after receiving the noise reduction starting instruction.
It is understood that the noise reduction mode control system of the headphone of the present invention further includes other existing functional modules that support the operation of the noise reduction mode control system of the headphone. The noise reduction mode control system of the earphone shown in fig. 3 is only an example, and should not bring any limitation to the function and the range of use of the embodiment of the present invention.
The noise reduction mode control system of the earphone in this embodiment is used to implement the above noise reduction mode control method of the earphone, so for the specific implementation steps of the noise reduction mode control system of the earphone, reference may be made to the above description of the noise reduction mode control method of the earphone, and details are not repeated here.
The embodiment of the invention also discloses a device for controlling the noise reduction mode of the earphone, which comprises a processor and a memory, wherein the memory stores the executable instruction of the processor; the processor is configured to perform the steps in the above-described headphone noise reduction mode control method via execution of executable instructions. Fig. 4 is a schematic structural diagram of a noise reduction mode control device for a headset according to the present disclosure. An electronic device 600 according to this embodiment of the invention is described below with reference to fig. 4. The electronic device 600 shown in fig. 4 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 4, the electronic device 600 is embodied in the form of a general purpose computing device. The components of the electronic device 600 may include, but are not limited to: at least one processing unit 610, at least one memory unit 620, a bus 630 connecting the different platform components (including the memory unit 620 and the processing unit 610), a display unit 640, etc.
Wherein the memory unit stores program code which may be executed by the processing unit 610 such that the processing unit 610 performs the steps according to various exemplary embodiments of the present invention as described in the above-mentioned headphone noise reduction mode control method section of the present specification. For example, processing unit 610 may perform the steps as shown in fig. 1.
The storage unit 620 may include readable media in the form of volatile memory units, such as a random access memory unit (RAM)6201 and/or a cache memory unit 6202, and may further include a read-only memory unit (ROM) 6203.
The memory unit 620 may also include a program/utility 6204 having a set (at least one) of program modules 6205, such program modules 6205 including, but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which, or some combination thereof, may comprise an implementation of a network environment.
Bus 630 may be one or more of several types of bus structures, including a memory unit bus or memory unit controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of a variety of bus architectures.
The electronic device 600 may also communicate with one or more external devices 700 (e.g., keyboard, pointing device, bluetooth device, etc.), with one or more devices that enable a user to interact with the electronic device 600, and/or with any devices (e.g., router, modem, etc.) that enable the electronic device 600 to communicate with one or more other computing devices. Such communication may occur via an input/output (I/O) interface 650. Also, the electronic device 600 may communicate with one or more networks (e.g., a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public network such as the Internet) via the network adapter 660. The network adapter 660 may communicate with other modules of the electronic device 600 via the bus 630. It should be appreciated that although not shown in the figures, other hardware and/or software modules may be used in conjunction with the electronic device 600, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage platforms, to name a few.
The invention also discloses a computer readable storage medium for storing a program, which when executed implements the steps in the above-mentioned earphone noise reduction mode control method. In some possible embodiments, the various aspects of the present invention may also be implemented in the form of a program product comprising program code for causing a terminal device to perform the steps according to various exemplary embodiments of the present invention described in the above-mentioned headphone noise reduction mode control methods of this specification, when the program product is run on the terminal device.
As described above, the program of the computer-readable storage medium of this embodiment, when executed, collects an ambient sound signal, and turns off the noise reduction mode when it is determined that there is high noise in the environment; the user can pay attention to the abnormal sound of the surrounding environment in time, and accidents caused by the fact that the external environment sound cannot be known in time can be avoided. And after the ambient sound is stable, the earphone is controlled to resume the starting of the noise reduction mode, the user does not need to manually start the noise reduction again, and better use experience is provided for the user.
Fig. 5 is a schematic structural diagram of a computer-readable storage medium of the present invention. Referring to fig. 5, a program product 800 for implementing the above method according to an embodiment of the present invention is described, which may employ a portable compact disc read only memory (CD-ROM) and include program code, and may be run on a terminal device, such as a personal computer. However, the program product of the present invention is not limited in this regard and, in the present document, a readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
The program product may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium include: an electrical connection having one or more wires, a portable disk, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
A computer readable storage medium may include a propagated data signal with readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A readable storage medium may also be any readable medium that is not a readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a readable storage medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
Program code for carrying out operations for aspects of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computing device, partly on the user's device, as a stand-alone software package, partly on the user's computing device and partly on a remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computing device (e.g., through the internet using an internet service provider).
The method, the system, the equipment and the storage medium for controlling the noise reduction mode of the earphone provided by the embodiment of the invention collect environmental sound signals, and when the amplitude deviation value is judged to be larger than a first preset threshold value, namely high noise exists in the environment, the noise reduction mode is closed and the output volume of the earphone is reduced; the user can pay attention to the abnormal sound of the surrounding environment in time, and accidents caused by the fact that the external environment sound cannot be known in time can be avoided. And after the ambient sound is stable, the earphone is controlled to resume the starting of the noise reduction mode and resume the previous output volume, so that the user does not need to manually start the noise reduction again, and better use experience is provided for the user.
The foregoing is a more detailed description of the invention in connection with specific preferred embodiments and it is not intended that the invention be limited to these specific details. For those skilled in the art to which the invention pertains, several simple deductions or substitutions can be made without departing from the spirit of the invention, and all shall be considered as belonging to the protection scope of the invention.

Claims (13)

1. A method for controlling a noise reduction mode of a headset is characterized by comprising the following steps:
s10, the noise reduction mode of the earphone is in an open state, and an environment sound signal is collected;
s20, judging whether the amplitude deviation value of the environment sound signal is larger than a first preset threshold value, if so, executing a step S30; if not, returning to the step S10;
s30, closing the noise reduction mode of the earphone;
s40, collecting the environment sound signal, judging whether the amplitude deviation value of the environment sound signal is smaller than a second preset threshold value, if so, executing a step S50; if not, go to step S60; the first preset threshold is greater than the second preset threshold;
s50, opening a noise reduction mode of the earphone;
s60, the noise reduction mode of the headphone is kept off, and the process returns to step S40.
2. The headphone noise reduction mode control method according to claim 1, wherein the amplitude deviation value is obtained from an average value of a first amplitude value corresponding to the ambient sound signal at the current time and a first amplitude value of the ambient sound signal x seconds before the current time; x is a predetermined parameter, and x is a positive number.
3. The headphone noise reduction mode control method according to claim 1 or 2, wherein the amplitude deviation value of the ambient sound signal is calculated according to the following formula:
D(t)=|[As(t)-Aavg(x)]|/[Aavg(x)]
wherein D (t) represents an amplitude deviation value of the ambient sound signal, As(t) represents a first amplitude value, A, corresponding to the ambient sound signal at the current timeavg(x) An average value of the first amplitude value representing the ambient sound signal x seconds before the current time.
4. The headphone noise reduction mode control method according to claim 3, wherein the first amplitude value corresponding to the ambient sound signal at the current time is calculated according to the following formula:
Figure FDA0002710629870000011
wherein t represents the current time, N represents the number of sampling points in the current time, Ap(r) represents the amplitude value of the r-th sample point.
5. The headphone noise reduction mode control method according to claim 3, wherein the average value of the first amplitude value of the ambient sound signal x seconds before the current time is calculated according to the following formula:
Figure FDA0002710629870000012
wherein A iss(m) represents a first amplitude value corresponding to the ambient sound signal at the m-th time.
6. The headphone noise reduction mode control method according to claim 1, wherein between the step S30 and the step S40, the step S70 is included:
when the signal of speaking of the earphone wearer is collected, returning to the step S30; otherwise, step S40 is executed.
7. The headphone noise reduction mode control method according to claim 1, wherein the step S30 further includes: reducing the output volume of the earphone from a first volume value to a second volume value;
the step S50 further includes:
and restoring the output volume of the earphone to the first volume value.
8. The headphone noise reduction mode control method according to claim 1, wherein the first preset threshold is 2.
9. The headphone noise reduction mode control method according to claim 1, wherein the second preset threshold is 0.5.
10. A headphone noise reduction mode control system for implementing the headphone noise reduction mode control method according to any one of claims 1 to 9, the system comprising:
the state acquisition module is used for acquiring the working state of the noise reduction mode of the earphone and an ambient sound signal;
the first judgment module is used for judging whether the amplitude deviation value of the environmental sound signal is larger than a first preset threshold value or not, and if so, sending a noise reduction closing instruction to the noise reduction closing module;
the noise reduction closing module is used for closing the noise reduction mode of the earphone after receiving the noise reduction closing instruction;
the second judgment module is used for judging whether the amplitude deviation value of the environmental sound signal is smaller than a second preset threshold value or not, and if yes, sending a noise reduction starting instruction to the noise reduction starting module; if not, the noise reduction is kept closed;
and the noise reduction starting module is used for starting the noise reduction mode of the earphone after receiving the noise reduction starting instruction.
11. The system of claim 10, further comprising a third determining module for determining whether the collected signal is a signal of the earphone wearer speaking; if so, sending a noise reduction closing instruction to the noise reduction closing module.
12. A headphone noise reduction mode control device, comprising:
a processor;
a memory having stored therein executable instructions of the processor;
wherein the processor is configured to perform the steps of the headphone noise reduction mode control method of any one of claims 1 to 9 via execution of the executable instructions.
13. A computer-readable storage medium storing a program, wherein the program when executed by a processor implements the steps of the headphone noise reduction mode control method according to any one of claims 1 to 9.
CN202011055090.6A 2020-09-29 2020-09-29 Earphone noise reduction mode control method, system, equipment and storage medium Active CN112118506B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202011055090.6A CN112118506B (en) 2020-09-29 2020-09-29 Earphone noise reduction mode control method, system, equipment and storage medium
TW109142845A TWI753685B (en) 2020-09-29 2020-12-04 Headphone noise reduction mode control method, system, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011055090.6A CN112118506B (en) 2020-09-29 2020-09-29 Earphone noise reduction mode control method, system, equipment and storage medium

Publications (2)

Publication Number Publication Date
CN112118506A true CN112118506A (en) 2020-12-22
CN112118506B CN112118506B (en) 2022-11-11

Family

ID=73798413

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011055090.6A Active CN112118506B (en) 2020-09-29 2020-09-29 Earphone noise reduction mode control method, system, equipment and storage medium

Country Status (2)

Country Link
CN (1) CN112118506B (en)
TW (1) TWI753685B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112770214A (en) * 2021-01-28 2021-05-07 歌尔科技有限公司 Earphone control method and device and earphone
CN115134708A (en) * 2022-06-30 2022-09-30 歌尔股份有限公司 Earphone mode switching method and device, electronic equipment and readable storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017120956A1 (en) * 2016-01-17 2017-07-20 谢文 Method of giving alarm during headphone usage, and headphones for giving alarm
US20180020282A1 (en) * 2015-01-26 2018-01-18 Shenzhen Grandsun Electronic Co., Ltd. Earphone noise reduction method and apparatus
CN209642920U (en) * 2018-11-30 2019-11-15 陕西烽火宏声科技有限责任公司 Environment sensing noise reduction in-ear typed Bluetooth headset
CN111432305A (en) * 2020-03-27 2020-07-17 歌尔科技有限公司 Earphone alarm method and device and wireless earphone

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5593851B2 (en) * 2010-06-01 2014-09-24 ソニー株式会社 Audio signal processing apparatus, audio signal processing method, and program
US9761247B2 (en) * 2013-01-31 2017-09-12 Microsoft Technology Licensing, Llc Prosodic and lexical addressee detection
WO2016119108A1 (en) * 2015-01-26 2016-08-04 深圳市冠旭电子有限公司 Earphone noise reduction control method and apparatus
CN110364151B (en) * 2019-07-15 2024-01-30 华为技术有限公司 Voice awakening method and electronic equipment

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180020282A1 (en) * 2015-01-26 2018-01-18 Shenzhen Grandsun Electronic Co., Ltd. Earphone noise reduction method and apparatus
WO2017120956A1 (en) * 2016-01-17 2017-07-20 谢文 Method of giving alarm during headphone usage, and headphones for giving alarm
CN209642920U (en) * 2018-11-30 2019-11-15 陕西烽火宏声科技有限责任公司 Environment sensing noise reduction in-ear typed Bluetooth headset
CN111432305A (en) * 2020-03-27 2020-07-17 歌尔科技有限公司 Earphone alarm method and device and wireless earphone

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112770214A (en) * 2021-01-28 2021-05-07 歌尔科技有限公司 Earphone control method and device and earphone
CN115134708A (en) * 2022-06-30 2022-09-30 歌尔股份有限公司 Earphone mode switching method and device, electronic equipment and readable storage medium

Also Published As

Publication number Publication date
TW202213328A (en) 2022-04-01
CN112118506B (en) 2022-11-11
TWI753685B (en) 2022-01-21

Similar Documents

Publication Publication Date Title
US11626116B2 (en) Contingent device actions during loss of network connectivity
EP2267695B1 (en) Controlling music players using environment audio analysis
US9800730B2 (en) Methods and apparatus to audibly provide messages in a mobile device
US9299348B2 (en) Method and apparatus for obtaining information from the web
EP2605239A2 (en) Method and arrangement for noise reduction
US20080025523A1 (en) System and method for noise canceling in a mobile phone headset accessory
CN112118506B (en) Earphone noise reduction mode control method, system, equipment and storage medium
WO2008083315A2 (en) Method and device configured for sound signature detection
US20120189129A1 (en) Apparatus for Aiding and Informing a User
CN102333157A (en) Mobile terminal and conversation voice recording method and device used for mobile terminal
CN112770214A (en) Earphone control method and device and earphone
US20140087704A1 (en) Blocking incoming communication interruptions
US9368884B2 (en) Apparatus for electrically coupling contacts by magnetic forces
CN113938785A (en) Noise reduction processing method, device, equipment, earphone and storage medium
KR102607120B1 (en) Sound data noise canceling method and apparatus, electronic device , computer readable storage medium and computer program
US20130039154A1 (en) Remote control of a portable electronic device and method therefor
CN111863004A (en) Sound signal processing method, system, electronic device and storage medium
EP2439913B1 (en) Methods and apparatus to audibly provide messages in a mobile device
JP2013157924A (en) Communication apparatus, communication program, and communication method
EP2557763A1 (en) Remote control of a portable electronic device and method therefor
CN113973149A (en) Electronic apparatus, device failure detection method and medium thereof
CN111324331A (en) Interactive message prompting method and device, electronic equipment and storage medium
CN106856537B (en) Volume adjustment method and device
US20130039501A1 (en) System, Method, and Computer Program Product for Voice Decibel Monitoring on Electronic Computing Devices
CN110333838A (en) A kind of control method of volume, terminal and computer storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant