A tank under sampling box and sampling system

CN224921489UActive Publication Date: 2026-10-30CHINA PETROLEUM & CHEMICAL CORP +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202522559233.1
Authority / Receiving Office
CN · China
Patent Type
Utility models(China)
Current Assignee / Owner
Filing Date
2025-12-02
Publication Date
2026-10-30
Estimated Expiration
2035-12-02

AI Technical Summary

Technical Problem

[0004]鉴于上述问题,本申请提供了一种罐下取样箱及取样系统,以解决现有设计电子屏显示信息单一、现场操作受限的问题

Benefits of technology

[0019]借由上述技术方案,本申请提供的罐下取样箱通过在人机交互界面设置显示屏,并构建“单片机-串口-显示屏”的通信链路,使单片机可实时将取样剩余时间、取样桶位置等过程数据通过串口传输至显示屏,突破原有仅能显示取样完成状态的局限,实现取样过程信息的多维度可视化;并且,其通过在人机交互界面设置的多个电容按键替代原有机械式放样按键,通过按键处理电路建立多个电容按键与单片机的信号传输通道,同时依托“单片机-驱动电路-通断电控制电路-电磁阀”的控制链路,使操作人员可在罐下现场通过多个电容按键向单片机发送取样启动、位置调节、阀控调试等指令,单片机根据指令驱动对应电磁阀动作,无需依赖上位机即可完成多样化操作;且电容按键适配防爆箱隔玻璃操作,显示屏也通过该玻璃实现防爆隔离,二者共同满足工业现场防爆安全要求。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN224921489U_ABST
    Figure CN224921489U_ABST
Patent Text Reader

Abstract

The application discloses a tank under sampling box and a sampling system, and solves the problems of single display information of an electronic screen and limited field operation of the existing design. The tank under sampling box is internally configured with an explosion-proof box, the explosion-proof box is internally provided with a button processing circuit, a single-chip microcomputer, a driving circuit, m on-off power control circuits and m electromagnetic valves, and m is greater than or equal to 2; a human-computer interaction interface is arranged on the shell of the explosion-proof box, the interface is provided with a display screen and n capacitive buttons, n is greater than or equal to 2; electrodes of the n capacitive buttons are respectively connected to n input pins of the button processing circuit; n output pins of the capacitive button processing circuit are respectively connected to n button input pins of the single-chip microcomputer; a serial port of the single-chip microcomputer is connected to a serial port of the display screen; m valve control output pins of the single-chip microcomputer are respectively connected to m input pins of the driving circuit; m output pins of the driving circuit are one-to-one connected to control ends of the m on-off power control circuits; output ends of the m on-off power control circuits are one-to-one connected to power supply ends of the m electromagnetic valves.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of industrial automation control technology, and in particular to a tank-under-sampling box and sampling system. Background Technology

[0002] In the sampling system, the online sampler automatically samples the medium in the storage tank (such as an oil tank) and transports the sample to the sampling box under the tank for temporary storage through a dedicated pipeline. The sampling box under the tank only displays the sampling completion status on an electronic screen and realizes human-machine interaction through a mechanical sampling button. The operator needs to use the button to control the corresponding solenoid valve to release the sample (such as injecting it into the test container), thereby completing the entire process from taking material from the storage tank to obtaining the test sample.

[0003] However, the existing design has the following limitations: First, the electronic screen displays only limited information, showing only the sampling completion status and failing to display more information about the sampling process (such as remaining sampling time and the location of the sampling box under the tank). Second, on-site operation is limited, as sampling can only be performed directly under the tank using mechanical sampling buttons, which cannot cover more of the customer's on-site commissioning needs (such as direct sampling under the tank). Currently, displaying more sampling process information and meeting more on-site commissioning needs raised by customers requires the use of a host computer (such as a remote control terminal or an operating platform in the control room), and cannot be done directly at the sampling box location under the tank. Utility Model Content

[0004] In view of the above problems, this application provides a sampling box and sampling system under the tank to solve the problems of limited information displayed on the electronic screen and restricted on-site operation in existing designs. The specific solution is as follows:

[0005] The first aspect of this application provides a tank-mounted sampling box, which is equipped with an explosion-proof box. The explosion-proof box has a built-in key processing circuit, a microcontroller, a drive circuit, m on / off control circuits, and m solenoid valves for controlling the flow of oil samples, where m ≥ 2.

[0006] The explosion-proof box has a human-machine interface on its shell, and the outside of the human-machine interface is covered with an explosion-proof glass panel. The human-machine interface is directly opposite to the preset observation and operation port on the shell of the sampling box under the tank. The human-machine interface has a display screen and n capacitive buttons. The sensing area of ​​the capacitive buttons is directly opposite to the operation area of ​​the explosion-proof glass panel to respond to touch actions through the glass. n≥2.

[0007] The electrodes of the n capacitive buttons are respectively connected to the n input pins of the button processing circuit; the n output pins of the capacitive button processing circuit are respectively connected to the n button input pins of the microcontroller; the serial port of the microcontroller is connected to the serial port of the display screen; the m valve control output pins of the microcontroller are respectively connected to the m input pins of the drive circuit; the m output pins of the drive circuit are connected one-to-one to the control terminals of the m on / off control circuits; the output terminals of the m on / off control circuits are connected one-to-one to the power supply terminals of the m solenoid valves used to control the flow of oil samples.

[0008] In one possible implementation, the thickness of the explosion-proof glass panel is 10 mm.

[0009] In one possible implementation, n=4, and the button processing circuit consists of a touch screen / touch button microcontroller and its peripheral circuits.

[0010] In one possible implementation, the power supply pin of the touchscreen / touch button microcontroller is connected to a 3.3V voltage; the 3.3V voltage is obtained through a power conversion circuit; the power conversion circuit consists of a power conversion chip of model AP2210K-3.3TRG1 and its peripheral circuits, used to convert an external 5.1V input voltage into a 3.3V output voltage.

[0011] In one possible implementation, the microcontroller consists of an STM32F103RDT6 microcontroller unit and its peripheral circuitry.

[0012] In one possible implementation, the driving circuit consists of a ULN2001D chip and its peripheral circuitry.

[0013] In one possible implementation, the power-on / off control circuit includes: a relay U10, a resistor R20, a light-emitting diode D27, a diode D28, a capacitor C20, and a solenoid valve interface CON2;

[0014] One end of the coil of relay U10 is connected to the first power supply and one end of resistor R20. The other end of resistor R20 is connected to the anode of light-emitting diode D27. The cathode of light-emitting diode D27 is connected to the other end of the coil and one output pin of the driving circuit.

[0015] One end of the normally open contact of relay U10 is connected to the first power supply and one end of capacitor C20. The other end of capacitor C20 is connected to the other end of the normally open contact, the cathode of diode D28, and one pin of solenoid valve interface CON2. The anode of diode D28 and the other pin of solenoid valve interface CON2 are grounded.

[0016] In one possible implementation, a serial port expansion chip is connected between the microcontroller and the display screen.

[0017] In one possible implementation, the serial port expansion chip is model WK2114.

[0018] A second aspect of this application provides a sampling system, comprising: an under-tank sampling box of the first aspect or any implementation thereof.

[0019] By employing the aforementioned technical solution, the tank-under-tank sampling box provided in this application establishes a display screen on the human-machine interface and constructs a communication link of "microcontroller-serial port-display screen." This allows the microcontroller to transmit process data such as the remaining sampling time and sampling bucket position to the display screen in real time via the serial port, breaking through the original limitation of only displaying the sampling completion status and achieving multi-dimensional visualization of sampling process information. Furthermore, it replaces the original mechanical sampling buttons with multiple capacitive buttons on the human-machine interface. A signal transmission channel between the multiple capacitive buttons and the microcontroller is established through the button processing circuit. Simultaneously, relying on the control link of "microcontroller-drive circuit-power-off control circuit-solenoid valve," operators can send instructions such as sampling start, position adjustment, and valve control debugging to the microcontroller on-site under the tank via multiple capacitive buttons. The microcontroller drives the corresponding solenoid valve according to the instructions, enabling diverse operations without relying on a host computer. Moreover, the capacitive buttons are compatible with the explosion-proof enclosure's glass partition, and the display screen also achieves explosion-proof isolation through this glass, both jointly meeting the explosion-proof safety requirements of industrial sites. Attached Figure Description

[0020] The above and other features, advantages, and aspects of the embodiments of this disclosure will become more apparent when taken in conjunction with the accompanying drawings and the following detailed description. Throughout the drawings, the same or similar reference numerals denote the same or similar elements. It should be understood that the drawings are schematic, and the originals and elements are not necessarily drawn to scale.

[0021] Figure 1 This application provides a schematic diagram of the internal circuitry of an under-tank sampling box.

[0022] Figure 2 A circuit schematic diagram of a key processing circuit provided in this application;

[0023] Figure 3 A circuit schematic diagram of a power conversion circuit provided in this application;

[0024] Figure 4 The circuit diagram of a power-on / off control circuit provided in this application.

[0025] The annotations in the attached figures are explained as follows:

[0026] 1. Button processing circuit; 2. Microcontroller; 3. Drive circuit; 4. Power on / off control circuit; 5. Solenoid valve; 6. Human-machine interface; 7. Display screen; 8. Capacitive buttons. Detailed Implementation

[0027] To address the issues of limited information display and restricted on-site operation in existing electronic screen designs, this application provides an under-tank sampling box that not only enables diversified display of sampling process information and flexible on-site operation control, but also fully meets the safety requirements of industrial explosion-proof environments.

[0028] The following detailed description, with reference to the accompanying drawings, describes a sub-tank sampling box provided in an embodiment of this application. Those skilled in the art will recognize that, with technological advancements and the emergence of new scenarios, the technical solutions provided in this application are also applicable to similar technical problems.

[0029] The terms "first," "second," etc., used in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such terms are interchangeable where appropriate; this is merely a way of distinguishing objects with the same attributes in the embodiments of this application. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion, so that a process, method, system, product, or apparatus that comprises a series of elements is not necessarily limited to those elements, but may include other elements not explicitly listed or inherent to those processes, methods, products, or apparatuses.

[0030] See Figure 1 The present application provides a tank sampling box, which is equipped with an explosion-proof box. The explosion-proof box contains a button processing circuit 1, a microcontroller 2, a drive circuit 3, m on / off control circuits 4, and m solenoid valves 8 for controlling the flow of oil samples, where m ≥ 2.

[0031] The explosion-proof box is equipped with a human-machine interface 5, which is covered with an explosion-proof glass panel. The human-machine interface 5 is directly opposite to the preset observation and operation port on the shell of the sampling box under the tank. The human-machine interface is equipped with a display screen 6 and n capacitive buttons 7. The sensing area of ​​the capacitive buttons 7 is directly opposite to the operation area of ​​the explosion-proof glass panel to respond to touch actions through the glass. n≥2.

[0032] The electrodes of the n capacitive buttons 7 are respectively connected to the n input pins of the button processing circuit 1; the n output pins of the button processing circuit 1 are respectively connected to the n button input pins of the microcontroller 2; the serial port of the microcontroller 2 is connected to the serial port of the display screen 6; the m valve control output pins of the microcontroller 2 are respectively connected to the m input pins of the drive circuit 3; the m output pins of the drive circuit 3 are connected one-to-one to the control terminals of the m on / off control circuits 4; the output terminals of the m on / off control circuits are connected one-to-one to the power supply terminals of the m solenoid valves 8 used to control the flow of oil samples.

[0033] The working principle of a tank-under-tank sampling box provided in the embodiments of this application will be described in detail below:

[0034] Under-tank sampling boxes are commonly used for sampling liquid storage tanks (such as oil tanks) in the petroleum and chemical industries. Since flammable and explosive media (such as oil and gas) may be present on-site, they must meet explosion-proof standards. This application's embodiment integrates electrical components such as a button processing circuit, microcontroller, drive circuit, m on / off control circuits, and m solenoid valves within an explosion-proof enclosure. The sealed structure of the explosion-proof enclosure prevents direct contact between electrical sparks and high temperatures generated during operation and the external flammable and explosive environment, thus physically eliminating the risk of explosion. This is an essential design to meet the safety requirements of hazardous industrial scenarios.

[0035] The explosion-proof enclosure is equipped with a human-machine interface (containing a display screen and n capacitive buttons, n≥2). This human-machine interface is directly opposite the preset observation and operation port on the shell of the sampling box under the tank. That is, the display area of ​​the human-machine interface and the sensing area of ​​the capacitive buttons are completely overlapped with the visible area and the touch area of ​​the preset observation and operation port, respectively. This ensures that the operator can clearly see the information on the display screen and trigger the capacitive buttons through the preset observation and operation port on the shell of the sampling box under the tank, avoiding the inconvenience caused by the hidden location of the interface and improving the on-site efficiency of sampling and debugging.

[0036] The human-machine interface is covered by an explosion-proof glass panel (usually tempered glass), and the sensing area of ​​the capacitive buttons is positioned directly opposite the operating area of ​​the explosion-proof glass panel. This achieves explosion-proof safety through physical isolation while also specifically meeting the functional requirements of "visibility" of the display screen and "operability" of the capacitive buttons, ultimately achieving a balance between "safe isolation" and "functional usability." Specifically, the core of the capacitive buttons is to identify operations by detecting changes in capacitance between the electrodes and the human body (or the object being operated on). When an operator touches the corresponding position of the button through the explosion-proof glass panel, the human body, as a conductor, forms a coupling capacitance with the button electrodes through the explosion-proof glass panel (the insulating medium), causing a detectable change in the capacitance value of the electrodes. This change is recognized by the button processing circuit and converted into an electrical signal, which can then be captured by the microcontroller, thus enabling touch operation through the glass (i.e., the operator touching the corresponding area of ​​the explosion-proof glass panel triggers the corresponding capacitive button action). Furthermore, the transparency of the explosion-proof glass panel ensures that the operator can clearly observe the information on the display screen, preventing information from being obstructed by the isolation structure.

[0037] In this design, capacitive buttons rely on the coupling capacitance between the human body and the electrodes to function. The thickness of the explosion-proof glass panel, acting as an intermediate insulating layer, directly affects the capacitance value. If the explosion-proof glass panel is too thick (usually exceeding 10mm), the coupling capacitance will be too small, making it difficult for the button processing circuit to recognize the signal. If the explosion-proof glass panel is too thin, its mechanical strength will be insufficient to meet the impact and vibration resistance requirements of the explosion-proof enclosure (e.g., collisions at the sampling site can easily cause the glass to shatter, damaging the explosion-proof sealing structure and posing a safety risk). Furthermore, an excessively thin explosion-proof glass panel may break due to stress changes during long-term use, losing its physical isolation function. Therefore, the thickness of the explosion-proof glass panel needs to balance "effectiveness of capacitive signal recognition" and "stability of the explosion-proof structure." For example, a thickness of 10mm is suitable. This thickness ensures sufficient coupling capacitance between the human body and the electrodes (meeting the signal detection threshold of the button processing circuit) while also meeting the explosion-proof standard requirements for the mechanical strength of the glass, thus balancing operational reliability and industrial site safety.

[0038] The core control link, composed of electrical components inside the enclosure, is executed in the logical sequence of "command input and signal preprocessing - command processing and information feedback - execution drive and solenoid valve control".

[0039] In the "command input and signal preprocessing" stage, the capacitive buttons and the button processing circuit work together. When an operator touches a capacitive button through the explosion-proof glass panel, the insulating properties of the glass do not affect the formation of the coupling capacitance of the capacitive button. The electrode of the touched capacitive button can effectively sense the change in coupling capacitance between the human body and the electrode. The resulting capacitance change signal is transmitted in real time through an independent circuit path to the dedicated input pin of the button processing circuit (which has a one-to-one correspondence with the capacitive button). The button processing circuit converts the capacitance change signal into a digital signal that can be recognized by the microcontroller, while accurately detecting whether a button has been pressed and distinguishing the specific button number that has been pressed. Finally, the button processing circuit transmits the processed digital command one-to-one to the n button input pins of the microcontroller through its n output pins, realizing the accurate input and preprocessing of the operation command.

[0040] During the "instruction processing and information feedback" phase, the microcontroller and the display screen work together. After receiving the digital signals transmitted by the button processing circuit, the microcontroller performs logical analysis according to the preset control program (e.g., the "sampling start" instruction corresponds to triggering the opening sequence of a specific solenoid valve, and the "parameter view" instruction corresponds to retrieving the remaining sampling time data). On one hand, the microcontroller transmits the analyzed equipment operation data (such as sampling progress, real-time on / off status of each solenoid valve, fault codes, etc.) to the display screen in real time through a serial communication link. The display screen clearly visualizes the data through the explosion-proof glass panel, allowing operators to intuitively obtain information. On the other hand, based on the digital signal analysis results, the microcontroller generates a low-voltage control signal for the corresponding target solenoid valve and transmits the low-voltage control signal to the corresponding drive circuit through the corresponding number of valve control output pins to start the execution control process.

[0041] In the "execution drive and solenoid valve control" stage, the drive circuit, the on / off control circuit, and the target solenoid valve work together. Because the microcontroller's output voltage is incompatible with the solenoid valve's drive voltage, the drive circuit only receives the low-voltage control signal transmitted by the microcontroller to the target solenoid valve and converts it into a high-voltage drive signal adapted to the target solenoid valve. Subsequently, the corresponding output pin of the drive circuit transmits the high-voltage drive signal one-to-one to the control terminal of the on / off control circuit of the target solenoid valve, triggering the switching action of the corresponding on / off control circuit. Finally, the triggered on / off control circuit drives the target solenoid valve to perform switching actions by controlling the on / off of the power supply terminal of the corresponding solenoid valve (e.g., only 1-2 solenoid valves corresponding to the sampling pipeline are turned on when "sampling starts", and only the solenoid valve of the pipeline is turned off and sealed when "sampling is completed"), thus achieving precise control of the oil sample flow path.

[0042] Taking the "valve-controlled debugging mode" of the under-tank sampling box as an example, assuming m=13, n=4, the four capacitive buttons correspond to the "return", "adjust up", "adjust down" and "confirm" functions respectively. Figure 1(Using n=4 as an example for illustration only, but not a limitation), the operator touches the capacitive button on the explosion-proof glass panel to switch the interface and enter the valve control debugging mode menu. The display screen clearly shows three columns of solenoid valve control function options. Each option triggers the corresponding control command through the operation logic of "capacitive button selection + confirmation": The first is the "valve fully closed" function. After the operator selects and confirms this option, the microcontroller receives the command and pulls the output pin of the drive circuit corresponding to all controlled solenoid valves low, cutting off the drive signal of the corresponding solenoid valves, realizing the synchronous closure of all solenoid valves, and ensuring that the pipeline is in a sealed state before debugging; The second is the "full cavity pressure detection" function. After confirmation, the microcontroller only controls the output pin of the drive circuit corresponding to solenoid valves 3, 4, 5, 6, 9, 10, 11, 12, and 13 to output a high level, driving the solenoid valves of this group to open individually, constructing the pipeline path required for pressure detection, and meeting the process requirements of full cavity pressure monitoring. Thirdly, there is the "Cavity 1 Waste Discharge" function. After the command is triggered, the microcontroller only outputs a high level on the drive circuit output pins corresponding to solenoid valves 2, 3, and 9, driving the corresponding solenoid valves to open and forming a dedicated waste discharge path for cavity 1 to perform the waste discharge operation. Fourthly, there is the "Barrel Oil Intake" function. After confirmation, the microcontroller only controls the drive circuit output pin corresponding to solenoid valve 6 to output a high level, causing this solenoid valve to open independently, realizing the directional delivery of oil samples to the sampling barrel. Fifthly, there is the "Cavity 1 Barrel Oil Intake" function. After the command is triggered, the microcontroller drives the drive circuit output pins corresponding to solenoid valves 4, 5, 7, and 9 to output a high level. Through the coordinated opening of this group of solenoid valves, the transfer of oil samples from the sampling barrel to cavity 1 is completed. Sixthly, there is the "Waste Discharge Pipe Detection" function. After confirmation, the microcontroller only outputs a high level on the drive circuit output pins corresponding to solenoid valves 2 and 3, driving the corresponding solenoid valves to open, constructing a detection path for the waste discharge pipeline, and verifying the pipeline's sealing and flowability.

[0043] Furthermore, in this example, at the bottom of the valve control debugging mode menu, the display shows the numbers of 13 independent solenoid valves in a list format. The operator can position the cursor to the target solenoid valve number using the capacitive button and then trigger the confirmation button. The microcontroller can then individually control the level state of the output pin of the drive circuit corresponding to that solenoid valve—a high output level drives the solenoid valve to open, and a low output level controls the solenoid valve to close, enabling independent switching and debugging of the 13 solenoid valves and meeting the needs of single-valve fault diagnosis and performance verification.

[0044] In summary, the tank sampling box provided in this application provides a display screen in the human-machine interface and establishes a communication link of "microcontroller-serial port-display screen". This allows the microcontroller to transmit process data such as the remaining sampling time and the position of the sampling bucket to the display screen in real time via the serial port, breaking through the original limitation of only being able to display the sampling completion status and realizing multi-dimensional visualization of sampling process information. Furthermore, it replaces the original mechanical sampling buttons with multiple capacitive buttons in the human-machine interface. A signal transmission channel between the multiple capacitive buttons and the microcontroller is established through the button processing circuit. At the same time, relying on the control link of "microcontroller-drive circuit-power-off control circuit-solenoid valve", the operator can send instructions such as sampling start, position adjustment, and valve control debugging to the microcontroller on-site under the tank via multiple capacitive buttons. The microcontroller drives the corresponding solenoid valve to act according to the instructions, and can complete various operations without relying on a host computer. Moreover, the capacitive buttons are compatible with the explosion-proof box and operate through the glass (the glass does not affect signal recognition), and the display screen also achieves explosion-proof isolation through the glass (the glass ensures that information is visible). Both meet the explosion-proof safety requirements of industrial sites.

[0045] In one possible implementation, based on any of the under-tank sampling boxes provided above, such as Figure 2 As shown, taking n=4 as an example, the button processing circuit consists of a touch screen / touch button microcontroller U1 (often abbreviated as TP_MCU) and its peripheral circuits. The peripheral circuits include: resistors R1, R2, R3, R4, R5, R6, R7, R8, R9, capacitors C1, C2, and C3;

[0046] The touchscreen / touch button microcontroller U1 has 16 pins: VDD pin (power supply pin - pin 1), GND pin (ground pin - pin 3), CAP pin (capacitance detection reference pin - pin 2), SWCLK pin (serial clock pin - pin 5), SWDAT pin (serial data pin - pin 6), and 11 pins with dual functions of "capacitance signal input + status feedback output" (including PA0 pin - pin 4, PA3 pin - pin 7, PA4 pin - pin 8, PA5 pin - pin 9, PA6 pin - pin 10, PA7 pin - pin 11, PB0 pin - pin 12, PB1 pin - pin 13, PB2 pin - pin 14, PB3 pin - pin 15, PB4 pin - pin 16).

[0047] One end of resistor R1 is connected to the 3V3 power supply (i.e., 3.3V voltage), and the other end of resistor R1 is connected to one end of capacitor C1 and pin 1 of the touch screen / touch button microcontroller U1; one end of capacitor C3 is connected to pin 2 of the touch screen / touch button microcontroller U1, and the other ends of capacitors C1 and C3 are grounded; capacitor C1 is connected in parallel with capacitor C2.

[0048] Pin 16 of the touchscreen / touch button microcontroller U1 is connected to the electrode TP1 of the first capacitive button via resistor R2; pin 15 of the touchscreen / touch button microcontroller U1 is connected to the electrode TP2 of the second capacitive button via resistor R3; pin 14 of the touchscreen / touch button microcontroller U1 is connected to the electrode TP3 of the third capacitive button via resistor R4; and pin 13 of the touchscreen / touch button microcontroller U1 is connected to the electrode TP4 of the fourth capacitive button via resistor R5.

[0049] Pin 10 of the touchscreen / touch button microcontroller U1 is connected to node PC0 via resistor R7, and node PC0 is connected to the 3V3 power supply via resistor R14; pin 9 of the touchscreen / touch button microcontroller U1 is connected to node PC1 via resistor R9, and node PC1 is connected to the 3V3 power supply via resistor R15; pin 8 of the touchscreen / touch button microcontroller U1 is connected to node PC2 via resistor R8, and node PC2 is connected to the 3V3 power supply via resistor R16; pin 7 of the touchscreen / touch button microcontroller U1 is connected to node PC3 via resistor R6, and node PC3 is connected to the 3V3 power supply via resistor R17.

[0050] PC0, PC1, PC2, and PC3 nodes are connected to n key input pins of the microcontroller.

[0051] In one possible implementation, the 3V3 power supply can be obtained via a power conversion circuit, such as... Figure 3 As shown, the power conversion circuit consists of a power conversion chip U2 (model AP2210K-3.3TRG1) and its peripheral circuitry, used to convert an external 5.1V input voltage to a 3.3V output voltage. The peripheral circuitry includes: capacitors C4, C5, C6, C7, and C8; resistor R10; and a light-emitting diode D1.

[0052] The power conversion chip U2 has five pins: VIN (voltage input pin - pin 1), EN (enable control pin - pin 3), GND (ground pin - pin 2), VOUT (voltage output pin - pin 5), and BYP (bypass filter pin - pin 4).

[0053] Pins 1 and 3 of power conversion chip U2 are connected to a 5V1 power supply (i.e., 5.1V voltage) and one end of capacitor C4. Pin 2 of power conversion chip U2 is grounded and connected to the other end of capacitor C4. Capacitor C4 and capacitor C5 are connected in parallel. Pin 4 of power conversion chip U2 is grounded via capacitor C6, one end of capacitor C7, and the cathode of LED D1. Pin 5 of power conversion chip U2 is connected to a 3V3 power supply, one end of resistor R10, and the other end of capacitor C7. Capacitor C7 and capacitor C8 are connected in parallel. The other end of resistor R10 is connected to the anode of LED D1.

[0054] In one possible implementation, based on any of the tank-mounted sampling boxes provided above, the microcontroller consists of an STM32F103RDT6 MCU (Micro Control Unit) and its peripheral circuitry. The microcontroller connects to the display screen via the MCU's MRX (serial receive pin) and MIX (serial transmit pin), and uses UART (Universal Asynchronous Receiver / Transmitter) serial communication for data exchange.

[0055] In one possible implementation, based on any of the tank sampling boxes provided above, the drive circuit is designed specifically for "weak current control of strong current load" in explosion-proof scenarios, and may be composed of a ULN2001D chip and its peripheral circuits.

[0056] In one possible implementation, based on any of the under-tank sampling boxes provided above, such as Figure 4 As shown, the power-on / off control circuit includes: relay U10, resistor R20, light-emitting diode D27, diode D28, capacitor C20, and solenoid valve interface CON2;

[0057] One end of the coil of relay U10 is connected to the first power supply (such as power supply 12V) and one end of resistor R20. The other end of resistor R20 is connected to the anode of light-emitting diode D27. The cathode of light-emitting diode D27 is connected to the other end of the coil and one output pin Relay11 of the driving circuit.

[0058] One end of the normally open contact of relay U10 is connected to the first power supply (such as power supply 24V) and one end of capacitor C20. The other end of capacitor C20 is connected to the other end of the normally open contact, the cathode of diode D28 and pin 1 of solenoid valve interface CON2. The anode of diode D28 and pin 2 of solenoid valve interface CON2 are grounded.

[0059] Figure 4The working principle of the power-on / off control circuit shown is as follows: When the drive circuit outputs a low level, the 12V power supply flows into the LED D27 after being current-limited by resistor R20. LED D27 illuminates due to forward bias (the operator can observe the indicator light status through the explosion-proof glass to confirm that the circuit has been triggered). The current continues to flow into the coil of relay U10, generating electromagnetic attraction and realizing the "electrical to magnetic" conversion. After the coil of relay U10 is energized, the normally open contact of relay U10 closes under the action of electromagnetic attraction. The 24V power supply forms a path through the closed contact. At this time, the 24V power supply is divided into two paths after the contact: one path is filtered by C20 (to ensure voltage stability), and the other path is supplied to the solenoid valve through the CON2 interface. Simultaneously, D28 is in a reverse cutoff state, not affecting the power supply to the solenoid valve. After the solenoid valve obtains a 24V operating voltage through the CON2 interface, the internal coil is energized to generate magnetic force, which drives the valve core to move, completing the "magnetic to mechanical" conversion. When the drive circuit stops outputting a low level, the coil of relay U10 is de-energized, the normally open contact of relay U10 opens, and the solenoid valve is de-energized. At this time, the reverse electromotive force generated by the solenoid valve coil is released through diode D28 freewheeling to avoid high voltage damage to the relay contacts or drive circuit. At the same time, capacitor C20 discharges to replenish the instantaneous voltage and ensure circuit stability.

[0060] In one possible implementation, based on any of the aforementioned under-tank sampling boxes, a serial port expansion chip (e.g., WK2114) is introduced between the microcontroller and the display screen. The multi-serial port feature of the WK2114 reserves space for future system upgrades. If temperature and humidity sensors, pressure sensors, or other devices need to be added inside the explosion-proof box in the future, they can be connected through the remaining expansion serial ports without modifying the core communication link between the microcontroller and the display screen. This protects the established explosion-proof glass structure from damage while improving the system's flexibility.

[0061] Furthermore, this application also provides a sampling system, including any of the tank sampling boxes provided in this application. This sampling system, with the tank sampling box as its core, integrates an online sampler, a dedicated transmission pipeline, and a sample collection component, constructing a complete closed loop from material extraction from the storage tank (such as an oil tank) to sample acquisition. The online sampler connects to the storage tank via an explosion-proof interface. It automatically extracts the medium according to a preset program or instructions from the sampling box under the tank, and then transports the sample directionally to the temporary storage unit of the sampling box via a pressure-resistant sealed pipeline. The sampling box under the tank, serving as the system's control and interaction hub, not only dynamically displays multi-dimensional information such as sampling progress, temporary liquid level, and pipeline pressure on an optimized glass display screen, but also replaces traditional mechanical sampling buttons with capacitive touch buttons. This allows operators to directly trigger operations such as sampling initiation, valve group adjustment, and quantitative sampling on-site. Instructions are parsed by a microcontroller and controlled by a drive circuit to activate the corresponding solenoid valve, achieving precise sample release to the testing container. The transmission pipeline uses corrosion-resistant materials and is equipped with pressure monitoring points to provide real-time feedback on the flow path status to the sampling box under the tank, ensuring safe and stable sample delivery. Through the functional upgrade of the sampling box under the tank, this system retains the automation advantages of online sampling while solving the problems of limited information and operation in traditional designs, achieving on-site visibility, local control, and safety and reliability throughout the entire sampling process from the storage tank.

[0062] The above description of the disclosed embodiments enables those skilled in the art to make or use this application. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the embodiments of this application. Therefore, the embodiments of this application are not to be limited to the embodiments shown herein, but are to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. A sampling box under a tank, characterized in that: The sampling box under the tank is equipped with an explosion-proof box, which contains a button processing circuit, a microcontroller, a drive circuit, m on / off control circuits, and m solenoid valves for controlling the flow of oil samples, where m ≥ 2. The explosion-proof box has a human-machine interface on its shell, and the outside of the human-machine interface is covered with an explosion-proof glass panel. The human-machine interface is directly opposite to the preset observation and operation port on the shell of the sampling box under the tank. The human-machine interface has a display screen and n capacitive buttons. The sensing area of ​​the capacitive buttons is directly opposite to the operation area of ​​the explosion-proof glass panel to respond to touch actions through the glass. n≥2. The electrodes of the n capacitive buttons are respectively connected to the n input pins of the button processing circuit; the n output pins of the capacitive button processing circuit are respectively connected to the n button input pins of the microcontroller; the serial port of the microcontroller is connected to the serial port of the display screen; the m valve control output pins of the microcontroller are respectively connected to the m input pins of the drive circuit; the m output pins of the drive circuit are connected one-to-one to the control terminals of the m on / off control circuits; the output terminals of the m on / off control circuits are connected one-to-one to the power supply terminals of the m solenoid valves used to control the flow of oil samples.

2. The under-tank sampling box according to claim 1, characterized in that, The thickness of the explosion-proof glass panel is 10 mm.

3. The under-tank sampling box according to claim 1, characterized in that, n=4, the button processing circuit consists of a touch screen / touch button microcontroller and its peripheral circuits.

4. The under-tank sampling box according to claim 3, characterized in that, The power supply pin of the touch screen / touch button microcontroller is connected to a 3.3V voltage; the 3.3V voltage is obtained through a power conversion circuit; the power conversion circuit consists of a power conversion chip of model AP2210K-3.3TRG1 and its peripheral circuits, which is used to convert the external 5.1V input voltage into a 3.3V output voltage.

5. The under-tank sampling box according to claim 1, characterized in that, The microcontroller consists of an STM32F103RDT6 microcontroller unit and its peripheral circuits.

6. The under-tank sampling box according to claim 1, characterized in that, The driving circuit consists of a ULN2001D chip and its peripheral circuitry.

7. The under-tank sampling box according to claim 1, characterized in that, The power on / off control circuit includes: relay U10, resistor R20, light-emitting diode D27, diode D28, capacitor C20, and solenoid valve interface CON2; One end of the coil of relay U10 is connected to the first power supply and one end of resistor R20. The other end of resistor R20 is connected to the anode of light-emitting diode D27. The cathode of light-emitting diode D27 is connected to the other end of the coil and one output pin of the driving circuit. One end of the normally open contact of relay U10 is connected to the first power supply and one end of capacitor C20. The other end of capacitor C20 is connected to the other end of the normally open contact, the cathode of diode D28, and one pin of solenoid valve interface CON2. The anode of diode D28 and the other pin of solenoid valve interface CON2 are grounded.

8. The under-tank sampling box according to claim 1, characterized in that, A serial port expansion chip connects the microcontroller and the display screen.

9. The under-tank sampling box according to claim 8, characterized in that, The serial port expansion chip is model WK2114.

10. A sampling system, characterized in that, include: The under-tank sampling box as described in any one of claims 1 to 9.