A dual-source input automatic switching circuit and method

By designing a dual-sound source input automatic switching circuit including an MCU control module, an electronic switch module and a comparator, the problem of inconvenient switching between broadcast signals and system voice signals in the prior art is solved, fast automatic switching and signal continuity are achieved, and operation complexity and cost are reduced.

CN114827826BActive Publication Date: 2025-05-20YANGZHOU FAMA INTELLIGENT EQUIP CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210234891.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-09
Publication Date
2025-05-20
Estimated Expiration
2042-03-09

AI Technical Summary

Technical Problem

The prior art cannot quickly and efficiently switch broadcast signals and system voice signals, and manual operations are required, resulting in the equipment requiring personnel to be on standby and prepare during work, affecting efficiency.

Method used

Design a dual-sound source input automatic switching circuit, including an MCU control module, an electronic switching module, an amplifier, a rectifying filter circuit and a reference voltage circuit, automatically switch signal channels through comparator and reference voltage circuit, and configure a delay circuit to ensure signal continuity.

Benefits of technology

It realizes rapid automatic switching between broadcast signals and system voice signals, ensures the continuity and stability of the signal, reduces the operation complexity and the possibility of human errors, and is low in cost, simple and reliable.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114827826B_ABST
    Figure CN114827826B_ABST
Patent Text Reader

Abstract

The invention discloses a dual-source input automatic switching circuit and method, comprising an MCU control module, an electronic switch module, an amplifier, a rectifier filter circuit, a reference voltage circuit and a configuration delay circuit; in the case where there is always a system voice signal input, if the controller detects that there is currently a broadcast signal input, the electronic switch is controlled to automatically switch to the broadcast signal input channel, and play the currently detected broadcast signal, and when the broadcast signal is finished and delayed for several seconds, it is automatically switched back to the system voice signal input channel; the invention configures a delay circuit to prevent the input of the system voice signal when the broadcast signal is paused, resulting in discontinuous broadcast signal input, and ensure the continuity of the broadcast signal; the broadcast signal and the system voice signal are automatically switched back and forth, and the switching speed is fast, the circuit components are few, the cost is low, the volume is small, simple and reliable, and the design is convenient.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of audio processing, and particularly relates to a dual-audio-source input automatic switching circuit and method. Background Art

[0002] With the continuous development of modern technology, various audio signals around us will be input into devices. Commonly used in products are broadcast signals and system voice signals, etc. In some urban traffic, broadcast signals and system voice signals are also beginning to be used. For example, the system voice signal prompts people traveling whether it is a red light prohibiting passage or a green light allowing passage. The broadcast signal is generally used by traffic police in work such as directing traffic on the road, maintaining traffic order, correcting and punishing traffic violations, handling traffic accidents, and maintaining public order. However, when they need to be switched, manual selection is required, inserting the required signal line into the device, or using a manual switch. For a certain path, just close the switch of the required path. But such a method cannot quickly and effectively achieve the desired effect and requires the operator to be on standby at any time during the operation of the device to manually switch the audio signal. Summary of the Invention

[0003] The technical problem solved by the present invention: Provide a dual-audio-source input automatic switching circuit and method with fast automatic switching of broadcast signals and system voice signals, low cost, simplicity and reliability.

[0004] Technical Solution: To solve the above technical problem, the technical solution adopted by the present invention is as follows:

[0005] A dual-audio-source input automatic switching circuit includes an MCU control module, an electronic switch module, an amplifier, a rectifier filter circuit, and a reference voltage circuit; the system voice signal and the broadcast signal are respectively connected to the electronic switch module, a reverse proportional amplifier, a rectifier filter circuit, and a comparator are connected in sequence, and the reference voltage circuit is connected to the reverse proportional amplifier and the comparator to provide a reference voltage for the broadcast signal inverting amplifier and the broadcast signal comparator; the output end of the comparator is connected to the MCU main control circuit, outputting a high level or a low level to the MCU main control circuit, and the MCU main control circuit is connected to the electronic switch module to control the electronic switch module to switch the system voice signal input channel and the broadcast signal input channel according to the output level of the comparator.

[0006] Further, it further includes a configuration delay circuit, and the configuration delay circuit is connected to the MCU main control circuit to provide a delay signal;

[0007] Further, the configuration delay circuit includes a resistor R15, a resistor R16, a resistor R17, and an S1 dip switch.

[0008] Further, the amplifier uses an inverting proportional amplifier, which includes a resistor R9, a capacitor C6, a resistor R6, and a dual operational amplifier U1A. The reference voltage circuit is connected to the non-inverting input terminal of the dual operational amplifier U1A to provide a reference voltage. The broadcast signal is connected to the inverting input terminal of the dual operational amplifier U1A through the resistor R9. The resistor R6 and the capacitor C6 are connected in parallel between the inverting input terminal and the output terminal of the dual operational amplifier U1A.

[0009] Further, the comparator includes a voltage-dividing resistor R11, a voltage-dividing resistor R12, a pull-up resistor R7, a filtering capacitor C8, and a dual operational amplifier U1B. The output terminal of the rectifying and filtering circuit is connected to the non-inverting input terminal of the dual operational amplifier U1B through the voltage-dividing resistor R11, and the output terminal of the rectifying and filtering circuit is grounded through the voltage-dividing resistor R12. The reference voltage circuit is connected to the inverting input terminal of the dual operational amplifier U1B. The output terminal of the dual operational amplifier U1B is grounded through the filtering capacitor C8 and is connected to the power supply through the pull-up resistor R7. The output terminal of the dual operational amplifier U1B is connected to the MCU main control circuit.

[0010] Further, the electronic switch module uses an M74HC4066 electronic switch module.

[0011] Further, the MCU control module realizes the time counting of detecting the broadcast signal and the delay, and controls the electronic switch. When the MCU main control circuit detects a high-level trigger for an internal interrupt of the MCU, the MCU main control circuit outputs a high level, causing the electronic switch to switch from the system voice signal channel to the broadcast signal channel and play the input content of the broadcast signal. If there is no broadcast signal input at this time, it will be delayed for 1 to 8 seconds, and the electronic switch will be switched back to the system voice channel.

[0012] An audio switching method includes: when there is always a system voice signal input, if the controller detects that there is a broadcast signal input currently, it controls the electronic switch to automatically switch to the broadcast signal input channel and play the currently detected broadcast signal. After the broadcast signal is played and delayed for several seconds, it automatically switches back to the system voice signal input channel.

[0013] Beneficial effects: Compared with the prior art, the present invention has the following advantages:

[0014] (1) In the dual audio source input automatic switching circuit of the present invention, when the MCU controls the M74HC4066 electronic switch to switch to the broadcast signal input channel, if there is suddenly no broadcast signal input, after the MCU detects and judges and confirms that there is no broadcast signal input, the MCU will delay according to the configured delay time (1 to 8 seconds). The present invention configures a delay circuit to prevent the input of the system voice signal when the broadcast signal pauses, resulting in the discontinuous input of the broadcast signal; ensuring the continuity of the broadcast signal.

[0015] (2) The comparator circuit and the M74HC4066 electronic switch of the present invention switch the signal channels, ensuring the quick back-and-forth switching between the broadcast signal and the system voice signal. The circuit has fewer components, lower cost, smaller size, is simple and reliable, and is convenient for design.

[0016] (3) The reference voltage circuit of the present invention eliminates small-signal interference when there is no audio signal input. Description of the Drawings

[0017] Figure 1 is the principle block diagram of the automatic switching circuit for dual audio sources input;

[0018] Figure 2 is the schematic diagram of the automatic switching circuit for dual audio sources input;

[0019] Figure 3 is the method flow chart of the automatic switching circuit for dual audio sources input. Detailed Embodiments

[0020] The following further clarifies the present invention in conjunction with specific embodiments. The embodiments are implemented on the premise of the technical solution of the present invention. It should be understood that these embodiments are only used to illustrate the present invention and not to limit the scope of the present invention.

[0021] As Figure 1 shown, the automatic switching circuit for dual audio sources input of the present application includes an inverting proportional amplifier, a comparator, an MCU control module, a configuration delay circuit, an M74HC4066 electronic switch module, a reference voltage circuit, and a rectifier filter circuit.

[0022] The system voice signal and the broadcast signal are respectively connected to the electronic switch module, and the electronic switch module is connected to the signal output end. The broadcast signal is input to the inverting proportional amplifier, and the inverting proportional amplifier, the rectifier filter circuit, and the comparator are connected in sequence. The reference voltage circuit is connected to the inverting proportional amplifier and the comparator, providing a reference voltage for the broadcast signal inverting amplifier and the broadcast signal comparator, and can eliminate small-signal interference to a certain extent. The output end of the comparator is connected to the MCU main control circuit, outputting a high level or a low level to the MCU main control circuit. The MCU main control circuit is connected to the electronic switch module to control the electronic switch module to switch the system voice signal input channel and the broadcast signal input channel; at the same time, the configuration delay circuit is connected to the MCU main control circuit, and the MCU main control circuit can perform a delay operation according to the user-set time.

[0023] Inverting proportional amplifier, which amplifies the input broadcast signal by 100 times, is composed of resistor R9, capacitor C6, resistor R6 and dual operational amplifier LM258 (U1A). The reference voltage circuit is connected to the non-inverting input terminal of the dual operational amplifier LM258 to provide a reference voltage. The broadcast signal is connected to the inverting input terminal of the dual operational amplifier LM258 via resistor R9. Resistor R6 and capacitor C6 are connected in parallel between the inverting input terminal and the output terminal of the amplifier.

[0024] Rectifier filter circuit: Rectifies and filters the broadcast signal amplified by the inverting proportional amplifier.

[0025] Comparator: It is composed of voltage-dividing resistor R11, voltage-dividing resistor R12, pull-up resistor R7, filtering capacitor C8 and dual operational amplifier LM258 (U1B). The output terminal of the rectifier filter circuit is connected to the non-inverting input terminal of LM258 via voltage-dividing resistor R11, and a voltage-dividing resistor R12 is connected between the output terminal of the rectifier filter circuit and the ground. The reference voltage circuit is connected to the inverting input terminal of LM258. The output terminal of LM258 is grounded via filtering capacitor C8 and is connected to the power supply via pull-up resistor R7; the output terminal of LM258 is connected to the (6th pin MISO) of the MCU main control circuit. Compares the rectified and filtered broadcast signal with the reference voltage circuit. When there is a rectified and filtered broadcast signal input, after being divided by the resistor and input to the comparator, the comparator outputs a high level to the 6th pin MISO of the MUC, otherwise it outputs a low level.

[0026] M74HC4066 electronic switch module: Switches the broadcast signal and the system voice signal back and forth.

[0027] Configuration delay circuit: It is composed of resistor R15, resistor R16, resistor R17 and S1 DIP switch. Sets a delay time of 1 to 8 seconds. For each path of the DIP switch, one end is connected to the power supply, one end is grounded via a resistor and is connected to the MUC at the same time. One path is grounded via resistor R15 and is connected to the 3rd pin of the MCU at the same time. One path is grounded via resistor R16 and is connected to the 2nd pin of the MCU at the same time. One path is grounded via resistor R17 and is connected to the 1st pin of the MCU for reset; the other two paths except the reset terminal are used to set the delay time.

[0028] The MCU control module realizes the detection of the broadcast signal and the timing of the delay time, as well as the control of the M74HC4066 electronic switch. When the MCU (6th pin MISO) detects a high level, it triggers an internal interrupt of the MCU. The MCU (5th pin MOSI) outputs a high level, causing the M74HC4066 electronic switch to switch from the system voice signal channel to the broadcast signal channel and play the input content of the broadcast signal. If there is no broadcast signal input at this time, it will be delayed for 1 to 8 seconds, and the M74HC4066 electronic switch will switch back to the system voice channel.

[0029] The LM258 operational amplifier chip can be replaced by other models of operational amplifier chips.

[0030] The M74HC4066 electronic switch chip can be replaced by switch chips or relays of other models.

[0031] The MCU can be replaced by single-chip microcomputers of other models.

[0032] The diodes in the rectifier and filter circuit can be replaced by various rectifier diodes, switching diodes, and Schottky diodes.

[0033] Circuit working principle:

[0034] Since the system voice signal is directly connected to the M74HC4066 electronic switch module and the MCU (MOSI on pin 5) is initialized to a low level, the circuit is initially in a default conducting state for the system voice signal input channel and plays the content of the system voice signal input. When a broadcast signal is input, the broadcast signal passes through an inverting proportional amplifier, which amplifies the input broadcast signal by 100 times, and then is sent to the rectifier and filter circuit and then to the comparator. The comparator receives the rectified and filtered broadcast signal, and the comparator outputs a high level to the MCU (MISO on pin 6). When the MCU (MISO on pin 6) detects the high level, it triggers an internal trigger interrupt, and the MCU (MOSI on pin 5) outputs a low level, causing the M74HC4066 electronic switch to switch from the system voice signal input channel to the broadcast signal input channel and play the content of the broadcast signal input. If there is no broadcast signal input at this time and the MCU (MISO on pin 6) does not detect the high level, the MCU will delay for 1 - 8 seconds according to the time set by the user to prevent the input of the system voice signal during the pause of the broadcast signal, resulting in discontinuous broadcast signal input. After the delay, the MCU (MOSI on pin 5) outputs a high level to make the M74HC4066 electronic switch switch back from the broadcast signal input to the system voice channel, ending the audio switching operation.

[0035] The present invention also discloses an audio switching method. When there is always a system voice signal input, if the controller detects that there is a current broadcast signal input, it controls the electronic switch to automatically switch to the broadcast signal input channel and plays the currently detected broadcast signal. When the broadcast signal playback ends and after a few seconds of delay, it automatically switches back to the system voice signal input channel. The specific steps are as Figure 3 shown,

[0036] S1: First, initialize the device. The circuit is initially in a default conducting state for the system voice signal input channel;

[0037] S2: Set the delay time by configuring the delay circuit;

[0038] S3: The MCU detects whether a broadcast signal is input. If a broadcast signal is input, it controls the electronic switch to output the broadcast signal; if no broadcast signal is input, it continuously inputs the system voice signal;

[0039] S4: After outputting the broadcast signal, determine whether the broadcast signal has ended. If the broadcast signal has ended, maintain the broadcast signal path according to the set delay time. After the delay ends, return to the initialized state.

[0040] The present invention uses a primary-secondary method to switch between the broadcast signal and the system voice signal. The broadcast signal is the primary signal with higher priority, and the system voice is the secondary signal. The system always defaults to the input of the secondary system voice signal. When the MCU detects the input of the broadcast voice signal, it will quickly switch to the broadcast voice signal channel and play the currently detected broadcast signal. When the broadcast signal playback ends, the MCU will automatically switch back to the system voice signal input channel after a delay of 1 to 8 seconds (the delay can be set) according to the delay time set by the operator, thereby realizing audio switching.

[0041] The above are only the preferred embodiments of the present invention. It should be noted that for those of ordinary skill in the art, without departing from the principle of the present invention, several improvements and refinements can still be made, and these improvements and refinements should also be regarded as the protection scope of the present invention.

Claims

1. A dual-source input automatic switching circuit, characterized in that: include: MCU control module, electronic switch module, amplifier, rectifier filter circuit and reference voltage circuit; the system voice signal and broadcast signal are respectively connected to the electronic switch module, the reverse proportional amplifier, the rectifier filter circuit and the comparator are connected in sequence, the reference voltage circuit is connected to the reverse proportional amplifier and the comparator, and provides a reference voltage for the broadcast signal inverting amplifier and the broadcast signal comparator; the output end of the comparator is connected to the MCU main control circuit, and outputs a high level or a low level to the MCU main control circuit, and the MCU main control circuit is connected to the electronic switch module, and the electronic switch module is controlled to switch the system voice signal input channel and the broadcast signal input channel according to the output level of the comparator; The amplifier adopts an inverse proportional amplifier, which includes a resistor R9, a capacitor C6, a resistor R6 and a dual operational amplifier U1A. The reference voltage circuit is connected to the same-direction input terminal of the dual operational amplifier U1A to provide a reference voltage. The broadcast signal is connected to the inverse input terminal of the dual operational amplifier U1A via the resistor R9. The resistor R6 and the capacitor C6 are connected in parallel to the inverse input terminal and the output terminal of the dual operational amplifier U1A. The comparator includes a voltage-dividing resistor R11, a voltage-dividing resistor R12, a pull-up resistor R7, a filter capacitor C8 and a dual operational amplifier U1B, the output end of the rectifier and filter circuit is connected to the same-direction input end of the dual operational amplifier U1B via the voltage-dividing resistor R11, and the output end of the rectifier and filter circuit is grounded via the voltage-dividing resistor R12, the reference voltage circuit is connected to the reverse input end of the dual operational amplifier U1B, the output end of the dual operational amplifier U1B is grounded via the filter capacitor C8, and is connected to the power supply via the pull-up resistor R7; the output end of the dual operational amplifier U1B is connected to the MCU main control circuit; The system voice signal is directly connected to the electronic switch module. MCU5 pin MOSI is initialized to a low level. The circuit defaults to turn on the system voice signal input channel in the initial state and plays the system voice signal input content. When there is a broadcast signal input, the broadcast signal passes through the inverting proportional amplifier to amplify the input broadcast signal 100 times, and then is sent to the rectifier and filter circuit and then to the comparator. The comparator receives the rectified and filtered broadcast signal, and the comparator outputs a high level to MCU6 pin MISO. MCU6 pin MISO detects a high level to trigger an internal trigger interrupt, and MCU5 pin MOSI outputs a low level, so that the electronic switch module switches from the system voice signal input channel to the broadcast signal input channel and plays the content of the broadcast signal input. If there is no broadcast signal input at this time, MCU6 pin MISO does not detect a high level, and the MCU will delay 1 to 8 seconds according to the time set by the user to prevent the input of the system voice signal when the broadcast signal is paused, causing the broadcast signal input to be discontinuous. After the delay, MCU5 pin MOSI outputs a high level to switch the electronic switch module from the broadcast signal input back to the system voice channel, ending the audio switching work.

2. The dual-source input automatic switching circuit according to claim 1, characterized in that: It also includes a configuration delay circuit, which is connected to the MCU main control circuit to provide a delay signal.

3. The dual-source input automatic switching circuit according to claim 2, characterized in that: The configuration delay circuit includes a resistor R15, a resistor R16, a resistor R17 and an S1 dip switch.

4. The dual-source input automatic switching circuit according to claim 1, characterized in that: The electronic switch module adopts the M74HC4066 electronic switch module.

5. An audio switching method implemented by using the circuit described in any one of claims 1 to 4, characterized in that: include: When there is always a system voice signal input, if the controller detects that there is a broadcast signal input, the electronic switch is controlled to automatically switch to the broadcast signal input channel and play the currently detected broadcast signal. When the broadcast signal ends and is delayed for a few seconds, it automatically switches back to the system voice signal input channel. The specific steps are as follows: S1: First, the device is initialized. The circuit is initially turned on by default. S2: Set the delay time by configuring the delay circuit; S3: MCU detects whether a broadcast signal is input. If a broadcast signal is input, the electronic switch is controlled to output the broadcast signal; if no broadcast signal is input, the system voice signal is continuously input; S4: After the broadcast signal is output, it is determined whether the broadcast signal has ended. If the broadcast signal has ended, the broadcast signal path is maintained according to the set delay time. After the delay ends, it returns to the initialized state.

Citation Information

Patent Citations

  • Audio processing device

    CN104501826A

  • Take signal generator of fire control signal linkage function

    CN208224780U