Adaptive headset interface standard configuration method and device based on detection circuit
By obtaining the user mode setting and switching the pin connection through the detection circuit, the incompatibility problem of headphones of different standards is solved, the compatibility detection of American standard and Chinese standard headphones is realized, and the flexibility and accuracy of insertion detection are improved.
Patent Information
- Application Number
- CN202510917597.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-03
- Publication Date
- 2025-10-10
AI Technical Summary
Existing headphone jack standard detection technology is not compatible with headphones of different standards, resulting in inconsistent detection logic and affecting software and hardware design.
The detection circuit obtains the user's HS-DET normally open/normally closed mode setting and American standard/Chinese standard mode setting, switches the pin connection method of the detection circuit, achieves compatibility of headphones with both American standard and Chinese standard, and uses the microcontroller and processor to communicate and verify the connection status.
It achieves compatibility with headphones of different standards, ensures that the connection status conforms to the mode set by the user, generates an alarm signal to prompt abnormal connection, and improves the flexibility and accuracy of headphone insertion detection.
Smart Images

Figure CN120769201A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of earphone standard configuration, for example, to a configuration method and device of adaptive earphone interface standard based on a detection circuit. BACKGROUND
[0002] 3.5mm earphone interface can be divided into single-hole and double-hole forms according to appearance, wherein, under the double-hole form, the earphone and microphone occupy one three-segment jack respectively, and the two functions are distinguished by the color of the connector shell; under the single-hole form, the earphone and microphone are in the same jack, and the jack adopts a four-segment design, which is divided into American standard and Chinese standard according to different designs, the difference between which lies in the difference in the definition of each segment, and the four-segment earphone interface detection signal of different models also has the difference between normally open and normally closed, which leads to different detection logic and further affects the software and hardware design.
[0003] Therefore, in the existing configuration detection technical solution, there is a problem of incompatibility of different standard earphones.
[0004] It should be noted that the information disclosed in the above background section is only used to strengthen the understanding of the background of the present application. SUMMARY
[0005] To have a basic understanding of some aspects of the disclosed embodiments, a brief overview is given below. The overview is not an overall description of the application, nor is it intended to identify key / important elements or delineate the scope of the embodiments, but to serve as a prelude to the detailed description below.
[0006] The configuration method and device of adaptive earphone interface standard based on a detection circuit provided by the embodiments of the present application can solve the problem of incompatibility of different standard earphones.
[0007] The embodiments of the present application provide a configuration method of adaptive earphone interface standard based on a detection circuit, which can include:
[0008] Obtaining the HS-DET normally open / closed mode setting of the user;
[0009] Obtaining the American standard / Chinese standard mode setting of the user;
[0010] When the American standard mode is adopted, the switch between the first segment pin of the detection circuit and the GND terminal is closed to establish a communication connection, and the switch between the second segment pin of the detection circuit and the MIC terminal is closed to establish a communication connection;
[0011] When the Chinese standard mode is adopted, the switch between the first segment pin of the detection circuit and the MIC terminal is closed to establish a communication connection, and the switch between the second segment pin of the detection circuit and the GND terminal is closed to establish a communication connection.
[0012] In some embodiments, the method further comprises:
[0013] Upon insertion of the headset, the headset insertion condition is determined based on the change of the level obtained by the detection circuit, and a pop-up window is generated to display the selection of the American standard / German standard mode and the selection of the HS-DET normally open / normally closed mode.
[0014] In some embodiments, the detection circuit comprises a MIC terminal, a HPH-R terminal, a HPH-L terminal, and a HS-DET terminal, wherein the HS-DET terminal comprises a normally closed structure or a normally open structure.
[0015] In some embodiments, the first segment of pins is connected to the GND terminal and the MIC terminal through respective corresponding switches, for selecting to establish a communication connection.
[0016] The second segment of pins is connected to the GND terminal and the MIC terminal through respective corresponding switches, for selecting to establish a communication connection.
[0017] In some embodiments, the insertion detection signal HS-DET of the detection circuit is communicated with the processor through the UART interface of the single-chip microcomputer.
[0018] In some embodiments, after the closing operation of the switch is completed to establish the communication connection, the method further comprises:
[0019] The current connection state is verified to determine whether it conforms to the American standard or the German standard mode set by the user.
[0020] In some embodiments, the verification of the current connection state to determine whether it conforms to the American standard or the German standard mode set by the user comprises:
[0021] The voltage and current values between the first segment of pins and the second segment of pins and the GND terminal and the MIC terminal are detected, and the detected parameters are compared with the standard parameters in the American standard or the German standard mode. If the parameter deviation is within the allowable range, it is determined that the connection state conforms to the set mode. If the deviation exceeds the allowable range, it is determined that the connection is abnormal.
[0022] If the connection is abnormal, an alarm signal is generated to prompt the user to check the connection or re-set the mode.
[0023] The disclosure embodiments provide a configuration device for adaptive headset interface standards based on a detection circuit, which comprises:
[0024] The acquisition module is configured to acquire the HS-DET normally open / normally closed mode setting of the user.
[0025] The acquisition module is further configured to acquire the American standard / German standard mode setting of the user.
[0026] The control module is configured to control the switch between the first segment pin of the detection circuit and the GND terminal to establish a communication connection, and control the switch between the second segment pin of the detection circuit and the MIC terminal to establish a communication connection when the American standard mode is adopted.
[0027] The control module is further configured to control the switch between the first segment pin of the detection circuit and the MIC terminal to establish a communication connection, and control the switch between the second segment pin of the detection circuit and the GND terminal to establish a communication connection when the national standard mode is adopted.
[0028] The electronic device provided by the embodiment of the present disclosure comprises at least one processor;
[0029] and a memory in communication connection with the at least one processor;
[0030] The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the configuration method of the adaptive earphone interface standard based on the detection circuit.
[0031] The embodiment of the present disclosure provides a non-transient computer readable storage medium storing computer instructions for causing the computer to perform the configuration method of the adaptive earphone interface standard based on the detection circuit.
[0032] The configuration method, device, equipment and storage medium of the adaptive earphone interface standard based on the detection circuit provided by the embodiment of the present disclosure can achieve the following technical effects:
[0033] The present disclosure can meet the earphone design of the American standard and the national standard by acquiring the insertion detection signal HS-DET, determining the HS-DET normally open / closed mode, and switching the functions of the first segment pin and the second segment pin of the detection circuit, and can also meet the design of the earphone insertion detection signal normally open / closed of different models of earphone sockets, thereby solving the problem of incompatibility of earphones of different standards.
[0034] The general description above and the description below are merely exemplary and explanatory, and are not intended to limit the present application. BRIEF DESCRIPTION OF DRAWINGS
[0035] One or more embodiments are exemplarily illustrated by corresponding drawings, which are not intended to limit the embodiments, and elements with the same reference numerals in the drawings are shown as similar elements, the drawings do not constitute a proportional limit, and wherein:
[0036] Figure 1 is a flow diagram of a configuration method of an adaptive earphone interface standard based on a detection circuit provided by the embodiment of the present disclosure.
[0037] Figure 2 Schematic diagram of a normally closed structure of an insertion detection signal (HS-DET) provided in an embodiment of the present disclosure;
[0038] Figure 3 Schematic diagram of a normally open structure of an insertion detection signal (HS-DET) provided in an embodiment of the present disclosure;
[0039] Figure 4 is a schematic diagram of an HS-DET signal transmission link provided by an embodiment of the present disclosure;
[0040] Figure 5 This is a schematic diagram of a pop-up window for selecting a headset design mode in a system provided by an embodiment of the present disclosure;
[0041] Figure 6 This is a schematic diagram of the definition of an American standard four-section headset interface provided by an embodiment of the present disclosure;
[0042] Figure 7 This is a schematic diagram of a national standard four-section headset interface definition provided by an embodiment of the present disclosure;
[0043] Figure 8 This is a schematic diagram of a four-stage headset interface design compatible with national and American standards provided by an embodiment of the present disclosure;
[0044] Figure 9 This is a schematic block diagram of a configuration device for an adaptive headset interface standard based on a detection circuit provided by an embodiment of the present disclosure;
[0045] Figure 10 1 is a schematic diagram of a configuration device for an adaptive headset interface standard based on a detection circuit provided in an embodiment of the present disclosure. DETAILED DESCRIPTION
[0046] In order to be able to understand the features and technical content of the embodiments of the present disclosure in more detail, the implementation of the embodiments of the present disclosure is described in detail below in conjunction with the accompanying drawings. The accompanying drawings are for reference only and are not used to limit the embodiments of the present disclosure. In the following technical description, for the sake of convenience of explanation, a full understanding of the disclosed embodiments is provided through multiple details. However, one or more embodiments can still be implemented without these details. In other cases, to simplify the drawings, well-known structures and devices can be simplified for display.
[0047] The terms "first," "second," and the like in the embodiments of the present disclosure are used to distinguish similar objects and are not necessarily used to describe a particular order or precedence. It should be understood that the terms used in this manner are interchangeable where appropriate to facilitate the description of the embodiments of the present disclosure herein. Furthermore, the terms "including," "having," and any variations thereof are intended to cover non-exclusive inclusions.
[0048] Unless otherwise stated, the term "plurality" means two or more.
[0049] In the embodiment of the present disclosure, the character " / " indicates that the preceding and following objects are in an "or" relationship. For example, A / B means: A or B.
[0050] The term "and / or" describes an association between objects, indicating that three relationships can exist. For example, A and / or B means: A or B, or A and B.
[0051] The term "correspondence" may refer to an association relationship or a binding relationship. The correspondence between A and B means that there is an association relationship or a binding relationship between A and B.
[0052] In order to solve the above problems, the present disclosure provides a method, apparatus, device and storage medium for configuring an adaptive headset interface standard based on a detection circuit.
[0053] The following describes the configuration method, apparatus, device, and storage medium for the adaptive headset interface standard based on the detection circuit provided by the embodiments of the present disclosure in conjunction with the accompanying drawings.
[0054] Figure 1 The present invention provides a flow chart of a method for configuring an adaptive headset interface standard based on a detection circuit according to an embodiment of the present invention.
[0055] Combine Figure 1 As shown, the configuration method of the adaptive headset interface standard based on the detection circuit may include:
[0056] S101, obtaining the user's HS-DET normally open / normally closed mode setting;
[0057] S102, obtaining the user's American standard / Chinese standard mode setting;
[0058] S103, when the American standard mode is adopted, the switch between the first section pin of the detection circuit and the GND terminal is closed to establish a communication connection, and the switch between the second section pin of the detection circuit and the MIC terminal is closed to establish a communication connection;
[0059] S104, when the national standard mode is adopted, the switch between the first section pin of the detection circuit and the MIC end is closed to establish a communication connection, and the switch between the second section pin of the detection circuit and the GND end is closed to establish a communication connection.
[0060] Figure 2 Schematic diagram of a normally closed structure of an insertion detection signal (HS-DET) provided by an embodiment of the present disclosure. Figure 3 Schematic diagram of a normally open structure of an insertion detection signal (HS-DET) provided by an embodiment of the present disclosure. Figure 4 is a schematic diagram of an HS-DET signal transmission link provided by an embodiment of the present disclosure, Figure 5 This is a schematic diagram of a pop-up window for selecting a headset design mode in a system provided by an embodiment of the present disclosure. Figure 6 This is a schematic diagram of the definition of an American standard four-section headset interface provided by an embodiment of the present disclosure. Figure 7 This is a schematic diagram of a national standard four-section headset interface definition provided by an embodiment of the present disclosure. Figure 8 This is a schematic diagram of a four-stage headset interface design compatible with the national standard and the American standard provided by the embodiment of the present disclosure. Figures 2 to 8 ,right Figure 1 The configuration method of the adaptive headset interface standard based on the detection circuit is further described in the following.
[0061] In some embodiments, Figure 1 The methods also include:
[0062] When the headset is plugged in, the headset insertion status is determined based on the change in the electrical level obtained by the detection circuit, and a pop-up window is generated to display the American standard / Chinese standard mode selection and the HS-DET normally open / normally closed mode selection.
[0063] In some embodiments, the detection circuit includes a MIC terminal, an HPH-R terminal, an HPH-L terminal, and a HS-DET terminal, wherein the HS-DET terminal includes a normally closed structure or a normally open structure.
[0064] In some embodiments, the first section pin is connected to the GND terminal and the MIC terminal through respective corresponding switches for selecting to establish a communication connection;
[0065] The second section of pins is connected to the GND end and the MIC end through their respective corresponding switches for selecting to establish a communication connection.
[0066] In some embodiments, the insertion detection signal HS-DET of the detection circuit is communicated with the processor via the microcontroller using a UART interface.
[0067] In some embodiments, after completing the switch closure operation to establish the communication connection, Figure 1 The method may further include:
[0068] Verify the current connection state, and determine whether it meets the user's set American or Chinese standard mode.
[0069] In some embodiments, the above verification of the current connection state, and determination of whether it meets the user's set American or Chinese standard mode, comprises:
[0070] Detect the voltage and current values between the first and second segments of pins and the GND and MIC ends, compare the detected parameters with the standard parameters in the American or Chinese standard mode, if the parameter deviation is within the allowable range, determine that the connection state meets the set mode, if the deviation exceeds the allowable range, determine that the connection is abnormal;
[0071] If the connection is abnormal, generate an alarm signal to prompt the user to check the connection or re-set the mode.
[0072] In a specific embodiment, the 3.5mm four-segment earphone and its circuit design of the present application include a plug part and a circuit part.
[0073] To detect the earphone insertion, an earphone insertion detection pin is designed on the earphone interface. The insertion detection signal of some models of earphone connectors is normally closed with GND, and after inserting the earphone, the insertion detection signal and GND are disconnected and suspended. The insertion detection signal of some models of earphone connectors is suspended, and after inserting the earphone, it is closed with GND and becomes low level.
[0074] Connect the insertion detection signal HS-DET to the single-chip microcomputer, and after detecting the earphone insertion, there will be a level change of high level→low level→high level, the single-chip microcomputer will upload this level change to the processor, and a pop-up window function is set in the system, which is used to set the American / Chinese standard, insertion detection signal HS-DET normally open / closed mode selection. In this embodiment, the default selection is Chinese standard, insertion detection signal HS-DET normally open mode.
[0075] By Figure 6 and Figure 7 As can be seen, the signal definitions of the American and Chinese standard four-segment earphone interfaces differ in the order of GND and MIC signals. To ensure compatibility of the design with American / Chinese standard earphones, an analog switch is used to realize the switching of signal definition in the design of the following two pins. When using American earphones, switches K1 and K4 are closed, and K2 and K3 are disconnected, and when using Chinese standard earphones, switches K2 and K3 are closed, and K1 and K4 are disconnected.
[0076] The adaptive earphone interface standard configuration method based on the detection circuit can meet the design of the earphone of the American standard and the Chinese standard, can meet the design of the earphone insertion detection signal of the earphone socket of different models, and can solve the problem that earphones of different standards cannot be compatible.
[0077] With Figure 1 Corresponding to the flowchart of the adaptive earphone interface standard configuration method based on the detection circuit, the adaptive earphone interface standard configuration device based on the detection circuit is also provided. Figure 9 As shown in the adaptive earphone interface standard configuration device based on the detection circuit, the adaptive earphone interface standard configuration device based on the detection circuit can include:
[0078] The acquisition module 901 is configured to acquire the HS-DET normally open / closed mode setting of the user.
[0079] The acquisition module 901 is further configured to acquire the mode setting of the American standard / chinese standard of the user.
[0080] The control module 902 is configured to, when the American standard mode is adopted, control the switch between the first segment pin of the detection circuit and the GND end to be closed to establish a communication connection, and control the switch between the second segment pin of the detection circuit and the MIC end to be closed to establish a communication connection.
[0081] The control module 902 is further configured to, when the Chinese standard mode is adopted, control the switch between the first segment pin of the detection circuit and the MIC end to be closed to establish a communication connection, and control the switch between the second segment pin of the detection circuit and the GND end to be closed to establish a communication connection.
[0082] In some embodiments, the device described above can also, when the earphone is inserted, determine the earphone insertion condition based on the change of the level acquired by the detection circuit, and generate a pop-up window to display the mode selection of the American standard / chinese standard and the mode selection of the HS-DET normally open / closed.
[0083] In some embodiments, the detection circuit includes the MIC end, the HPH-R end, the HPH-L end, and the HS-DET end, wherein the HS-DET end includes a normally closed structure or a normally open structure.
[0084] In some embodiments, the first segment pin and the GND end and the MIC end are connected through respective corresponding switches, for selecting to establish a communication connection.
[0085] The second segment pin and the GND end and the MIC end are connected through respective corresponding switches, for selecting to establish a communication connection.
[0086] In some embodiments, the insertion detection signal HS-DET of the detection circuit is communicated with the processor by the single-chip microcomputer using the UART interface.
[0087] In some embodiments, after the communication connection is established by the closing operation of the switch, the device can further verify the current connection state to determine whether it conforms to the user-set American standard or Chinese standard mode.
[0088] In some embodiments, the verification of the current connection state to determine whether it conforms to the user-set American standard or Chinese standard mode comprises:
[0089] The voltage and current values between the first and second pins and the GND terminal and the MIC terminal are detected, and the detected parameters are compared with the standard parameters in the American standard or Chinese standard mode. If the parameter deviation is within the allowable range, it is determined that the connection state conforms to the set mode. If the deviation exceeds the allowable range, it is determined that the connection is abnormal.
[0090] If the connection is abnormal, an alarm signal is generated to prompt the user to check the connection or re-set the mode.
[0091] In combination with Figure 10 As shown in the accompanying drawings, the disclosure also provides a configuration device 1000 for adaptive earphone interface standards based on a detection circuit, which comprises a processor 1004 and a memory 1001. Optionally, the system can further comprise a communication interface 1002 and a bus 1003. The processor 1004, the communication interface 1002, and the memory 1001 can communicate with each other through the bus 1003. The communication interface 1002 can be used for information transmission. The processor 1004 can invoke the logical instructions in the memory 1001 to execute the configuration method for adaptive earphone interface standards based on a detection circuit in the above embodiments.
[0092] In addition, the logical instructions in the memory 1001 can be implemented in the form of a software functional unit and sold or used as an independent product. In this case, it can be stored in a computer-readable storage medium.
[0093] The memory 1001 is a computer-readable storage medium and can be used to store software programs, computer-executable programs, such as program instructions / modules corresponding to the method in the embodiments of the disclosure. The processor 1004 executes the function application and data processing by running the program instructions / modules stored in the memory 1001, that is, implements the configuration method for adaptive earphone interface standards based on a detection circuit in the above embodiments.
[0094] The memory 1001 may include a program storage area and a data storage area. The program storage area may store an operating system and at least one application required for a function; the data storage area may store data generated based on the use of the terminal device. Furthermore, the memory 1001 may include high-speed random access memory and non-volatile memory.
[0095] An embodiment of the present disclosure provides a computer-readable storage medium storing computer-executable instructions, wherein the computer-executable instructions are configured as a method for configuring an adaptive headset interface standard based on a detection circuit.
[0096] The aforementioned computer-readable storage medium may be a transient computer-readable storage medium or a non-transitory computer-readable storage medium.
[0097] The technical solution of the embodiments of the present disclosure may be embodied in the form of a software product, which is stored in a storage medium and includes one or more instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the method of the embodiments of the present disclosure. The aforementioned storage medium may be a non-transitory storage medium, including: a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, and other media that can store program code, or a transient storage medium.
[0098] The above description and drawings are illustrative of embodiments of the present disclosure and are not intended to be limiting. Other embodiments can include structural, logical, electrical, process, and other changes. Embodiments are illustrative of the many possible variations that are readily undertaken. Individual components and functions are optional unless explicitly required, and the order of operations can be varied. Portions and features of some embodiments can be included in, or substituted for, those of other embodiments. As used in the description of the embodiments, the article "a" is intended to include one or more items unless the context clearly indicates otherwise. Likewise, the term "and / or" as used in the application refers to any and all possible combinations of one or more of the associated listed items. Additionally, as used in this application, the term "comprises" and variations thereof do not intend to preclude the presence or addition of one or more other features, integers, steps, operations, elements, and / or groups thereof, but rather to encompass them. An element procured under the recitation "a..." does not, without additional recitation, exclude other identical elements of that element procured. Each embodiment is intended to cover its own variations and alternatives. For embodiments of methods, products, and the like, if they correspond to any of the method embodiments disclosed, then reference can be made to the description thereof.
[0099] Those skilled in the art can understand that the units and algorithm steps of each example described in combination with the embodiments disclosed herein can be realized in electronic hardware or a combination of computer software and electronic hardware. Whether the functions are realized in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the embodiments of the present disclosure. Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the above-described systems, devices and units can refer to the corresponding processes in the foregoing method embodiments, which will not be repeated here.
[0100] In the embodiments disclosed herein, the disclosed methods, products (including but not limited to apparatuses, devices, etc.) can be implemented in other manners. For example, the apparatus embodiments described above are merely schematic. For example, the division of the units is merely logical function division. There can be other division manners in actual implementation. For example, a plurality of units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the displayed or discussed mutual couplings or direct couplings or communication connections can be indirect couplings or communication connections through some interfaces, apparatuses, or units, and can be in electrical, mechanical, or other forms.
[0101] The flowcharts and block diagrams in the drawings show the possible implementation architectures, functions, and operations of the systems, methods, and computer program products according to the embodiments of the present disclosure. In this regard, each block in the flowcharts or block diagrams can represent a module, a program segment, or a part of code that contains one or more executable instructions for implementing a specified logical function. In some alternative implementations, the functions noted in the blocks can occur in an order different from that noted in the drawings. For example, two consecutive blocks can actually be executed substantially in parallel, and sometimes can be executed in reverse order, depending on the functions involved. In the descriptions corresponding to the flowcharts and block diagrams in the drawings, the operations or steps corresponding to different blocks can also occur in an order different from that disclosed in the descriptions, and sometimes there is no specific order between different operations or steps. For example, two consecutive operations or steps can actually be executed substantially in parallel, and sometimes can be executed in reverse order, depending on the functions involved. Each block in the block diagrams and / or flowcharts, and the combination of blocks in the block diagrams and / or flowcharts, can be implemented by a dedicated hardware-based system that performs the specified functions or actions, or can be implemented by a combination of dedicated hardware and computer instructions.
[0102] Various implementations of the systems and techniques described above can be realized in digital electronic circuitry, integrated circuitry, a field programmable gate array (FPGA), an application specific integrated circuit (ASIC), a system on a chip (SOC), a programmable logic device (PLD), a computer hardware, firmware, software, and / or combinations thereof. These various implementations can include implementation in one or more computer programs that are executable and / or interpretable on a programmable system including at least one programmable processor, which can be special or general purpose, coupled to receive data and instructions from, and to transmit data and instructions to, a storage system, at least one input device, and at least one output device.
[0103] Program code for carrying out methods of the present disclosure can be written in any combination of one or more programming languages. The program code can be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus to produce a machine, such that the program code, when executed by the processor or controller, produces the functions / operations specified in the flowcharts and / or the block diagrams. The program code can be executed entirely on a machine, partially on a machine, partially on a machine as a stand-alone software package, partially on a machine and partially on a remote machine or entirely on a remote machine or server.
[0104] In the context of the present disclosure, a machine-readable medium can be a tangible medium that contains or stores a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include but is not limited to an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of the machine-readable storage medium will include one or more lines of electrical connections, portable computer disks, hard disk drives, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or Flash memory), optical fibers, portable compact disc read-only memories (CD-ROMs), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
[0105] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).
[0106] The systems and techniques described herein can be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network (LAN), a wide area network (WAN), and the Internet.
[0107] A computer system may include a client and a server. The client and server are generally remote from each other and typically interact through a communication network. The client-server relationship arises from computer programs running on the respective computers and having a client-server relationship with each other. The server may be a cloud server, a server in a distributed system, or a server integrated with a blockchain.
[0108] It should be understood that the various forms of processes shown above can be used to reorder, add, or delete steps. For example, the steps described in this disclosure can be performed in parallel, sequentially, or in a different order, as long as the desired results of the technical solutions of this disclosure can be achieved, and this document is not limited here.
[0109] The above specific embodiments do not constitute a limitation on the scope of protection of this disclosure. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions may be made based on design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this disclosure shall be included within the scope of protection of this disclosure.
Claims
1. A method for configuring an adaptive headset interface standard based on a detection circuit, characterized in that: The method comprises: Get the user's HS-DET normally open / normally closed mode setting; Get the user's American standard / Chinese standard mode setting; When using the American standard mode, the switch between the first section pin of the detection circuit and the GND terminal is closed to establish a communication connection, and the switch between the second section pin of the detection circuit and the MIC terminal is closed to establish a communication connection; When the national standard mode is adopted, the switch between the first section pin of the detection circuit and the MIC end is closed to establish a communication connection, and the switch between the second section pin of the detection circuit and the GND end is closed to establish a communication connection.
2. The configuration method according to claim 1, characterized in that: The method further comprises: When the headset is plugged in, the headset insertion status is determined based on the change in the electrical level obtained by the detection circuit, and a pop-up window is generated to display the American standard / Chinese standard mode selection and the HS-DET normally open / normally closed mode selection.
3. The configuration method according to claim 1, wherein: The detection circuit includes a MIC terminal, an HPH-R terminal, an HPH-L terminal, and a HS-DET terminal, wherein the HS-DET terminal includes a normally closed structure or a normally open structure.
4. The configuration method according to claim 1, wherein: The first section of pins is connected to the GND terminal and the MIC terminal through their respective corresponding switches to select and establish a communication connection; The second section of pins is connected to the GND end and the MIC end through their respective corresponding switches for selecting to establish a communication connection.
5. The configuration method according to claim 1, wherein: The insertion detection signal HS-DET of the detection circuit communicates with the processor via the single chip microcomputer using the UART interface.
6. The configuration method according to claim 1, characterized in that: After completing the switch closing operation to establish the communication connection, the method further includes: Verify the current connection status to determine whether it complies with the American standard or national standard mode set by the user.
7. The configuration method according to claim 6, characterized in that: The verification of the current connection status to determine whether it complies with the American standard or Chinese standard mode set by the user includes: Detect the voltage and current values between the first and second segment pins and the GND and MIC terminals, and compare the detected parameters with the standard parameters in the American or national standard mode. If the parameter deviation is within the allowable range, the connection status is determined to be in compliance with the set mode; if the deviation exceeds the allowable range, the connection is determined to be abnormal. If the connection is abnormal, an alarm signal is generated to prompt the user to check the connection or reset the mode.
8. A device for configuring an adaptive headset interface standard based on a detection circuit, characterized in that: The device comprises: The acquisition module is used to obtain the user's HS-DET normally open / normally closed mode setting; The acquisition module is further used to obtain the user's American standard / Chinese standard mode setting; A control module, configured to control, when the American standard mode is adopted, closing a switch between the first section pin of the detection circuit and the GND terminal to establish a communication connection, and closing a switch between the second section pin of the detection circuit and the MIC terminal to establish a communication connection; The control module is also used to control the switch between the first section pin of the detection circuit and the MIC end to close and establish a communication connection, and to control the switch between the second section pin of the detection circuit and the GND end to close and establish a communication connection when the national standard mode is adopted.
9. An electronic device, characterized in that: include: at least one processor; and a memory communicatively coupled to the at least one processor; The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 7.
10. A non-transitory computer-readable storage medium storing computer instructions, characterized in that: The computer instructions are used to cause the computer to execute the method according to any one of claims 1 to 7.