Interconversion circuit of NPN type sensor and PNP type sensor
By designing the mutual conversion circuit of NPN and PNP type sensors, the combination of NPN transistor and PNP sensors is used to solve the problem of sensor type mismatch in the PLC system, signal conversion is realized, and installation and debugging are carried out smoothly.
Patent Information
- Application Number
- CN202422231960.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Utility models(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-12
- Publication Date
- 2025-07-22
- Estimated Expiration
- 2034-09-12
AI Technical Summary
In existing PLC systems, when NPN or PNP switches do not match the PLC type, the signal cannot be connected to the system, hindering the installation and debugging.
A mutual conversion circuit of NPN and PNP type sensors is designed to realize signal type conversion through the combination of NPN transistor and PNP sensor, including an NPN converter and a PNP converter, which are respectively used to convert PNP signals into NPN signals and NPN signals into PNP signals.
The matching conversion of different types of sensor signals is realized, avoiding the problem that the signals cannot be connected to the PLC system, and ensuring the smooth installation and debugging.
Smart Images

Figure CN223141907U_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the technical field of sensors, and in particular, to a circuit for converting between NPN and PNP type sensors. Background Art
[0002] For a PLC or DCS system that has been put into normal operation, when adding new technical renovation equipment and the proximity switch used is of the NPN type (or PNP type), it often occurs that the type of configured sensor does not match the type of PLC used. At the same time, due to selection or procurement time issues, it is impossible to replace, and in the case of very urgent construction period, it is easy to cause the signal to fail to be smoothly connected to the system, hindering the installation and debugging. Summary of the Utility Model
[0003] The embodiments of the present application provide a circuit for converting between NPN and PNP type sensors to solve the problem that when the existing PLC system uses an NPN type (or PNP type) switch, the signal is likely to fail to be connected to the system, hindering the installation and debugging.
[0004] In a first aspect, the embodiments of the present application provide a circuit for converting between NPN and PNP type sensors, including an NPN converter and a PNP converter;
[0005] The NPN converter includes an NPN triode and a PNP sensor. The base of the NPN triode is connected to the collector of the PNP sensor. The collector of the NPN triode is connected to the output terminal. The emitter of the NPN triode is connected to the negative power supply and the base of the PNP sensor. The emitter of the PNP sensor is connected to the positive power supply;
[0006] The PNP converter includes a PNP triode and an NPN sensor. The base of the PNP triode is connected to the collector of the NPN sensor. The emitter of the PNP triode is connected to the base of the NPN sensor and the positive power supply. The collector of the PNP triode is connected to the output terminal. The emitter of the NPN sensor is connected to the negative power supply.
[0007] In some embodiments, the NPN converter further includes a first resistor, and the first resistor is disposed at the base of the NPN triode.
[0008] In some embodiments, the NPN converter further includes a first switch, and the first switch is disposed at the base of the PNP sensor.
[0009] In some embodiments, the PNP converter further includes a second resistor, and the second resistor is disposed at the base of the PNP triode.
[0010] In some embodiments, the PNP converter further includes a second switch disposed at the base of the NPN sensor.
[0011] In some embodiments, the NPN converter further includes a first light-emitting diode and a third resistor. The positive electrode of the first light-emitting diode is connected to the positive electrode of the power supply, the negative electrode of the first light-emitting diode is connected to the first end of the third resistor, and the second end of the third resistor is connected to the negative electrode of the power supply.
[0012] In some embodiments, the NPN converter further includes a second light-emitting diode and a fourth resistor. The negative electrode of the second light-emitting diode is connected to the negative electrode of the power supply, the positive electrode of the second light-emitting diode is connected to the first end of the fourth resistor, and the second end of the fourth resistor is connected to the base of the NPN triode.
[0013] In some embodiments, the PNP converter further includes a third light-emitting diode and a fifth resistor. The positive electrode of the third light-emitting diode is connected to the positive electrode of the power supply, the negative electrode of the third light-emitting diode is connected to the first end of the fifth resistor, and the second end of the fifth resistor is connected to the negative electrode of the power supply.
[0014] In some embodiments, the PNP converter further includes a fourth light-emitting diode and a sixth resistor. The positive electrode of the fourth light-emitting diode is connected to the positive electrode of the power supply, the negative electrode of the fourth light-emitting diode is connected to the first end of the sixth resistor, and the second end of the sixth resistor is connected to the base of the PNP triode.
[0015] In some embodiments, the positive electrode of the power supply is 24V.
[0016] Advantages of the embodiments of the present application: In order to convert to a PNP signal, an NPN triode is provided to be connected to a PNP sensor in the embodiments of the present application to achieve the output of an NPN signal. In order to convert to an NPN signal, a PNP triode is provided to be connected to an NPN sensor; to achieve the output of a PNP signal, thereby realizing the mutual conversion of PNP signals and NPN signals, and avoiding the problem that the signal cannot be accessed into the PLC system and hindering installation and debugging. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] Figure 1 is a schematic circuit structure diagram of an NPN converter of a circuit for mutual conversion between NPN and PNP type sensors provided by an embodiment of the present application;
[0018] Figure 2 is a schematic circuit structure diagram of a PNP converter of a circuit for mutual conversion between NPN and PNP type sensors provided by an embodiment of the present application. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0019] To make the objectives, technical solutions and advantages of this application more clear, the following further describes specific embodiments of this application in conjunction with the accompanying drawings. It can be understood that the specific embodiments described herein are only used to explain this application, rather than limiting this application. Additionally, it should be noted that for the convenience of description, only parts related to this application rather than all content are shown in the drawings. Before discussing the exemplary embodiments in more detail, it should be mentioned that some exemplary embodiments are described as processes or methods depicted as flowcharts. Although the flowcharts describe the operations (or steps) as sequential processes, many of the operations can be implemented in parallel, concurrently or simultaneously. In addition, the order of the operations can be rearranged. When the operations are completed, the process can be terminated, but there can also be additional steps not included in the drawings. The process can correspond to a method, function, procedure, subroutine, subprogram, etc.
[0020] Provide the NPN and PNP type sensor mutual conversion circuit of the embodiments of this application to avoid the problem that when the existing PLC system uses an NPN type (or PNP type) switch, it is easy for the signal to be unable to access the system, which hinders the installation and debugging.
[0021] Figure 1 It is a schematic diagram of the circuit structure of an NPN and PNP type sensor mutual conversion circuit provided by the embodiments of this application. Refer to Figure 1 and Figure 2 , the NPN and PNP type sensor mutual conversion circuit includes an NPN converter and a PNP converter; the NPN converter includes an NPN triode 101 and a PNP sensor 102, the base of the NPN triode 101 is connected to the collector of the PNP sensor 102, the collector of the NPN triode 101 is connected to the output terminal, the emitter of the NPN triode 101 is connected to the negative power supply and the base of the PNP sensor 102, and the emitter of the PNP sensor 102 is connected to the positive power supply; the PNP converter includes a PNP triode 201 and an NPN sensor 202, the base of the PNP triode 201 is connected to the collector of the NPN sensor 202, the emitter of the PNP triode 201 is connected to the base of the NPN sensor 202 and the positive power supply, the collector of the PNP triode 201 is connected to the output terminal, and the emitter of the NPN sensor 202 is connected to the negative power supply.
[0022] The widely used PLC DI input modules currently available are of the NPN or PNP type, and can be connected to proximity switch signals of the corresponding type respectively. A PNP-type sensor means that the signal output terminal outputs a high-level output, and its internal switch is connected between the signal terminal and the anode; an NPN-type sensor means that the signal output terminal outputs a low-level output, and the internal switch is connected between the signal terminal and the negative pole. When the three-wire proximity switch of the PNP type is in the high-level output mode. The input types of the PLC are divided into sink and source types. The former refers to the positive signal input (PNP can be directly used), and the latter refers to the negative signal input (NPN can be directly used). Otherwise, a relay conversion or other component conversion must be used to convert the signal before inputting.
[0023] Specifically, the NPN converter of the embodiment of the present application includes an NPN triode 101 and a PNP sensor 102. When the PNP switch needs to be converted into an NPN signal, the PNP sensor 102 can be regarded as a PNP triode 201. The emitter of the PNP triode 201 is connected to the positive pole of the power supply, the collector is used as the output terminal, and the base is connected to the negative pole of the power supply. In order to convert into a PNP signal, the NPN triode 101 is used. The output terminal of the PNP sensor 102 is connected to the base of the NPN triode 101, the emitter of the NPN triode 101 is connected to the negative pole of the power supply, and the collector of the NPN triode 101 is used as the output terminal after conversion to realize the output of the NPN signal; the PNP converter includes a PNP triode 201 and an NPN sensor 202. When the NPN switch needs to be converted into a PNP signal, the NPN sensor 202 can be regarded as an NPN triode 101. The emitter of the NPN triode 101 is connected to the negative pole of the power supply, the collector is used as the output terminal, and the base is connected to the positive pole of the power supply. In order to convert into an NPN signal, the PNP triode 201 is used. The output terminal of the NPN sensor 202 is connected to the base of the PNP triode 201, the emitter of the PNP triode 201 is connected to the positive pole of the power supply, and the collector of the PNP triode 201 is used as the output terminal after conversion; this avoids the problem that the signal cannot be accessed into the PLC system and hinders installation and debugging. When applied on-site, when the type of the configured sensor does not match the type of the used PLC, according to the principle difference between PNP and NPN, through the conversion element, the signal can be converted into a signal with a matching type to meet the PLC requirements.
[0024] As a preferred embodiment, the NPN converter further includes a first resistor R1, and the first resistor R1 is arranged at the base of the NPN triode 101; the NPN converter further includes a first switch S1, and the first switch S1 is arranged at the base of the PNP sensor 102.
[0025] As a preferred embodiment, the PNP converter further includes a second resistor R2 disposed at the base of the PNP transistor 201; the PNP converter further includes a second switch S2 disposed at the base of the NPN sensor 202.
[0026] As a preferred embodiment, the NPN converter further includes a first light-emitting diode D1, a third resistor R3, a second light-emitting diode D2, and a fourth resistor R4. The positive electrode of the first light-emitting diode D1 is connected to the positive power supply, the negative electrode of the first light-emitting diode D1 is connected to the first end of the third resistor R3, and the second end of the third resistor R3 is connected to the negative power supply; the negative electrode of the second light-emitting diode D2 is connected to the negative power supply, the positive electrode of the second light-emitting diode D2 is connected to the first end of the fourth resistor R4, and the second end of the fourth resistor R4 is connected to the base of the NPN transistor 101.
[0027] It can be understood that the first light-emitting diode D1 is used to display the power supply state of the NPN transistor 101, and the second light-emitting diode D2 is used to display the detection state of the NPN transistor 101.
[0028] As a preferred embodiment, the PNP converter further includes a third light-emitting diode D3, a fifth resistor R5, a fourth light-emitting diode D4, and a sixth resistor R6. The positive electrode of the third light-emitting diode D3 is connected to the positive power supply, the negative electrode of the third light-emitting diode D3 is connected to the first end of the fifth resistor R5, and the second end of the fifth resistor R5 is connected to the negative power supply; the positive electrode of the fourth light-emitting diode D4 is connected to the positive power supply, the negative electrode of the fourth light-emitting diode D4 is connected to the first end of the sixth resistor R6, and the second end of the sixth resistor R6 is connected to the base of the PNP transistor 201.
[0029] Optionally, the third light-emitting diode D3 is used to display the power supply state of the PNP transistor 201, and the fourth light-emitting diode D4 is used to display the detection state of the PNP transistor 201.
[0030] As a preferred embodiment, the positive power supply is 24V.
[0031] Specifically, when a PNP switch needs to be converted into an NPN signal, the PNP sensor 102 can be regarded as a PNP triode whose base is controlled by the first switch S1. Its emitter is connected to 24V, the collector is used as the output terminal, and the base is connected to 0V through a first switch S1. For a normally open sensor, the first switch S1 is in an open state usually, and the first switch S1 is in a closed state when the sensor operates. To convert it into a PNP signal, an NPN triode 101 can be used. The output terminal of the PNP sensor 102 is connected to the base of the NPN triode 101. The emitter of the NPN triode 101 is connected to 0V, and the collector of the NPN triode 101 is used as the converted output terminal. The conversion components can be made into a simple package as a simple converter.
[0032] Specifically, when an NPN switch needs to be converted into a PNP signal, the NPN sensor 202 can be regarded as an NPN triode whose base is controlled by the second switch S2. Its emitter is connected to 0V, the collector is used as the output terminal, and the base is connected to 24V through a second switch S2. For a normally open sensor, the second switch S2 is in an open state usually, and the second switch S2 is in a closed state when the sensor operates. To convert it into an NPN signal, a PNP triode 201 can be used. The output terminal of the NPN sensor 202 is connected to the base of the PNP triode 201. The emitter of the PNP triode 201 is connected to 24V, and the collector of the PNP triode 201 is used as the converted output terminal. The conversion components can be made into a simple package as a simple converter.
[0033] It can be understood that the first resistor R1 and the second resistor R2 play a role in voltage division protection.
[0034] For a PLC or DCS system of PNP type (or NPN type) that has been put into normal operation, if new technical transformation equipment is added and the proximity switch adopted is of NPN type (or PNP type), and it cannot be replaced due to selection or procurement time issues and the construction period is very urgent, the components of the embodiments of the present application can be used to convert the signal to ensure that the signal is smoothly connected to the system without hindering the installation and commissioning. If a light-emitting diode is added to the packaged component, the power supply state of the loop can be displayed and the detection state of the sensor can also be displayed, and the detection state of the sensor can be displayed in real time to judge whether the sensor is working properly.
[0035] The above are only the preferred embodiments of the present application and the technical principles applied. The present application is not limited to the specific embodiments described herein. Various obvious changes, re-adjustments and substitutions that can be made by those skilled in the art will not depart from the protection scope of the present application. Therefore, although the present application has been described in more detail through the above embodiments, the present application is not limited to the above embodiments. Without departing from the concept of the present application, more other equivalent embodiments can be included, and the scope of the present application is determined by the scope of the claims.
Claims
1. A circuit for converting between NPN and PNP type sensors, characterized in that, Comprising: NPN converter and PNP converter; The NPN converter includes an NPN triode and a PNP sensor. The base of the NPN triode is connected to the collector of the PNP sensor. The collector of the NPN triode is connected to the output terminal. The emitter of the NPN triode is connected to the negative pole of the power supply and the base of the PNP sensor. The emitter of the PNP sensor is connected to the positive pole of the power supply; The PNP converter includes a PNP triode and an NPN sensor. The base of the PNP triode is connected to the collector of the NPN sensor. The emitter of the PNP triode is connected to the base of the NPN sensor and the positive pole of the power supply. The collector of the PNP triode is connected to the output terminal. The emitter of the NPN sensor is connected to the negative pole of the power supply.
2. The NPN and PNP type sensor mutual conversion circuit according to claim 1, characterized in that The NPN converter further includes a first resistor, and the first resistor is disposed at the base of the NPN triode.
3. The NPN and PNP type sensor mutual conversion circuit according to claim 1, characterized in that The NPN converter further includes a first switch, and the first switch is disposed at the base of the PNP sensor.
4. The NPN and PNP type sensor mutual conversion circuit according to claim 1, characterized in that, The PNP converter further includes a second resistor, and the second resistor is disposed at the base of the PNP triode.
5. The NPN and PNP type sensor mutual conversion circuit according to claim 1, characterized in that The PNP converter further includes a second switch, and the second switch is disposed at the base of the NPN sensor.
6. The NPN and PNP type sensor mutual conversion circuit according to claim 1, characterized in that, The NPN converter further includes a first light-emitting diode and a third resistor. The positive pole of the first light-emitting diode is connected to the positive pole of the power supply. The negative pole of the first light-emitting diode is connected to the first end of the third resistor. The second end of the third resistor is connected to the negative pole of the power supply.
7. The NPN and PNP type sensor mutual conversion circuit according to claim 1, characterized in that The NPN converter further includes a second light-emitting diode and a fourth resistor. The negative pole of the second light-emitting diode is connected to the negative pole of the power supply. The positive pole of the second light-emitting diode is connected to the first end of the fourth resistor. The second end of the fourth resistor is connected to the base of the NPN triode.
8. The NPN and PNP type sensor mutual conversion circuit according to claim 1, wherein The PNP converter further includes a third light-emitting diode and a fifth resistor. The positive pole of the third light-emitting diode is connected to the positive pole of the power supply. The negative pole of the third light-emitting diode is connected to the first end of the fifth resistor. The second end of the fifth resistor is connected to the negative pole of the power supply.
9. The NPN and PNP type sensor mutual conversion circuit according to claim 1, wherein The PNP converter further includes a fourth light-emitting diode and a sixth resistor. The positive pole of the fourth light-emitting diode is connected to the positive pole of the power supply. The negative pole of the fourth light-emitting diode is connected to the first end of the sixth resistor. The second end of the sixth resistor is connected to the base of the PNP triode.
10. The NPN and PNP type sensor mutual conversion circuit according to claim 1, characterized in that The positive pole of the power supply is 24V.