CN113316064A - Method, system, head-mounted display device and storage medium for earphone and loudspeaker recognition - Google Patents

Method, system, head-mounted display device and storage medium for earphone and loudspeaker recognition Download PDF

Info

Publication number
CN113316064A
CN113316064A CN202110468845.3A CN202110468845A CN113316064A CN 113316064 A CN113316064 A CN 113316064A CN 202110468845 A CN202110468845 A CN 202110468845A CN 113316064 A CN113316064 A CN 113316064A
Authority
CN
China
Prior art keywords
loudspeaker
earphone
section
audio plug
voltage
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
CN202110468845.3A
Other languages
Chinese (zh)
Other versions
CN113316064B (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.)
Hangzhou Pimax Intelligent Technology Co.,Ltd.
Xiaopai Technology Hangzhou Co ltd
Original Assignee
Hangzhou Xiaopai Intelligent Technology Co ltd
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 Hangzhou Xiaopai Intelligent Technology Co ltd filed Critical Hangzhou Xiaopai Intelligent Technology Co ltd
Priority to CN202110468845.3A priority Critical patent/CN113316064B/en
Publication of CN113316064A publication Critical patent/CN113316064A/en
Application granted granted Critical
Publication of CN113316064B publication Critical patent/CN113316064B/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
    • H04R3/00Circuits for transducers, loudspeakers or microphones
    • H04R3/12Circuits for transducers, loudspeakers or microphones for distributing signals to two or more loudspeakers
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R2420/00Details of connection covered by H04R, not provided for in its groups
    • H04R2420/05Detection of connection of loudspeakers or headphones to amplifiers

Abstract

The application relates to a method and a system for identifying an earphone and a loudspeaker, a head-mounted display device and a storage medium, wherein a first voltage of an external device is obtained when the insertion time of the external device reaches a preset time by detecting the insertion of the external device; whether the first voltage is in a preset range is judged, if the judgment result is yes, the external equipment is a loudspeaker, if the judgment result is no, the external equipment is an earphone, the impedance of the loudspeaker is far smaller than the impedance of the earphone, so that the voltage stabilization time of the loudspeaker is far smaller than the voltage stabilization time of the earphone, in the preset time, after the voltage of the loudspeaker rises to the preset range, the voltage of the earphone is far smaller than the voltage in the preset range, so that whether the voltage of the external equipment is in the preset range or not can be judged, whether the inserted external equipment is the earphone or the loudspeaker can be identified, the problem that an audio interface of the terminal equipment supports both the earphone and the loudspeaker, and noise exists when the earphone and the loudspeaker are identified wrongly is solved.

Description

Method, system, head-mounted display device and storage medium for earphone and loudspeaker recognition
Technical Field
The present application relates to the field of electronic product technologies, and in particular, to a method and system for recognizing a headphone and a speaker, a head-mounted display device, and a storage medium.
Background
Along with the improvement of living standard, the use of VR equipment has become more and more common, in order to satisfy the demand of user to the audio, the VR equipment of PC end still supports external loudspeaker except supporting earphone equipment, but because the signal type of loudspeaker signal and earphone signal is different, need two audio interface to transmit the signal respectively, make VR equipment interface many, be unfavorable for product miniaturization and lightweight, in order to solve the many problem of interface, a lot of VR equipment has realized earphone and loudspeaker sharing audio interface, but an audio interface both supported the earphone and supported loudspeaker and can lead to earphone and loudspeaker discernment mistake, cause earphone and loudspeaker to have the noise.
At present, no effective solution is provided for the problem that one audio interface of the terminal equipment in the related art supports both the earphone and the loudspeaker and noise exists when the earphone and the loudspeaker are identified incorrectly.
Disclosure of Invention
The embodiment of the application provides a method and a system for identifying an earphone and a loudspeaker, a head-mounted display device and a storage medium, so as to at least solve the problems that one audio interface of a terminal device in the related art supports both the earphone and the loudspeaker, and noise exists when the earphone and the loudspeaker are identified incorrectly.
In a first aspect, an embodiment of the present application provides a method for identifying a headphone and a speaker, where the speaker and the headphone share an audio interface, and an impedance of the speaker is much smaller than an impedance of the headphone, the method includes:
detecting that an external device is inserted, and acquiring a first voltage of the external device when the insertion time of the external device reaches a preset time;
and judging whether the first voltage is within a preset range, if so, determining that the external equipment is a loudspeaker, and if not, determining that the external equipment is an earphone.
In some embodiments, after the detecting of the insertion of the external device, the method further includes:
under the condition that the insertion time of the external equipment reaches the preset time, continuously and repeatedly acquiring a second voltage of the external equipment, and acquiring an average value of the second voltage;
and judging whether the average value of the second voltage is within the preset range, if so, determining that the external equipment is a loudspeaker, and if not, determining that the external equipment is an earphone.
In some embodiments, obtaining the first voltage of the external device comprises:
the external equipment is a four-section type audio plug equipment, and the voltage between the third section of the audio plug and the fourth section of the audio plug is obtained;
if the external device is an earphone, the first section of the earphone audio plug is a left sound channel, the second section of the earphone audio plug is a right sound channel, the third section of the earphone audio plug is a microphone, and the fourth section of the earphone audio plug is a ground;
if the external equipment is a loudspeaker, the first section of the loudspeaker audio plug is a left loudspeaker, the second section of the loudspeaker audio plug is a right loudspeaker, the third section of the loudspeaker audio plug is a detection pin, and the fourth section of the loudspeaker audio plug is a ground.
In some embodiments, before detecting insertion of the external device, the method further comprises:
setting a preset time;
and the time required by fully charging the capacitive load between the third section of the horn audio plug and the fourth section of the horn audio plug is the preset time.
In a second aspect, the present application provides a system for identifying a speaker and a headset, which is applied to the speaker and the headset sharing an audio interface, wherein the impedance of the speaker is much smaller than the impedance of the headset, the system includes a detection module, an acquisition module and a determination module,
the detection module is used for detecting the insertion of the external equipment;
the external equipment comprises an acquisition module, a control module and a control module, wherein the acquisition module is used for acquiring a first voltage of the external equipment under the condition that the insertion time of the external equipment reaches a preset time;
and the judging module is used for judging whether the first voltage is within a preset range, if so, the external equipment is a loudspeaker, and if not, the external equipment is an earphone.
In some embodiments, after the detection module detects the insertion of the external device,
the obtaining module obtains a second voltage of the external equipment continuously for multiple times when the insertion time of the external equipment reaches a preset time, and obtains an average value of the second voltage;
the judgment module judges whether the average value of the second voltage is within the preset range, if so, the external equipment is a loudspeaker, and if not, the external equipment is an earphone.
In some embodiments, the obtaining module obtains the first voltage of the external device by:
the external equipment is equipment with a four-section type audio plug, and the acquisition module acquires voltage between the third section of the audio plug and the fourth section of the audio plug;
if the external device is an earphone, the first section of the earphone audio plug is a left sound channel, the second section of the earphone audio plug is a right sound channel, the third section of the earphone audio plug is a microphone, and the fourth section of the earphone audio plug is a ground;
if the external equipment is a loudspeaker, the first section of the loudspeaker audio plug is a left loudspeaker, the second section of the loudspeaker audio plug is a right loudspeaker, the third section of the loudspeaker audio plug is a detection pin, and the fourth section of the loudspeaker audio plug is a ground.
In some embodiments, the system further comprises a setting module, before the detection module detects the insertion of the external device,
the setting module is used for setting preset time;
and the time required by fully charging the capacitive load between the third section of the horn audio plug and the fourth section of the horn audio plug is the preset time.
In a third aspect, embodiments of the present application provide a head-mounted display device, including a memory, a processor, and a computer program stored on the memory and executable on the processor, where the processor, when executing the computer program, implements the method for identifying earphones and speakers as described in the first aspect.
In a fourth aspect, embodiments of the present application provide a storage medium having a computer program stored thereon, where the computer program is executed by a processor to implement the method for recognizing a headphone and a loudspeaker as described in the first aspect.
Compared with the related art, the method for identifying the earphone and the loudspeaker is applied to the loudspeaker and the earphone which share one audio interface, the impedance of the loudspeaker is far smaller than that of the earphone, and the first voltage of the external equipment is obtained when the insertion time of the external equipment reaches the preset time by detecting the insertion of the external equipment; whether the first voltage is in a preset range is judged, if the judgment result is yes, the external equipment is a loudspeaker, if the judgment result is no, the external equipment is an earphone, the impedance of the loudspeaker is far smaller than the impedance of the earphone, so that the voltage stabilization time of the loudspeaker is far smaller than the voltage stabilization time of the earphone, in the preset time, after the voltage of the loudspeaker rises to the preset range, the voltage of the earphone is far smaller than the voltage in the preset range, so that whether the voltage of the external equipment is in the preset range or not can be judged, whether the inserted external equipment is the earphone or the loudspeaker can be identified, the problem that an audio interface of the terminal equipment supports both the earphone and the loudspeaker, errors are easily identified by the earphone and the loudspeaker, and noise exists when the earphone and the loudspeaker are identified incorrectly is solved.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the application and together with the description serve to explain the application and not to limit the application. In the drawings:
fig. 1 is a flow chart of a method of headset and speaker identification according to an embodiment of the present application;
FIG. 2 is a flow chart of another method of headset and speaker identification according to an embodiment of the present application;
fig. 3 is a block diagram of a system for headset and speaker identification according to an embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application will be described and illustrated below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application. All other embodiments obtained by a person of ordinary skill in the art based on the embodiments provided in the present application without any inventive step are within the scope of protection of the present application. Moreover, it should be appreciated that in the development of any such actual implementation, as in any engineering or design project, numerous implementation-specific decisions must be made to achieve the developers' specific goals, such as compliance with system-related and business-related constraints, which may vary from one implementation to another.
Reference in the specification to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the specification. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. Those of ordinary skill in the art will explicitly and implicitly appreciate that the embodiments described herein may be combined with other embodiments without conflict.
Unless defined otherwise, technical or scientific terms referred to herein shall have the ordinary meaning as understood by those of ordinary skill in the art to which this application belongs. Reference to "a," "an," "the," and similar words throughout this application are not to be construed as limiting in number, and may refer to the singular or the plural. The present application is directed to the use of the terms "including," "comprising," "having," and any variations thereof, which are intended to cover non-exclusive inclusions; for example, a process, method, system, article, or apparatus that comprises a list of steps or modules (elements) is not limited to the listed steps or elements, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus. Reference to "connected," "coupled," and the like in this application is not intended to be limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. Reference herein to "a plurality" means greater than or equal to two. "and/or" describes an association relationship of associated objects, meaning that three relationships may exist, for example, "A and/or B" may mean: a exists alone, A and B exist simultaneously, and B exists alone. Reference herein to the terms "first," "second," "third," and the like, are merely to distinguish similar objects and do not denote a particular ordering for the objects.
The present embodiment provides a method for identifying a speaker and a headset, which is applied to a speaker and a headset sharing an audio interface, where the impedance of the speaker is much smaller than the impedance of the headset, fig. 1 is a flowchart of a method for identifying a speaker and a headset according to an embodiment of the present application, and as shown in fig. 1, the method includes the following steps:
step S101, detecting that an external device is inserted, and acquiring a first voltage of the external device when the insertion time of the external device reaches a preset time;
step S102, judging whether the first voltage is in a preset range, if so, determining that the external equipment is a loudspeaker, and if not, determining that the external equipment is an earphone. In this embodiment, the preset range is a voltage value of the loudspeaker or the earphone after the voltage is stabilized, the voltage value is within a range of a positive preset value and a negative preset value, and the preset value is as small as possible, so that the result is more accurate.
Through the steps from S101 to S102, the impedance of the loudspeaker is far smaller than the impedance of the earphone, so that the voltage stabilization time of the loudspeaker is far smaller than the voltage stabilization time of the earphone, and after the voltage of the loudspeaker rises to a preset range within the preset time, the voltage of the earphone is far smaller than the voltage within the preset range, so that whether the inserted external equipment is the earphone or the loudspeaker can be identified by judging whether the voltage of the external equipment is within the preset range, and the problems that an audio interface of the terminal equipment supports both the earphone and the loudspeaker, and noise exists when the earphone and the loudspeaker are identified incorrectly are solved.
In some embodiments, in acquiring the first voltage of the external device, in order to prevent inaccurate voltage measurement due to various reasons, the voltage of the external device needs to be acquired multiple times, fig. 2 is a flowchart of another method for recognizing a headset and a speaker according to an embodiment of the present application, and as shown in fig. 2, the method includes the following steps:
step S201, under the condition that the insertion time of the external equipment reaches the preset time, continuously and repeatedly acquiring a second voltage of the external equipment, and acquiring an average value of the second voltage;
step S202, judging whether the average value of the second voltage is in a preset range, if so, the external equipment is a loudspeaker, and if not, the external equipment is an earphone.
Through the steps S201 to S202, after the second voltage of the external device is continuously obtained for multiple times, the maximum voltage and the minimum voltage are discarded, and then the average voltage is obtained, and whether the average voltage is within the preset range or not is determined, so that the problem of determination errors caused by measurement errors is prevented, and the determination accuracy is improved;
in some embodiments, obtaining the first voltage of the external device comprises: the external equipment is a four-section type audio plug equipment, and the voltage between the third section of the audio plug and the fourth section of the audio plug is obtained; if the external equipment is an earphone, the first section of the earphone audio plug is a left sound channel, the second section of the earphone audio plug is a right sound channel, the third section of the earphone audio plug is a microphone, and the fourth section of the earphone audio plug is a ground; if the external equipment is a loudspeaker, the first section of the loudspeaker audio plug is a left loudspeaker, the second section of the loudspeaker audio plug is a right loudspeaker, the third section of the loudspeaker audio plug is a detection pin, and the fourth section of the loudspeaker audio plug is a ground. In this embodiment, the impedance between the third section of the speaker audio plug and the fourth section of the speaker audio plug is far smaller than the impedance between the third section of the earphone audio plug and the fourth section of the earphone audio plug, so that the voltage stabilization time between the third section of the speaker audio plug and the fourth section of the speaker audio plug is far smaller than the voltage between the third section of the earphone audio plug and the fourth section of the earphone audio plug, and after the voltage between the third section of the speaker audio plug and the fourth section of the speaker audio plug rises to a preset range within a preset time, the voltage between the third section of the earphone audio plug and the fourth section of the earphone audio plug is far smaller than the voltage within the preset range, so that whether the inserted external device is an earphone or a speaker can be identified by judging whether the voltage between the third section of the external device audio plug and the fourth section of the audio plug is within the preset range.
In some embodiments, a preset time is set before the insertion of the external device is detected; and the time required by fully charging the capacitive load between the third section of the horn audio plug and the fourth section of the horn audio plug is preset time. Illustratively, the capacitive load between the third and fourth sections of the horn audio plug is fully charged to a voltage, the voltage is equal to the voltage of the fully charged capacitive load between the third section and the fourth section of the earphone audio plug, but the time required for fully charging the capacitive load and the fourth section of the earphone audio plug is different, because the impedance between the third section and the fourth section of the loudspeaker audio plug is far smaller than the impedance between the third section and the fourth section of the earphone audio plug, the time required for fully charging the capacitive load between the third section and the fourth section of the loudspeaker audio plug is taken as the preset time, for example, the preset time is 500ms, when the insertion time of the external device reaches 500ms, acquiring the voltage between the third section of the audio plug of the external equipment and the fourth section of the audio plug, if the voltage is increased to be within a preset range, the external device is a loudspeaker, and if the voltage is far smaller than the minimum value of the preset range, the external device is an earphone.
It should be noted that the steps illustrated in the above-described flow diagrams or in the flow diagrams of the figures may be performed in a computer system, such as a set of computer-executable instructions, and that, although a logical order is illustrated in the flow diagrams, in some cases, the steps illustrated or described may be performed in an order different than here.
The present embodiment further provides a system for recognizing an earphone and a speaker, which is used to implement the foregoing embodiments and preferred embodiments, and the description of the system is omitted here. As used hereinafter, the terms "module," "unit," "subunit," and the like may implement a combination of software and/or hardware for a predetermined function. Although the means described in the embodiments below are preferably implemented in software, an implementation in hardware, or a combination of software and hardware is also possible and contemplated.
Fig. 3 is a block diagram of a structure of a system for recognizing a speaker and an earphone according to an embodiment of the present application, which is applied to an audio interface shared by the speaker and the earphone, where an impedance of the speaker is smaller than an impedance of the earphone, as shown in fig. 3, the system includes a detection module 31, an obtaining module 32, and a determining module 33, where the detection module 31 is used to detect that an external device is inserted; the obtaining module 32 is configured to obtain a first voltage of the external device when the insertion time of the external device reaches a preset time; the judging module 33 is configured to judge whether the first voltage is within a preset range, if the judging result is yes, the external device is a loudspeaker, if the judging result is no, the external device is an earphone, the impedance of the loudspeaker is far smaller than the impedance of the earphone, so that the voltage stabilization time of the loudspeaker is far smaller than the voltage stabilization time of the earphone, within the preset time, after the voltage of the loudspeaker rises to the preset range, the voltage of the earphone is far smaller than the voltage within the preset range, so that whether the voltage of the external device is within the preset range or not can be judged, whether the external device is an earphone or a loudspeaker can be identified, and the problem that an audio interface of the terminal device supports both the earphone and the loudspeaker, and noise exists when the earphone and the loudspeaker are identified incorrectly is solved.
The above modules may be functional modules or program modules, and may be implemented by software or hardware. For a module implemented by hardware, the modules may be located in the same processor; or the modules can be respectively positioned in different processors in any combination.
The present embodiment also provides a head-mounted display device comprising a memory having a computer program stored therein and a processor arranged to execute the computer program to perform the steps of any of the above method embodiments.
Optionally, the head-mounted display device may further include a transmission device and an input/output device, wherein the transmission device is connected to the processor, and the input/output device is connected to the processor.
It should be noted that, for specific examples in this embodiment, reference may be made to examples described in the foregoing embodiments and optional implementations, and details of this embodiment are not described herein again.
In addition, in combination with the method for recognizing the earphone and the speaker in the above embodiments, the embodiments of the present application may provide a storage medium to implement. The storage medium having stored thereon a computer program; the computer program when executed by a processor implements any of the above-described embodiments of the method of headset and speaker recognition.
In one embodiment, a computer device is provided, which may be a terminal. The computer device includes a processor, a memory, a network interface, a display screen, and an input device connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The network interface of the computer device is used for communicating with an external terminal through a network connection. The computer program is executed by a processor to implement a method of headset and speaker recognition. The display screen of the computer equipment can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer equipment can be a touch layer covered on the display screen, a key, a track ball or a touch pad arranged on the shell of the computer equipment, an external keyboard, a touch pad or a mouse and the like.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, storage, database, or other medium used in the embodiments provided herein may include non-volatile and/or volatile memory, among others. Non-volatile memory can include read-only memory (ROM), Programmable ROM (PROM), Electrically Programmable ROM (EPROM), Electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (DDRSDRAM), Enhanced SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), Rambus Direct RAM (RDRAM), direct bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
It should be understood by those skilled in the art that various features of the above-described embodiments can be combined in any combination, and for the sake of brevity, all possible combinations of features in the above-described embodiments are not described in detail, but rather, all combinations of features which are not inconsistent with each other should be construed as being within the scope of the present disclosure.
The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present patent shall be subject to the appended claims.

Claims (10)

1. A method of headset and speaker identification, applied to an audio interface common to both the speaker and the headset, the impedance of the speaker being substantially less than the impedance of the headset, the method comprising:
detecting that an external device is inserted, and acquiring a first voltage of the external device when the insertion time of the external device reaches a preset time;
and judging whether the first voltage is within a preset range, if so, determining that the external equipment is a loudspeaker, and if not, determining that the external equipment is an earphone.
2. The method of claim 1, wherein after detecting insertion of an external device, the method further comprises:
under the condition that the insertion time of the external equipment reaches the preset time, continuously and repeatedly acquiring a second voltage of the external equipment, and acquiring an average value of the second voltage;
and judging whether the average value of the second voltage is within the preset range, if so, determining that the external equipment is a loudspeaker, and if not, determining that the external equipment is an earphone.
3. The method of claim 1, wherein obtaining the first voltage of the peripheral device comprises:
the external equipment is a four-section type audio plug equipment, and the voltage between the third section of the audio plug and the fourth section of the audio plug is obtained;
if the external device is an earphone, the first section of the earphone audio plug is a left sound channel, the second section of the earphone audio plug is a right sound channel, the third section of the earphone audio plug is a microphone, and the fourth section of the earphone audio plug is a ground;
if the external equipment is a loudspeaker, the first section of the loudspeaker audio plug is a left loudspeaker, the second section of the loudspeaker audio plug is a right loudspeaker, the third section of the loudspeaker audio plug is a detection pin, and the fourth section of the loudspeaker audio plug is a ground.
4. The method of claim 1, wherein prior to detecting insertion of an external device, the method further comprises:
setting a preset time;
and the time required by fully charging the capacitive load between the third section of the horn audio plug and the fourth section of the horn audio plug is the preset time.
5. A system for identifying a loudspeaker and an earphone is characterized in that the system is applied to an audio interface shared by the earphone and the loudspeaker, the impedance of the loudspeaker is far smaller than that of the earphone, the system comprises a detection module, an acquisition module and a judgment module,
the detection module is used for detecting the insertion of the external equipment;
the external equipment comprises an acquisition module, a control module and a control module, wherein the acquisition module is used for acquiring a first voltage of the external equipment under the condition that the insertion time of the external equipment reaches a preset time;
and the judging module is used for judging whether the first voltage is within a preset range, if so, the external equipment is a loudspeaker, and if not, the external equipment is an earphone.
6. The system of claim 5, wherein after the detection module detects the insertion of an external device,
the obtaining module obtains a second voltage of the external equipment continuously for multiple times when the insertion time of the external equipment reaches a preset time, and obtains an average value of the second voltage;
the judgment module judges whether the average value of the second voltage is within the preset range, if so, the external equipment is a loudspeaker, and if not, the external equipment is an earphone.
7. The system of claim 5, wherein the obtaining module obtains the first voltage of the peripheral device comprises:
the external equipment is equipment with a four-section type audio plug, and the acquisition module acquires voltage between the third section of the audio plug and the fourth section of the audio plug;
if the external device is an earphone, the first section of the earphone audio plug is a left sound channel, the second section of the earphone audio plug is a right sound channel, the third section of the earphone audio plug is a microphone, and the fourth section of the earphone audio plug is a ground;
if the external equipment is a loudspeaker, the first section of the loudspeaker audio plug is a left loudspeaker, the second section of the loudspeaker audio plug is a right loudspeaker, the third section of the loudspeaker audio plug is a detection pin, and the fourth section of the loudspeaker audio plug is a ground.
8. The system of claim 5, further comprising a setup module, wherein the detection module detects that an external device is inserted,
the setting module is used for setting preset time;
and the time required by fully charging the capacitive load between the third section of the horn audio plug and the fourth section of the horn audio plug is the preset time.
9. A head-mounted display device comprising a memory and a processor, characterized in that the memory has stored therein a computer program, the processor being arranged to execute the computer program to perform the method of headphone and loudspeaker identification as claimed in any one of claims 1 to 4.
10. A storage medium having a computer program stored thereon, wherein the computer program is arranged to perform the method of headset and speaker recognition according to any of claims 1-4 when run.
CN202110468845.3A 2021-04-28 2021-04-28 Method, system, head-mounted display device and storage medium for earphone and loudspeaker recognition Active CN113316064B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110468845.3A CN113316064B (en) 2021-04-28 2021-04-28 Method, system, head-mounted display device and storage medium for earphone and loudspeaker recognition

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110468845.3A CN113316064B (en) 2021-04-28 2021-04-28 Method, system, head-mounted display device and storage medium for earphone and loudspeaker recognition

Publications (2)

Publication Number Publication Date
CN113316064A true CN113316064A (en) 2021-08-27
CN113316064B CN113316064B (en) 2023-01-24

Family

ID=77371315

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110468845.3A Active CN113316064B (en) 2021-04-28 2021-04-28 Method, system, head-mounted display device and storage medium for earphone and loudspeaker recognition

Country Status (1)

Country Link
CN (1) CN113316064B (en)

Citations (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080130911A1 (en) * 2006-12-01 2008-06-05 Kuo-Ting Tsen Electronic device Capable of Automatically Discriminating Headset Type and Related Method
CN101431708A (en) * 2008-12-10 2009-05-13 深圳华为通信技术有限公司 Terminal and method for recognizing headphone type
CN101924835A (en) * 2010-08-17 2010-12-22 惠州Tcl移动通信有限公司 Mobile telephone communication method and mobile telephone
CN101938546A (en) * 2010-08-26 2011-01-05 惠州Tcl移动通信有限公司 Earphone microphone detection method based on mobile phone and mobile phone
CN102082846A (en) * 2010-12-02 2011-06-01 惠州Tcl移动通信有限公司 Terminal equipment with plurality of externally arranged shared interfaces
CN102413239A (en) * 2011-11-15 2012-04-11 惠州Tcl移动通信有限公司 Mobile phone and method for detecting earphone mode of mobile phone
CN103686535A (en) * 2013-12-02 2014-03-26 Tcl集团股份有限公司 Terminal capable of automatically recognizing headset microphone and karaoke devices, and recognition method thereof
CN103793193A (en) * 2012-10-30 2014-05-14 联想(北京)有限公司 Mode switching method for audio interface, audio interface and electronic equipment
CN105101001A (en) * 2015-09-18 2015-11-25 青岛海信移动通信技术股份有限公司 Earphone identification device and terminal equipment
CN105142072A (en) * 2015-09-30 2015-12-09 惠州Tcl移动通信有限公司 Audio apparatus with externally connected player and audio playing method thereof
WO2016082563A1 (en) * 2014-11-24 2016-06-02 天地融科技股份有限公司 Universal audio adapter apparatus and electronic device
WO2016161596A1 (en) * 2015-04-09 2016-10-13 华为技术有限公司 Audio connector recognition method and portable electronic device
CN107295140A (en) * 2017-06-27 2017-10-24 努比亚技术有限公司 A kind of detection method of earphone, device and terminal
CN111586549A (en) * 2020-05-14 2020-08-25 西安闻泰电子科技有限公司 Earphone insertion detection circuit

Patent Citations (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080130911A1 (en) * 2006-12-01 2008-06-05 Kuo-Ting Tsen Electronic device Capable of Automatically Discriminating Headset Type and Related Method
CN101431708A (en) * 2008-12-10 2009-05-13 深圳华为通信技术有限公司 Terminal and method for recognizing headphone type
CN101924835A (en) * 2010-08-17 2010-12-22 惠州Tcl移动通信有限公司 Mobile telephone communication method and mobile telephone
CN101938546A (en) * 2010-08-26 2011-01-05 惠州Tcl移动通信有限公司 Earphone microphone detection method based on mobile phone and mobile phone
CN102082846A (en) * 2010-12-02 2011-06-01 惠州Tcl移动通信有限公司 Terminal equipment with plurality of externally arranged shared interfaces
CN102413239A (en) * 2011-11-15 2012-04-11 惠州Tcl移动通信有限公司 Mobile phone and method for detecting earphone mode of mobile phone
CN103793193A (en) * 2012-10-30 2014-05-14 联想(北京)有限公司 Mode switching method for audio interface, audio interface and electronic equipment
CN103686535A (en) * 2013-12-02 2014-03-26 Tcl集团股份有限公司 Terminal capable of automatically recognizing headset microphone and karaoke devices, and recognition method thereof
WO2016082563A1 (en) * 2014-11-24 2016-06-02 天地融科技股份有限公司 Universal audio adapter apparatus and electronic device
WO2016161596A1 (en) * 2015-04-09 2016-10-13 华为技术有限公司 Audio connector recognition method and portable electronic device
CN105101001A (en) * 2015-09-18 2015-11-25 青岛海信移动通信技术股份有限公司 Earphone identification device and terminal equipment
CN105142072A (en) * 2015-09-30 2015-12-09 惠州Tcl移动通信有限公司 Audio apparatus with externally connected player and audio playing method thereof
CN107295140A (en) * 2017-06-27 2017-10-24 努比亚技术有限公司 A kind of detection method of earphone, device and terminal
CN111586549A (en) * 2020-05-14 2020-08-25 西安闻泰电子科技有限公司 Earphone insertion detection circuit

Also Published As

Publication number Publication date
CN113316064B (en) 2023-01-24

Similar Documents

Publication Publication Date Title
US20160157033A1 (en) Method and apparatus for identifying foreign substances in connectors
CN108810697B (en) Wireless earphone pairing method and device and wireless earphone
US9723408B2 (en) Electronic device and method of preventing erroneous recognizing inserting connector into earphone jack
KR20200073478A (en) Electronic device and method for identifying connection state between connector and electrical path
KR20200085546A (en) Method for controlling power back off using grip sensor and electronic device for supporting the same
CN110602672B (en) Bluetooth device reconnection method, device, terminal and computer readable storage medium
US10257363B2 (en) Coordinating input on multiple local devices
US9819321B2 (en) Method and apparatus for automatically controlling gain based on sensitivity of microphone in electronic device
WO2017166598A1 (en) Sound channel adjusting method and apparatus for headphones, electronic device, and storage medium
CN113316064B (en) Method, system, head-mounted display device and storage medium for earphone and loudspeaker recognition
US20140065963A1 (en) Method for establishing communications between peer devices, wireless communication device using the same and computer-readable medium
CN112423176A (en) Earphone noise reduction method and device, storage medium and noise reduction earphone
CN112492439B (en) Earphone falling reminding method and device, electronic equipment and storage medium
CN113271194A (en) System and method for providing channel state information reference signal power determination
CN112804651A (en) Binding method and device and computer equipment
KR20210083059A (en) Outputting method of audio data and electronic device supporting the same
US11562763B2 (en) Method for improving sound quality and electronic device using same
CN106201930B (en) A kind of device port determining device, terminal and method
CN112929099B (en) Signal detection method, terminal and storage medium
CN113766406A (en) Method, system and device for testing earphone
CN113612717A (en) Frequency offset calibration method and device, electronic equipment and storage medium
CN112291696B (en) Audio chip testing method, storage medium and computer equipment
CN106656352B (en) Information transmission method and device and wearable device
US20220013130A1 (en) Shared ai speaker
EP3214855B1 (en) Device and method for adjusting an output to an audio port based on a determined sensitivity

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
CP01 Change in the name or title of a patent holder

Address after: 310000 room 208, building 1, 1818-1, Wenyi West Road, Yuhang street, Yuhang District, Hangzhou City, Zhejiang Province

Patentee after: Hangzhou Pimax Intelligent Technology Co.,Ltd.

Address before: 310000 room 208, building 1, 1818-1, Wenyi West Road, Yuhang street, Yuhang District, Hangzhou City, Zhejiang Province

Patentee before: Hangzhou Xiaopai Intelligent Technology Co.,Ltd.

CP01 Change in the name or title of a patent holder
TR01 Transfer of patent right

Effective date of registration: 20231020

Address after: Room 208-2, Building 1, 1818-1 Wenyi West Road, Yuhang Street, Yuhang District, Hangzhou City, Zhejiang Province, 311100

Patentee after: Xiaopai Technology (Hangzhou) Co.,Ltd.

Address before: 310000 room 208, building 1, 1818-1, Wenyi West Road, Yuhang street, Yuhang District, Hangzhou City, Zhejiang Province

Patentee before: Hangzhou Pimax Intelligent Technology Co.,Ltd.

TR01 Transfer of patent right