A NAMUR switch instrument transmitter and control method
The on-site setting of the flow alarm threshold is realized in the NAMUR switching instrument transmitter through the MCU microprocessor and the switching current control circuit, which solves the problem of complexity and inconvenience of the mechanical alarm device, improves the stability and functionality of the system, and ensures Accuracy of flow alarms and proper operation of equipment.
Patent Information
- Application Number
- CN202010892251.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-08-31
- Publication Date
- 2024-09-13
- Estimated Expiration
- 2040-08-31
AI Technical Summary
The mechanical alarm device of the existing NAMUR switch instrument transmitter has a complex structure, and it is inconvenient to set the alarm point for on-site adjustment.
Using MCU microprocessor, sensor, key unit and switch current control circuit, the flow alarm threshold is set through the key component. The MCU processes sensor data and controls the output current value of the switch current control circuit to achieve flow alarm. Low-power isolation components and voltage regulators are used. circuit improves system stability.
It realizes the convenient setting of the flow alarm threshold on site, reduces the average current of the NAMUR switch instrument transmitter, improves the stability and functionality of the system, and ensures the accuracy of the flow alarm and the normal operation of the equipment.
Smart Images

Figure CN111912470B
Abstract
Description
Technical Field
[0001] The present application relates to the field of transmitters, and in particular to a NAMUR switch instrument transmitter and a control method. Background Art
[0002] In the process of industrial preparation, many sites involving flow and liquid level require real-time monitoring of the state parameters of flow or liquid level to ensure the smooth progress of industrial preparation and other processes.
[0003] A Chinese patent with announcement number CN202403709U discloses a NAMUR signal alarm device, including a mounting seat, a metal sheet, a slot-type NAMUR proximity switch, a terminal block and a connecting support plate. The mounting seat is mounted on the housing of the indicator through a long support and a short support. The metal sheet is a centrally symmetrical sector, and the center of symmetry is mounted on the pointer shaft of the indicator. The mounting seat is divided into a groove with the indicator as the center of the circle at the upper and lower parts. The slot-type NAMUR proximity switch is connected to the connecting support plate, which is fixedly mounted on the pointer shaft and positioned in two arc grooves by two screws. The upper end of the mounting seat is equipped with a terminal block, which is connected to the slot-type NAMUR proximity switch through a wire. Through the above scheme, the signal alarm is realized by the swing of the pointer. However, the alarm device is a mechanical alarm device with a complex structure, a rough setting of the alarm point, and inconvenient operation. If the alarm point needs to be adjusted, the complex mechanical structure needs to be changed.
[0004] With respect to the above-mentioned related technologies, the inventor believes that there is a defect that it is inconvenient to set alarm points on site. Summary of the invention
[0005] In order to facilitate setting of alarm points on site, the present application provides a NAMUR switch instrument transmitter.
[0006] In a first aspect, the present application provides a NAMUR switch instrument transmitter, which adopts the following technical solution:
[0007] A NAMUR switch instrument transmitter comprises an MCU microprocessor, a sensor connected to an input end of the MCU microprocessor, a key unit connected to the input end of the MCU microprocessor, and a switch current control circuit connected to an output end of the MCU microprocessor.
[0008] By adopting the above technical solution, the flow alarm threshold can be set on site through the button component. The sensor sends the collected flow data to the MCU microprocessor for processing. The MCU judges and processes the flow data collected by the sensor and the set alarm threshold. When the collected flow data reaches the alarm condition, the corresponding switch current control circuit outputs the corresponding current value. The current value output by the switch current control circuit is used to judge whether the current flow is within the alarm value range to achieve the flow alarm effect.
[0009] Preferably, the output end of the MCU microprocessor is connected to a constant current excitation for powering the sensor, and the constant current excitation is electrically connected to a connector of the sensor; wherein the MCU microprocessor is used to control the opening and closing of the constant current excitation.
[0010] By adopting the above technical solution, the switching state of the constant current excitation is controlled by the MCU microprocessor. When the constant current excitation is turned on, it powers the sensor, and when the constant current excitation is turned off, it stops powering the sensor. The switch of the constant current excitation controlled by the MCU microprocessor reduces the average current during the operation of the NAMUR switch instrument transmitter, thereby ensuring the normal operation of the NAMUR switch instrument transmitter.
[0011] Preferably, the switch current control circuit includes a first switch current control circuit, the first switch current control circuit is electrically connected to the output end of the MCU microprocessor, and the first switch current control circuit is connected to a DC / DC power supply and a wiring terminal SW1.
[0012] By adopting the above technical solution, the external power supply is connected through the terminal SW1, and the power supply after voltage stabilization and filtering by the voltage regulator diode and capacitor in the first switch current control circuit is transmitted to the DC / DC power supply, thereby improving the stability of the transmitter.
[0013] Preferably, the switch current control circuit further includes a second switch current control circuit, the second switch current control circuit is connected to a wiring terminal SW2, and a low-power isolation element is connected between the second switch current control circuit and an output end of the MCU microprocessor.
[0014] By adopting the above technical solution, the MCU microprocessor and the second switch current control circuit are isolated by using a low-power isolation element, so as to prevent the MCU microprocessor from being affected by external interference introduced by the connection terminal SW2, thereby ensuring the stable operation of the system.
[0015] Preferably, the first switch current control circuit and the second switch current control circuit both include a power supply processing circuit and an operational amplifier, the power supply processing circuit includes a power supply circuit, a transistor state adjustment circuit and a resistor R1 connected between the negative electrode of the wiring terminal SW1 and the ground, and the operational amplifier includes an operational amplifier unit A and an operational amplifier unit B;
[0016] The power supply circuit includes a resistor R3, the resistor R3 is connected to the positive electrode of the terminal SW1, the emitter of the transistor Q1 and the resistor R4, the other end of the resistor R4 is connected to the base of the transistor Q1, the other end of the resistor R3 is connected to the negative electrode of the diode D5, the voltage regulator LDO, the collector of the transistor Q1, the negative electrode of the diode D2 and the DC / DC power supply, and the positive electrode of the diode D2 and the positive electrode of the diode D5 are grounded respectively;
[0017] The transistor state adjustment circuit includes a resistor R7, a transistor Q2 and a resistor R6, the resistor R7 is connected to the pin OUTA of the operational amplifier unit A, the other end of the resistor R7 is connected to the base of the transistor Q2, the emitter of the transistor Q2 is grounded, the collector of the transistor Q2 is connected to the resistor R6, and the other end of the resistor R6 is connected to the base B of the transistor Q1.
[0018] By adopting the above technical solution, in the initial power-on state, transistors Q1 and Q2 are in the cut-off state, and the current can only flow through resistor R3 and the voltage-stabilized power supply LDO. After the voltage-stabilized power supply LDO supplies power to the operational amplifier, it enters the current loop adjustment state. The current flowing into the positive electrode of the terminal SW1 flows to the ground through the devices in the power processing circuit, and then flows back to the negative electrode of the power supply through the resistor R1, forming a closed-loop negative feedback circuit, thereby improving the stability of the switching current control circuit.
[0019] Preferably, the first switch current control circuit and the second switch current control circuit also preferably include a current output control circuit, and the current output control circuit includes a first voltage divider circuit, a second voltage divider circuit and a current output circuit;
[0020] The first voltage divider circuit includes a resistor R9 and a resistor R10, the resistor R9 and the resistor R10 are connected in series, the other end of the resistor R9 is connected to the MCU microprocessor, the other end of the resistor R10 is grounded, and the pin INB+ of the operational amplifier unit B is connected to the connection point of the resistor R9 and the resistor R10;
[0021] The second voltage divider circuit includes a resistor R11 and a resistor R12, the resistor R11 and the resistor R12 are connected in series, the other end of the resistor R12 is connected to the voltage-stabilizing power supply LDO, the other end of the resistor R11 is grounded, and the pin INB- of the operational amplifier unit B is connected to the connection point of the resistor R11 and the resistor R12;
[0022] The current output circuit includes a resistor R2, a resistor R5 and a resistor R8, the resistor R2 is connected in series with the resistor R5, the other end of the resistor R2 is connected to the negative electrode of the terminal SW1, the other end of the resistor R5 is connected to the voltage-stabilized power supply LDO, the resistor R8 is connected to the connection point between the resistor R2 and the resistor R5, and the other end of the resistor R8 is connected to the pin OUTB of the operational amplifier unit B.
[0023] By adopting the above technical solution, the MCU microprocessor outputs high and low levels to change the input voltage of the pin INB+ of the operational amplifier unit B. After the input voltage of the pin INB+ is compared with the voltage of the pin INB-, a high level or a low level is output at the output terminal OUTB of the operational amplifier unit B. The high level or the low level output at the output terminal OUTB of the operational amplifier unit B is converted into a current value through the resistor R5 and superimposed with the current flowing through the resistor R8, so that the current output circuit outputs a current value that meets the NAMUR standard.
[0024] Preferably, the power supply circuit is provided with a diode D1, a diode D4 and a capacitor C1, the diode D1 is connected in series between the positive electrode of the terminal SW1 and the resistor R3; the diode D4 is connected in series between the negative electrode of the diode D5 and the voltage-stabilizing power supply LDO; the capacitor C1 is connected in parallel with the diode D2.
[0025] By adopting the above technical solution, the reliability of the power supply circuit is improved. The diode D1 and the diode D4 are set to play a one-way cutoff role to prevent the current backflow; the capacitor C1 is used for energy storage and filtering in the circuit to filter out low-frequency interference in the power supply input to the DC / DC power supply.
[0026] Preferably, the MCU microprocessor is also connected to a ROM memory and an LCD display screen respectively.
[0027] By adopting the above technical solution, the LCD display can display the flow value in real time, and the ROM memory can store the set alarm threshold, so that the transmitter does not need to be reset after power failure, thereby increasing the functionality of the transmitter.
[0028] In a second aspect, the present application provides a control method for a NAMUR switch instrument transmitter, which adopts the following technical solution:
[0029] The control method of the NAMUR switch instrument transmitter comprises the following steps:
[0030] Step S100, controlling the constant current excitation and the AD converter to be turned on simultaneously, so that the constant current excitation powers the sensor;
[0031] Step S200, the AD converter processes the data input by several sensors and stores them in the ROM memory;
[0032] Step S300, turning off the constant current excitation and the AD converter, and turning on the LCD display screen;
[0033] Step S400, performing calculations on the data input by the sensor processed by the AD converter in step S300 for a number of times and then transmitting the data to the LCD display screen for display;
[0034] By adopting the above technical solution, the average current of the NAMUR switch instrument transmitter does not exceed the available current of the power supply, thereby ensuring the normal operation of the NAMUR switch instrument transmitter.
[0035] Preferably, the step of performing calculations on the data input by the sensor processed by the AD converter for several times and then transmitting the data to the LCD display screen for display comprises:
[0036] Step S401, comparing the data input by the sensor processed by the AD converter for several times with the set alarm threshold, and outputting a current value on the switch current control circuit to indicate alarm or no alarm according to the comparison result;
[0037] Step S402, the LCD display screen displays the flow data collected by the sensor with a delay;
[0038] By adopting the above technical solution, the average current of the NAMUR switch instrument transmitter does not exceed the available current of the power supply, thereby ensuring the normal operation of the NAMUR switch instrument transmitter.
[0039] In summary, the present application includes at least one of the following beneficial technical effects:
[0040] 1. The flow alarm threshold can be set on site through the button assembly. The sensor sends the collected flow data to the MCU microprocessor for processing. The MCU microprocessor compares and judges the flow data collected by the sensor with the set alarm threshold. When the collected flow data reaches the alarm condition, the corresponding switch current control circuit outputs the corresponding current value. The current value output by the switch current control circuit is used to determine whether the current flow is within the alarm value range to achieve the flow alarm effect;
[0041] 2. Use low-power isolation components to isolate the MCU microprocessor and the second switch current control circuit to prevent the MCU microprocessor from external interference introduced by the wiring terminal SW2, thus ensuring the stable operation of the system;
[0042] 3. In the initial state of power-on, transistors Q1 and Q2 are in the cut-off state, and the current can only flow through resistor R3 and the voltage regulator LDO. After the voltage regulator LDO supplies power to the operational amplifier, it enters the current loop adjustment state. The current flowing in from the positive electrode of the terminal SW1 flows to the ground through the devices in the power processing circuit, and then flows back to the negative electrode of the power supply through the resistor R1, forming a closed-loop negative feedback circuit, which improves the stability of the switch current control circuit;
[0043] 4. Make the average current of NAMUR switch instrument transmitter not exceed the available current of power supply, thus ensuring the normal operation of NAMUR switch instrument transmitter. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] Figure 1 It is a schematic diagram of the circuit structure of a NAMUR switch instrument transmitter according to an embodiment of the present application.
[0045] Figure 2 It is a circuit structure diagram of a first switch current control circuit or a second switch current control circuit in a NAMUR switch instrument transmitter according to an embodiment of the present application.
[0046] Figure 3 It is a flow chart of a control method of a NAMUR switch instrument transmitter according to the first embodiment of the present application.
[0047] Figure 4 It is a flow chart of a control method of a NAMUR switch instrument transmitter according to the second embodiment of the present application.
[0048] Explanation of the accompanying drawings: 1. MCU microprocessor; 2. Sensor; 3. Key unit; 4. LCD display; 5. Constant current excitation; 6. First switch current control circuit; 60. Power supply processing circuit; 61. Power supply circuit; 62. Transistor state adjustment circuit; 7. Second switch current control circuit; 70. Current output control circuit; 71. First voltage divider circuit; 72. Second voltage divider circuit; 73. Current output circuit; 8. High-efficiency DC / DC power supply; 80. Operational amplifier; 9. Low-power isolation element; 10. ROM memory. DETAILED DESCRIPTION
[0049] The following is combined with Figure 1-4 This application is described in further detail.
[0050] The present application embodiment discloses a NAMUR switch instrument transmitter. Figure 1 A NAMUR switch instrument transmitter includes an MCU microprocessor 1, a sensor 2 connected to the input end of the MCU microprocessor 1, a key unit 3 connected to the input end of the MCU microprocessor 1, and a switch current control circuit connected to the output end of the MCU microprocessor 1.
[0051] The sensor 2 is used to collect the analog electrical signal of the industrial liquid flow or liquid level in real time, and the MCU microprocessor 1 is used to receive and process the analog electrical signal of the industrial liquid flow or liquid level input by the sensor 2. The sensor 2 can be one of a bridge resistance sensor, a Hall sensor, a capacitive sensor or an inductive sensor.
[0052] MCU microprocessor 1 uses a low-power MSP430F4270 chip with an internal integrated preamplifier and AD converter. When the NAMUR switch instrument transmitter is running, sensor 2 is connected to MCU microprocessor 1 through its connector. The preamplifier and AD converter in MCU microprocessor 1 respectively amplify and convert the analog electrical signal input by sensor 2 into a digital signal.
[0053] Furthermore, the MCU microprocessor 1 internally integrates a ROM for data reading or is electrically connected to a ROM memory 10 .
[0054] The button assembly 3 is used to set the flow or liquid level alarm threshold. The MCU microprocessor 1 compares the flow or liquid level alarm threshold set by the button assembly 3 with the flow value or liquid level value collected and input by the sensor 2 and received and processed by the MCU microprocessor 1 to determine whether an alarm signal needs to be output.
[0055] The output end of the MCU microprocessor 1 is also connected to an LCD display unit 4 for displaying the flow value in real time and a constant current excitation 5 for supplying power to the sensor 2.
[0056] The constant current excitation 5 is electrically connected to the connector of the sensor 2. The MCU microprocessor 1 controls the opening and closing of the constant current excitation 5 by changing the high and low levels of its output terminal. When the constant current excitation 5 is turned on, it supplies power to the sensor 2. When the constant current excitation 5 is turned off, it stops supplying power to the sensor 2.
[0057] Further, the switch current control circuit includes a first switch current control circuit 6 and a second switch current control circuit 7, and the first switch current control circuit 6 and the second switch current control circuit 7 are electrically connected to the output end of the MCU microprocessor 1, respectively. The first switch current control circuit 6 is electrically connected to a DC / DC power supply 8 and a wiring terminal SW1 for powering the MCU microprocessor 1, and the wiring terminal SW1 is connected to an external power supply. The external power supply is connected to the first switch current control circuit 6 through the wiring terminal SW1, a part of which is used to power the first switch current control circuit 6, and a part of which is used to provide power input for the DC / DC power supply 8 after voltage stabilization and filtering by the first switch current control circuit 6. The line connecting the MCU microprocessor 1 and the first switch power supply control circuit 6 is defined as the SW1 control line, and the MCU microprocessor 1 controls the current value output by the first switch current control circuit 6 by controlling the high and low level states on the SW1 control line, and the current value output by the first switch current control circuit 6 is reflected on the negative pole of the wiring terminal SW1.
[0058] Furthermore, the DC / DC power supply 8 is used to supply power to the key unit 3 , the LCD display unit 4 and the ROM memory 10 in addition to supplying power to the MCU microprocessor 1 .
[0059] A low-power isolation element 9 is also connected between the MCU microprocessor 1 and the second switch current control circuit 7, and the second switch current control circuit 7 is also connected to an independent power supply through the terminal SW2. Among them, the low-power isolation element 9 uses an optical coupler to isolate the MCU microprocessor 1 from the second switch current control circuit 7 to prevent the MCU microprocessor 1 from being subjected to external interference introduced through the terminal SW2. The independent power supply is connected to the second switch current control circuit 7 through the terminal SW2 to power the second switch current control circuit 7. The line connecting the MCU microprocessor 1 and the low-power isolation element 9 is defined as the SW2 control line. The MCU microprocessor 1 controls the high and low level states on the SW2 control line, and indirectly controls the output current value of the second switch current control circuit 7 after photoelectric isolation by the low-power isolation element 9. The current value output by the second switch current control circuit 7 is reflected on the negative pole of the terminal SW2.
[0060] Reference Figure 2 , Figure 2 1 is a schematic diagram of the circuit structure of a first switch current control circuit or a second switch current control circuit in a NAMUR switch instrument transmitter according to an embodiment of the present application. The first switch current control circuit 6 and the second switch current control circuit 7 adopt the same circuit structure. The first switch current control circuit 6 is taken as an example for specific description. The first switch current control circuit 6 includes a power supply processing circuit 60 and a current output control circuit 70.
[0061] The power processing circuit 60 includes a power supply circuit 61 and a transistor state adjustment circuit 62. The power supply circuit 61 includes a resistor R3, the resistor R3 is connected to the positive electrode of the terminal SW1, the emitter E of the transistor Q1 and the resistor R4, the other end of the resistor R4 is connected to the base B of the transistor Q1, and the resistor R4 is used for shunting to reduce the current flowing into the emitter E of the transistor Q1. The other end of the resistor R3 is connected to the cathode of the voltage regulator diode D5, the anode of the voltage regulator diode D5 is grounded, and the resistor R3 is used to prevent the voltage regulator diode D5 from being broken down by an external power supply. The cathode of the voltage regulator diode D5 is also connected to the input end of the voltage regulator power supply LDO, the collector C of the transistor Q1, the cathode of the voltage regulator diode D2 and the input end of the DC / DC power supply 8. The output end of the voltage regulator power supply LDO outputs a 3.3V DC voltage, which is used to power the transistor state adjustment circuit 62, the voltage regulator diode D5 is used to stabilize the voltage of the LDO voltage regulator power supply, and the DC / DC power supply 8 is used to power the MCU microprocessor 1. The anode of the voltage stabilizing diode D2 is grounded, and the voltage stabilizing diode D2 is used to stabilize the voltage input to the DC / DC power supply 8 .
[0062] Furthermore, a diode D1 can be connected in series between the positive electrode of the wiring terminal SW1 and the resistor R3, the positive electrode of the diode D1 is connected to the positive electrode of SW1, and the negative electrode of the diode D1 is connected to the resistor R3; a diode D4 is connected in series between the negative electrode of the voltage regulator diode D5 and the input end of the voltage regulator power supply LDO, the positive electrode of the diode D4 is connected to the negative electrode of the voltage regulator tube D5, and the negative electrode of the diode D4 is connected to the input end of the voltage regulator power supply LDO. The diodes D1 and D4 play a one-way cutoff role to prevent current backflow.
[0063] Furthermore, a capacitor C1 is connected in parallel to the voltage regulator diode D2, the positive electrode of the capacitor C1 is connected to the negative electrode of the voltage regulator diode D2, and the negative electrode of the capacitor C1 is grounded. The main function of the capacitor C1 is to store energy and filter out low-frequency interference in the power supply.
[0064] The base B of the transistor Q1 is connected to the transistor state adjustment circuit 62 that controls the state of the transistor Q1. The external current enters from the terminal SW1, flows through the resistor R3 and flows to the voltage regulator LDO and the DC / DC power supply. When the transistor state adjustment circuit 62 controls the transistor Q1, the transistor Q1 is converted from the cut-off state to the linear state or the saturation state, and the current flows through the transistor Q1 to the voltage regulator LDO and the DC / DC power supply.
[0065] Furthermore, the power processing circuit 60 also includes a resistor R1 connected between the negative pole of the terminal SW1 and the ground. In the initial power-on state, the transistor Q1 and the transistor Q2 are in the cut-off state, and the current can only flow through the resistor R3 and the voltage-stabilized power supply LDO. After the voltage-stabilized power supply LDO supplies power to the operational amplifier, it enters the current loop adjustment state. The current flowing into the positive pole of the terminal SW1 flows to the ground through the devices in the power processing circuit, and then flows back to the negative pole of the power supply through the resistor R1, forming a closed-loop negative feedback circuit.
[0066] The first switch current control circuit 6 also includes an operational amplifier 80, wherein the model of the operational amplifier in this embodiment is MAX9913. The operational amplifier 80 includes two parts: an operational amplifier unit A and an operational amplifier unit B. The power input pin Vdd of the operational amplifier 80 is connected to the 3.3V output end of the voltage regulator LDO, the pin Vss is grounded, and the pin SHDNA and the pin SHDNB are connected to the 3.3V output end of the voltage regulator LDO, which is used to turn on the operational amplifier units A and B of the operational amplifier 80.
[0067] The transistor state adjustment circuit 62 includes a resistor R7, a transistor Q2, and a resistor R6. The output pin OUTA of the operational amplifier unit A is connected to the resistor R7, the other end of the resistor R7 is connected to the base B of the transistor Q2, the emitter E of the transistor Q2 is grounded, the collector C of the transistor Q2 is connected to the resistor R6, and the other end of the resistor R6 is connected to the base B of the transistor Q1. When the pin OUTA of the operational amplifier unit A continuously outputs a high level, the high level of the pin OUTA puts the transistor Q2 in a linear state or a saturated state, thereby controlling the transistor Q1 to be converted from a cut-off state to a linear state or a saturated state.
[0068] The current output control circuit 70 further includes a first voltage dividing circuit 71 , a second voltage dividing circuit 72 and a current output circuit 73 .
[0069] The first voltage divider circuit 71 includes a resistor R9 and a resistor R10, which are connected in series, the other end of the resistor R9 is connected to the output end of the MCU microprocessor 1 through the SW1 control line, the other end of the resistor R10 is grounded, and the in-phase input pin INB+ of the operational amplifier unit B is connected to the connection point of the resistor R9 and the resistor R10. When the MCU microprocessor outputs a high level, the resistor R10 plays a voltage divider role; when the MCU microprocessor outputs a low level, the resistor R10 makes the pin INB+ in a stable low level state.
[0070] The second voltage divider circuit 72 includes a resistor R11 and a resistor R12, which are connected in series, the other end of the resistor R12 is connected to the output end of the voltage-stabilized power supply LDO, the other end of the resistor R11 is grounded, and the inverting input pin INB- of the operational amplifier unit B is connected to the connection point of the resistor R11 and the resistor R12. The voltage-stabilized power supply LDO provides a 3.3V DC voltage for the voltage divider circuit 72, and the resistor R11 plays a role in voltage division, providing a reference voltage for the pin INB-.
[0071] The current output circuit 73 includes a resistor R2, a resistor R5 and a resistor R8, wherein the resistor R2 is connected in series with the resistor R5, the other end of the resistor R2 is connected to the negative electrode of the wiring terminal SW1, the other end of the resistor R5 is connected to the 3.3V output end of the voltage-stabilized power supply LDO, the resistor R8 is connected to the connection point between the resistor R2 and the resistor R5, and the other end of the resistor R8 is connected to the output pin OUTB of the operational amplifier unit B. The output voltage of the pin OUTB is defined as Voutb, and Voutb and the resistors R5 and R8 determine the output current of the switch current control circuit. The output current of the switch control circuit is defined as Iout, and Iout=3.3 / R5+Voutb / R8. By adjusting the resistance values of the resistors R5 and R8, the output current value that meets the NAMUR standard can be set.
[0072] Furthermore, the in-phase input pin INA+ of the operational amplifier unit A is connected to resistors R8, R5 and R2, the other end of the resistor R2 is also connected to the resistor R1, the other end of the resistor R1 is grounded, the inverting input pin INA- of the operational amplifier unit A is grounded, the other end of the resistor R5 is connected to the 3.3V output end of the voltage-regulated power supply LDO, and the resistor R5 is used to pull up the level of the in-phase input pin INA+ of the operational amplifier unit A.
[0073] Operational amplifier 80 is used as a comparator, pin INA+ is in a high level state and INA- is grounded, so pin OUTA continuously outputs a high level. The high level of pin OUTA puts transistor Q2 in a linear state or a saturated state, thereby controlling transistor Q1 to switch from a cutoff state to a linear state or a saturated state.
[0074] The working principle of this embodiment is:
[0075] The MCU microprocessor 1 controls the output voltage Voutb of the output pin OUTB of the operational amplifier unit B by controlling the level on the SW1 control line. Since the operational amplifier 80 used is a rail to rail type, when the operational amplifier 80 is used as a comparator, the low level output is 0, and the high level output is the power supply voltage 3.3V. When the MCU microprocessor 1 outputs a low level, the input voltage of pin INB+ is less than the input voltage of pin INB-, and the output pin OUTB of the operational amplifier unit B outputs a low level. By calculating by the formula Iout=3.3 / R5+Voutb / R8, when R5=2.8kΩ, the output current Iout≈1.16mA; when the MCU microprocessor 1 outputs a high level, the input voltage of pin INB+ is greater than the input voltage of pin INB-, and the output pin OUTB of the operational amplifier unit B outputs a high level. It is known that the resistance value of resistor R5 is 2.8kΩ. By calculating by the formula Iout=3.3 / R5+Voutb / R8, when R8=2.4kΩ, the output current Iout≈2.56mA, the MCU microprocessor 1 controls the first switch current control circuit 6 and the second switch current control circuit 7 to output the above two current values by outputting high and low levels.
[0076] The standard flow safety alarm range required by the industrial site is input through the key unit 3, which is specifically divided into four alarm values: flow upper limit alarm, upper upper limit alarm, lower limit alarm, and lower lower limit alarm. The MCU microprocessor 1 compares the actual flow value measured by the sensor 2 with the alarm threshold input through the key unit 3, and then the MCU microprocessor 1 controls the first switch current control circuit 6 and the second switch current control circuit 7 to output the above two current values by outputting high and low levels.
[0077] For example, the first switch current control circuit 6 is set as a flow lower limit alarm circuit, the second switch current control circuit 7 is set as a flow lower-lower limit alarm circuit, the lower flow alarm threshold is set to 30 cubic meters / hour, and the lower-lower flow alarm threshold is set to 20 cubic meters / hour. When the actual flow value measured by sensor 2 is greater than the lower flow alarm threshold, both switch current control circuits will output a current of ≤1.2mA; when the actual flow measured by sensor 3 is between the lower alarm threshold and the lower-lower alarm threshold, the first switch current control circuit 6 will output a current of ≥2.1mA, and the second switch current control circuit will output a current of ≤1.2mA. When the actual current measured by sensor 2 is less than the lower-lower alarm threshold, both switch current control circuits will output a current of ≥2.1mA.
[0078] Furthermore, a switching current control circuit A and a switching current control circuit B can be added, and the switching current control circuit A can be set as a flow upper limit alarm circuit, and the switching current control circuit B can be set as a flow upper and lower limit alarm circuit. The upper limit flow alarm threshold can be set to 60 cubic meters / hour, and the upper upper limit flow alarm threshold can be set to 80 cubic meters / hour. When the actual flow value measured by sensor 2 is less than the upper limit flow alarm threshold, both switching current control circuits will output a current of ≤1.2mA; when the actual flow value measured by sensor 2 is between the upper limit alarm threshold and the upper upper limit alarm threshold, the switching current control circuit A will output a current of ≥2.1mA, and the switching current control circuit B will output a current of ≤1.2mA. When the actual current measured by sensor 2 is greater than the upper and lower limit alarm thresholds, both switching current control circuits will output a current of ≥2.1mA.
[0079] refer to Figure 3 , Figure 3 This is a flow chart of a control method for a NAMUR switch instrument transmitter in the first embodiment of the present application. When the program starts running, the MCU microprocessor is first initialized, and after the initialization is completed, the delay program is executed to ensure that the LDO voltage-stabilized power supply and the DC / DC power supply 8 in the switch current control circuit remain in a stable state. After the power supply is stable, the MCU microprocessor is self-checked, and after the self-check is completed, the time-sharing control main program is executed.
[0080] Step S100, controlling the constant current excitation and the AD converter to be turned on simultaneously, so that the constant current excitation powers the sensor;
[0081] Specifically, the MCU microprocessor outputs a high level to control the constant current excitation to turn on, so that the constant current excitation powers the sensor and turns on the AD converter at the same time; the LCD display is prohibited from running, and the MCU microprocessor enters a low power consumption state.
[0082] Step S200, the AD converter processes the data input by several sensors and stores them in the ROM memory;
[0083] Specifically, the AD converter in the MCU microprocessor performs the AD acquisition function, collects a certain amount of analog data sent back by the sensor according to the set value, amplifies and AD-converts the collected analog data into digital signals and stores them in the ROM memory.
[0084] Step S300, turning off the constant current excitation and the AD converter, and turning on the LCD display screen;
[0085] Specifically, the MCU microprocessor outputs a low level to control the constant current excitation to be turned off, so that the constant current excitation stops supplying power to the sensor and the sensor stops collecting data; at the same time, the AD converter is turned off to stop its collection function; and the LCD display screen enters the state of receiving display instructions.
[0086] Step S400, performing calculations on the data input by the sensor processed by the AD converter in step S300 for a number of times and then transmitting the data to the LCD display screen for display;
[0087] Specifically, the MCU microprocessor performs judgment and calculation processing on the data sent back by the sensor, and sends it to the LCD display screen for display. After the execution is completed, it returns to step S100.
[0088] For further information, see Figure 4 , Figure 4 It is a flow chart of a control method of a NAMUR switch instrument transmitter according to the second embodiment of the present application.
[0089] Step S100, controlling the constant current excitation and the AD converter to be turned on simultaneously, so that the constant current excitation powers the sensor;
[0090] Specifically, the MCU microprocessor outputs a high level to control the constant current excitation to turn on, so that the constant current excitation powers the sensor and turns on the AD converter at the same time; the LCD display is prohibited from running, and the MCU microprocessor enters a low power consumption state.
[0091] Step S200, the AD converter processes the data input by several sensors and stores them in the ROM memory;
[0092] Specifically, the AD converter in the MCU microprocessor performs the AD acquisition function, collects a certain amount of analog data sent back by the sensor according to the set value, amplifies and AD-converts the collected analog data into digital signals and stores them in the ROM memory.
[0093] Step S300, turning off the constant current excitation and the AD converter, and enabling the LCD display;
[0094] Specifically, the MCU microprocessor outputs a low level to control the constant current excitation to be turned off, so that the constant current excitation stops supplying power to the sensor and the sensor stops collecting data; at the same time, the AD converter is turned off to stop its collection function; and the LCD display screen enters the state of receiving display instructions.
[0095] Step S400, performing calculations on the data input by the sensor processed by the AD converter for several times and then transmitting the data to the LCD display screen for display includes:
[0096] Step S401, comparing the data input by the sensor processed by the AD converter for several times with the set alarm threshold, and outputting a current value on the switch current control circuit to indicate alarm or no alarm according to the comparison result;
[0097] Step S402, the LCD display screen displays the flow data collected by the sensor with a delay;
[0098] It includes delaying for several seconds first, and sending the flow value to the LCD display screen for display after the delay ends;
[0099] Specifically, the MCU microprocessor can control the LCD display screen to delay for 2 seconds before displaying the flow value.
[0100] Specifically, the AD converter collects and processes the data input by the sensor several times, and then compares it with the alarm threshold of the set value. When the alarm condition is met, the current value is output by the switch current control circuit to reflect the alarm status and display the current flow value on the LCD display. Among them, several switch current control circuits can be set as needed, and each switch current control circuit can correspond to an alarm range.
[0101] For example, the first switch current control circuit is set as a flow lower limit alarm circuit, the second switch current control circuit is set as a flow lower-lower limit alarm circuit, the lower flow alarm threshold is set to 30 cubic meters / hour, and the lower-lower flow alarm threshold is set to 20 cubic meters / hour. When the actual flow value measured by the sensor is greater than the lower flow alarm threshold, both switch current control circuits will output a current of ≤1.2mA; when the actual flow measured by the sensor is between the lower alarm threshold and the lower-lower alarm threshold, the first switch current control circuit will output a current of ≥2.1mA, and the second switch current control circuit will output a current of ≤1.2mA. When the actual current measured by sensor 2 is less than the lower-lower alarm threshold, both switch current control circuits will output a current of ≥2.1mA.
[0102] The above are all preferred embodiments of the present application, and the protection scope of the present application is not limited thereto. Therefore, any equivalent changes made according to the structure, shape, and principle of the present application should be included in the protection scope of the present application.
Claims
1. A NAMUR switch instrument transmitter, characterized in that: It comprises an MCU microprocessor (1), a sensor (2) connected to an input end of the MCU microprocessor (1), a key unit (3) connected to the input end of the MCU microprocessor (1), and a switch current control circuit connected to an output end of the MCU microprocessor (1); The output end of the MCU microprocessor (1) is connected to a constant current excitation (5) for supplying power to the sensor (2), and the constant current excitation (5) is electrically connected to a connector of the sensor (2); wherein the MCU microprocessor (1) is used to control the opening and closing of the constant current excitation (5); The switch current control circuit comprises a first switch current control circuit (6), the first switch current control circuit (6) being electrically connected to an output end of the MCU microprocessor (1), and the first switch current control circuit (6) being connected to a DC / DC power supply (8) and a connection terminal SW1; The switch current control circuit further comprises a second switch current control circuit (7), the second switch current control circuit (7) being connected to a wiring terminal SW2, and a low-power isolation element (9) being connected between the second switch current control circuit (7) and an output end of the MCU microprocessor (1); The first switch current control circuit (6) and the second switch current control circuit (7) both comprise a power supply processing circuit (60) and an operational amplifier (80); the power supply processing circuit (60) comprises a power supply circuit (61), a transistor state adjustment circuit (62) and a resistor R1 connected between a connection terminal SW1 and ground; and the operational amplifier (80) comprises an operational amplifier unit A and an operational amplifier unit B; The power supply circuit (61) comprises a resistor R3, the resistor R3 is connected to the positive electrode of the wiring terminal SW1, the emitter of the transistor Q1 and the resistor R4, the other end of the resistor R4 is connected to the base of the transistor Q1, the other end of the resistor R3 is connected to the negative electrode of the diode D5, the voltage regulator power supply LDO, the collector of the transistor Q1, the negative electrode of the diode D2 and the DC / DC power supply, and the positive electrode of the diode D2 and the positive electrode of the diode D5 are grounded respectively; The power input pin Vdd of the operational amplifier (80) is connected to the 3.3V output end of the voltage-stabilized power supply LDO, the pin Vss is grounded, the pin SHDNA and the pin SHDNB are connected to the 3.3V output end of the voltage-stabilized power supply LDO, and their function is to turn on the operational amplifier units A and B of the operational amplifier 80; The transistor state adjustment circuit (62) comprises a resistor R7, a transistor Q2 and a resistor R6, the resistor R7 is connected to the pin OUTA of the operational amplifier unit A, the other end of the resistor R7 is connected to the base of the transistor Q2, the emitter of the transistor Q2 is grounded, the collector of the transistor Q2 is connected to the resistor R6, and the other end of the resistor R6 is connected to the base B of the transistor Q1; The first switch current control circuit (6) and the second switch current control circuit (7) each further comprise a current output control circuit (70), wherein the current output control circuit (70) comprises a first voltage divider circuit (71), a second voltage divider circuit (72) and a current output circuit (73); The first voltage divider circuit (71) comprises a resistor R9 and a resistor R10, the resistor R9 and the resistor R10 are connected in series, the other end of the resistor R9 is connected to the MCU microprocessor (1), the other end of the resistor R10 is grounded, and the pin INB+ of the operational amplifier unit B is connected to the connection point between the resistor R9 and the resistor R10; The second voltage divider circuit (72) comprises a resistor R11 and a resistor R12, the resistor R11 and the resistor R12 are connected in series, the other end of the resistor R12 is connected to a voltage-stabilizing power supply LDO, the other end of the resistor R11 is grounded, and the pin INB- of the operational amplifier unit B is connected to the connection point between the resistor R11 and the resistor R12; The current output circuit (73) comprises a resistor R2, a resistor R5 and a resistor R8, wherein the resistor R2 is connected in series with the resistor R5, the other end of the resistor R2 is connected to the negative electrode of the wiring terminal SW1, the other end of the resistor R5 is connected to the voltage-stabilizing power supply LDO, the resistor R8 is connected to the connection point between the resistor R2 and the resistor R5, and the other end of the resistor R8 is connected to the pin OUTB of the operational amplifier unit B.
2. The NAMUR switch instrument transmitter according to claim 1, characterized in that: The power supply circuit (61) is provided with a diode D1, a diode D4 and a capacitor C1; the diode D1 is connected in series between the positive electrode of the wiring terminal SW1 and the resistor R3; the diode D4 is connected in series between the negative electrode of the diode D5 and the voltage-stabilizing power supply LDO; and the capacitor C1 is connected in parallel with the diode D2.
3. The NAMUR switch instrument transmitter according to claim 1, characterized in that: The MCU microprocessor (1) is also respectively connected to a ROM memory (10) and an LCD display screen (4).
4. A control method for a NAMUR switch instrument transmitter according to any one of claims 1 to 3, characterized in that: include: Control the constant current excitation and the AD converter to be turned on at the same time, so that the constant current excitation powers the sensor; The AD converter processes the data input by several sensors and stores it in the ROM memory; Turn off the constant current excitation and AD converter, and turn on the LCD display; The AD converter processes the data input by the sensor for several times and then transmits it to the LCD display screen for display.
5. The control method of the NAMUR switch instrument transmitter according to claim 4, characterized in that: The step of processing the data input by the sensor for several times by the AD converter and transmitting the data to the LCD display screen for display comprises: Comparing the data input by the sensor processed by the AD converter for several times with the set alarm threshold, and outputting a current value on the switch current control circuit to indicate alarm or no alarm according to the comparison result; The LCD display screen displays the flow data collected by the sensor with a delayed display.
Citation Information
Patent Citations
NAMUR signal alarm device
CN202403709U
Implementation method of programmable general digital quantity I / O signal conditioning
CN104410405A
Transformer circuit with a current interface and measuring instrument with such a transformer circuit
CN104956592A
High-precision in-situ seawater pH sensor control system and control method
CN109164731A
Digital piezoresistive pressure sensor circuit and digital piezoresistive pressure sensor
CN113252233A
