Sampling mode switching circuit and electronic equipment
By designing the sampling mode switching circuit and data acquisition circuit, automatic switching of the current voltage sampling mode and high-precision sampling are realized, solving the problems of complex operation, low safety and external interference in the prior art.
Patent Information
- Application Number
- CN202420978636.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Utility models(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-08
- Publication Date
- 2025-04-15
- Estimated Expiration
- 2034-05-08
AI Technical Summary
The existing current and voltage sampling and switching operations are cumbersome, low safety, and external electric field interference, which cannot meet the needs of high-precision sampling.
A sampling mode switching circuit is designed to automatically switch the current voltage sampling mode through the switching circuit, and the sampled signal is filtered in combination with the data acquisition circuit to improve the anti-interference.
It realizes simple switching of the current voltage sampling mode, improves operational safety and accuracy, and reduces the impact of external interference.
Smart Images

Figure CN222762212U_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of sampling technology, and in particular relates to a sampling mode switching circuit and an electronic device. Background Art
[0002] In industrial environments, collected analog signals such as current or voltage often need to be transmitted over long distances under the interference of various sensor signals, so there must be interference from external electric fields. Therefore, controllers (such as motor drivers, programmable logic controllers, and input-output controllers) are required to have high anti-interference and high-precision current analog input sampling modules and voltage analog input sampling modules when used in related products in industrial environments. In the prior art, the two modules are usually switched according to actual needs.
[0003] Currently, the voltage and current modes are mainly switched manually through hardware switches such as wiring caps. Users need to turn off the power, remove the wires, and disassemble the machine before switching the voltage and current modes through the wiring cap. The operation is cumbersome and complicated, and there are safety risks. In addition, the existing current analog input sampling modules and voltage analog input sampling modules are interfered by external electric fields and are not suitable for high-precision sampling.
[0004] Therefore, there is an urgent need for a sampling mode switching circuit that is simple to operate, highly safe and anti-interference. Utility Model Content
[0005] The purpose of the present application is to provide a sampling mode switching circuit and electronic equipment, aiming to solve the problems of high cost, complex operation, low safety and external electric field interference in existing current and voltage sampling switching.
[0006] The embodiment of the present application provides a sampling mode switching circuit, which has an input terminal for receiving an input signal, including:
[0007] a switching circuit connected to the input terminal and configured to sample the current signal to output a sampled voltage in response to a current mode switching signal, and transmit a voltage signal in response to a voltage mode switching signal;
[0008] A data acquisition circuit is connected to the switching circuit and converts the sampled voltage or the voltage signal into an analog voltage; wherein the analog voltage represents the voltage value of the sampled voltage or the voltage value of the voltage signal.
[0009] In one embodiment, the sampling mode switching circuit further includes:
[0010] The control circuit is connected to the input terminal, the switching circuit and the data acquisition circuit, and is configured to output the current mode switching signal in response to the input signal being a current signal, and to output the voltage mode switching signal in response to the input signal being a voltage signal.
[0011] In one embodiment, the control circuit includes a microprocessor;
[0012] The input terminal includes a positive input terminal and a negative input terminal;
[0013] The first universal input / output terminal of the microprocessor is connected to the positive input terminal, and the second universal input / output terminal of the microprocessor is connected to the negative input terminal. The first universal input / output terminal of the microprocessor and the second universal input / output terminal of the microprocessor are jointly used as the current signal input terminal of the control circuit or the voltage signal input terminal of the control circuit to input the current signal or the voltage signal; the third universal input / output terminal of the microprocessor is used as the current mode switching signal output terminal of the control circuit and the voltage mode switching signal output terminal of the control circuit, and is connected to the switching circuit to output the current mode switching signal or the voltage mode switching signal; the fourth universal input / output terminal of the microprocessor is used as the analog voltage input terminal of the control circuit, and is connected to the data acquisition circuit to input the analog voltage.
[0014] In one embodiment, the sampling mode switching circuit further includes:
[0015] The protection circuit is connected to the input terminal and the switching circuit and is configured to perform surge protection on the input signal.
[0016] In one embodiment, the protection circuit includes a transient voltage suppression tube;
[0017] The first end of the transient voltage suppression tube and the second end of the transient voltage suppression tube serve together as the input signal input end of the protection circuit and the input signal output end after surge protection of the protection circuit, and are connected to the input end and the switching circuit to input the input signal and output the input signal after surge protection.
[0018] In one embodiment, the sampling mode switching circuit further includes:
[0019] The filter circuit is connected to the data acquisition circuit and is configured to filter the analog voltage to output the filtered analog voltage.
[0020] In one of the embodiments, the filtering circuit includes a seventh resistor and a first capacitor;
[0021] The first end of the seventh resistor serves as the analog voltage input end of the filter circuit and is connected to the data acquisition circuit to input the analog voltage; the second end of the seventh resistor and the first end of the first capacitor serve together as the filtered analog voltage output end of the filter circuit and are connected to the control circuit to output the filtered analog voltage; the second end of the first capacitor is connected to the analog ground.
[0022] In one of the embodiments, the switching circuit includes a photocoupler and a first resistor;
[0023] The input terminal includes a positive input terminal and a negative input terminal;
[0024] The positive electrode of the photoelectric coupler serves as the current mode switching signal input terminal and the voltage mode switching signal input terminal of the switching circuit to input the current mode switching signal and the voltage mode switching signal; the first drain of the photoelectric coupler is connected to the first end of the first resistor, the second end of the first resistor is connected to the positive input terminal, the second drain of the photoelectric coupler is connected to the negative input terminal, the second end of the first resistor and the second drain of the photoelectric coupler serve together as the current signal input terminal, the sampling voltage output terminal, the voltage signal input terminal and the voltage signal output terminal of the switching circuit, and are also connected to the data acquisition circuit, wherein the current signal input terminal of the switching circuit is used to input the current signal, the sampling voltage output terminal of the switching circuit is used to output the sampling voltage, the voltage signal input terminal of the switching circuit is used to input the voltage signal, and the voltage signal output terminal of the switching circuit is used to output the voltage signal; the negative electrode of the photoelectric coupler is connected to the power ground.
[0025] In one embodiment, the data acquisition circuit includes an operational amplifier, a third resistor, a fourth resistor, a fifth resistor, and a sixth resistor;
[0026] The first end of the third resistor and the first end of the fourth resistor serve together as the sampling voltage input end and the voltage signal input end of the data acquisition circuit, and are connected to the switching circuit to input the sampling voltage or the voltage signal; the second end of the third resistor is connected to the positive phase input end of the operational amplifier and the first end of the sixth resistor, the second end of the sixth resistor and the negative power supply end of the operational amplifier are connected to the analog ground, and the positive power supply end of the operational amplifier is connected to the first power supply; the second end of the fourth resistor is connected to the inverting input end of the operational amplifier and the first end of the fifth resistor, the output end of the operational amplifier and the second end of the fifth resistor serve together as the analog voltage output end of the data acquisition circuit to output the analog voltage.
[0027] An embodiment of the present application further provides an electronic device, which includes the above-mentioned sampling mode switching circuit.
[0028] Compared with the prior art, the embodiments of the present application have the following beneficial effects: the current and voltage sampling modes are switched by a switching circuit without the need for manual operation of hardware switches such as wiring caps, thereby simplifying the operation and improving safety; the interference signal of the sampled voltage or voltage signal is filtered by a data acquisition circuit, thereby improving the anti-interference ability of the sampling mode switching circuit and achieving high-precision sampling. BRIEF DESCRIPTION OF THE DRAWINGS
[0029] In order to more clearly illustrate the technical application in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0030] Figure 1 A schematic diagram of a structure of a sampling mode switching circuit provided in an embodiment of the present application;
[0031] Figure 2 Another structural schematic diagram of a sampling mode switching circuit provided in an embodiment of the present application;
[0032] Figure 3 Another structural schematic diagram of a sampling mode switching circuit provided in an embodiment of the present application;
[0033] Figure 4 Another structural schematic diagram of a sampling mode switching circuit provided in an embodiment of the present application;
[0034] Figure 5 A partial exemplary circuit schematic diagram of a sampling mode switching circuit provided in an embodiment of the present application. DETAILED DESCRIPTION
[0035] In order to make the technical problems, technical solutions and beneficial effects to be solved by the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0036] It should be noted that when an element is referred to as being "fixed to" or "disposed on" another element, it can be directly on the other element or indirectly on the other element. When an element is referred to as being "connected to" another element, it can be directly connected to the other element or indirectly connected to the other element.
[0037] It should be understood that the orientation or position relationship indicated by terms such as "length", "width", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside" and "outside" are based on the orientation or position relationship shown in the drawings, and are only for the convenience of describing the present application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as a limitation on the present application.
[0038] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features. In the description of this application, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.
[0039] Figure 1 A schematic diagram of the structure of a sampling mode switching circuit provided in an embodiment of the present application is shown. For the sake of convenience, only the part related to the present embodiment is shown, which is described in detail as follows:
[0040] The sampling mode switching circuit has an input terminal for receiving an input signal, and includes a switching circuit 100 and a data acquisition circuit 200 .
[0041] The switching circuit 100 is connected to the input terminal and is configured to sample the current signal to output a sampled voltage in response to a current mode switching signal, and transmit a voltage signal in response to a voltage mode switching signal.
[0042] The data acquisition circuit 200 is connected to the switching circuit 100 and is configured to convert the sampled voltage or the voltage signal into an analog voltage; wherein the analog voltage represents the voltage value of the sampled voltage or the voltage value of the voltage signal.
[0043] Among them, the sampling voltage includes a positive sampling voltage and a negative sampling voltage, and the voltage signal includes a positive voltage signal and a negative voltage signal; the data acquisition circuit 200 is specifically configured to subtract the positive sampling voltage from the negative sampling voltage to output an analog voltage, or to subtract the positive voltage signal from the negative voltage signal to output an analog voltage.
[0044] The current and voltage sampling modes are switched by the switching circuit 100, and there is no need to manually operate hardware switches such as wiring caps, which simplifies the operation and improves safety. Interference signals will be introduced when the sampling voltage and voltage signal are input, and because the two wires are very close during the signal transmission process, the positive sampling voltage and the negative sampling voltage introduce the same external interference. The data acquisition circuit 200 subtracts the positive sampling voltage and the negative sampling voltage and outputs an analog voltage, filtering out the external interference on the positive sampling voltage and the negative sampling voltage. Similarly, the positive voltage signal and the negative voltage signal also introduce the same external interference. The data acquisition circuit 200 subtracts the positive voltage signal and the negative voltage signal and outputs an analog voltage, filtering out the external interference on the positive voltage signal and the negative voltage signal, thereby improving the anti-interference of the sampling mode switching circuit and achieving high-precision sampling. It should be noted that the sampling mode switching circuit can be applied to industrial environments and used for long-distance transmission of collected analog signals such as current or voltage.
[0045] By way of example and not limitation, Figure 2 As shown, the sampling mode switching circuit further includes a control circuit 300 .
[0046] The control circuit 300 is connected to the input terminal, the switching circuit 100 and the data acquisition circuit 200, and is configured to output a current mode switching signal in response to the input signal being a current signal, and to output a voltage mode switching signal in response to the input signal being a voltage signal.
[0047] In a specific implementation, the current mode switching signal can be set to a high level, and the voltage mode switching signal can be set to a low level.
[0048] In a specific implementation, the operator can also change the current mode switching signal and the voltage mode switching signal through the web page to perform current sampling or voltage sampling according to actual needs.
[0049] The control circuit 300 outputs a first-level switching signal and a second-level switching signal to control the switching circuit 100 to output a sampling voltage or a voltage signal. This is simple and convenient, and the user no longer needs to open the product housing to perform tedious operations such as changing the line.
[0050] By way of example and not limitation, Figure 3 As shown, the sampling mode switching circuit further includes a protection circuit 400 connected to the input terminal and the switching circuit 100 and configured to perform surge protection on the input signal.
[0051] The circuit safety is improved by the protection circuit 400 .
[0052] By way of example and not limitation, Figure 4As shown, the sampling mode switching circuit further includes a filtering circuit 500 connected to the data acquisition circuit 200 and configured to filter the analog voltage to output a filtered analog voltage.
[0053] The analog voltage is filtered by the filter circuit 500, thereby reducing interference and improving the quality of the analog voltage.
[0054] Figure 5 A partial exemplary circuit structure of a sampling mode switching circuit provided in an embodiment of the present application is shown. For the sake of convenience, only the part related to the embodiment of the present application is shown, which is described in detail as follows:
[0055] The control circuit 300 includes a microprocessor U1.
[0056] The input terminal includes a positive input terminal and a negative input terminal.
[0057] The first universal input and output terminal P1.0 of the microprocessor U1 is connected to the positive input terminal, and the second universal input and output terminal P1.1 of the microprocessor U1 is connected to the negative input terminal. The first universal input and output terminal P1.0 of the microprocessor U1 and the second universal input and output terminal P1.1 of the microprocessor U1 are jointly used as the current signal input terminal of the control circuit 300 or the voltage signal input terminal of the control circuit 300 to input the current signal or the voltage signal; the third universal input and output terminal P1.2 of the microprocessor U1 is used as the current mode switching signal output terminal of the control circuit 300 and the voltage mode switching signal output terminal of the control circuit 300, and is connected to the switching circuit 100 to output the current mode switching signal or the voltage mode switching signal; the fourth universal input and output terminal P1.3 of the microprocessor U1 is used as the analog voltage input terminal of the control circuit 300, and is connected to the data acquisition circuit 200 to input the analog voltage.
[0058] It should be noted that the microprocessor U1 can convert analog voltage into digital quantity to complete voltage acquisition or current acquisition. The microprocessor U1 can also select the corresponding working mode according to the level of the switching signal to perform operations in the current sampling corresponding mode or the voltage sampling corresponding mode.
[0059] The circuit is simple and reliable.
[0060] The protection circuit 400 includes a transient voltage suppressor (TVS) T1 .
[0061] The first end of the transient voltage suppressor tube T1 and the second end of the transient voltage suppressor tube T1 serve together as the input signal input end of the protection circuit 400 and the input signal output end after surge protection of the protection circuit 400, and are connected to the input end and the switching circuit 100 to input the input signal and output the input signal after surge protection.
[0062] Transient voltage suppressor tube T1 has fast response speed and strong protection capability.
[0063] The filter circuit 500 includes a seventh resistor R7 and a first capacitor C1.
[0064] The first end of the seventh resistor R7 serves as the analog voltage input end of the filter circuit 500, and is connected to the data acquisition circuit 200 to input the analog voltage; the second end of the seventh resistor R7 and the first end of the first capacitor C1 serve together as the filtered analog voltage output end of the filter circuit 500, and are connected to the control circuit 300 to output the filtered analog voltage; the second end of the first capacitor C1 is connected to the analog ground.
[0065] The circuit only uses resistors and capacitors, and has a simple circuit and low cost.
[0066] The switching circuit 100 includes a photocoupler A1 and a first resistor R1 .
[0067] The input terminal includes a positive input terminal and a negative input terminal.
[0068] The positive electrode of the photocoupler A1 serves as the current mode switching signal input terminal and the voltage mode switching signal input terminal of the switching circuit 100, so as to input the current mode switching signal and the voltage mode switching signal; the first drain of the photocoupler A1 is connected to the first end of the first resistor R1, the second end of the first resistor R1 is connected to the positive input terminal, the second drain of the photocoupler A1 is connected to the negative input terminal, the second end of the first resistor R1 and the second drain of the photocoupler A1 serve together as the current signal input terminal, the sampling voltage output terminal, the voltage signal input terminal and the voltage signal output terminal of the switching circuit 100, and the data acquisition circuit 200, wherein the current signal input terminal of the switching circuit 100 is used to input the current signal, the sampling voltage output terminal of the switching circuit 100 is used to output the sampling voltage, the voltage signal input terminal of the switching circuit 100 is used to input the voltage signal, and the voltage signal output terminal of the switching circuit 100 is used to output the voltage signal; the negative electrode of the photocoupler A1 is connected to the power ground.
[0069] It should be noted that the first resistor R1 may also be connected between the negative input terminal and the second drain of the photocoupler A1.
[0070] The switching circuit 100 may further include a second resistor R2, which may be connected between the positive electrode of the photocoupler A1 and the control circuit 300, or between the negative electrode of the photocoupler A1 and the power ground. The second resistor R2 is used to limit the current of the switching signal.
[0071] In a specific implementation, the photocoupler A1 may be a photorelay. The circuit only uses one photorelay, which is low in cost.
[0072] The input terminal and the control circuit 300 are isolated by the photocoupler A1, and the isolation voltage between the input terminal and the control circuit 300 can reach 3750Vrms. The input terminal and the control circuit 300 do not share a common ground, which further improves the anti-interference and accuracy of the sampling mode switching circuit.
[0073] The data acquisition circuit 200 includes an operational amplifier M1 , a third resistor R3 , a fourth resistor R4 , a fifth resistor R5 , and a sixth resistor R6 .
[0074] The first end of the third resistor R3 and the first end of the fourth resistor R4 are jointly used as the sampling voltage input end and the voltage signal input end of the data acquisition circuit 200, and are connected to the switching circuit 100 to input the sampling voltage or voltage signal; the second end of the third resistor R3 is connected to the positive phase input end of the operational amplifier M1 and the first end of the sixth resistor R6, the second end of the sixth resistor R6 and the negative power supply end of the operational amplifier M1 are jointly connected to the analog ground, and the positive power supply end of the operational amplifier M1 is connected to the first power supply; the second end of the fourth resistor R4 is connected to the inverting input end of the operational amplifier M1 and the first end of the fifth resistor R5, the output end of the operational amplifier M1 and the second end of the fifth resistor R5 are jointly used as the analog voltage output end of the data acquisition circuit 200 to output the analog voltage.
[0075] It should be noted that the data acquisition circuit 200 may further include a filter capacitor, and the filter capacitor may include a second capacitor C2, a third capacitor C3 and a fourth capacitor C4.
[0076] The voltage value of the sampled voltage is the product of the input current and the first resistor R1 , and the voltage value of the voltage signal is the voltage of the input signal.
[0077] The input end supports differential signal sampling. During the signal transmission process, since the two wires are very close, the two wires are subject to the same external interference, that is, U +扰动 =U -扰动 In a specific implementation, when interference enters along with the acquisition signal, after passing through the data acquisition circuit 200, the output interference signal may be U 扰动 =R5 / R4*(U +扰动 -U -扰动 )=0, where R6 / R3=R5 / R4, thus, the interference signal is filtered out. At the same time, for high-frequency interference signals, the operational amplifier M1 itself is also a first-order low-pass filter with closed-loop gain, which can filter out signals with 1.57 times the upper cutoff frequency of the operational amplifier, thereby further improving the anti-interference ability of the circuit.
[0078] The following is a combination of working principles Figure 5 As shown for further explanation:
[0079] The first universal input and output terminal P1.0 of the microprocessor U1 and the second universal input and output terminal P1.1 of the microprocessor U1 are connected to the input signal. If the input signal is a current signal, the microprocessor U1 outputs the current mode switch from the third universal input and output terminal P1.2 of the microprocessor U1 to the positive electrode of the photocoupler A1. The photocoupler A1 is switched on according to the current mode switch. At this time, it is the current sampling mode. Since the resistance value of the first resistor R1 is much smaller than the internal resistance of the operational amplifier M1, it can be considered that the input current flows into the first resistor R1 at this time. The input signal is current sampled through the first resistor R1. The second end of the first resistor R1 and the second drain of the photocoupler A1 jointly output the sampling voltage to the first end of the third resistor R3 and the first end of the fourth resistor R4. The subtraction circuit filters the interference of the sampling voltage, and outputs the analog voltage from the output end of the operational amplifier M1 and the second end of the fifth resistor R5 to the first end of the seventh resistor R7. At this time, the analog voltage represents the voltage value of the sampling voltage. The seventh resistor R7 and the first capacitor C1 filter the analog voltage and The filtered analog voltage is output from the second end of the seventh resistor R7 and the first end of the first capacitor C1 to the fourth general input and output terminal P1.3 of the microprocessor U1; if the input signal is a voltage signal, the microprocessor U1 outputs a voltage mode switching signal from the third general input and output terminal P1.2 of the microprocessor U1 to the positive electrode of the photoelectric coupler A1, and the photoelectric coupler A1 is disconnected according to the voltage mode switching signal. At this time, it is a voltage sampling mode. The second end of the first resistor R1 and the second drain of the photoelectric coupler A1 jointly output a voltage signal to the first end of the third resistor R3 and the first end of the fourth resistor R4. The data acquisition circuit 200 filters the interference of the voltage signal, and outputs an analog voltage from the output end of the operational amplifier M1 and the second end of the fifth resistor R5 to the first end of the seventh resistor R7. At this time, the analog voltage represents the voltage value of the voltage signal. The seventh resistor R7 and the first capacitor C1 filter the analog voltage, and output the filtered analog voltage from the second end of the seventh resistor R7 and the first end of the first capacitor C1 to the fourth general input and output terminal P1.3 of the microprocessor U1.
[0080] An embodiment of the present application further provides an electronic device, which includes the above-mentioned sampling mode switching circuit.
[0081] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
[0082] The embodiments described above are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, a person skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.
Claims
1. A sampling mode switching circuit having an input terminal for receiving an input signal, characterized in that: include: a switching circuit connected to the input terminal and configured to sample the current signal to output a sampled voltage in response to a current mode switching signal, and transmit a voltage signal in response to a voltage mode switching signal; A data acquisition circuit is connected to the switching circuit and converts the sampled voltage or the voltage signal into an analog voltage; wherein the analog voltage represents the voltage value of the sampled voltage or the voltage value of the voltage signal.
2. The sampling mode switching circuit according to claim 1, characterized in that: Also includes: The control circuit is connected to the input terminal, the switching circuit and the data acquisition circuit, and is configured to output the current mode switching signal in response to the input signal being a current signal, and to output the voltage mode switching signal in response to the input signal being a voltage signal.
3. The sampling mode switching circuit according to claim 2, characterized in that: The control circuit includes a microprocessor; The input terminal includes a positive input terminal and a negative input terminal; The first universal input / output terminal of the microprocessor is connected to the positive input terminal, the second universal input / output terminal of the microprocessor is connected to the negative input terminal, and the first universal input / output terminal of the microprocessor and the second universal input / output terminal of the microprocessor are used together as the current signal input terminal of the control circuit or the voltage signal input terminal of the control circuit to input the current signal or the voltage signal; The third general input and output terminal of the microprocessor is connected to the switching circuit as a current mode switching signal output terminal of the control circuit and a voltage mode switching signal output terminal of the control circuit to output the current mode switching signal or the voltage mode switching signal; The fourth general input / output terminal of the microprocessor is used as an analog voltage input terminal of the control circuit and is connected to the data acquisition circuit to input the analog voltage.
4. The sampling mode switching circuit according to claim 1, wherein: Also includes: The protection circuit is connected to the input terminal and the switching circuit and is configured to perform surge protection on the input signal.
5. The sampling mode switching circuit according to claim 4, characterized in that: The protection circuit includes a transient voltage suppression tube; The first end of the transient voltage suppression tube and the second end of the transient voltage suppression tube serve together as the input signal input end of the protection circuit and the input signal output end after surge protection of the protection circuit, and are connected to the input end and the switching circuit to input the input signal and output the input signal after surge protection.
6. The sampling mode switching circuit according to claim 1, wherein: Also includes: The filter circuit is connected to the data acquisition circuit and is configured to filter the analog voltage to output the filtered analog voltage.
7. The sampling mode switching circuit according to claim 6, characterized in that: The filtering circuit includes a seventh resistor and a first capacitor; The first end of the seventh resistor serves as the analog voltage input end of the filter circuit and is connected to the data acquisition circuit to input the analog voltage; the second end of the seventh resistor and the first end of the first capacitor serve together as the filtered analog voltage output end of the filter circuit and are connected to the control circuit to output the filtered analog voltage; the second end of the first capacitor is connected to the analog ground.
8. The sampling mode switching circuit according to any one of claims 1 to 7, characterized in that: The switching circuit includes a photocoupler and a first resistor; The input terminal includes a positive input terminal and a negative input terminal; The positive electrode of the photoelectric coupler serves as the current mode switching signal input terminal and the voltage mode switching signal input terminal of the switching circuit to input the current mode switching signal and the voltage mode switching signal; the first drain of the photoelectric coupler is connected to the first end of the first resistor, the second end of the first resistor is connected to the positive input terminal, the second drain of the photoelectric coupler is connected to the negative input terminal, the second end of the first resistor and the second drain of the photoelectric coupler serve together as the current signal input terminal, the sampling voltage output terminal, the voltage signal input terminal and the voltage signal output terminal of the switching circuit, and are also connected to the data acquisition circuit, wherein the current signal input terminal of the switching circuit is used to input the current signal, the sampling voltage output terminal of the switching circuit is used to output the sampling voltage, the voltage signal input terminal of the switching circuit is used to input the voltage signal, and the voltage signal output terminal of the switching circuit is used to output the voltage signal; the negative electrode of the photoelectric coupler is connected to the power ground.
9. The sampling mode switching circuit according to any one of claims 1 to 7, characterized in that: The data acquisition circuit includes an operational amplifier, a third resistor, a fourth resistor, a fifth resistor and a sixth resistor; The first end of the third resistor and the first end of the fourth resistor serve together as the sampling voltage input end and the voltage signal input end of the data acquisition circuit, and are connected to the switching circuit to input the sampling voltage or the voltage signal; the second end of the third resistor is connected to the positive phase input end of the operational amplifier and the first end of the sixth resistor, the second end of the sixth resistor and the negative power supply end of the operational amplifier are connected to the analog ground, and the positive power supply end of the operational amplifier is connected to the first power supply; the second end of the fourth resistor is connected to the inverting input end of the operational amplifier and the first end of the fifth resistor, the output end of the operational amplifier and the second end of the fifth resistor serve together as the analog voltage output end of the data acquisition circuit to output the analog voltage.
10. An electronic device, characterized in that: The method comprises the sampling mode switching circuit as claimed in any one of claims 1 to 9.