A downhole oil reservoir multi-parameter synchronous measurement and dual-link communication device and method
Patent Information
- Application Number
- CN202611001739.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-07
- Publication Date
- 2026-09-25
AI Technical Summary
[0009]针对现有井下油藏监测设备存在多参数采样同步性差;传统流量检测采用分体式结构或分时采样模式,设备体积大、存在固有采样盲区与控制滞后、检测精度偏低;电导率检测依赖快速傅里叶变换运算与多级模拟电路,硬件架构繁杂,难以实现小型化集成;设备工作模式单一、存储数据管理混乱;单一通信链路场景适配性弱、数据传输可靠性不足等技术缺陷,本发明提出一种井下油藏多参数同步测量与双链路通信装置及方法
一、多参数同步测量精度高。本发明采用单主 MCU 搭配 0.4 秒短周期主循环与中断协同调度架构,统一全系统采样时序、集中完成模数转换,彻底解决传统设备分时采集带来的时序偏差问题,大幅提升多参数数据的时序一致性,满足高精度油藏数据分析的使用要求。
Smart Images

Figure CN122812611A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of downhole monitoring technology in petroleum engineering, specifically relating to a device and method for synchronous measurement of multiple parameters and dual-link communication in downhole reservoirs. Background Technology
[0002] Parameters such as temperature, flow rate, pressure, conductivity, and tubing couplings in oil reservoirs are crucial for assessing reservoir operating conditions and analyzing downhole fluid characteristics. Currently, embedded monitoring and control equipment is widely used in the industry to complete the acquisition and data transmission of multiple downhole parameters.
[0003] Existing downhole measurement devices of the same type mostly adopt a cross-cycle distributed time-sharing acquisition architecture. The sampling of various parameters is distributed in multiple master control cycles. The sampling time intervals of each channel are significantly different and the timing is misaligned. The synchronous measurement accuracy is insufficient and it is difficult to meet the requirements of high-precision reservoir data analysis.
[0004] In conductivity detection, traditional methods generally employ sinusoidal excitation combined with Fast Fourier Transform (FFT) for spectrum analysis. On the one hand, this requires the main control unit to perform a large number of complex number operations, significantly increasing the processor's workload. On the other hand, to ensure waveform quality and detection accuracy, additional peripheral circuits such as multi-stage analog filtering and waveform shaping are required. Due to the limitations of the confined underground cavity and limited onboard space, the layout of complex analog circuits and computing architectures is difficult, severely restricting the multi-parameter integration and synchronous measurement capabilities of miniaturized equipment.
[0005] Downhole fluid flow rate detection has long been a technical challenge. Traditional downhole flow rate detection devices often employ a separate sensor structure, with temperature measurement, flow measurement, and heating units operating independently. This results in a large number of discrete components, a bulky overall size, and occupies valuable downhole equipment space. Furthermore, traditional detection methods are susceptible to fluctuations in downhole ambient temperature and dynamic changes in fluid conditions, leading to significant temperature drift. Moreover, the use of time-sharing temperature measurement modes introduces inherent sampling blind spots and control lags, making it impossible to stably lock onto the detection benchmark. Regarding constant temperature difference control, existing solutions generally employ a fixed target temperature difference and a single PID parameter, making it difficult to simultaneously balance the sensitivity of low-flow-rate measurements at low temperatures with power consumption and range constraints at high temperatures. Insufficient stability of temperature difference control over a wide temperature range ultimately results in low flow measurement accuracy and poor adaptability and long-term stability.
[0006] In terms of operating modes and data storage, traditional equipment has a single functional mode, mostly supporting only offline storage or a single online transmission method. It cannot simultaneously adapt to various engineering scenarios such as short-term fixed-point measurement underground, surface data playback, real-time on-site monitoring, and long-term underground remote data transmission, resulting in weak equipment versatility. At the same time, most equipment does not have partitioned storage areas, and configuration parameters and measurement data are stored together, leading to poor data read / write stability and insufficient data management convenience.
[0007] At the communication transmission level, existing equipment is mostly configured with only a single data transmission link, which limits its applicable scenarios. Among them, conventional downhole 485 asynchronous communication protocols have the risk of frame synchronization misjudgment, byte conflicts are prone to generating additional escaping overhead, and the link cannot recover autonomously after being interfered with, resulting in poor communication fault tolerance; traditional tubing string acoustic communication mostly adopts simple encoding methods, with limited encoding capacity and weak anti-interference ability, making it difficult to achieve stable and reliable downhole data transmission.
[0008] In summary, existing downhole multi-parameter measurement equipment generally suffers from problems such as poor synchronization of multi-parameter sampling, low flow detection accuracy and low hardware integration, complex conductivity detection circuits that are not conducive to miniaturization, single working mode with weak adaptability, and insufficient reliability of dual-mode communication. These issues make it difficult to meet the current integrated monitoring needs of oil and gas wells for high precision, multiple scenarios, and high reliability. The industry urgently needs a downhole reservoir multi-parameter synchronous measurement and communication device with better overall performance. Summary of the Invention
[0009] To address the shortcomings of existing downhole reservoir monitoring equipment, such as poor synchronization of multi-parameter sampling; traditional flow detection employs a split structure or time-sharing sampling mode, resulting in large equipment size, inherent sampling blind spots and control lag, and low detection accuracy; conductivity detection relies on fast Fourier transform operations and multi-level analog circuits, leading to complex hardware architectures that are difficult to miniaturize and integrate; the equipment operates in a single mode with chaotic data management; and single communication link has weak adaptability to various scenarios and insufficient data transmission reliability, this invention proposes a downhole reservoir multi-parameter synchronous measurement and dual-link communication device and method.
[0010] This invention aims to solve the technical challenge of highly integrating multiple parameters within confined downhole cavities, achieving high-precision synchronous acquisition of temperature, flow rate, pressure, conductivity, and coupling signals; simplifying the hardware architecture and computational overhead for conductivity detection; improving the anti-interference capability and operational stability of downhole flow measurement; and ensuring compatibility with various downhole operating conditions, enabling reliable local data storage and dual-link high-reliability communication, thus fully meeting the integrated monitoring needs of oil and gas wells for high precision, miniaturization, multi-scenario operation, and high stability.
[0011] To achieve the above objectives, the present invention adopts the following technical solution: A downhole reservoir multi-parameter synchronous measurement and dual-link communication device includes a battery-powered module, a multi-parameter detection unit, a 24-bit AD sampling module, a data storage module, and a dual-link communication module. Its features include: a single master MCU control module; the single master MCU employs a working architecture with a 0.4-second fixed-cycle main loop and multi-interrupt collaborative scheduling; the multi-parameter detection unit integrates a four-wire PT100 temperature and flow rate integrated detection unit, a pressure detection unit, a conductivity detection unit, and an electromagnetic induction coupling detection unit; the four-wire PT100 temperature and flow rate integrated detection unit integrates heating and temperature measurement parallel multiplexing functions, employing a hardware-simulated constant current inner loop combined with a single-stage digital temperature difference outer loop constant temperature difference control architecture; the conductivity detection unit can output software-adjustable multi-frequency excitation signals and complete conductivity parameter acquisition using peak detection; the analog output signals of each detection unit are uniformly connected to the 24-bit AD sampling module for centralized synchronous analog-to-digital conversion; the data storage module uses an EEPROM partitioned storage structure, dividing it into independent parameter storage partitions and measurement data storage partitions; the dual-link communication module includes a 485... The device includes a wired communication unit and a dual-frequency acoustic wireless communication unit; it is configured with three switchable operating modes: a timed measurement and storage mode, a 485 online real-time measurement mode, and an acoustic long-term residence and upload mode.
[0012] The electromagnetic induction coupling detection unit consists of an upper magnet, a ring induction coil, and a lower magnet forming a closed magnetic circuit. It identifies the oil pipe coupling by relying on magnetic field distortion and marks the timestamp. The MCU is configured with four types of interrupts. The interrupts are only used for flag setting and a small amount of buffering. Complex calculations, storage, and communication are all executed serially in the main loop in 0.4s.
[0013] The four-wire PT100 unit adopts a dual-probe four-wire platinum resistance structure. Two leads carry constant current heating current, and the other two synchronously acquire voltage signals, with no time-sharing switching during the entire heating and temperature measurement process. The constant temperature difference control adopts an ambient temperature segmented adaptive target temperature difference strategy, with a temperature hysteresis threshold to suppress gear jumps. The control algorithm uses a PID with different parameters for heating and cooling, and synchronously sets integral freeze and deviation dead zone anti-oscillation mechanisms. The flow calculation uses the reference power ratio method to complete multi-medium normalization compensation, and the static reference power achieves full-temperature-range temperature compensation through a quadratic polynomial. The entire flow measurement adopts a hierarchical computing architecture. The downhole MCU only performs integer closed-loop control and raw data acquisition, while the floating-point calculations for temperature compensation, medium normalization, and flow velocity fitting are completed by the ground host computer. The conductivity unit consists of a measuring electrode, an excitation circuit, and a peak rectification sampling circuit. Multi-frequency excitation combined with peak sampling measures conductivity, and dual-frequency integer multiples suppress temperature drift and frequency deviation, eliminating the need for FFT demodulation.
[0014] The EEPROM is divided into a parameter area and a measurement data area, which are isolated and independently read and written. The parameter area stores calibration coefficients and configurations. The 485 unit is responsible for real-time configuration and online transmission, and the dual-frequency acoustic wave unit is used for long-distance long-term residence and transmission. The two links are independently enabled as needed.
[0015] The three working modes are automatically determined upon power-on, and can be dynamically switched by instructions from the host computer during operation. The whole machine has the ability to automatically reset and heal itself in case of software and hardware abnormalities.
[0016] Pressure detection uses three-segment linear calibration: 0-10MPa, 10-20MPa, and 20-35MPa. The boundary points are shared, and each segment is configured with independent K and B coefficients. The calibration coefficients K and B are amplified by 1000 times and stored as integers in EEPROM. The original AD data is not stored on the ground. The MCU reads the coefficients and converts them into physical quantities.
[0017] A method for synchronous measurement of multiple parameters and dual-link communication in downhole reservoirs, characterized by the following steps applied to the aforementioned device: S1. After powering on, the device completes hardware self-test and system parameter loading, reads preset configuration parameters, and determines the current working mode; S2. A single main MCU runs the main loop at a fixed cycle of 0.4 seconds, coordinating with multiple interrupts to output excitation signals, centrally and synchronously acquiring temperature, pressure, conductivity, and coupling position signals, and calculating fluid flow parameters; S3. The raw sampled data is filtered and converted using engineering methods. Fluid flow is calculated using dual PT100 temperature difference combined with constant temperature difference control logic, and fluid conductivity parameters are obtained through multi-frequency excitation peak detection; S4. According to the current working mode, corresponding local timed storage, 485 real-time transmission, or acoustic remote buffer upload operations are executed; S5. During operation, the system and link status are monitored in real time. When an anomaly occurs, invalid data is automatically discarded and self-healing reset is performed to maintain continuous downhole monitoring operations.
[0018] Automatic restart upon power-on self-test failure; loading calibration and configuration parameters upon successful self-test. All interrupts only complete flag and signal output; all data processing, storage, and communication tasks run serially in the main loop to ensure stable cycle. Local data storage in timer mode, instant response and uploading in 485 mode, and low-power buffered timed remote transmission in acoustic wave mode. Timer, excitation waveform, and coupling capture interrupts provide storage timing, dual-frequency waveform, and position pulse acquisition references, respectively.
[0019] When communication, sampling, or hardware anomalies occur, the current task is terminated, errors are cleared, and the system falls back to the mode determination to achieve unmanned self-healing. The pressure algorithm adopts the segmented calibration and coefficient scaling restoration scheme, and the conductivity adopts frequency doubling + peak sampling, abandoning FFT operation. The flow measurement adopts the reference power ratio method to complete the medium normalization, and combines segmented adaptive temperature difference and temperature rise and fall parameter PID to complete constant temperature difference control. After the raw data is uploaded, the floating point flow rate is calculated by the ground.
[0020] Compared with existing technologies, this invention has several significant technical advantages and specifically addresses various shortcomings of existing equipment: I. High accuracy of multi-parameter synchronous measurement. This invention adopts a single main MCU with a 0.4-second short-cycle main loop and interrupt collaborative scheduling architecture to unify the sampling timing of the entire system and centrally complete analog-to-digital conversion, completely solving the timing deviation problem caused by time-sharing acquisition of traditional equipment, greatly improving the timing consistency of multi-parameter data, and meeting the requirements of high-precision reservoir data analysis.
[0021] II. High flow detection accuracy and fast response speed, with significantly improved hardware integration. Adopting a four-wire PT100 integrated temperature and flow structure, replacing the traditional separate detection unit, reduces the number of discrete components, shrinks the PCB footprint, and adapts to confined downhole cavity layouts. Utilizing a topology that combines heating and temperature measurement in parallel, it achieves continuous, blind-zone-free constant temperature difference control, eliminating sampling blind spots and control lag in traditional time-sharing schemes, effectively suppressing downhole temperature fluctuations and fluid condition disturbances, and stabilizing the detection benchmark. Simultaneously, through a combination of segmented adaptive temperature difference, heterogeneous parameter PID, and hierarchical computing power design, it balances full-temperature-range measurement sensitivity with downhole operational stability. Only clean water calibration is required to adapt to multiphase flow conditions in downhole oil and water, significantly improving the equipment's adaptability to on-site conditions and long-term measurement accuracy.
[0022] III. The conductivity detection hardware is extremely simplified and adapted to miniaturized integrated designs in downhole applications. It abandons the traditional fast Fourier transform demodulation and phase detection schemes, directly acquiring peak amplitude values through a precision rectifier circuit to achieve high-precision measurement. This significantly simplifies the hardware chain and reduces computational load, solving the industry problem of complex circuits in traditional high-precision solutions that cannot adapt to multi-parameter integration in confined downhole cavities.
[0023] IV. Diverse working modes and strong adaptability to various working conditions. It integrates three working modes: offline storage and playback, 485 real-time transmission, and long-term acoustic wave uploading. It can adapt to various engineering scenarios such as short-term fixed-point sampling inspection in wells, factory calibration and debugging on the ground, and long-term unattended monitoring of low-temperature wells. The equipment's versatility is far superior to traditional single-mode equipment.
[0024] V. Reliable data storage and standardized management. An EEPROM partitioned storage mechanism is adopted to store configuration parameters and measurement data in separate partitions, avoiding data interference and improving the long-term read / write reliability and ease of data management.
[0025] VI. Dual-link communication boasts strong anti-interference capabilities and high transmission reliability. A dual-link system is established, integrating wired 485 communication and acoustic wireless communication for oil pipelines. These two types of links complement each other and have a wider range of applications. 485 communication relies on a self-synchronization error-proofing protocol to eliminate byte conflicts and support autonomous link self-healing. Acoustic communication employs a high-low dual-frequency decimal combination encoding, offering large encoding capacity, high efficiency, and excellent anti-interference performance, comprehensively solving the problems of poor fault tolerance, low reliability, low communication speed, and limited application scenarios inherent in traditional communication. Attached Figure Description
[0026] 1. Figure 1 This is a schematic diagram of the overall external structure of the device of the present invention, used to show the overall shape of the complete downhole measurement equipment, the layout of each functional component, and the overall assembly structure. Specific component names are: 1. Upper magnet; 2. Coil; 3. Lower magnet; 4. Pressure sensor; 5. Wall; 6. Heat-absorbing material; 7. Four-wire PT100 lead wire; 8. Adapter; 9. Sealing copper gasket; 10. Pressure guiding capillary tube; 11. Ambient temperature measuring probe; 12. Thermally conductive adhesive; 13. Four-wire PT100 for temperature measurement; 14. Four-wire PT100 for heating / temperature measurement parallel multiplexing; 15. Heating / temperature measurement parallel multiplexing probe; 16. Conductivity measuring electrode.
[0027] 2. Figure 2 This is a timing diagram illustrating the main loop and interrupt handling of the single-master MCU in this invention. It demonstrates the scheduling logic of the 0.4-second cycle main loop working in conjunction with interrupts, as well as the timing relationship of multi-parameter synchronous measurement. The main program is an infinite loop with a maximum cycle of 400ms; all complex business logic is executed within the main program, and interrupts are handled with minimal intervention. The system includes two four-wire PT100 transceivers, one for parallel multiplexing of heating temperature measurement and the other for measuring the ambient reference temperature. Solid circles represent fixed-time interval interrupts of Timer 1, used to generate time stamps; dotted circles represent adjustable frequency interrupts of Timer 2, used for time-division multiplexing of conductivity multi-frequency excitation; grid circles represent adjustable frequency interrupts of Timer 3, used for superimposing to generate pipeline communication carrier waves; hollow single circles represent UART asynchronous interrupts; and double-ringed circles represent burst pulse interrupts for coupling detection.
[0028] 3. Figure 3 This is a schematic diagram of the switching process of the three working modes of the present invention, used to show the selection logic, operation process and state switching relationship of the three working modes after the device is powered on.
[0029] 4. Figure 4This is a hardware electrical principle block diagram of the system of the present invention, used to illustrate the composition, power supply relationship, signal flow and interconnection architecture of each functional module of the whole machine. Detailed Implementation
[0030] Exemplary embodiments of this disclosure will now be described in more detail with reference to the accompanying drawings.
[0031] Figure 1 is a schematic diagram of the overall external structure of the device of the present invention, which is used to show the overall shape of the entire downhole measurement equipment, the layout of each functional component and the overall assembly structure.
[0032] Figure 2 is a schematic diagram of the timing of the main loop and interrupt handling of the single-master MCU of the present invention, which is used to illustrate the scheduling logic of the main loop with 0.4-second cycle working in conjunction with the interrupt, as well as the timing relationship of multi-parameter synchronous measurement.
[0033] Figure 3 is a schematic diagram of the switching process of the three working modes of the present invention, which is used to show the selection logic, operation process and state switching relationship of the three working modes after the device is powered on.
[0034] Figure 4 is a block diagram of the electrical principle of the system hardware of the present invention, which is used to show the composition, power supply relationship, signal flow and interconnection architecture of each functional module of the whole machine.
[0035] To achieve the objectives of this invention, the technical solution of this invention will be described in detail in specific embodiments:
[0036] A downhole reservoir multi-parameter synchronous measurement and dual-link communication device includes a single main MCU main control module, a battery power supply module, a multi-parameter detection unit, a 24-bit AD sampling module, a data storage module, and a dual-link communication module.
[0037] The battery power supply module provides a stable power supply for all functional units of the whole machine. The whole machine adopts a compact board-level integrated layout, which is suitable for the installation conditions of narrow underground cavities. The single main MCU serves as the only control core of the whole machine. It adopts a main loop with a fixed cycle of 0.4 seconds and an interrupt-coordinated scheduling architecture to coordinate the scheduling of various parameter acquisition and signal processing tasks, and realize high-precision synchronous measurement of multiple parameters.
[0038] The multi-parameter detection unit integrates a four-wire PT100 temperature and flow rate integrated detection unit, a pressure detection unit, a conductivity detection unit, and an electromagnetic induction coupling detection unit. The four-wire PT100 temperature and flow rate integrated detection unit abandons the traditional separate sensor design, highly integrating temperature measurement, flow measurement, and heating functions. It adopts a periodic command-based hierarchical control architecture combining a hardware-simulated constant current inner loop and a digital temperature difference outer loop. Based on the topology of parallel multiplexing of four-wire platinum resistance heating and temperature measurement, the probe internally features a dual-parallel metal electrode structure. Two sets of electrodes are connected to both ends of the platinum resistance core. One pair of electrodes forms a high-current heating circuit, and the other pair forms a high-impedance temperature measurement sampling circuit. The two physical paths are independent, with no time-sharing switching throughout the heating process. Continuous, blind-zone-free temperature measurement and closed-loop regulation can be achieved while the heating current is continuously conducting. The heating drive adopts a linear continuous DC constant current architecture. The output current is continuously adjustable through a digitally controlled voltage adjustment reference and a hardware negative feedback current stabilization topology. There is no PWM switching chopper ripple, which avoids electromagnetic crosstalk interference with weak temperature measurement signals. The temperature measurement sampling adopts a high impedance differential acquisition scheme, and the front end is equipped with an instrumentation amplifier and a low-pass filter to completely suppress the temperature measurement error caused by the parasitic resistance of the lead wires at the hardware level.
[0039] This unit is configured to employ a segmented adaptive target temperature difference control strategy based on ambient temperature. The higher the ambient fluid temperature, the smaller the target temperature difference value. A built-in temperature hysteresis threshold suppresses frequent temperature difference jumps. The closed-loop control algorithm uses a PID controller with varying parameters for both heating and cooling phases. Two independent gain parameters are automatically invoked during heating and cooling, and integrated integral freeze and deviation dead zone mechanisms are synchronously implemented to suppress control oscillations. Flow rate calculation is supported by a multi-medium normalization compensation logic based on the reference power ratio method. The static reference power of clean water is used as a benchmark to compensate for the difference in thermal conductivity between the oil and water phases. The static reference power is used to achieve full-temperature-range temperature compensation through a quadratic polynomial.
[0040] The entire flow measurement system adopts a hierarchical computing architecture. The downhole MCU only performs integer PID closed-loop control, raw data acquisition, and buffering; floating-point operations such as reference power temperature compensation, medium normalization calculation, and segmented flow velocity fitting are all performed on the surface host computer. This design can effectively suppress downhole temperature drift and fluid condition disturbances, stabilize the flow detection reference, and reduce the computational load on the downhole main control unit.
[0041] The conductivity detection unit adopts a multi-frequency time-division excitation architecture, consisting of a sinusoidal excitation module, measuring electrodes, a precision reference resistor, and two peak detection circuits. It utilizes a shared 24-bit AD sampling unit for analog-to-digital conversion. The sinusoidal excitation module outputs multiple sets of time-division sinusoidal signals at integer multiples of frequency, which are applied to the measurement circuit connected in series between the reference resistor and the measuring electrodes. The two peak detection circuits synchronously acquire the peak voltages across the reference resistor and electrodes, and synchronously discharge and reset after sampling at a single frequency point. The single main MCU calculates the equivalent impedance modulus at each frequency point using the peak voltage ratio method. The overall architecture employs a downhole-to-surface layered computational structure: the downhole system only performs excitation control, peak acquisition, and impedance modulus preprocessing; the host computer uses a progressive adaptive matching mechanism that prioritizes the RC model and gradually enables the RLC model, combined with three-frequency consistency redundancy verification and physical validity screening, to finally calculate the conductivity parameters. Phase detection and FFT calculations are not required throughout the process.
[0042] The pressure detection unit and the electromagnetic induction coupling detection unit respectively complete the acquisition and shaping of downhole pressure signals and tubing coupling signals; the analog signals output by each detection unit are uniformly connected to a shared 24-bit AD sampling module to complete analog-to-digital conversion, centralized sampling, and unified timing to ensure the synchronization of multi-parameter acquisition.
[0043] The data storage module adopts an EEPROM partitioned storage design, dividing the data into independent parameter storage areas and measurement data storage areas to avoid mixing different types of data and improve data read / write stability and management standardization.
[0044] The dual-link communication module includes a self-synchronizing error-proof 485 serial communication unit and a dual-frequency acoustic tubing communication unit. The two links are independent of each other and can be adapted to different downhole data transmission scenarios.
[0045] This invention integrates three switchable working modes, comprehensively covering various downhole monitoring conditions: Mode 1: Downhole timed measurement and storage mode. The equipment autonomously samples at regular intervals downhole, writes multi-parameter measurement data into the local EEPROM in real time, and retrieves it to the surface for data playback after the operation is completed.
[0046] Mode 2: 485 Online Real-Time Measurement Mode. This mode receives commands from the host computer via the 485 bus, collects and transmits multi-parameter data from the well in real time, and is suitable for on-site online commissioning and real-time monitoring scenarios.
[0047] Mode 3: Long-term downhole acoustic uploading mode. The equipment relies on batteries to operate continuously downhole, periodically collecting and buffering monitoring data, and remotely uploading the data through dual-frequency acoustic encoding of the pumping tubing string.
[0048] The RS485 serial communication employs a simplified self-synchronizing error-proof serial communication mechanism. It is a pure data link layer protocol, not bound to physical layer parameters or application layer business logic. The protocol frame structure consists of a frame header, instruction code, data field, optional check byte, and identifier byte in a fixed order. The optional check byte has a length of 0 or 1 byte and can be enabled or disabled as needed. The identifier byte uses a grouping design of 1 byte for every 7 data bytes, with the number adaptively adjusted according to the data field length. It is used to mark the conflict state between data and the frame header, and the idle bits can be customized. The protocol achieves full-byte transmission without restricted areas (0-255 bytes) through an offset modulo numerical conflict correction mechanism, without additional escaping overhead. The highest-order bits of the instruction code, identifier byte, and optional check byte (in the enabled state) are electrically opposite to the highest-order bits of the frame header, avoiding frame synchronization misjudgments at the bit level. A built-in link layer self-synchronizing and self-healing mechanism automatically discards invalid data and re-listens to the frame header in case of an anomaly, without upper-layer intervention. A supporting directional field isolation check system performs cumulative check only on the instruction code and data field, balancing high-speed and high-reliability transmission requirements.
[0049] The dual-frequency acoustic communication uses a steel tubing string as the transmission medium and employs a high-low frequency grouped decimal encoding: a low-frequency group and a high-frequency group containing multiple frequency points are set up respectively. One frequency point is selected from each group and combined in pairs to map and transmit information. Some combinations correspond to decimal numbers 0-9, while the rest are used as frame headers, commands, and other control identifiers. Fixed-duration symbol window transmission is used, eliminating the need for an independent synchronization clock. The receiving end identifies frequency point combinations through spectrum analysis to complete decoding. Interference can be determined by identifying abnormal frequencies outside the frequency point pool. It is equipped with a sine wave excitation and timed wake-up low-power strategy, supporting wireless communication between downhole and surface. The transmission efficiency, verification convenience, and anti-interference are all superior to traditional binary encoding. The communication frame structure includes a frame header identifier, a data field, and a check field. An error retransmission mechanism is provided to improve link reliability under strong interference. The mapping relationship between frequency point combinations, digital codes, and control commands can be configured as needed. The hardware is equipped with a piezoelectric transducer and impedance matching circuit to complete electroacoustic conversion, adapting to the installation requirements of downhole working conditions.
[0050] A method for synchronous measurement of multiple parameters and dual-link communication in downhole reservoirs includes the following steps: S1. The equipment is powered on and initialized, and hardware self-test, system and calibration parameter loading and configuration are performed sequentially, and the current working mode is determined; S2. A single main MCU runs the main loop with a fixed cycle of 0.4 seconds, and coordinates the synchronous acquisition of multiple parameters such as temperature, flow rate, pressure, conductivity, and coupling signal; at the same time, a dual-frequency sinusoidal excitation signal is output in coordination through an interrupt mechanism, and the conductivity signal is synchronously acquired; S3. The conductivity is excited by multi-frequency time division, and the peak voltage at each frequency is acquired by a precision rectifier circuit, without the need for fast Fourier transform spectrum analysis and phase detection. High-speed analog-to-digital conversion is completed in combination with a 24-bit AD module; the four-wire PT100 unit relies on a parallel multiplexing architecture for heating and temperature measurement, first matching the segmented target temperature difference according to the ambient temperature, and then using a PID controller with different parameters for heating and cooling. The closed-loop control adjusts the heating current and simultaneously collects raw data of heating power and two temperature channels. The raw data is preprocessed at the integer level and then cached locally. The floating-point flow rate calculation is completed by the ground host computer based on the reference power ratio method and piecewise polynomial fitting, achieving accurate detection of flow rate and temperature. S4. The collected multi-parameter data is written to EEPROM for local storage according to the partitioning rules, or transmitted to the outside in real time via the 485 link, or cached and then remotely uploaded via dual-frequency acoustic wave encoding modulation. S5. During equipment operation, if communication abnormalities, data disorder, or other faults are detected, the communication link automatically performs self-healing reset to ensure the continuous operation of downhole monitoring.
[0051] The overall mechanical structure, hardware electrical architecture, component composition, and working principle of the present invention will be described in detail below with reference to Figures 1 to 4. The downhole reservoir multi-parameter synchronous measurement and dual-link communication device of the present invention adopts an integrated cylindrical pressure-resistant sealed cavity structure, adaptable to standard oil wellbore dimensions, and is made of high-strength stainless steel with a pressure resistance rating of ≥35MPa, meeting the long-term working requirements of conventional oil reservoirs. A high-temperature insulated bottle assembly can be optionally added to further expand the device's applicable environmental temperature range, adapting to the measurement needs of deep, high-temperature oil reservoirs. The device adopts a vertically layered layout of "top power supply - middle measurement and control - bottom sensing," resulting in a compact structure and high integration, maximizing the use of limited downhole cavity space.
[0052] As shown in Figure 1, the structure and function of each component of the device from top to bottom are described below: Battery module: Installed at the top of the cavity, it adopts a high-temperature resistant lithium thionyl chloride battery pack to provide a stable power supply for all electronic components and sensors of the whole machine. The battery capacity can support the device to operate continuously for ≥6 months in the long-term downhole residence mode; when used with the high-temperature insulated bottle assembly, it can meet the long-term power supply needs of deep high-temperature oil reservoirs.
[0053] Upper magnet: A ring structure, coaxially mounted below the battery module, working with the lower magnet to form a stable axial magnetic field, providing a basic magnetic field environment for coupling testing.
[0054] Coil: A ring-shaped induction coil, coaxially mounted between the upper and lower magnets, is wound with high-temperature resistant enameled copper wire. It achieves non-contact, accurate identification and timestamp marking of the position of the pipe coupling by detecting the magnetic field distortion caused by the passage of the pipe coupling.
[0055] Lower magnet: Ring structure, coaxially and symmetrically installed with the upper magnet to form a closed magnetic circuit, improving the sensitivity and anti-interference ability of the coupling detection.
[0056] Measurement and control system: Installed below the coupling detection component, it is the core control unit of the device. It integrates a single main MCU main control circuit, an 8-channel 24-bit AD sampling circuit, a signal conditioning circuit, a data storage circuit, and a dual-link communication interface circuit, and coordinates the tasks of synchronous acquisition of multiple parameters downhole, data processing, local storage, and dual-link communication transmission.
[0057] Chamber: The main pressure-resistant outer shell of the device is made of seamless stainless steel tubing and houses all electronic components and sensor assemblies, providing high-pressure sealing protection.
[0058] Heat-absorbing material: Filled in the cavities on the left and right sides of the middle of the cavity, it is made of high specific heat capacity and high temperature resistant insulation material. It is used to absorb heat from the underground environment, delay the temperature rise of internal electronic components, and ensure the stable operation of the measurement and control system in high temperature environment. It works in synergy with the high temperature insulation bottle assembly to further improve the thermal management capability of the device.
[0059] Lead wires: Multi-strand high-temperature resistant shielded wires are laid in the central area of the cavity to connect the top measurement and control system and various sensors at the bottom to realize the transmission of signals and power.
[0060] Pressure sensor: Installed in the lower middle part of the cavity, it connects to the downhole fluid through a pressure-guided capillary tube to detect the fluid pressure signal in the wellbore in real time.
[0061] Adapter: Installed in series in the middle section of the lead wire to achieve a reliable electrical connection between the upper and lower lead wires, facilitating modular assembly and maintenance of the device.
[0062] Conductivity measuring electrode: Installed at the bottom left of the cavity, made of gold-plated titanium alloy, it is in direct contact with the downhole fluid and, together with the multi-frequency sinusoidal excitation signal output by the measurement and control system, completes the fluid conductivity measurement.
[0063] Heating / temperature measurement multiplex probe: Installed at the second position from the left at the bottom of the cavity, it internally encapsulates a four-wire PT100 platinum resistance thermometer on the flow side, and the probe contact end with the fluid is filled with thermally conductive adhesive to achieve the multiplexing of heating and temperature measurement functions: on the one hand, it acts as a heating element, generating a temperature difference through current heating; on the other hand, it acts as a temperature measuring element, detecting the temperature difference between the probe and the ambient temperature in real time, providing basic data for flow calculation.
[0064] Ambient temperature measurement probe: Installed at the second position from the right at the bottom of the cavity, it is internally encapsulated with a four-wire PT100 platinum resistance thermometer for the environment side. The probe is in direct contact with the downhole fluid to measure the actual ambient temperature of the fluid, providing a reference temperature for flow calculation, and enabling independent detection of downhole ambient temperature parameters.
[0065] Pressure guiding capillary tubes: There are two in total, symmetrically installed at the bottom right of the cavity. The upper end is connected to the pressure sensor, and the lower end is directly connected to the downhole fluid, transmitting the fluid pressure to the pressure sensor to achieve isolated transmission of the pressure signal.
[0066] Sealing copper gasket: Installed between each bottom sensor and the end face of the cavity, using a cold-press sealing process to achieve a reliable seal under high pressure and prevent downhole fluid from entering the device.
[0067] Thermally conductive adhesive: Fills the space between the heating-temperature measurement multiplex probe, the ambient temperature measurement probe, and the internal four-wire PT100 to ensure good heat conduction and improve temperature measurement accuracy and response speed.
[0068] Core structural design features: The core structural design of this invention has the following advantages: Dual PT100 differential flow measurement structure: It adopts an independent heating-temperature measurement multiplexing probe and an ambient temperature measurement probe, each encapsulated with a four-wire PT100 platinum resistance thermometer. The fluid flow rate is calculated by differentially measuring the temperature difference between the two probes, effectively eliminating the influence of downhole ambient temperature fluctuations on the measurement results and significantly improving the accuracy of flow measurement.
[0069] Layered insulation and thermal management design: The middle of the cavity is filled with a high specific heat capacity heat-absorbing material to isolate the top monitoring and control system from the bottom high-temperature sensing area, delaying the conduction of heat from the downhole environment to the internal electronic components and ensuring the long-term stable operation of the monitoring and control system in a high-temperature environment.
[0070] Integrated sensor design: The conductivity, flow, temperature and pressure sensors are all integrated into the bottom end face of the cavity (the coupling detection is inside the cavity), resulting in a compact structure with no exposed moving parts; at the same time, the pressure sensor is installed inside the pressure guide capillary, which further improves the reliability and miniaturization of the device.
[0071] System hardware electrical architecture (corresponding to Figure 4); The overall hardware system architecture of this invention is shown in Figure 4. The device uses a single main MCU as the sole control core and selects an industrial-grade 8-bit microcontroller that integrates an 8-channel 24-bit Σ-Δ AD sampling unit, a dual-channel DAC output unit, a UART communication interface, and two independent hardware timers. The overall hardware is divided into six functional areas: a battery power supply module, a single main MCU control unit, a multi-parameter detection module, a dual-link communication module, a data storage module, and an alarm indication module. The battery module mentioned in Section 5.1 above is the physical carrier of the battery power supply module, providing a regulated power supply adapted to downhole working conditions for all functional modules of the system, meeting the power supply requirements of the device during high-temperature and long-term downhole operation.
[0072] The single-master MCU integrates two independent hardware timer units, a UART unit, two DAC output units, an 8-channel 24-bit AD sampling unit, and an interrupt unit. All on-chip resources are uniformly scheduled and managed by the main control kernel. The functions and connections of each unit are as follows: 1) Timer Unit 1: Fixed 10ms overflow interrupt period, serving as the global system time base, sending timing interrupt signals only to the single-master MCU kernel, used for global timing, data storage timing triggering, and system timeout detection; 2) Timer Unit 2: The overflow frequency can be dynamically configured by the main program according to actual working requirements, serving as a dedicated time base for high-precision waveform generation. Its sole function is to drive the two DAC output units to generate dual-frequency sine excitation signals; 3) UART Unit: Serving as the underlying transceiver interface for wired communication, it bidirectionally electricalally interfaces with the self-synchronizing error-proof 485 communication unit inside the dual-link communication module to achieve half-duplex data transmission and reception; 4) DAC Output Unit 1 (Dual-frequency sine excitation - 5) Conductivity Measurement: Controlled by timer unit 2, it outputs the multi-frequency sinusoidal excitation signal required for conductivity measurement to the conductivity detection unit in a time-division manner; 6) DAC Output Unit 2 (Dual-frequency sinusoidal excitation - tubing acoustic communication): Controlled by timer unit 2, it outputs the dual-frequency sinusoidal carrier signal required for tubing communication to the dual-frequency acoustic tubing communication unit; 7) 8-channel 24-bit AD sampling unit: The start and stop are directly controlled by the main program. All analog measurement signals output by the multi-parameter detection module are connected to this unit. The sampling and AD conversion processes of the three parameters of PT100—temperature, flow rate, pressure, and conductivity—are all executed synchronously in the main program; 8) Interrupt unit: It is only responsible for receiving asynchronous trigger signals, including UART receive interrupt and electromagnetic induction coupling detection interrupt, and does not participate in any measurement timing trigger control.
[0073] The multi-parameter detection module consists of four parts: a four-wire PT100 integrated temperature and flow detection unit, a pressure detection unit, a conductivity detection unit, and an electromagnetic induction coupling detection unit. The analog measurement signals output by all units are aggregated and connected to the MCU's built-in 8-channel 24-bit AD sampling unit. Four-wire PT100 integrated temperature and flow detection unit: Corresponding to the heating-temperature measurement multiplexing probe and ambient temperature measurement probe described in Section 5.1, it has two built-in independent four-wire PT100 platinum resistance thermometers and adopts a digitally controlled variable constant current heating scheme. Based on the parallel multiplexing architecture of four-wire platinum resistance heating and temperature measurement and the dual PT100 temperature difference differential principle, it achieves constant temperature difference flow measurement through a periodic command-based hierarchical control architecture and PID closed-loop regulation with varying parameters for temperature rise and fall. The heating drive circuit consists of a built-in DAC module, operational amplifier, power MOSFET, and low-end current sensing resistor forming a negative feedback closed loop: the DAC output voltage is connected to the non-inverting input of the operational amplifier, the operational amplifier output is connected to the gate of the MOSFET through a current-limiting resistor, the source of the MOSFET is grounded through the current sensing resistor, and the upper end of the current sensing resistor is connected to the inverting input of the operational amplifier to form hardware negative feedback; under closed-loop steady-state conditions, the heating current is only supplied by the DAC. The output voltage is determined by the current sensing resistor value and is unaffected by platinum resistance temperature drift, lead parasitic resistance, and power supply fluctuations. The output is a continuous DC signal, free from switching chopper ripple and electromagnetic interference. The temperature sampling circuit adopts a high-impedance differential acquisition architecture, with an instrumentation amplifier and a single-stage RC low-pass filter unit at the front end, directly acquiring the voltage across the platinum resistance core. Due to the extremely high input impedance and near-zero operating current of the sampling branch, the lead parasitic resistance does not generate a measurement voltage drop, eliminating lead resistance temperature measurement errors from the hardware structure level. The environmental reference four-wire PT100 probe is equipped with an independent precision constant current excitation unit and differential acquisition branch, using microampere-level excitation current to avoid probe self-heating, providing a stable environmental temperature reference for flow measurement.
[0074] 2. Pressure detection unit: Corresponding to the pressure sensor and pressure guiding capillary described in Section 5.1, the unit collects the hydrostatic pressure of the wellbore fluid through the pressure guiding capillary, and sends the preprocessed raw pressure signal to the AD sampling unit.
[0075] 3. Conductivity Detection Unit: Corresponding to the conductivity measurement electrodes described in Section 5.1, a multi-frequency redundant adaptive measurement scheme is adopted. Hardware-wise, a measurement circuit is formed by connecting a precision reference resistor and the measurement electrode in series. The MCU's built-in DAC outputs multiple sets of sinusoidal excitations at integer multiple frequencies in a time-division manner. Two independent peak-hold detector circuits are configured to synchronously acquire two peak voltages. The detector outputs are connected to a shared 24-bit AD sampling unit, synchronously completing analog-to-digital conversion with other parameters. The computation adopts a downhole-surface layered architecture: the downhole MCU only performs excitation timing control, peak acquisition, and simplified impedance magnitude conversion; the host computer prioritizes using the RC model to perform pairwise consistency checks of the three frequencies. When the deviation is below a preset threshold, the equivalent resistance result is output; if the check fails, the RLC model closed-loop analysis is initiated. After sign, interval, and self-consistency triple physical validity checks, a reliable solution is output, and the conductivity parameter is finally calculated. This scheme requires no phase detection or FFT calculation throughout the process, highly reusing system resources and adapting to low computing power and small space conditions in downhole environments.
[0076] 4. Electromagnetic induction coupling detection unit: Corresponding to the upper magnet, coil and lower magnet assembly described in Section 5.1, it picks up the oil pipe coupling position pulse signal based on the magnetic field distortion principle of magnet-coil, directly triggers the MCU interrupt unit, and completes the pipe string position marking and timestamp storage.
[0077] Before leaving the factory, the equipment is calibrated using clean water medium through three-layer circulation, traversing multiple temperature and flow rate levels. After determining the steady state through sliding standard deviation, a complete set of compensation coefficients is fitted and written into EEPROM. On-site, it supports self-calibration by shutting down the well and allowing the current static reference power of the medium to be measured in a static fluid state, updating the stored parameters to compensate for zero-point drift caused by probe scaling and device aging.
[0078] The dual-link communication module consists of two independent transmission links: a self-synchronizing error-proof 485 communication unit and a dual-frequency acoustic tubing communication unit, enabling dual backup transmission of downhole data. 1) Self-synchronizing error-proof 485 communication unit: bidirectional communication with the MCU's internal UART unit, equipped with a self-synchronizing error-proof link layer communication protocol, adapted to long-distance 485 half-duplex strong interference transmission scenarios underground. The protocol frame structure is arranged in a fixed order: a 1-byte custom frame header for synchronization and positioning; a 1-byte instruction code carrying basic link layer instructions, with its most significant bit being different from the most significant bit of the frame header; a variable-length data field supporting 0-byte empty data frames, which can embed address fields to achieve multi-machine networking without changing the core protocol rules; optional check bytes with a length of 0 or 1 byte, which, when enabled, only performs cumulative check on the instruction code and data field, and its most significant bit is different from the most significant bit of the frame header; the identifier byte adopts a grouping rule of 1 per 7 data bytes, with the number calculated according to the formula n = ⌈L / 7⌉ (L is the data field length, ⌈⌉ is rounded up), used to mark the conflict status between the data and the frame header in the corresponding group, and the idle bits can be extended to link layer functions such as alarms and priorities, and the most significant bit of all identifier bytes is different from the most significant bit of the frame header. The protocol incorporates a built-in numerical conflict correction mechanism: With a frame header value of H and a correction amount M that is a configurable integer from 1 to 255, when data from the same source appears in the data field with the same value as the frame header, the sending end corrects in the forward direction using X' = (X+M) mod 256, and the receiving end restores it in the reverse direction using X = (X'-M) mod 256, ensuring that the corrected value is not equal to the frame header value, achieving zero-overhead, full-byte, no-forbidden-area transmission. The protocol possesses link-layer self-synchronization and self-healing capabilities: when any anomaly occurs during parsing, such as frame header errors, high-order logical conflicts, checksum discrepancies, frame breaks, or garbled characters, invalid data is immediately discarded and the protocol automatically returns to frame header listening without upper-layer reset; link recovery time is less than 1ms. The protocol adopts a binary native direct transmission mode, eliminating ASCII translation overhead and ensuring stable transmission timing.
[0079] 2) Dual-frequency acoustic tubing communication unit: Receives sinusoidal carrier signals output by the MCU, uses steel tubing as the transmission medium, adopts high and low frequency grouped decimal encoding, supports fixed-duration symbol transmission and timed wake-up low-power operation, and realizes wireless remote data upload between downhole and surface.
[0080] 1. Data storage module: Utilizing an EEPROM partitioned storage architecture, this module has two independent signal links connected to the main MCU. ① Bidirectional data bus: A single main MCU can read the factory calibration coefficients and equipment configuration parameters stored in the EEPROM via this bus, and can also write real-time downhole measurement data to the memory; ② Timing trigger signal: the No. 1 timer unit generates an overflow interrupt every 10 ms and outputs a timing signal to the single-master MCU. After the software cumulative count reaches a preset threshold, the MCU automatically starts a periodic data writing operation; the EEPROM storage space is divided into a calibration parameter storage partition and a real-time measurement data storage partition, which are respectively used for storing the factory calibration coefficients of the whole machine and various actual measurement parameters collected at the downhole site. The calibration parameter storage partition stores pressure segmented calibration coefficients, flow reference power temperature compensation coefficients, and fitting coefficients for each flow velocity segment at the same time. All coefficients are stored in integer format according to a preset scaling ratio, which adapts to the integer operation architecture of 8-bit MCUs used in downhole applications.
[0081] Alarm indication module: an auxiliary functional unit matched with the present device, which is controlled by the single-master MCU; the module triggers audible and visual alarm prompts according to equipment working abnormal states such as equipment undervoltage, communication link abnormality, and AD sampling failure. This module adopts the existing mature general circuit design, and does not belong to the technically innovative content improved by the present invention.
[0082] As shown in Figure 2, the present invention adopts a single-master MCU architecture to implement downhole multi-parameter measurement and communication functions. The core design concept is "the main program serially processes complex services, and interrupts only perform extremely simple operations", which completely avoids the communication failure problem of the traditional multi-MCU architecture and the risk of deadlock caused by interrupt nesting in the single-MCU architecture.
[0083] The main loop adopts an infinite loop architecture, the actually measured maximum operation period does not exceed 400 milliseconds, no additional independent software timeout judgment program is configured, and full-task timing constraints are realized by relying on the fixed main loop period. A complete main loop sequentially executes the following tasks: Poll all interrupt flags to determine whether an interrupt event occurs; Execute centralized AD sampling, and synchronously collect PT100 temperature, flow signals, pressure signals and conductivity signals; Perform digital filtering processing on the collected raw data, and complete engineering unit conversion; Run the PT100 constant temperature difference PID closed-loop control algorithm, update the DAC output value to adjust the heating current, complete constant temperature difference adjustment, and calculate the real-time flow based on the thermal principle. Only integer-type PID operations and raw data packaging and caching are completed in the main loop, and floating-point operations such as medium normalization and flow velocity polynomial fitting are not executed. All the above operations are completed after the data is uploaded to the ground upper computer, ensuring the stable operation of the main loop with a fixed period of 0.4 seconds.
[0084] Query the interrupt flag of timer 1, and when the flag is set, write the calibrated multi-parameter data into the designated partition of EEPROM; Complete dual-link data transmission and reception processing of 485 wired communication and pipeline acoustic wireless communication.
[0085] All interrupt service routines perform only flag setting or single-byte data buffering operations, without any complex calculations or business logic, ensuring an interrupt response time of less than 10μs. Timer 1 interrupt: Triggered every 10ms, only sets the EEPROM storage flag, does not perform data write operation; Timer 2 Interrupt: Runs continuously without interruption throughout the entire time period, with an output frequency that is adjustable by software. It is used in conjunction with a DAC to generate multi-frequency excitation signals for conductivity measurement in a time-division manner. Timer 3 interrupt: The output frequency is adjustable by software and can be used with a DAC to generate a dual-frequency carrier signal for tubing acoustic communication. UART receive interrupt: Asynchronous random trigger, only completes the reception of a single byte of data and writes it to the circular buffer; Interruption detection of coupling: triggered by an external hardware pulse, only the trigger time is recorded for subsequent depth correction.
[0086] This timing design achieves high-speed quasi-synchronous measurement of multiple parameters on a single 8-bit MCU by migrating all computationally intensive tasks and business logic to the main program for serial execution, while significantly improving the system's operational stability in downhole environments with temperatures above 125°C.
[0087] Referring to the working state switching flowchart in Figure 3, this invention relies on the single-master control MCU software state machine logic to set three independent working conditions: downhole timed storage and playback mode, oil tubing dual-frequency acoustic periodic data transmission mode, and 485 bus real-time communication mode. The working condition switching is achieved by the host computer issuing serial commands one by one via the 485 bus. The three modes have clear division of labor: the downhole timed storage and playback mode is suitable for centralized sampling and inspection of downhole reservoir parameters; the oil tubing dual-frequency acoustic periodic data transmission mode is suitable for long-term downhole residence timed monitoring; and the 485 bus real-time communication mode is suitable for factory calibration, ground whole machine debugging, and real-time data detection, fully covering the application needs of the entire life cycle of the device.
[0088] 1. Downhole timed storage and playback mode (default operating condition upon power-on); This mode is the default operating mode after the instrument passes self-test, and is designed for scenarios involving centralized sampling of downhole reservoir parameters. The MCU completes the synchronous acquisition, filtering, and engineering quantity conversion of multiple parameters such as pressure, ambient temperature, flow rate, and conductivity according to the preset sampling cycle, and writes the valid measurement data into the corresponding storage partition of the on-chip EEPROM according to the set cycle. The whole machine adopts a low-power operation strategy, normally only polling the communication link and listening for instructions issued by the host computer, and continuously looping the acquisition and storage tasks when there is no instruction input.
[0089] 2. Dual-frequency acoustic periodic data transmission mode for the oil tubing; Building upon the existing functions of timed data acquisition and local data storage, a dual-frequency acoustic wireless transmission function for tubing has been added to adapt to long-term downhole monitoring conditions. Because the instrument is permanently deployed in the wellbore under these conditions, a thermos cannot be installed; therefore, this operating mode is only suitable for low-temperature wellbores. To extend the battery life and meet the needs of long-term unattended monitoring, the device employs an intermittent operating mechanism, performing parameter acquisition only once or twice per day according to the preset configuration, with the device entering a sleep / power-saving state for the vast majority of the remaining time. When the preset transmission cycle is reached, the DAC unit generates a dual-frequency carrier signal, which is transmitted back to the storage location along with equipment status information via the dual-frequency acoustic tubing communication unit using the steel tubing wall as the transmission medium. The data transmission task is implemented through a main loop time-sharing scheduling mechanism, ensuring no interruption of the regular multi-parameter sampling process. After each transmission, the device resumes its intermittent acquisition and sleep logic.
[0090] 485 bus real-time communication mode; It is mainly used in factory calibration, ground-based whole-machine debugging, and real-time data detection scenarios. The main control MCU prioritizes responding to 485 bus interaction commands, supports online modification of equipment operating parameters, updating segment calibration coefficients, real-time retrieval of instantaneous AD sampling data, and batch reading of historical data stored in EEPROM. It can also flexibly adjust the sampling interval as needed to adapt to the diverse control requirements of calibration and field debugging.
[0091] After powering on, the instrument initiates a hardware self-test, which includes power supply voltage detection, MCU peripheral resource verification, continuity testing of each sensor circuit, and EEPROM read / write reliability verification. If the self-test fails, the instrument illuminates the fault indicator light and continuously performs the self-test in a loop, with no limit on the number of retries. After the self-test passes, the system automatically switches to downhole timed storage and playback mode and starts routine multi-parameter acquisition.
[0092] The host computer sends serial commands one by one via the 485 link, with only one valid command sent at a time. The main controller completes two levels of logical judgment—switching command recognition and ending command recognition—in each main cycle. For details, please refer to Appendix 3.
[0093] ① Downhole timed storage and playback mode: Parse the command. If it is a command to switch to 485 bus real-time communication, then jump to 485 bus real-time communication mode; if it is not a 485 switching command, then jump to the dual-frequency acoustic periodic data transmission mode of the sucker tubing string. ② Dual-frequency acoustic periodic data transmission mode for oil tubing: parsing commands, if a command to switch back to storage mode is received, it will jump to downhole timed storage and playback mode; other switching commands will jump to 485 bus real-time communication mode. ③ 485 bus real-time communication mode: parsing commands, if a switch-back to storage command is received, it switches to downhole timed storage and playback mode; other valid switching commands switch to the dual-frequency acoustic periodic data transmission mode of the sucker tubing string.
[0094] 2. If there is no valid switching instruction (determined as N), the system proceeds to the end instruction judgment stage and does not execute mode jump.
[0095] ① Upon receiving the termination command (judgment Y): the device directly terminates all running programs without saving cached data or turning off the power of various peripherals; ② No termination instruction received (Decision N): The program returns to the starting node of the current mode, and the instrument continues to perform the original acquisition, storage, or communication tasks.
[0096] 1. The serial transmission and reception of instructions are matched with the characteristics of the 485 half-duplex bus. The three working conditions are smoothly switched without reset through hierarchical logic. The switching process retains the underlying hardware configuration and avoids the impact damage to the device caused by frequent power-on and power-off. 2. The three operating modes are clearly divided: the storage mode is used for centralized sampling and testing of downhole parameters, the acoustic data transmission mode enables long-term downhole monitoring of low-temperature wells, and the 485 real-time mode is responsible for factory calibration and real-time on-site detection. The operating modes can be switched on-site without modifying the hardware or re-flashing the firmware, which significantly reduces the cost of on-site operations in the oilfield. 3. The entire state machine is implemented through software programming and does not contain any mechanical switching components. It can adapt to the harsh wellbore environment with high temperature, high pressure and high humidity, and improve the long-term reliability of the instrument in the well.
Claims
1. A downhole reservoir multi-parameter synchronous measurement and dual-link communication device, comprising a battery-powered module, a multi-parameter detection unit, a 24-bit AD sampling module, a data storage module, and a dual-link communication module, characterized in that: A single-master MCU main control module is set up; the single-master MCU adopts a working architecture with a 0.4-second fixed cycle main loop and multiple interrupt collaborative scheduling; the multi-parameter detection unit is an integrated four-wire PT100 temperature and flow integrated detection unit, pressure detection unit, conductivity detection unit and electromagnetic induction coupling detection unit; the four-wire PT100 temperature and flow integrated detection unit integrates heating and temperature measurement parallel multiplexing functions, and adopts a constant temperature difference control architecture with hardware simulated constant current inner loop and single-level digital temperature difference outer loop; the conductivity detection unit can output software adjustable multi-frequency excitation signal and complete conductivity parameter acquisition with peak detection method; the analog output signals of each detection unit are uniformly connected to the 24-bit AD sampling module to achieve centralized synchronous analog-to-digital conversion; the data storage module is an EEPROM partitioned storage structure, divided into independent parameter storage partition and measurement data storage partition; the dual-link communication module includes a 485 wired communication unit and a dual-frequency acoustic wireless communication unit; the device is configured with three interchangeable working modes, namely timed measurement and storage mode, 485 online real-time measurement mode and acoustic long-term residence and upload mode.
2. The apparatus according to claim 1, characterized in that: The electromagnetic induction coupling detection unit consists of an upper magnet, a ring induction coil, and a lower magnet forming a closed magnetic circuit. It identifies the oil pipe coupling by relying on magnetic field distortion and marks the timestamp. The MCU is configured with four types of interrupts. The interrupts are only used for flag setting and a small amount of buffering. Complex calculations, storage, and communication are all executed serially in the main loop in 0.4s.
3. The apparatus according to claim 1, characterized in that: The four-wire PT100 unit adopts a dual-probe four-wire platinum resistance structure. Two leads carry constant current heating current, and the other two synchronously acquire voltage signals. There is no time-sharing switching during the entire heating and temperature measurement process. The constant temperature difference control adopts an ambient temperature segmented adaptive target temperature difference strategy, with a temperature hysteresis threshold to suppress gear jumps. The control algorithm adopts a PID with different parameters for heating and cooling, and synchronously sets integral freeze and deviation dead zone anti-oscillation mechanisms. The flow rate calculation employs a reference power ratio method to achieve multi-medium normalization compensation, while the static reference power achieves full-temperature-range temperature compensation through a quadratic polynomial. The entire flow rate measurement system adopts a hierarchical computing architecture, with the downhole MCU performing only integer closed-loop control and raw data acquisition, while floating-point calculations for temperature compensation, medium normalization, and flow velocity fitting are performed by the surface-based host computer. The conductivity unit consists of a measuring electrode, an excitation circuit, and a peak rectification sampling circuit. Multi-frequency excitation combined with peak sampling measures conductivity, and dual-frequency integer multiples suppress temperature drift and frequency deviation, eliminating the need for FFT demodulation.
4. The apparatus according to claim 1, characterized in that: The EEPROM is divided into a parameter area and a measurement data area, which are isolated and independently read and written. The parameter area stores calibration coefficients and configurations. The 485 unit is responsible for real-time configuration and online transmission, and the dual-frequency acoustic wave unit is used for long-distance long-term residence and transmission. The two links are independently enabled as needed.
5. The apparatus according to claim 1, characterized in that: The three working modes are automatically determined upon power-on, and can be dynamically switched by instructions from the host computer during operation. The whole machine has the ability to automatically reset and heal itself in case of software and hardware abnormalities.
6. The apparatus according to claim 1, characterized in that: Pressure detection uses three-segment linear calibration: 0-10MPa, 10-20MPa, and 20-35MPa. The boundary points are shared, and each segment is configured with independent K and B coefficients. The calibration coefficients K and B are amplified by 1000 times and stored as integers in EEPROM. The original AD data is not stored on the ground. The MCU reads the coefficients and converts them into physical quantities.
7. A method for simultaneous multi-parameter measurement and dual-link communication in downhole reservoirs, characterized in that, The device described in claim 1 comprises the following steps: S1. After powering on, the device completes hardware self-test and system parameter loading, reads preset configuration parameters, and determines the current working mode; S2. A single main MCU runs the main loop at a fixed cycle of 0.4 seconds, coordinating with multiple interrupts to output excitation signals, centrally and synchronously collect temperature, pressure, conductivity, and coupling position signals, and calculate fluid flow parameters; S3. The raw sampled data is filtered and converted using engineering methods, and the fluid flow rate is calculated by combining dual PT100 temperature difference with constant temperature difference control logic. Fluid conductivity parameters are obtained by multi-frequency excitation peak detection; S4. According to the current working mode, local timed storage, 485 real-time transmission, or acoustic remote buffer upload operations are executed accordingly; S5. During operation, the system and link status are monitored in real time. When an abnormality occurs, invalid data is automatically discarded and self-healing reset is performed to maintain continuous downhole monitoring operations.
8. The method according to claim 7, characterized in that: If a power-on self-test fails, the system will automatically restart; if the self-test passes, the calibration and configuration parameters will be loaded. All interrupts only complete flag and signal output, and all data processing, storage, and communication tasks run serially in the main loop to ensure cycle stability; local data storage in timed mode, instant response and uploading in 485 mode, and low-power buffered timed remote transmission in acoustic wave mode; The three types of interrupts—timer, excitation waveform, and coupling capture—provide the reference for storing timing, dual-frequency waveform, and position pulse acquisition, respectively.
9. The method according to claim 7, characterized in that: When communication, sampling, or hardware anomalies occur, the current task is terminated, errors are cleared, and the system falls back to the mode determination to achieve unmanned self-healing. The pressure algorithm adopts the segmented calibration and coefficient scaling restoration scheme, and the conductivity adopts frequency doubling + peak sampling, abandoning FFT operation. The flow measurement adopts the reference power ratio method to complete the medium normalization, and combines segmented adaptive temperature difference and temperature rise and fall parameter PID to complete constant temperature difference control. After the raw data is uploaded, the floating point flow rate is calculated by the ground.