CN109582270B - Method and device for multiplexing 3.5 mm interface and terminal equipment - Google Patents

Method and device for multiplexing 3.5 mm interface and terminal equipment Download PDF

Info

Publication number
CN109582270B
CN109582270B CN201811246842.XA CN201811246842A CN109582270B CN 109582270 B CN109582270 B CN 109582270B CN 201811246842 A CN201811246842 A CN 201811246842A CN 109582270 B CN109582270 B CN 109582270B
Authority
CN
China
Prior art keywords
signal
programmable gate
gate array
field programmable
interface
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.)
Active
Application number
CN201811246842.XA
Other languages
Chinese (zh)
Other versions
CN109582270A (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.)
Visionvera Information Technology Co Ltd
Original Assignee
Visionvera Information 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 Visionvera Information Technology Co Ltd filed Critical Visionvera Information Technology Co Ltd
Priority to CN201811246842.XA priority Critical patent/CN109582270B/en
Publication of CN109582270A publication Critical patent/CN109582270A/en
Application granted granted Critical
Publication of CN109582270B publication Critical patent/CN109582270B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/16Sound input; Sound output
    • G06F3/162Interface to dedicated audio devices, e.g. audio drivers, interface to CODECs
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/76Television signal recording
    • H04N5/765Interface circuits between an apparatus for recording and another apparatus

Abstract

The invention provides a method and a device for multiplexing a 3.5 mm interface and terminal equipment. The method comprises the following steps: the MCU detects the level of the 3.5 mm interface access signal, judges whether the access signal is an RS232 signal or an audio signal according to the detected level, the access signal is the RS232 signal, sends a first instruction to the field programmable gate array, converts the RS232 signal into the standard signal, the access signal is an audio signal, sends a second instruction to the field programmable gate array, performs filtering and noise reduction on the audio signal, performs analog-to-digital conversion on the audio signal, converts the audio signal into a digital signal corresponding to the audio signal, and the field programmable gate array converts the digital signal corresponding to the audio signal into the standard signal. The invention realizes the function of simultaneously receiving the analog signal and the digital signal by the 3.5 mm interface, ensures the appearance of the terminal equipment and simultaneously leads a user to more conveniently use the terminal equipment.

Description

Method and device for multiplexing 3.5 mm interface and terminal equipment
Technical Field
The present invention relates to the field of interfaces, and in particular, to a method and an apparatus for multiplexing a 3.5 mm interface, and a terminal device.
Background
The existing terminal equipment generally has various interfaces for receiving and transmitting various signals and completing different functions, the functions to be completed by the equipment are different, and the types of the interfaces are also different, so that the more functions a piece of equipment needs to complete, the more interfaces are needed.
The existing terminal equipment is developed towards intellectualization and miniaturization, the higher the intellectualization is, the more functions need to be completed, the more interfaces are needed, and meanwhile, the miniaturization of the terminal equipment needs to reduce the number of interfaces of external equipment on the terminal equipment, and the interfaces of the existing terminal equipment for connecting the external equipment comprise 3.5 mm interfaces.
The 3.5 mm interface on the existing terminal equipment is used for receiving audio and video analog signals, and can not directly receive digital signals, so the terminal equipment also needs to be specially provided with an interface for receiving digital signals, thus not only the use of users is inconvenient, but also the appearance of the terminal equipment is influenced, and the miniaturization of the terminal equipment becomes more difficult.
Disclosure of Invention
The invention provides a method and a device for multiplexing a 3.5 mm interface and terminal equipment, and solves the problem that the 3.5 mm interface on the terminal equipment cannot directly receive digital signals in the prior art.
In order to solve the above technical problem, an embodiment of the present invention provides a method for multiplexing a 3.5 mm interface, which is applied to a terminal device, where the terminal device includes an MCU, a 3.5 mm interface, and a field programmable gate array, and the method includes:
the MCU detects the level of the 3.5 mm interface access signal;
when detecting that the level of the 3.5 mm interface access signal is greater than or equal to a preset value, the MCU judges that the access signal is an RS232 signal and sends a first instruction to the field programmable gate array;
the field programmable gate array converts the RS232 signal into a standard signal based on a preset conversion relation between the RS232 signal and the standard signal according to the first instruction, and sends the standard signal to the MCU;
when detecting that the level of the 3.5 mm interface access signal is smaller than a preset value, the MCU judges that the access signal is an audio signal and sends a second instruction to the field programmable gate array;
and the field programmable gate array performs analog-to-digital conversion on the audio signal after filtering and denoising the audio signal according to the second instruction, converts the audio signal into a digital signal corresponding to the audio signal, converts the digital signal corresponding to the audio signal into the standard signal, and sends the standard signal to the MCU.
Optionally, the method for converting the standard signal into the RS232 signal and sending the standard signal to the MCU includes:
and the field programmable gate array calls the IP core of the RS 232-to-UART to convert the RS232 signal into the standard signal and sends the standard signal to the MCU according to the first instruction, and the IP core of the RS 232-to-UART is used for converting the RS232 serial port data signal into the parallel port data signal.
Optionally, the field programmable gate array includes a second IP core for analog-to-digital conversion, and the field programmable gate array performs analog-to-digital conversion on the audio signal after performing filtering and noise reduction on the audio signal according to the second instruction, and converts the audio signal into a digital signal corresponding to the audio signal, including:
and the field programmable gate array calls the IP core for analog-to-digital conversion to convert the audio signal into a digital signal corresponding to the audio signal according to the second instruction, and the IP core for analog-to-digital conversion is used for converting the analog signal into the digital signal.
Optionally, the field programmable gate array includes an audio-encoded IP core therein, and the field programmable gate array converts a digital signal corresponding to an audio signal into the standard signal, including:
and the field programmable gate array calls the IP core of the audio coding to convert the digital signal corresponding to the audio signal into the standard signal according to the second instruction, and sends the standard signal to the MCU, and the IP core of the audio coding is used for coding the digital signal corresponding to the audio signal into an I2S signal.
Optionally, the access signal is input by an interface converter, the interface converter is connected to the 3.5 mm interface, and the interface converter is used for the conversion connection between the 3.5 mm interface and an RS232 serial port for transmitting the RS232 signal. The method comprises the following steps:
the embodiment of the invention also provides terminal equipment, which comprises the MCU, a 3.5 mm interface and a field programmable gate array;
the MCU includes:
the detection module is used for detecting the level of the 3.5 mm interface access signal;
the first judgment sending module is used for judging that the access signal is an RS232 signal after the detection module detects that the level of the 3.5 mm interface access signal is greater than or equal to a preset value, and sending a first instruction to the field programmable gate array;
the second judgment sending module is used for judging that the access signal is an audio signal after the detection module detects that the level of the 3.5 mm interface access signal is less than a preset value, and sending a second instruction to the field programmable gate array;
the field programmable gate array includes:
the first conversion sending module is used for converting the RS232 signal into a standard signal based on a preset conversion relation between the RS232 signal and the standard signal according to the first instruction, and sending the standard signal to the MCU;
and the second conversion sending module is used for performing analog-to-digital conversion on the audio signal after filtering and denoising the audio signal according to the second instruction, converting the audio signal into a digital signal corresponding to the audio signal, converting the digital signal corresponding to the audio signal into the standard signal by the field programmable gate array, and sending the standard signal to the MCU.
The embodiment of the invention also provides a device for multiplexing the 3.5 mm interface, which is applied to terminal equipment, wherein the terminal equipment comprises an MCU, the 3.5 mm interface and a field programmable gate array, and the device comprises:
the detection module is used for detecting the level of the 3.5 mm interface access signal;
the first judgment and transmission module is used for judging that the access signal is an RS232 signal when the detection module detects that the level of the 3.5 mm interface access signal is greater than or equal to a preset value, and transmitting a first instruction to the field programmable gate array, wherein the field programmable gate array converts the RS232 signal into the standard signal based on a preset conversion relation between the RS232 signal and the standard signal according to the first instruction, and transmits the standard signal to the MCU;
and the second judgment sending module is used for judging that the access signal is an audio signal when the detection module detects that the level of the 3.5 mm interface access signal is smaller than a preset value, and sending a second instruction to the field programmable gate array, wherein the field programmable gate array performs analog-to-digital conversion on the audio signal after performing filtering and noise reduction on the audio signal according to the second instruction, converts the audio signal into a digital signal corresponding to the audio signal, and converts the digital signal corresponding to the audio signal into the standard signal and sends the standard signal to the MCU.
Optionally, the access signal is input by an interface converter, the interface converter is connected to the 3.5 mm interface, and the interface converter is used for the conversion connection between the 3.5 mm interface and an RS232 serial port for transmitting the RS232 signal.
Optionally, the field programmable gate array comprises:
the first conversion sending module is used for converting the RS232 signal into a standard signal based on a preset conversion relation between the RS232 signal and the standard signal according to the first instruction, and sending the standard signal to the MCU;
optionally, the field programmable gate array further comprises:
and the second conversion sending module is used for performing analog-to-digital conversion on the audio signal after filtering and denoising the audio signal according to the second instruction, converting the audio signal into a digital signal corresponding to the audio signal, converting the digital signal corresponding to the audio signal into the standard signal by the field programmable gate array, and sending the standard signal to the MCU.
Compared with the prior art, the method, the device and the terminal equipment for multiplexing the 3.5 mm interface provided by the invention judge whether the signal level is an analog signal or a digital signal by detecting the level of an access signal in the 3.5 mm interface on the terminal equipment, then call the field programmable gate array, convert the received signal into a standard signal by utilizing various preset IP cores in the field programmable gate array, realize the function of simultaneously receiving the analog signal and the digital signal by the 3.5 mm interface, and ensure the appearance of the terminal equipment and simultaneously enable a user to more conveniently use the terminal equipment.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the description of the embodiments of the present invention will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art that other drawings can be obtained according to these drawings without inventive labor.
FIG. 1 is a flow chart of a method of 3.5 mm interface multiplexing according to an embodiment of the present invention;
FIG. 2 is a detailed flowchart of one step of a method for multiplexing a 3.5 mm interface according to an embodiment of the present invention;
FIG. 3 is another detailed flowchart of one step of a method for multiplexing a 3.5 mm interface according to an embodiment of the present invention;
fig. 4 is a schematic diagram of a terminal device according to an embodiment of the present invention;
fig. 5 is a block diagram of a 3.5 mm interface multiplexing apparatus according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Fig. 1 shows a flowchart of a method for multiplexing a 3.5 mm interface according to an embodiment of the present invention. The method is applied to terminal equipment, the terminal equipment comprises an MCU (micro control Unit), a 3.5 mm interface and a field programmable gate array, and the specific method for multiplexing the 3.5 mm interface comprises the following steps:
step 101: and the MCU of the terminal equipment detects the level of the 3.5 mm interface access signal.
In the embodiment of the present invention, the MCU of the terminal device has a level detection function, the 3.5 mm interface is generally used for receiving audio/video analog signals, the plug corresponding to the interface is divided into two layers, three layers and four layers, when the plug is plugged into the interface, the two-layer plug level is generated by a single channel pair, the three-layer plug level is generated by a left channel or a right channel pair, and the four-layer plug level is generated by a left channel or a right channel or a microphone pair.
Step 102: when detecting that the level of the 3.5 mm interface access signal is greater than or equal to a preset value, the MCU of the terminal equipment judges that the access signal is an RS232 signal and sends a first instruction to the field programmable gate array.
In the embodiment of the invention, RS232 (asynchronous transmission standard interface established by the electronic industry association) signals are serial digital signals, the level value of the serial digital signals is 5V or above, because the pins used by the RS232 interface for signal transmission comprise a data sending pin, a data receiving pin and a grounding pin, the three-layer structure used by the 3.5 mm interface for signal transmission is met, the RS232 interface can be connected with the 3.5 mm interface by using an interface converter, the interface converter is used for physical form conversion of the 3.5 mm interface and the RS232 serial port for transmitting the RS232 signals, a voltage detection pin of an MCU of a terminal device is connected with the 3.5 mm interface, when the voltage detection pin of the MCU of the terminal device detects that the level of the 3.5 mm interface access signals is 5V or above, the access signals can be judged to be RS232 signals, and then a first instruction is sent to a field programmable gate array, the signal receiving pin of the field programmable gate array is connected with the 3.5 mm interface, 4.5V is generally set as a preset value in practical application, and the specific level value of the serial port digital signal and the set preset value are not specifically limited in the embodiment of the invention.
Step 103: and the field programmable gate array converts the RS232 signal into a standard signal based on a preset conversion relation between the RS232 signal and the standard signal according to the first instruction, and sends the standard signal to the MCU of the terminal.
The method comprises the steps that a field programmable gate array receives a first instruction sent by an MCU of a terminal device, the first instruction is used for enabling the field programmable gate array to start a first IP core, the core is stored with a conversion relation between an RS232 signal and a standard signal which are preset in advance, the RS232 signal can be converted into the standard signal by starting the first IP core, and the standard signal is a parallel port digital signal which can be identified and used by the MCU of the terminal device.
Optionally, referring to fig. 2, step 103 may further include the following steps:
step 103 a: and calling the IP core of the RS 232-to-UART to convert the RS232 signal into a standard signal and sending the standard signal to the MCU, wherein the IP core of the RS 232-to-UART is used for converting the RS232 serial port data signal into a parallel port data signal.
In the embodiment of the invention, the field programmable gate array comprises a first IP core of an RS 232-UART, the IP core can convert a digital signal of a serial port into a parallel port digital signal which can be identified and used by a terminal MCU, so that a chip or a device for converting the serial port digital signal into the parallel port digital signal is saved for the terminal device, a digital-to-analog conversion chip or a device is saved for the terminal device because a 3.5 mm interface can only receive an analog signal, the use of a user is greatly facilitated, and a first instruction sent by the MCU of the terminal device is used for enabling the field programmable gate array to start the first IP core.
Step 104: and when detecting that the level of the 3.5 mm interface access signal is less than a preset value, the MCU of the terminal judges that the access signal is an audio signal and sends a second instruction to the field programmable gate array.
In the embodiment of the invention, the audio signal is an analog signal, the level value of the audio signal is between 0 and 4V, when the voltage detection pin of the MCU of the terminal device detects that the level of the access signal of the 3.5 mm interface is 4V or below, the access signal can be judged to be the audio signal, then a second instruction is sent to the field programmable gate array, the signal receiving pin of the field programmable gate array is connected with the 3.5 mm interface, 4.5V is generally set as a preset value in practical application, and the specific level value and the set preset value of the audio analog signal are not specifically limited in the embodiment of the invention.
Step 105: and the field programmable gate array converts the digital signal corresponding to the audio signal into a standard signal and sends the standard signal to the MCU.
The field programmable gate array receives a second instruction sent by the MCU of the terminal device, the second instruction is used for enabling the field programmable gate array to filter and reduce noise of the audio frequency analog signal to obtain a stable analog signal, the field programmable gate array comprises a circuit for filtering and reducing noise, the analog signal is unstable and is easy to be interfered, therefore, audio and video signals received by the field programmable gate array may include more clutter, the field programmable gate array needs to filter and reduce noise, remove the clutter to obtain a stable analog signal, and then start an analog-to-digital conversion IP core and an audio coding IP core, the analog-to-digital conversion IP core is used for converting the analog signal into a digital signal, the audio coding IP core is used for coding the audio digital signal converted from the audio analog signal into an I2S signal, and the I2S is a signal that can be identified and used by the terminal MCU.
Optionally, referring to fig. 3, step 105 may further include the following steps:
step 105 a: and calling an IP core for analog-to-digital conversion to convert the audio signal into a digital signal corresponding to the audio signal, wherein the IP core for analog-to-digital conversion is used for converting the analog signal into the digital signal.
Step 105 b: the IP core calling the audio coding is used for converting the digital signal corresponding to the audio signal into a standard signal and transmitting the standard signal to the MCU, and the IP core calling the audio coding is used for coding the digital signal corresponding to the audio signal into an I2S signal.
In the embodiment of the invention, the field programmable gate array comprises an IP core for analog-to-digital conversion and an IP core for audio coding, the IP core of analog-to-digital conversion can convert the audio analog signal into a digital signal, so that a chip or a device for converting the analog signal into the digital signal is saved for the terminal device, the IP core of audio coding can code the audio digital signal converted from the audio analog signal into an I2S signal, the I2S signal can be identified and used by the terminal MCU, a coding chip or a device is also saved for the terminal device, great convenience is brought to a user, a second instruction sent by the MCU of the terminal device is used for enabling the field programmable gate array to filter and reduce noise of the audio analog signal to obtain a stable analog signal, and then the IP core of analog-to-digital conversion and the IP core of audio coding are started.
For example, a terminal device includes an MCU, a 3.5 mm interface and a field programmable gate array, the MCU of the terminal device has a level detection function, the 3.5 mm interface of the terminal device is used to receive audio/video analog signals, the 3.5 mm interface can be connected to two-layer, three-layer and four-layer plugs, when the plug is plugged into the interface, if the plug is a two-layer plug, the MCU detects the level generated by the single channel to the ground, if the plug is a three-layer plug, the MCU detects the level generated by the left channel or the right channel to the ground, and if the plug is a four-layer plug, the MCU detects the level generated by the left channel or the right channel or the microphone to the ground.
In this embodiment, a three-layer plug is used for example, a preset level value of 4.5V is set in an MCU, when the three-layer plug is inserted into a 3.5 mm interface, the MCU can determine that an access signal is an RS232 signal when detecting that the level of a left channel or a right channel of the 3.5 mm interface plug to ground is 4.5V or above, because the RS232 signal is a digital signal of a serial port, the level value of which is 5V or above, and after determining that the access signal is the RS232 signal, the MCU sends a first command to a field programmable gate array, it should be noted that a general RS232 serial port adopts a 9-pin or 25-pin interface structure, when the access to a 3.5 mm interface is required, an interface converter is required to be connected, and the interface converter is used for converting the physical form of the 3.5 mm interface and the RS232 serial port transmitting the RS232 signal, it can be understood that any serial port can realize the physical form conversion between the RS232 physical form and the 3.5 mm interface, or the manner or apparatus in which the RS232 signal is transmitted into the 3.5 mm interface, fall within the scope of the present invention.
The field programmable gate array receives a first instruction sent by an MCU of the terminal equipment, a first IP core of RS 232-to-UART is started, the first IP core can convert a digital signal of a serial port into a digital signal which can be identified by the terminal MCU, and a parallel port digital signal is used, so that the terminal equipment is externally connected with the RS232 serial port equipment through a 3.5 mm interface, a user can complete various functions by utilizing the externally connected RS232 serial port equipment, meanwhile, a chip or equipment for converting the serial port digital signal into the parallel port digital signal is saved for the terminal equipment, and only an analog signal can be received by the 3.5 mm interface, a digital-to-analog conversion chip or equipment is saved for the terminal equipment, the problem that the user needs to use the RS232 serial port equipment and additionally needs to add chips or equipment is solved, the use of the user is greatly facilitated, and the miniaturization of the terminal equipment is easy.
When the three-layer plug is inserted into the 3.5 mm interface, the MCU judges that the access signal is an audio signal when the level of the left channel or the right channel of the 3.5 mm interface plug to the ground is below 4.5V, because the audio signal is an analog signal and the level value thereof is between 0V and 4V, and after judging that the access signal is an audio signal, sends a second instruction to the field programmable gate array, it should be noted that, in general, the audio signal is transmitted by using the 3.5 mm physical plug and the interface, but the audio signal is not transmitted by using the 3.5 mm physical plug, and it can be understood that any mode or device capable of transmitting the audio signal into the 3.5 mm interface falls within the protection scope of the present invention.
The field programmable gate array receives a second instruction sent by the MCU of the terminal device, the audio analog signal is filtered and denoised to obtain a stable analog signal, then the IP core of analog-to-digital conversion and the IP core of audio coding are started, wherein the IP core of analog-to-digital conversion can convert the audio analog signal into a digital signal, the IP core of audio coding can encode the audio digital signal converted from the audio analog signal into an I2S signal, and the I2S signal can be identified and used by the terminal MCU, so that the terminal device is externally connected with the audio and video device through a 3.5 mm interface, a user can complete various functions by utilizing the externally connected audio and video device, and meanwhile, a chip or a device for converting the analog signal into the digital signal and a coding chip or a device are saved for the terminal device, and the terminal device is easy to miniaturize.
Optionally, referring to a schematic diagram of a terminal device shown in fig. 4, the terminal device includes an MCU, a 3.5 mm interface, and a field programmable gate array;
the MCU of the terminal equipment comprises:
the detection module 30 is used for detecting the level of the 3.5 mm interface access signal;
the first judging and sending module 10 is configured to judge that the access signal is an RS232 signal after the detection module detects that the level of the 3.5 mm interface access signal is greater than or equal to a preset value, and send a first instruction to the field programmable gate array;
the second judgment sending module 20 is configured to, after the detection module detects that the level of the 3.5 mm interface access signal is smaller than a preset value, judge that the access signal is an audio signal, and send a second instruction to the field programmable gate array;
the field programmable gate array includes:
the first conversion sending module 40 is configured to convert the RS232 signal into a standard signal based on a preset conversion relationship between the RS232 signal and the standard signal according to the first instruction, and send the standard signal to the MCU of the terminal device;
and the second conversion sending module 50 is configured to perform analog-to-digital conversion on the audio signal after filtering and denoising the audio signal according to the second instruction, convert the audio signal into a digital signal corresponding to the audio signal, convert the digital signal corresponding to the audio signal into a standard signal by the field programmable gate array, and send the standard signal to the MCU of the terminal device.
Optionally, referring to a block diagram of an apparatus for multiplexing a 3.5 mm interface shown in fig. 5, the apparatus is applied to a terminal device, the terminal device includes an MCU, a 3.5 mm interface and a field programmable gate array, the apparatus includes:
the detection module 300 is used for detecting the level of the 3.5 mm interface access signal;
the first judging and sending module 310 is configured to judge that the access signal is an RS232 signal when the detection module detects that the level of the 3.5 mm interface access signal is greater than or equal to a preset value, send a first instruction to the field programmable gate array, and the field programmable gate array converts the RS232 signal into a standard signal based on a preset conversion relationship between the RS232 signal and the standard signal according to the first instruction, and sends the standard signal to the MCU of the terminal device;
the second determination sending module 320 is configured to determine that the access signal is an audio signal when the detection module detects that the level of the 3.5 mm interface access signal is smaller than a preset value, send a second instruction to the field programmable gate array, perform analog-to-digital conversion on the audio signal after the field programmable gate array performs filtering and noise reduction on the audio signal according to the second instruction, convert the audio signal into a digital signal corresponding to the audio signal, convert the digital signal corresponding to the audio signal into a standard signal by the field programmable gate array, and send the standard signal to the MCU of the terminal device.
Through the embodiment, the 3.5 mm interface of the terminal equipment can be multiplexed, and only one interface can be used for connecting the audio and video equipment and the RS232 serial port equipment, so that the terminal equipment is easy to miniaturize while the appearance of the terminal equipment is ensured, and a user can more conveniently use the terminal equipment to complete more functions.
Finally, it should also be noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or terminal that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or terminal. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or terminal that comprises the element.
The method, the apparatus and the terminal device for multiplexing a 3.5 mm interface provided by the present invention are introduced in detail, and a specific example is applied in the text to explain the principle and the implementation of the present invention, and the description of the above embodiment is only used to help understanding the method and the core idea of the present invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present invention.

Claims (10)

1. A3.5 mm interface multiplexing method is applied to a terminal device, wherein the terminal device comprises an MCU, a 3.5 mm interface and a field programmable gate array, and the method comprises the following steps:
the MCU detects the level of the 3.5 mm interface access signal;
when detecting that the level of the 3.5 mm interface access signal is greater than or equal to a preset value, the MCU judges that the access signal is an RS232 signal and sends a first instruction to the field programmable gate array;
the field programmable gate array converts the RS232 signal into a standard signal based on a preset conversion relation between the RS232 signal and the standard signal according to the first instruction, and sends the standard signal to the MCU;
when detecting that the level of the 3.5 mm interface access signal is smaller than a preset value, the MCU judges that the access signal is an audio signal and sends a second instruction to the field programmable gate array;
and the field programmable gate array performs analog-to-digital conversion on the audio signal after filtering and denoising the audio signal according to the second instruction, converts the audio signal into a digital signal corresponding to the audio signal, converts the digital signal corresponding to the audio signal into the standard signal, and sends the standard signal to the MCU.
2. The method according to claim 1, wherein the field programmable gate array includes a first IP core of an RS 232-to-UART, and the field programmable gate array converts the RS232 signal into a standard signal based on a preset conversion relationship between the RS232 signal and the standard signal according to the first instruction, and sends the standard signal to the MCU, including:
and the field programmable gate array calls the IP core of the RS 232-to-UART to convert the RS232 signal into the standard signal and sends the standard signal to the MCU according to the first instruction, and the IP core of the RS 232-to-UART is used for converting the RS232 serial port data signal into the parallel port data signal.
3. The method of claim 1, wherein the second IP core for analog-to-digital conversion is included in the field programmable gate array, and the field programmable gate array performs analog-to-digital conversion on the audio signal after performing filtering and noise reduction on the audio signal according to the second instruction to convert the audio signal into a digital signal corresponding to the audio signal, and comprises:
and the field programmable gate array calls the IP core for analog-to-digital conversion to convert the audio signal into a digital signal corresponding to the audio signal according to the second instruction, and the IP core for analog-to-digital conversion is used for converting the analog signal into the digital signal.
4. The method of claim 1, wherein the field programmable gate array includes an audio-encoded IP core therein, and wherein the field programmable gate array converts a digital signal corresponding to an audio signal into the standard signal, comprising:
and the field programmable gate array calls the IP core of the audio coding to convert the digital signal corresponding to the audio signal into the standard signal according to the second instruction, and sends the standard signal to the MCU, and the IP core of the audio coding is used for coding the digital signal corresponding to the audio signal into an I2S signal.
5. The method of claim 1, wherein the access signal is input by an interface converter, the interface converter is connected to the 3.5 mm interface, and the interface converter is used for converting and connecting the 3.5 mm interface and an RS232 serial port for transmitting the RS232 signal.
6. The terminal equipment is characterized by comprising an MCU (microprogrammed control unit), a 3.5 mm interface and a field programmable gate array;
the MCU includes:
the detection module is used for detecting the level of the 3.5 mm interface access signal;
the first judgment sending module is used for judging that the access signal is an RS232 signal after the detection module detects that the level of the 3.5 mm interface access signal is greater than or equal to a preset value, and sending a first instruction to the field programmable gate array;
the second judgment sending module is used for judging that the access signal is an audio signal after the detection module detects that the level of the 3.5 mm interface access signal is less than a preset value, and sending a second instruction to the field programmable gate array;
the field programmable gate array includes:
the first conversion sending module is used for converting the RS232 signal into a standard signal based on a preset conversion relation between the RS232 signal and the standard signal according to the first instruction, and sending the standard signal to the MCU;
and the second conversion sending module is used for performing analog-to-digital conversion on the audio signal after filtering and denoising the audio signal according to the second instruction, converting the audio signal into a digital signal corresponding to the audio signal, converting the digital signal corresponding to the audio signal into the standard signal by the field programmable gate array, and sending the standard signal to the MCU.
7. The device for multiplexing the 3.5 mm interface is applied to terminal equipment, wherein the terminal equipment comprises an MCU (microprogrammed control unit), the 3.5 mm interface and a field programmable gate array, and the device comprises:
the detection module is used for detecting the level of the 3.5 mm interface access signal;
the first judgment and transmission module is used for judging that the access signal is an RS232 signal when the detection module detects that the level of the 3.5 mm interface access signal is greater than or equal to a preset value, and transmitting a first instruction to the field programmable gate array, wherein the field programmable gate array converts the RS232 signal into a standard signal based on a preset conversion relation between the RS232 signal and the standard signal according to the first instruction, and transmits the standard signal to the MCU;
and the second judgment sending module is used for judging that the access signal is an audio signal when the detection module detects that the level of the 3.5 mm interface access signal is smaller than a preset value, and sending a second instruction to the field programmable gate array, wherein the field programmable gate array performs analog-to-digital conversion on the audio signal after performing filtering and noise reduction on the audio signal according to the second instruction, converts the audio signal into a digital signal corresponding to the audio signal, and converts the digital signal corresponding to the audio signal into the standard signal and sends the standard signal to the MCU.
8. The apparatus of claim 7, wherein the access signal is input by an interface converter, the interface converter is connected to the 3.5 mm interface, and the interface converter is used for converting and connecting the 3.5 mm interface and an RS232 serial port for transmitting the RS232 signal.
9. The apparatus of claim 7, wherein the field programmable gate array comprises:
and the first conversion sending module is used for converting the RS232 signal into the standard signal based on a preset conversion relation between the RS232 signal and the standard signal according to the first instruction, and sending the standard signal to the MCU.
10. The apparatus of claim 7, wherein the field programmable gate array further comprises:
and the second conversion sending module is used for performing analog-to-digital conversion on the audio signal after filtering and denoising the audio signal according to the second instruction, converting the audio signal into a digital signal corresponding to the audio signal, converting the digital signal corresponding to the audio signal into the standard signal by the field programmable gate array, and sending the standard signal to the MCU.
CN201811246842.XA 2018-10-24 2018-10-24 Method and device for multiplexing 3.5 mm interface and terminal equipment Active CN109582270B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811246842.XA CN109582270B (en) 2018-10-24 2018-10-24 Method and device for multiplexing 3.5 mm interface and terminal equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811246842.XA CN109582270B (en) 2018-10-24 2018-10-24 Method and device for multiplexing 3.5 mm interface and terminal equipment

Publications (2)

Publication Number Publication Date
CN109582270A CN109582270A (en) 2019-04-05
CN109582270B true CN109582270B (en) 2022-03-25

Family

ID=65920545

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811246842.XA Active CN109582270B (en) 2018-10-24 2018-10-24 Method and device for multiplexing 3.5 mm interface and terminal equipment

Country Status (1)

Country Link
CN (1) CN109582270B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110225289B (en) * 2019-05-14 2021-07-30 视联动力信息技术股份有限公司 Conference terminal and interface signal conversion method
CN111698614B (en) * 2020-05-25 2021-10-26 歌尔光学科技有限公司 Audio output circuit and electronic equipment

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN2867768Y (en) * 2006-03-16 2007-02-07 上海通信技术中心 Compact structure coding device with IP newtork interface
CN101882120A (en) * 2009-05-06 2010-11-10 上海华虹集成电路有限责任公司 Device capable of automatically detecting micro controller unit (MCU) interfaces and realizing interface conversion
CN202077042U (en) * 2009-07-02 2011-12-14 北京瑞光极远数码科技有限公司 Wired-wireless co-network operating device
CN202454825U (en) * 2012-02-29 2012-09-26 湖北广兴通信科技有限公司 Two-wire interface recognition device
CN103729490A (en) * 2012-10-15 2014-04-16 飞思卡尔半导体公司 Mixed signal IP core prototype design system
CN205038637U (en) * 2015-10-15 2016-02-17 洛阳银杏科技有限公司 RS232 and RS485422 interface converter based on microprocessor
CN105681145A (en) * 2016-02-29 2016-06-15 南京航空航天大学 FPGA-based FlexRay communication module

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN2867768Y (en) * 2006-03-16 2007-02-07 上海通信技术中心 Compact structure coding device with IP newtork interface
CN101882120A (en) * 2009-05-06 2010-11-10 上海华虹集成电路有限责任公司 Device capable of automatically detecting micro controller unit (MCU) interfaces and realizing interface conversion
CN202077042U (en) * 2009-07-02 2011-12-14 北京瑞光极远数码科技有限公司 Wired-wireless co-network operating device
CN202454825U (en) * 2012-02-29 2012-09-26 湖北广兴通信科技有限公司 Two-wire interface recognition device
CN103729490A (en) * 2012-10-15 2014-04-16 飞思卡尔半导体公司 Mixed signal IP core prototype design system
CN205038637U (en) * 2015-10-15 2016-02-17 洛阳银杏科技有限公司 RS232 and RS485422 interface converter based on microprocessor
CN105681145A (en) * 2016-02-29 2016-06-15 南京航空航天大学 FPGA-based FlexRay communication module

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
Kailong Zhang ; Liang Hu ; Panfei Zuo ; Xiao Wu ; Kejian Miao.Wireless extension mechanism and logic design for FPGA-based Ethernet Powerlink node.《 2016 IEEE/ACIS 15th International Conference on Computer and Information Science (ICIS)》.2016,第1-7页. *
基于FPGA数字音频嵌入和解嵌AES3音频编码研究与设计;郑江;《中国优秀硕士学位论文全文数据库 信息科技辑》;20180715;第I136-94页 *

Also Published As

Publication number Publication date
CN109582270A (en) 2019-04-05

Similar Documents

Publication Publication Date Title
US7564966B2 (en) Recognition of audio device in portable terminal
CN109582270B (en) Method and device for multiplexing 3.5 mm interface and terminal equipment
US8412268B2 (en) Detection, identification and operation of pheripherals connected via an audio/video-plug to an electronic device
CN100343837C (en) Identification system and method for recognizing any one of a number of different types of devices
CN106569774B (en) Method and terminal for removing noise
CN104023294A (en) Interface multiplexing apparatus in terminal, and adaptor panel
EP2336895A2 (en) Electronic device and method thereof for identifying electronic accessory
KR100640347B1 (en) Apparatus and method for recognizing connection to digital camera or ear-microphone in a mobile communication terminal equipment
CN104602162B (en) External denoising device and its noise-reduction method for mobile terminal
CN105049636B (en) A kind of main wheat hole inspection method and hole inspection of terminal and device
CN104461952A (en) Interface sharing method and terminal
WO2016070531A1 (en) Audio port, information processing method, device, player, and storage medium thereof
CN104093114A (en) Detection device, system and method for headset buttons
CN109065017B (en) Voice data generation method and related device
CN103095913B (en) Dialing method and electronic device
CN107273087B (en) Audio input/output system, equipment and method based on Type-C interface
CN100426901C (en) Earphone and pushbutton detection device and method in mobile communication terminal
CN111082830B (en) Data loopback detection circuit of digital audio interface and digital audio equipment
CN113179377B (en) Signal switching method of VR equipment and VR equipment
CN216673050U (en) Telephone set
CN214070165U (en) Audio jack test tool and system for detecting audio jack
CN103401981B (en) A kind of method of initiating communication request and mobile terminal
CN109040649B (en) Call control method, device, equipment and computer readable medium
CN108347662A (en) Earphone
CN115563991A (en) Audio processing device, system and method

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