A method for reliable communication using pilot square waves
By acquiring background reference features using pilot square waves and adaptively dividing windows to extract key current features, the problem of difficulty in identifying uplink feedback current caused by dynamic changes in line parameters in the electronic detonator two-bus system is solved, achieving reliable communication with high precision and low error rate.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-02-03
- Publication Date
- 2026-04-07
AI Technical Summary
In the electronic detonator two-bus system, dynamic changes in line parameters, significant waveform distortion, and fluctuations in background current make it difficult to achieve high accuracy and low error rate in the uplink feedback current identification. Existing communication solutions are not reliable enough in complex networking environments.
By sending pilot square waves before uplink communication, bus current sampling data is obtained to form background reference features. The sampling window is adaptively divided and key current features are extracted. Adaptive decision rules are selected in combination with line status categories to achieve real-time identification of uplink feedback current.
In complex networking environments, the uplink identification accuracy has been improved to the 500μA level, reducing false positives and false negatives, and improving the networking communication reliability of the electronic detonator system.
Smart Images

Figure CN121644287B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of two-bus communication technology for electronic detonators, specifically a method for achieving reliable communication using pilot square waves. Background Technology
[0002] Electronic detonator two-bus communication systems typically use a differential bus A / B for downlink voltage command transmission and employ module-side current feedback for uplink information transmission. The detonator side uses a current acquisition circuit to sense current changes across the bus sampling resistor to determine whether the module has generated a valid uplink feedback current.
[0003] Existing uplink current identification typically employs two schemes: First, sampling and integrating at equal intervals within the sampling window of the square wave under test, using the integral value exceeding a threshold as the criterion; second, sampling at equal intervals within the sampling window and averaging the extreme values by a fixed number of points, determining the presence of an uplink signal based on the range of the processed data exceeding a threshold. While these schemes are usable in conventional networking, in scenarios with unstable busbar materials, significant differences in busbar and lead wire lengths, or multiple series-connected lines of different materials, the induced current generated by bus flipping and line distortion can significantly increase background current fluctuations. This makes it difficult to uniformly set the threshold, leading to trial-and-error threshold selection and numerous erroneous communications. Consequently, this results in misjudgments of multiple or missing detonator connections, on-site binary search troubleshooting, construction delays, and increased risk costs.
[0004] In an electronic detonator two-bus system, how can a real-time updatable background reference be established under conditions of dynamic changes in line parameters formed by the bus and pins, significant waveform distortion, and induced fluctuations in background current? And how can a high-precision, low-false-judgment identification of the uplink feedback current be achieved without relying on multiple sets of fixed thresholds and trial communication, so as to ensure reliable uplink communication in complex networking environments? Summary of the Invention
[0005] The purpose of this invention is to provide a method for achieving reliable communication using pilot square waves, so as to solve the problems mentioned in the background art.
[0006] To solve the above-mentioned technical problems, the present invention provides the following technical solution: a method for achieving reliable communication using pilot square waves, comprising the following steps:
[0007] S1. Line Status Awareness: Before entering uplink communication, a pilot square wave is sent. Bus current sampling data is obtained in the sampling window corresponding to the pilot and a background reference feature is formed. The line status is classified based on the background reference feature to obtain the line status category for subsequent decision. The line status category and the background reference feature are cached as real-time modeling results.
[0008] S2. Command transmission and sampling: Send downlink command containing carrier square wave, sample bus current at equal intervals in the sampling window corresponding to each carrier square wave to form a stable current sampling sequence. The sampling sequence is associated with the corresponding carrier square wave one by one. The sampled data enters the subsequent window division and feature extraction process.
[0009] S3. Carrier window analysis: The sampling sequence of each carrier square wave is adaptively divided into windows according to the current change trend. The key stages of current change are located and key current features are extracted. Based on the key features, it is determined whether the carrier square wave has the candidate conditions for feedback features. The candidate conditions and key features are provided to the adaptive decision step.
[0010] S4. Adaptive Decision: Based on the line state category, select the matching decision rule, compare the key current feature quantity of the carrier square wave with the background reference feature quantity obtained by pilot modeling, determine whether there is a valid uplink feedback current based on the comparison result, and output the feedback existence determination result of each carrier square wave.
[0011] S5. Result Output and Update: The feedback existence determination result is used for uplink information confirmation and communication process control. The current pilot modeling result is cached and updated as a reference benchmark before the next uplink communication. Consistency processing is performed on abnormal sampling windows to ensure the stability of subsequent decisions.
[0012] According to the above technical solution, step S1 includes the following sub-steps:
[0013] S1-1 Pilot square wave transmission and sampling window establishment: Before uplink communication is required, the detonator side transmits a pilot square wave and establishes a sampling window with the bus flip time as the starting point of the sampling window. The total duration is denoted as Ttotal.
[0014] S1-2, Current Sampling and Median Filtering: Within the sampling window, a sampling time sequence t0, t1, ..., tn is formed according to a fixed sampling period, where t0 is the bus flip time and tn is the end point of the sampling window; Median filtering is performed on the three consecutively acquired current sampling values to obtain the filtered current sequence I(t0), I(t1), ..., I(tn);
[0015] S1-3, Current Difference and Trend Calculation: Based on the difference approximation of the current change rate between adjacent sampling points, the following definition is made: DeltaI(i)=I(ti)-I(t{i-1}), where DeltaI(i) is the current change of the i-th sampling point relative to the previous sampling point, which is used to determine the turning point of the overall current trend.
[0016] S1-4, Dynamic Sub-Window Division: Adaptively divide the sampling window into three consecutive sub-windows T1, T2, and T3:
[0017] Set the starting point of T1 as t0 and set the first threshold Th1; when there exists the smallest integer k that satisfies DeltaI(k) < Th1 and DeltaI(k + 1) >= Th1, set the ending point of T1 as t{k + 1}; when there does not exist a k that satisfies the condition, set the ending point of T1 as tn;
[0018] Set the starting point of T2 as the ending point of T1 and set the second threshold Th2; when the ending point of T1 is not equal to tn and there exists the smallest integer m that satisfies DeltaI(m) > Th2 and DeltaI(m + 1) <= Th2, set the ending point of T2 as t{m + 1} and consider that T2 exists; when the ending point of T1 is equal to tn, consider that T2 does not exist;
[0019] Set the starting point of T3 as the ending point of T2 and set the ending point as tn; when T2 does not exist, set the starting point of T3 as the ending point of T1 and set the ending point as tn;
[0020] S1-5. Benchmark feature quantity extraction and line classification: In the sampling result of the pilot square wave, extract the minimum value of the current within T1 and denote it as I0; when T2 exists, extract the maximum value of the current within T2 and denote it as I1 and calculate the duration of T2; when the duration of T2 is greater than 100 microseconds, extract the current value corresponding to the 100 microsecond moment from the starting point within T2 and denote it as I2; complete the line state classification based on whether T2 exists and the duration of T2; where, Ttotal is the total duration of the sampling window; ti is the i-th sampling moment; I(ti) is the i-th current sampling value after median filtering; Th1 is the threshold of the current change amount for determining the transition from descending to ascending and takes +200 μA; Th2 is the threshold of the current change amount for determining the transition from ascending to descending and takes -200 μA; I0 is the background reference current; I1 is the maximum background current caused by the pilot square wave; I2 is the climbing background current at the 100 microsecond mark in the rising stage of the pilot square wave, which is used to quantify the background fluctuation baseline of the severely distorted line.
[0021] According to the above technical solution, the step S2 includes the following sub-steps:
[0022] S2-1. Carrier square wave instruction sending: After the line classification of the pilot square wave is completed, the detonator side sends a downlink instruction containing the carrier square wave to drive the module to perform current feedback within the corresponding time sequence according to the communication protocol;
[0023] S2-2. Carrier sampling window alignment: For each carrier square wave in the instruction, use the bus flip moment of this carrier square wave as the starting point of the corresponding sampling window, and form a sampling moment sequence within this sampling window;
[0024] S2-3. Current sampling and filtering to form a sequence: Within the sampling window, the bus current is continuously sampled at a fixed sampling period, and median filtering is performed on the three current sample values collected each time to obtain the current sampling sequence corresponding to the carrier square wave.
[0025] S2-4. Sampling Link Parameter Constraints: The current acquisition circuit sets sampling resistors at both ends of the two-wire bus A and B, and inputs them to the MCU's ADC after operational amplification, so that the sampled current changes form digital current data that can be analyzed and judged by a window. The sampling resistor has a resistance of 10 ohms; the operational amplification factor is 7.8 times; the ADC uses a 12MHz clock and performs continuous sampling in a 1.5-cycle sampling mode; the median filtering of every 3 sampling points yields 1 effective current value; the sampling frequency of the effective current value is 285kHz.
[0026] According to the above technical solution, step S3 includes the following sub-steps:
[0027] S3-1, Carrier Sub-Window Division: Perform trend detection and sub-window division on the current sampling sequence corresponding to each carrier square wave to obtain three consecutive sub-windows T1, T2, and T3 for the carrier square wave;
[0028] S3-2, Valley Current Extraction: Extract the minimum current value within the T1 sub-window of the carrier square wave, denoted as I3, where I3 is used to characterize the background reference current within the carrier square wave window;
[0029] S3-3, No Feedback Candidate Determination: When the end point of the T1 sub-window is equal to the end point of the carrier square wave sampling window, it is determined that the carrier square wave does not have feedback candidate features and the no feedback candidate result is output.
[0030] S3-4, Peak Current Extraction: When the end point of the T1 sub-window is not equal to the end point of the carrier square wave sampling window, it is determined that the T2 sub-window exists and the maximum current value is extracted within the T2 sub-window, denoted as I4. I4 is used to characterize the possible feedback peak characteristics within the carrier square wave window, and the duration of the T2 sub-window is recorded. I3 is the minimum current during the falling phase of the carrier square wave; I4 is the maximum current during the rising phase of the carrier square wave; the duration of the T2 sub-window is used to constrain the time scale of the feedback characteristics to cooperate with adaptive decision-making.
[0031] According to the above technical solution, step S4 includes the following sub-steps:
[0032] S4-1, Decision premise establishment: The feedback decision process is entered if and only if the carrier square wave has a T2 sub-window and I4 is obtained; if the carrier square wave does not have a T2 sub-window, the no-feedback decision result is output.
[0033] S4-2. Select decision rules based on line status and perform comparison: Based on the line status category output in step S1, determine whether there is a valid signal feedback according to the following rules:
[0034] Communication conditions are good: the pilot square wave has no T2 sub-window and no T3 sub-window; when the duration of the T2 sub-window of the carrier square wave is greater than 100 microseconds and (I4-I3)>500μA, it is determined that there is a valid signal feedback; when the above conditions are not met, it is determined that there is no valid signal feedback.
[0035] Communication conditions are moderate: the pilot square wave has a T2 sub-window and its duration is no more than 100 microseconds; when (I4-I3)>(I1-I0)+500μA, it is determined that there is a valid signal feedback; when the above conditions are not met, it is determined that there is no valid signal feedback.
[0036] Extremely poor communication conditions: The pilot square wave has a T2 sub-window and its duration is greater than 100 microseconds; when (I4-I3)>(I2-I0)+500μA, it is determined that there is a valid signal feedback; when the above conditions are not met, it is determined that there is no valid signal feedback; where I0 is the minimum current in the pilot square wave T1 sub-window; I1 is the maximum current in the pilot square wave T2 sub-window; I2 is the current value at the start of the pilot square wave T2 sub-window 100 microseconds; I3 is the minimum current in the carrier square wave T1 sub-window; I4 is the maximum current in the carrier square wave T2 sub-window; 500μA is the minimum reliable identification feedback current margin, used to ensure that there is minimum resolution between the effective feedback of the module and the line distortion current; (I1-I0) and (I2-I0) respectively characterize the background fluctuation amplitude and the severe distortion rise amplitude caused by the pilot square wave under the current line conditions, and are used to construct an adaptive threshold baseline that varies with the degree of line distortion.
[0037] According to the above technical solution, step S5 includes the following sub-steps:
[0038] S5-1, Output of judgment result: Output the feedback existence judgment result of each carrier square wave obtained in step S4 to the upper layer communication process for uplink information confirmation and communication timing control.
[0039] S5-2, Modeling Result Cache Update: The line state category obtained in step S1 and the corresponding I0, I1 and I2 are cached as the current real-time modeling result of the line, and the cached result is used for pilot modeling comparison and decision baseline call before the next uplink communication.
[0040] S5-3, Sampling Consistency Handling: When there are insufficient sampling points, sampling window out of bounds, or sub-window duration of zero, resulting in the inability to form any of the necessary feature quantities I0, I1, I2, I3, and I4, the output is a no-feedback judgment result and the most recently valid cached line modeling result remains unchanged, so as to ensure that the subsequent decision process has definite input and reproducible output.
[0041] According to the above technical solution, the system used in this method includes a line status perception and real-time modeling module, which is used to send pilot square waves and collect bus current before uplink communication, obtain a real-time benchmark characterizing the line background current and distortion degree, and complete line status classification.
[0042] The dynamic sampling window division and feature extraction module is used to adaptively divide sub-windows and extract key current features within the sampling window of the pilot square wave and carrier square wave based on the current change trend.
[0043] The adaptive threshold decision and result output module is used to select the corresponding decision rule and calculate the decision threshold according to the line status, and output the identification result of whether there is a valid uplink feedback current in the carrier square wave.
[0044] According to the above technical solution, the line status perception and real-time modeling module includes a pilot square wave transmission submodule, a current equal interval sampling and median filtering submodule, a background reference feature extraction submodule, and a line status classification submodule, which are respectively used to generate pilot square waves, form a stable current sampling sequence, extract reference current and distortion current features from pilot sampling, and output line status categories.
[0045] The dynamic sampling window division and feature extraction module includes a trend detection submodule, a subwindow boundary determination submodule, and a valley peak and duration extraction submodule, which are used to calculate the current difference between adjacent sampling points and determine the trend, determine the boundaries of the falling segment, rising segment, and stable segment, and output the minimum current, maximum current, and duration in each subwindow.
[0046] The adaptive threshold decision and result output module includes a decision rule selection submodule, a threshold calculation submodule, a feedback existence determination submodule, and a result output and caching submodule, which are respectively used to select the corresponding rule according to the line status, form an adaptive decision threshold, determine whether there is effective feedback of the carrier square wave, output the decision result to the upper layer communication process, and cache the line reference.
[0047] Compared with existing technologies, the beneficial effects achieved by this invention are as follows: This invention uses pilot square waves to perceive the line status in real time before uplink communication, quantifies the background current fluctuations caused by the pilot into a calculable baseline, and uses dynamic windowing within the carrier square wave to extract key features such as valley and peak values, thereby achieving a decision threshold that automatically adjusts according to changes in the degree of line distortion. In scenarios involving complex busbar materials, long-distance buses, long leads, and induced current interference, the uplink identification accuracy is improved to the 500μA level, effectively reducing false positives and false negatives, reducing trial communication and on-site troubleshooting costs, and improving the reliability of network communication in electronic detonator systems. Attached Figure Description
[0048] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used in conjunction with embodiments of the invention to explain the invention and do not constitute a limitation thereof. In the drawings:
[0049] Figure 1 This is a schematic diagram of the overall system of the present invention;
[0050] Figure 2 These are schematic diagrams illustrating the pilot waveform effects under different conditions according to the present invention;
[0051] Figure 3 This is a schematic diagram of the ideal square wave of the present invention;
[0052] Figure 4 This is a comparison diagram of the uplink signal under actual conditions and the ideal square wave in this invention;
[0053] Figure 5 This is a schematic diagram of the ideal signal of the differential bus AB with pilot square wave of the present invention;
[0054] Figure 6 This is a comparison diagram of the uplink signal and the pilot square wave under actual conditions according to the present invention;
[0055] Figure 7 This is a schematic diagram of the window division and key current values of the present invention. Detailed Implementation
[0056] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0057] Please see Figures 1-7 The present invention provides a technical solution: a method for achieving reliable communication using pilot square waves, comprising the following steps:
[0058] S1. Line Status Awareness: Before entering uplink communication, a pilot square wave is sent. Bus current sampling data is obtained in the sampling window corresponding to the pilot and a background reference feature is formed. The line status is classified based on the background reference feature to obtain the line status category for subsequent decision. The line status category and the background reference feature are cached as real-time modeling results.
[0059] S2, Command transmission and sampling: Send downlink command containing carrier square wave, sample bus current at equal intervals in the sampling window corresponding to each carrier square wave to form a stable current sampling sequence, the sampling sequence is associated with the corresponding carrier square wave, and the sampled data enters the subsequent window division and feature extraction process.
[0060] S3. Carrier window analysis: The sampling sequence of each carrier square wave is adaptively divided into windows according to the current change trend. The key stages of current change are located and key current features are extracted. Based on the key features, it is determined whether the carrier square wave has the candidate conditions for feedback features. The candidate conditions and key features are provided to the adaptive decision step.
[0061] S4. Adaptive Decision: Select matching decision rules based on line status category, compare the key current characteristics of carrier square wave with the background reference characteristics obtained by pilot modeling, determine whether there is effective uplink feedback current based on the comparison results, and output the feedback existence determination result of each carrier square wave.
[0062] S5. Result Output and Update: The feedback existence determination result is used for uplink information confirmation and communication process control. The current pilot modeling result is cached and updated as a reference benchmark before the next uplink communication. Consistency processing is performed on abnormal sampling windows to ensure the stability of subsequent decisions.
[0063] Step S1 includes the following sub-steps:
[0064] S1-1 Pilot square wave transmission and sampling window establishment: Before uplink communication is required, the detonator side transmits a pilot square wave and establishes a sampling window with the bus flip time as the starting point of the sampling window. The total duration is denoted as Ttotal.
[0065] S1-2, Current Sampling and Median Filtering: Within the sampling window, a sampling time sequence t0, t1, ..., tn is formed according to a fixed sampling period, where t0 is the bus flip time and tn is the end point of the sampling window; Median filtering is performed on the three consecutively acquired current sampling values to obtain the filtered current sequence I(t0), I(t1), ..., I(tn);
[0066] S1-3. Current difference and trend quantity calculation: Based on the difference of adjacent sampling points to approximate the current change rate, define: DeltaI(i)=I(ti)-I(t{i - 1}), where DeltaI(i) is the current change amount of the i-th sampling point relative to the previous sampling point, used to judge the turning of the overall current trend;
[0067] S1-4. Dynamic division of sub-windows: Adaptive divide three consecutive sub-windows T1, T2, and T3 within the sampling window:
[0068] Set the starting point of T1 as t0 and set the first threshold Th1; when there exists the smallest integer k satisfying DeltaI(k)<Th1 and DeltaI(k + 1)>=Th1, set the end point of T1 as t{k + 1}; when there is no k satisfying the condition, set the end point of T1 as tn;
[0069] Set the starting point of T2 as the end point of T1 and set the second threshold Th2; when the end point of T1 is not equal to tn and there exists the smallest integer m satisfying DeltaI(m)>Th2 and DeltaI(m + 1)<=Th2, set the end point of T2 as t{m + 1} and consider T2 exists; when the end point of T1 is equal to tn, consider T2 does not exist;
[0070] Set the starting point of T3 as the end point of T2 and set the end point as tn; when T2 does not exist, set the starting point of T3 as the end point of T1 and set the end point as tn;
[0071] S1-5. Extraction of reference feature quantities and line classification: In the sampling result of the pilot square wave, extract the minimum current within T1 and record it as I0; when T2 exists, extract the maximum current within T2 and record it as I1 and calculate the duration of T2; when the duration of T2 is greater than 100 microseconds, extract the current value corresponding to the 100 microsecond moment from the starting point within T2 and record it as I2; complete the line state classification based on the existence of T2 and the duration of T2; where, Ttotal is the total duration of the sampling window; ti is the i-th sampling moment; I(ti) is the i-th current sampling value after median filtering; Th1 is the threshold of the current change amount used to judge the transition from decline to rise and take +200μA; Th2 is the threshold of the current change amount used to judge the transition from rise to decline and take -200μA; I0 is the background reference current; I1 is the maximum background current caused by the pilot square wave; I2 is the climbing background current of the pilot square wave at the 100 microsecond moment in the rising stage, used to quantify the background fluctuation baseline of the severely distorted line;
[0072] Step S2 includes the following sub-steps:
[0073] S2-1, Carrier Square Wave Command Transmission: After the pilot square wave completes the line classification, the detonator side sends a downlink command containing a carrier square wave to drive the module to perform current feedback in the corresponding timing according to the communication protocol.
[0074] S2-2, Carrier sampling window alignment: For each carrier square wave in the instruction, the bus flip time of the carrier square wave is taken as the starting point of the corresponding sampling window, and a sampling time sequence is formed within the sampling window;
[0075] S2-3. Current sampling and filtering to form a sequence: The bus current is continuously sampled at a fixed sampling period within the sampling window, and median filtering is performed on the three current sample values collected each time to obtain the current sampling sequence corresponding to the carrier square wave.
[0076] S2-4. Sampling Link Parameter Constraints: The current acquisition circuit sets sampling resistors at both ends of the dual-bus A and dual-bus B, and inputs them to the MCU's ADC after operational amplification, so that the sampled current changes form digital current data that can be analyzed and judged by a window. The sampling resistor value is 10 ohms; the operational amplification factor is 7.8 times; the ADC uses a 12MHz clock and performs continuous sampling in a 1.5-cycle sampling mode; the median filtering of every 3 sampling points yields 1 effective current value; the sampling frequency of the effective current value is 285kHz.
[0077] Step S3 includes the following sub-steps:
[0078] S3-1, Carrier Sub-Window Division: Perform trend detection and sub-window division on the current sampling sequence corresponding to each carrier square wave to obtain three consecutive sub-windows T1, T2, and T3 for the carrier square wave;
[0079] S3-2, Valley Current Extraction: Extract the minimum current value within the T1 sub-window of the carrier square wave, denoted as I3, where I3 is used to characterize the background reference current within the carrier square wave window;
[0080] S3-3, No Feedback Candidate Determination: When the end point of the T1 sub-window is equal to the end point of the carrier square wave sampling window, it is determined that the carrier square wave does not have feedback candidate features and the no feedback candidate result is output.
[0081] S3-4, Peak Current Extraction: When the end point of the T1 sub-window is not equal to the end point of the carrier square wave sampling window, it is determined that the T2 sub-window exists and the maximum current value is extracted within the T2 sub-window, denoted as I4. I4 is used to characterize the possible feedback peak characteristics within the carrier square wave window, and the duration of the T2 sub-window is recorded. I3 is the minimum current during the falling phase of the carrier square wave; I4 is the maximum current during the rising phase of the carrier square wave; the duration of the T2 sub-window is used to constrain the time scale of feedback characteristics to cooperate with adaptive decision-making.
[0082] Step S4 includes the following sub-steps:
[0083] S4-1, Decision premise establishment: The feedback decision process is entered if and only if the carrier square wave has a T2 sub-window and I4 is obtained; if the carrier square wave does not have a T2 sub-window, the no-feedback decision result is output.
[0084] S4-2. Select decision rules based on line status and perform comparison: Based on the line status category output in step S1, determine whether there is a valid signal feedback according to the following rules:
[0085] Communication conditions are good: the pilot square wave has no T2 sub-window and no T3 sub-window; when the duration of the T2 sub-window of the carrier square wave is greater than 100 microseconds and (I4-I3)>500μA, it is determined that there is a valid signal feedback; when the above conditions are not met, it is determined that there is no valid signal feedback.
[0086] Communication conditions are moderate: the pilot square wave has a T2 sub-window and its duration is no more than 100 microseconds; when (I4-I3)>(I1-I0)+500μA, it is determined that there is a valid signal feedback; when the above conditions are not met, it is determined that there is no valid signal feedback.
[0087] Extremely poor communication conditions: The pilot square wave has a T2 sub-window and its duration is greater than 100 microseconds; when (I4-I3)>(I2-I0)+500μA, it is determined that there is a valid signal feedback; when the above conditions are not met, it is determined that there is no valid signal feedback; where I0 is the minimum current in the pilot square wave T1 sub-window; I1 is the maximum current in the pilot square wave T2 sub-window; I2 is the current value at the start of the pilot square wave T2 sub-window 100 microseconds; I3 is the minimum current in the carrier square wave T1 sub-window; I4 is the maximum current in the carrier square wave T2 sub-window; 500μA is the minimum reliable identification feedback current margin, used to ensure that there is minimum resolution between the effective feedback of the module and the line distortion current; (I1-I0) and (I2-I0) respectively characterize the background fluctuation amplitude and the severe distortion rise amplitude caused by the pilot square wave under the current line conditions, used to construct an adaptive threshold baseline that varies with the degree of line distortion;
[0088] Step S5 includes the following sub-steps:
[0089] S5-1, Output of judgment result: Output the feedback existence judgment result of each carrier square wave obtained in step S4 to the upper layer communication process for uplink information confirmation and communication timing control.
[0090] S5-2, Modeling Result Cache Update: The line state category obtained in step S1 and the corresponding I0, I1 and I2 are cached as the current real-time modeling result of the line, and the cached result is used for pilot modeling comparison and decision baseline call before the next uplink communication.
[0091] S5-3, Sampling Consistency Processing: When there are insufficient sampling points, sampling window out of bounds, or sub-window duration of zero, resulting in the inability to form any of the necessary feature quantities I0, I1, I2, I3, and I4, the output is a no-feedback judgment result and the line modeling result of the most recent valid cache remains unchanged, so as to ensure that the subsequent decision process has definite input and reproducible output.
[0092] The system used in this method includes a line status perception and real-time modeling module, which is used to send pilot square waves and collect bus current before uplink communication, obtain a real-time benchmark characterizing the line background current and distortion degree, and complete line status classification.
[0093] The dynamic sampling window division and feature extraction module is used to adaptively divide sub-windows and extract key current features within the sampling window of the pilot square wave and carrier square wave based on the current change trend.
[0094] The adaptive threshold decision and result output module is used to select the corresponding decision rule and calculate the decision threshold according to the line status, and output the identification result of whether there is a valid uplink feedback current in the carrier square wave.
[0095] The line status perception and real-time modeling module includes a pilot square wave transmission submodule, a current equal interval sampling and median filtering submodule, a background reference feature extraction submodule, and a line status classification submodule, which are respectively used to generate pilot square waves, form stable current sampling sequences, extract reference current and distortion current features from pilot sampling, and output line status categories.
[0096] The dynamic sampling window division and feature extraction module includes a trend detection submodule, a sub-window boundary determination submodule, and a valley peak and duration extraction submodule, which are used to calculate the current difference between adjacent sampling points and determine the trend, determine the boundaries of the falling segment, rising segment, and stable segment, and output the minimum current, maximum current, and duration in each sub-window, respectively.
[0097] The adaptive threshold decision and result output module includes a decision rule selection submodule, a threshold calculation submodule, a feedback existence determination submodule, and a result output and caching submodule, which are respectively used to select the corresponding rule according to the line status, form an adaptive decision threshold, determine whether there is effective feedback of the carrier square wave, output the decision result to the upper layer communication process, and cache the line reference.
[0098] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus.
[0099] Finally, it should be noted that the above descriptions are merely preferred embodiments of the present invention and are not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A method for achieving reliable communication using pilot square waves, characterized in that: Includes the following steps: S1. Line Status Awareness: Before entering uplink communication, a pilot square wave is sent. Bus current sampling data is obtained in the sampling window corresponding to the pilot and a background reference feature is formed. The line status is classified based on the background reference feature to obtain the line status category for subsequent decision. The line status category and the background reference feature are cached as real-time modeling results. S2. Command transmission and sampling: Send downlink command containing carrier square wave, sample bus current at equal intervals in the sampling window corresponding to each carrier square wave to form a stable current sampling sequence. The sampling sequence is associated with the corresponding carrier square wave one by one. The sampled data enters the subsequent window division and feature extraction process. S3. Carrier window analysis: The sampling sequence of each carrier square wave is adaptively divided into windows according to the current change trend. The key stages of current change are located and key current features are extracted. Based on the key features, it is determined whether the carrier square wave has the candidate conditions for feedback features. The candidate conditions and key features are provided to the adaptive decision step. S4. Adaptive Decision: Based on the line state category, select the matching decision rule, compare the key current feature quantity of the carrier square wave with the background reference feature quantity obtained by pilot modeling, determine whether there is a valid uplink feedback current based on the comparison result, and output the feedback existence determination result of each carrier square wave. S5. Result Output and Update: The feedback existence determination result is used for uplink information confirmation and communication process control. The current pilot modeling result is cached and updated as a reference benchmark before the next uplink communication. Consistency processing is performed on abnormal sampling windows to ensure the stability of subsequent decisions.
2. The method for achieving reliable communication using pilot square waves according to claim 1, characterized in that: Step S1 includes the following sub-steps: S1-1 Pilot square wave transmission and sampling window establishment: Before uplink communication is required, the detonator side transmits a pilot square wave and establishes a sampling window with the bus flip time as the starting point of the sampling window. The total duration is denoted as Ttotal. S1-2, Current Sampling and Median Filtering: Within the sampling window, a sampling time sequence t0, t1, ..., tn is formed according to a fixed sampling period, where t0 is the bus flip time and tn is the end point of the sampling window; Median filtering is performed on the three consecutive current samples collected each time to obtain the filtered current sequence I(t0), I(t1), ..., I(tn); S1-3, Current Difference and Trend Calculation: Based on the difference approximation of the current change rate between adjacent sampling points, the following definition is made: DeltaI(i)=I(ti)-I(t{i-1}), where DeltaI(i) is the current change of the i-th sampling point relative to the previous sampling point, which is used to determine the turning point of the overall current trend. S1-4, Dynamic Sub-Window Division: Adaptively divide the sampling window into three consecutive sub-windows T1, T2, and T3: Set the starting point of T1 as t0, and set the first threshold Th1; when there exists the smallest integer k such that DeltaI(k) < Th1 and DeltaI(k + 1) >= Th1, set the ending point of T1 as t{k + 1}; when there is no k satisfying the condition, set the ending point of T1 as tn; Set the starting point of T2 as the ending point of T1, and set the second threshold Th2; when the ending point of T1 is not equal to tn and there exists the smallest integer m such that DeltaI(m) > Th2 and DeltaI(m + 1) <= Th2, set the ending point of T2 as t{m + 1} and consider that T2 exists; when the ending point of T1 is equal to tn, consider that T2 does not exist; Set the starting point of T3 as the ending point of T2 and set the ending point as tn; when T2 does not exist, set the starting point of T3 as the ending point of T1 and set the ending point as tn; S1-5. Reference feature quantity extraction and line classification: In the sampling result of the pilot square wave, extract the minimum current value within T1 and denote it as I0; when T2 exists, extract the maximum current value within T2 and denote it as I1, and calculate the duration of T2; when the duration of T2 is greater than 100 microseconds, extract the current value corresponding to the 100-microsecond moment from the starting point within T2 and denote it as I2; complete the line state classification based on the existence of T2 and the duration of T2; where, Ttotal is the total duration of the sampling window; ti is the i-th sampling moment; I(ti) is the i-th current sampling value after median filtering; Th1 is the threshold of the current change amount for determining the transition from decrease to increase and takes +200 μA; Th2 is the threshold of the current change amount for determining the transition from increase to decrease and takes -200 μA; I0 is the background reference current; I1 is the maximum background current caused by the pilot square wave; I2 is the climbing background current at the 100-microsecond moment in the rising stage of the pilot square wave, which is used to quantify the background fluctuation baseline of the severely distorted line.
3. The method for achieving reliable communication using pilot square waves according to claim 2, characterized in that: The step S2 includes the following sub-steps: S2-1. Carrier square wave instruction sending: After the line classification of the pilot square wave is completed, the detonator side sends a downstream instruction containing the carrier square wave to drive the module to perform current feedback within the corresponding time sequence according to the communication protocol; S2-2. Carrier sampling window alignment: For each carrier square wave in the instruction, take the bus flip moment of this carrier square wave as the starting point of the corresponding sampling window, and form a sampling moment sequence within this sampling window; S2-3. Current sampling and filtering into a sequence: Continuously sample the bus current within the sampling window at a fixed sampling period, and perform median filtering on every 3 continuously collected current sampling values to obtain the current sampling sequence corresponding to this carrier square wave; S2-4. Sampling Link Parameter Constraints: The current acquisition circuit sets sampling resistors at both ends of the two-wire bus A and B, and inputs them to the MCU's ADC after operational amplification, so that the sampled current changes form digital current data that can be analyzed and judged by a window. The sampling resistor has a resistance of 10 ohms; the operational amplification factor is 7.8 times; the ADC uses a 12MHz clock and performs continuous sampling in a 1.5-cycle sampling mode; the median filtering of every 3 sampling points yields 1 effective current value; the sampling frequency of the effective current value is 285kHz.
4. The method for achieving reliable communication using pilot square waves according to claim 3, characterized in that: Step S3 includes the following sub-steps: S3-1, Carrier Sub-Window Division: Perform trend detection and sub-window division on the current sampling sequence corresponding to each carrier square wave to obtain three consecutive sub-windows T1, T2, and T3 for the carrier square wave; S3-2, Valley Current Extraction: Extract the minimum current value within the T1 sub-window of the carrier square wave, denoted as I3, where I3 is used to characterize the background reference current within the carrier square wave window; S3-3, No Feedback Candidate Determination: When the end point of the T1 sub-window is equal to the end point of the carrier square wave sampling window, it is determined that the carrier square wave does not have feedback candidate features and the no feedback candidate result is output. S3-4, Peak Current Extraction: When the end point of the T1 sub-window is not equal to the end point of the carrier square wave sampling window, it is determined that the T2 sub-window exists and the maximum current value is extracted within the T2 sub-window, denoted as I4. I4 is used to characterize the possible feedback peak characteristics within the carrier square wave window, and the duration of the T2 sub-window is recorded. I3 is the minimum current during the falling phase of the carrier square wave; I4 is the maximum current during the rising phase of the carrier square wave; the duration of the T2 sub-window is used to constrain the time scale of the feedback characteristics to cooperate with adaptive decision-making.
5. A method for achieving reliable communication using pilot square waves according to claim 4, characterized in that: Step S4 includes the following sub-steps: S4-1, Decision premise establishment: The feedback decision process is entered if and only if the carrier square wave has a T2 sub-window and I4 is obtained; if the carrier square wave does not have a T2 sub-window, the no-feedback decision result is output. S4-2. Select decision rules based on line status and perform comparison: Based on the line status category output in step S1, determine whether there is a valid signal feedback according to the following rules: Communication conditions are good: the pilot square wave has no T2 sub-window and no T3 sub-window; when the duration of the T2 sub-window of the carrier square wave is greater than 100 microseconds and (I4-I3)>500μA, it is determined that there is a valid signal feedback; when the above conditions are not met, it is determined that there is no valid signal feedback. Communication conditions are moderate: the pilot square wave has a T2 sub-window and its duration is no more than 100 microseconds; when (I4-I3)>(I1-I0)+500μA, it is determined that there is a valid signal feedback; when the above conditions are not met, it is determined that there is no valid signal feedback. Extremely poor communication conditions: The pilot square wave has a T2 sub-window and its duration is greater than 100 microseconds; when (I4-I3)>(I2-I0)+500μA, it is determined that there is a valid signal feedback; when the above conditions are not met, it is determined that there is no valid signal feedback; where I0 is the minimum current in the pilot square wave T1 sub-window; I1 is the maximum current in the pilot square wave T2 sub-window; I2 is the current value at the start of the pilot square wave T2 sub-window 100 microseconds; I3 is the minimum current in the carrier square wave T1 sub-window; I4 is the maximum current in the carrier square wave T2 sub-window; 500μA is the minimum reliable identification feedback current margin, used to ensure that there is minimum resolution between the effective feedback of the module and the line distortion current; (I1-I0) and (I2-I0) respectively characterize the background fluctuation amplitude and the severe distortion rise amplitude caused by the pilot square wave under the current line conditions, and are used to construct an adaptive threshold baseline that varies with the degree of line distortion.
6. The method for achieving reliable communication using pilot square waves according to claim 5, characterized in that: Step S5 includes the following sub-steps: S5-1, Output of judgment result: Output the feedback existence judgment result of each carrier square wave obtained in step S4 to the upper layer communication process for uplink information confirmation and communication timing control. S5-2, Modeling Result Cache Update: The line state category obtained in step S1 and the corresponding I0, I1 and I2 are cached as the current real-time modeling result of the line, and the cached result is used for pilot modeling comparison and decision baseline call before the next uplink communication. S5-3, Sampling Consistency Handling: When there are insufficient sampling points, sampling window out of bounds, or sub-window duration of zero, resulting in the inability to form any of the necessary feature quantities I0, I1, I2, I3, and I4, the output is a no-feedback judgment result and the most recently valid cached line modeling result remains unchanged, so as to ensure that the subsequent decision process has definite input and reproducible output.
7. A method for achieving reliable communication using pilot square waves according to claim 6, characterized in that: The system used in this method includes a line status perception and real-time modeling module, which is used to send pilot square waves and collect bus current before uplink communication, obtain a real-time benchmark characterizing the line background current and distortion degree, and complete line status classification. The dynamic sampling window division and feature extraction module is used to adaptively divide sub-windows and extract key current features within the sampling window of the pilot square wave and carrier square wave based on the current change trend. The adaptive threshold decision and result output module is used to select the corresponding decision rule and calculate the decision threshold according to the line status, and output the identification result of whether there is a valid uplink feedback current in the carrier square wave.
8. A method for achieving reliable communication using pilot square waves according to claim 7, characterized in that: The line status perception and real-time modeling module includes a pilot square wave transmission submodule, a current equal interval sampling and median filtering submodule, a background reference feature extraction submodule, and a line status classification submodule, which are respectively used to generate pilot square waves, form a stable current sampling sequence, extract reference current and distortion current features from pilot sampling, and output line status categories. The dynamic sampling window division and feature extraction module includes a trend detection submodule, a subwindow boundary determination submodule, and a valley peak and duration extraction submodule, which are used to calculate the current difference between adjacent sampling points and determine the trend, determine the boundaries of the falling segment, rising segment, and stable segment, and output the minimum current, maximum current, and duration in each subwindow. The adaptive threshold decision and result output module includes a decision rule selection submodule, a threshold calculation submodule, a feedback existence determination submodule, and a result output and caching submodule, which are respectively used to select the corresponding rule according to the line status, form an adaptive decision threshold, determine whether there is effective feedback of the carrier square wave, output the decision result to the upper layer communication process, and cache the line reference.
Citation Information
Patent Citations
Microwave radio frequency link multi-index comprehensive measurement method
CN121150851A
Electrocardiosignal st section automatic determination method and apparatus based on artificial intelligence technology
WO2020114068A1