A method and device for optical fiber differential protection synchronization and data alignment of a ring main unit

CN122553052BActive Publication Date: 2026-10-30ZHUHAI OLE DISTRIBUTION AUTOMATION SYST CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202611012600.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-07-08
Publication Date
2026-10-30
Estimated Expiration
2046-07-08

AI Technical Summary

Technical Problem

1、同步依赖外部时钟:GPS/北斗在复杂环境下可靠性不足,且增加硬件成本

Benefits of technology

1、需外部时钟,不依赖GPS/北斗,仅利用光纤通道自身完成同步,抗干扰能力强,适用性广。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122553052B_ABST
    Figure CN122553052B_ABST
Patent Text Reader

Abstract

The application discloses a kind of optical fiber differential protection synchronization and data alignment method and device for ring network cabinet, belong to distribution network relay protection technical field.The application proposes a kind of light weight synchronization and sampling point serial number alignment method: sampling data is obtained from real-time core by shared memory, and sampling point serial number is encapsulated in optical fiber frame and sent;Channel transmission delay and sampling deviation are calculated using frame timestamp at receiving side, and local sampling period is fine-tuned according to sampling deviation from end;At the same time, according to the difference between the current sampling serial number of this side and the frame head serial number of the opposite side, the received sampling point array is circularly shifted, and the physical time alignment of the sampling points on both sides is realized.The application does not need external clock, the alignment error is less than one sampling interval, the calculation amount is small, and is suitable for ring network cabinet distributed DTU or microcomputer protection device.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of distribution network relay protection, and in particular to a method and apparatus for optical fiber differential protection synchronization and data alignment for ring main units. Background Art

[0002] Ring main units are key switchgear in distribution networks, and fast fault isolation between their outgoing lines is critical to power supply reliability. Optical fiber differential protection is gradually applied to line protection of ring main units due to its good selectivity, fast operation speed, and immunity to system operation modes.

[0003] At present, optical fiber differential protection generally adopts the following synchronization and data alignment methods: 1. GPS / Beidou-based synchronization method: The devices at both sides receive GPS / Beidou signals respectively to achieve sampling synchronization. This solution often suffers from signal occlusion in outdoor switch stations or underground distribution rooms, leading to synchronization failure, and requires additional hardware with high cost.

[0004] 2. Interpolation synchronization method based on channel delay measurement: A mechanism similar to IEEE 1588 is used to measure the transmission delay of the optical fiber channel, and then the sampling points at both sides are aligned to the same time axis through linear interpolation or Lagrange interpolation. This solution relies on floating-point operations, which imposes a heavy burden on embedded processors (such as ARM Cortex-M4), and the interpolation error varies with the sampling frequency, resulting in reduced accuracy under high-order harmonics.

[0005] 3. Hard synchronization method of sampling pulses: Sampling pulses are transmitted through a dedicated synchronization cable. This method requires additional physical wiring and is not suitable for the distributed installation scenario of ring main units.

[0006] Existing public documents (such as a certain issue of *Automation of Electric Power Systems* in 2018) have reported a differential protection synchronization scheme based on the ping-pong method for delay measurement, but it only compensates for the channel delay, does not solve the inherent deviation of the sampling moments at both sides, and still requires interpolation for alignment; moreover, it is not optimized for dual-core heterogeneous embedded platforms and cannot fully utilize the zero-copy feature of shared memory.

[0007] Distributed DTUs or microcomputer protection devices supporting ring main units adopt ARM Cortex-A7 or Cortex-M4 processors with limited computing power. Therefore, a lightweight synchronization and alignment method that does not require GPS, does not require floating-point interpolation, and is suitable for embedded terminals is needed.

[0008] The following problems exist in the existing optical fiber differential protection technology: 1. Synchronization relies on an external clock: GPS / Beidou has insufficient reliability in complex environments and increases hardware cost.

[0009] 2. The interpolation algorithm has a large computational load: Traditional synchronous interpolation methods require floating-point multiplication and division and trigonometric function operations, which makes it difficult to guarantee real-time performance on embedded processors.

[0010] 3. Insufficient sampling alignment accuracy: Simple timestamp alignment cannot eliminate the fixed deviation of sampling time, resulting in differential current calculation error.

[0011] 4. Low resource utilization: Functional modules such as startup components, differential calculation, and TA disconnection detection run independently, resulting in low efficiency of shared memory access and redundant data copying. Summary of the Invention

[0012] Based on the technical problems existing in the background technology, the present invention proposes a method and device for optical fiber differential protection synchronization and data alignment for ring network cabinets. It is applied to the distributed DTU or microcomputer protection device of the ring network cabinet. The device includes a real-time processor core (R core) and an application processor core (A core), which exchange data through shared memory.

[0013] This invention proposes a method for optical fiber differential protection synchronization and data alignment for ring main units, comprising the following steps: S1. The real-time core collects current and voltage waveforms at a fixed sampling period and stores the sampling points and sampling point numbers into a shared memory ring buffer. S2. The application core reads the sampling points, encapsulates them into an optical fiber frame containing the transmission time and the first sampling point sequence number, and sends it to the other side. S3. After receiving the optical fiber frame from the other side, calculate the channel transmission delay and sampling deviation based on the timestamp within the frame, and fine-tune the local sampling period from the slave end based on the sampling deviation. S4. Based on the difference between the current sampling point number on this side and the first point number in the frame on the other side, the received sampling point array is cyclically shifted to achieve physical time alignment of the sampling points on both sides. S5. Calculate the differential current and braking current based on the aligned sampling points, and determine whether to trip.

[0014] Preferably, in step S1, the shared memory is the on-chip shared RAM in a dual-core heterogeneous processor, and the real-time core and the application core can directly access each other through memory mapping without the need for data copying.

[0015] Preferably, in step S1, the sampling point number is a monotonically increasing integer, which is used cyclically in the shared memory circular buffer, and each frame carries the first point number for alignment calculation.

[0016] Preferably, in step S3, the normalization formula for the sampling bias is: If Ts > Ts_max / 2, then Ts -= Ts_max; if Ts < -Ts_max / 2, then Ts += Ts_max, where Ts_max is the sampling period.

[0017] Preferably, in step S3, the step size of the slave end for fine-tuning the sampling deviation is 2 microseconds, and the adjustment direction is opposite to the sign of the sampling deviation, until the absolute value of the deviation is less than 10 microseconds.

[0018] Preferably, in step S4, the cyclic shift alignment specifically involves: Offset = (Current sampling point number on this side - First frame point number on the opposite side)% Number of sampling points per frame; After cyclically shifting the sampling point array on the opposite side by the offset, they are sequentially matched with the subsequent sampling points on this side.

[0019] Preferably, it also includes S6, TA disconnection detection lockout. When the differential current is greater than 0.8 times the low set value and the current on one side is less than the no-current threshold (0.06 times the rated current) while the current on the other side is greater than the current-current threshold, the TA disconnection flag is set after a 10-second delay confirmation, and the differential output is locked.

[0020] This invention also proposes a fiber optic differential protection device for ring main units, comprising: The real-time sampling module, executed by the real-time processor core, is used to control the ADC to acquire current and voltage, and write the sampling points and sequence numbers into shared memory. The communication module, executed by the application processor core, is used to encapsulate / decapsulate fiber frames, calculate channel delay and sampling deviation, and perform slave-end sampling period adjustment. The alignment module is used to perform cyclic shift alignment on the received data based on the difference in the sampling point sequence numbers; The differential calculation module is used to perform Fourier transform, differential current and braking current calculations based on the aligned data; The output module is used to drive the relay when the tripping conditions are met.

[0021] Compared with existing technologies, the beneficial effects of this invention are: 1. Requires an external clock, does not rely on GPS / BeiDou, and only uses the fiber optic channel itself to complete synchronization. It has strong anti-interference ability and wide applicability.

[0022] 2. Minimal computational load: synchronization and data alignment involve only integer addition and subtraction, modular arithmetic, and circular shifts, requiring no floating-point interpolation, and can run easily on ARM Cortex-M4 (200MHz).

[0023] 3. High alignment accuracy: Through fine-tuning of the sampling period, the long-term steady-state deviation is less than 10µs; through cyclic shifting of the serial number, the alignment error of the sampling point is less than one sampling interval (78µs), which meets the accuracy requirements of differential protection.

[0024] 4. Good real-time performance: zero-copy shared memory ensures that the delay from data sampling to transmission is less than 1ms; protection calculation is performed once per cycle (20ms), and the action time is less than 40ms.

[0025] 5. High integration: It integrates functions such as synchronization, alignment, startup, and TA disconnection detection into the same device, eliminating the need for additional hardware and reducing the cost of secondary equipment in ring main units.

[0026] 6. Highly adaptable, supports automatic configuration of master and slave roles, and can be flexibly applied to different ring network cabinet lines (such as two-terminal or three-terminal differential). Attached Figure Description

[0027] Figure 1 : Flowchart of the overall method of this invention.

[0028] Figure 2 : Schematic diagram of fiber optic frame structure.

[0029] Figure 3 Timing diagram for calculating channel transmission delay and sampling deviation.

[0030] Figure 4 : Schematic diagram of cyclic shifting and alignment of sampling point numbers.

[0031] Figure 5 Shared memory dual-core data interaction architecture diagram.

[0032] Figure 6 Differential protection action logic block diagram.

[0033] Figure 7 Flowchart for TA disconnection detection and interlocking. Detailed Implementation

[0034] Reference Figure 1-7 This embodiment proposes a method for optical fiber differential protection synchronization and data alignment for ring main units, including the following steps; Step S1: Real-time sampling and shared memory storage The real-time core (R core) controls the analog-to-digital converter (ADC) to synchronously sample the three-phase current (IA, IB, IC) and three-phase voltage (UA, UB, UC) of the ring main unit outgoing lines at a fixed sampling frequency (preferably 12800Hz, 256 points per cycle).

[0035] Each sampling point is assigned a monotonically increasing sampling point number (us_sample_idx, ranging from 0 to TC_ADC_DOTS_PER_CHANNEL-1), and is stored together with the original sampled value in a circular buffer (struct t_sampledata_mc) in shared memory.

[0036] The application core (A core) directly reads the sampling points through shared memory, achieving zero-copy data acquisition.

[0037] Step S2: Fiber Frame Encapsulation and Transmission The application core reads 64 newly acquired sampling points from shared memory at fixed intervals (every 5ms) and encapsulates them into custom fiber frames.

[0038] The fiber optic frame structure includes: Frame header: version number, frame length, frame sequence number; Synchronization information: local transmission time t1_send (microsecond-level timestamp), local sampling point first point number local_sample_no; Sampling data: 64 sampling points, each sampling point contains ADC code values ​​for 6 channels (IA, IB, IC, UA, UB, UC); Verification field: 32-bit CRC (IEEE 802.3).

[0039] The frame is sent to the protection device on the other side through the device's Ethernet port or dedicated fiber optic interface.

[0040] Step S3: Fiber optic frame reception and preliminary analysis After the receiving device receives the fiber frame, it records the receiving time t4_recv_local.

[0041] Perform CRC check on the frame. After the check passes, parse out the three timestamps provided by the other side: t1_send (time when the other side sends the frame), t2_recv_opp (time when the other side receives the frame from this side), and t3_send_opp (time when the other side sends the frame).

[0042] At the same time, the first sampling point number opp_sample_no of the opposite side is obtained.

[0043] Step S4: Calculation of channel transmission delay and sampling deviation Calculate the round-trip time of the received frame on this side: round_trip = t4_recv_local - t1_send.

[0044] Calculate the processing delay on the other side: peer_delay = t3_send_opp - t2_recv_opp.

[0045] Calculate the one-way transmission delay: Td = (round_trip - peer_delay) / 2 (microseconds).

[0046] Apply sliding window filtering (window length 16) to Td to obtain the smoothed Td_avg.

[0047] Calculate the sampling bias: Ts = (t4_recv_local - t3_send_opp) - Td_avg.

[0048] Ts is normalized to within ±1 / 2 of the sampling period (the sampling period is 78.125µs, i.e., Ts = Ts mod 78.125; if it is greater than half a period, subtract one period).

[0049] The normalized Ts represents the lead / lag time of the sampling point on the opposite side relative to the sampling point on this side.

[0050] Step S5: Adaptive sampling period fine-tuning from the slave end If the device is configured as a slave (e.g., the master / slave role is determined by comparing device addresses), and |Ts| is greater than the target deviation threshold (preferably 10µs), then the adjustment step size ΔT is calculated (step size 2µs, direction opposite to Ts).

[0051] The real-time core sends adjustment commands to the shared memory, and then fine-tunes the period value of the ADC sampling timer (e.g., adjusting 78.125µs to 78.125±0.002µs).

[0052] After multiple adjustments, Ts converged to within 10µs, achieving long-term synchronization of sampling times on both sides. Step S6: Cyclic shift and alignment of sampling point numbers Get the latest sampling point number cur_local_idx on this side (read from shared memory).

[0053] Calculate the offset: shift = (cur_local_idx - opp_sample_no) % SAMPLES_PER_FRAME (SAMPLES_PER_FRAME is the number of sampling points per frame, which is 64 in this example).

[0054] The sampling point array in the received frame on the other side is cyclically shifted by the offset shift: the i-th point of the new array is equal to the (i+shift) % 64-th point of the original array.

[0055] The shifted sampling point array on the opposite side is physically time aligned with the subsequent SAMPLES_PER_FRAME sampling points on this side (error less than 1 sampling interval). Step S7: Differential Protection Calculation and Output The 256 consecutive aligned sampling points on the local and opposite sides (i.e., one power frequency cycle) are sent to the Fourier transform module to calculate the fundamental amplitude of the three-phase current.

[0056] Calculate the differential current Id = |I_local + K·I_remote| and the braking current Ir = |I_local -K·I_remote|, where K is the balance coefficient (to compensate for the difference in the transformer ratios on both sides).

[0057] Determine the start-up condition: the sudden change in phase current (second-order differential) or the differential current is greater than 0.8 times the low set value.

[0058] If the starting element operates and the synchronization state is valid, and the differential current satisfies the ratio braking characteristic (Id > I_set_low and Id > k·Ir), then a trip signal is output to drive the ring main unit circuit breaker to trip.

[0059] If a current transformer (CT) disconnection is detected (large differential current but no current on one side) and the interlocking function is engaged, the differential protection will be temporarily blocked.

[0060] Step S8: Redundancy and Anomaly Handling When the main communication channel (fiber optic cable) fails, it can automatically switch to the backup communication channel (such as a serial port or another fiber optic core) to ensure data continuity.

[0061] If the channel interruption exceeds the set time (e.g., 100ms), the synchronization status is set to invalid, and the differential protection is deactivated to prevent malfunction.

[0062] Application Example 1: Two-End Fiber Differential Protection Based on Distributed DTU This embodiment uses a distributed protection and control unit as the hardware platform, which is installed in the outgoing line bay of the ring main unit. Another identical device is installed in the ring main unit on the opposite side of the line. The two devices are directly connected via single-mode optical fiber.

[0063] I. Hardware Configuration Ring main unit: OLK-12 / T630-25, outgoing line configuration includes current transformer (600A / 5A ratio) and voltage transformer (10kV / 100V).

[0064] DTU: The main control chip is a dual-core heterogeneous processor: one ARM Cortex-A7 (1GHz) running Linux, responsible for communication, protection computing and human-computer interaction; one Cortex-M4 (200MHz) running RT-Thread, responsible for ADC sampling, shared memory maintenance and sampling period fine-tuning.

[0065] ADC: 16-bit synchronous sampling chip, sampling rate 12800Hz (78.125µs interval), 256 points per cycle.

[0066] Fiber optic interface: 100Mbps Ethernet optical port, custom EtherType 0x88CD.

[0067] Software implementation Real-time core (M4) tasks: The ADC sampling is triggered by a hardware timer, and after each sampling is completed, the DMA is triggered to move the data to a shared memory circular buffer.

[0068] Maintain the sampling point number us_sample_idx, increment it by 1 for each sampling, and cycle from 0 to 95 (because TC_ADC_DOTS_PER_CHANNEL=96).

[0069] Listen for adjustment commands at address SHM_PERIOD_ADJ_ADDR in shared memory. Upon receiving the command, modify the timer comparison value and adjust the sampling period (step ±2µs).

[0070] Application Core (A7) Task The sending thread (priority 85) reads the latest 64 sample points from shared memory every 5ms, encapsulates and sends the fiber frame using fiber_send_frame. The t1_send in the frame obtains a microsecond-level timestamp via clock_gettime(CLOCK_MONOTONIC), and local_sample_no is taken from us_sample_idx in shared memory.

[0071] Receive thread (priority 88): Blocks receiving fiber optic frames. Upon receipt, it records t4_recv_local, checks the CRC, and parses out fields such as t1_send, t2_recv_opp, t3_send_opp, and opp_sample_no. It calls sync_update to calculate Td and Ts. If this device is a slave and |Ts|>10µs, it calls rcore_adjust_sample_period to send an adjustment command.

[0072] Protection thread (priority 90): Executes in 5ms cycles, acquiring 64 new sampling points each time, and maintaining a 256-point circular window. When both the local and opposite windows are filled with 256 points, the following sub-steps are executed: a. Align the sampling points of the opposite window by cyclically shifting them according to the previously calculated offset.

[0073] b. Perform a Fourier transform on the 256-point array on both sides to obtain the fundamental amplitude.

[0074] c. Calculate the differential current and braking current.

[0075] d. Invoke the startup element (based on amplitude mutation and differential flow) and TA disconnection detection.

[0076] e. If the tripping conditions are met, drive the output relay via GPIO.

[0077] Table 1 Actual Test Results Synchronous convergence time Approximately 2 seconds (requires multiple interpolation filters) Approximately 200ms (5 frame exchanges) steady-state sampling bias ±20µs ±8µs Alignment error Approximately 1 sampling point <0.5 sampling points Single protection calculation time Approximately 8ms (including interpolation) Approximately 3ms (no floating-point) TA disconnection blocking delay None or fixed 5s 10s adaptive The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.

Claims

1. A method for optical fiber differential protection synchronization and data alignment for ring main units, characterized in that, Includes the following steps: S1. The real-time core collects current and voltage waveforms at a fixed sampling period and stores the sampling points and sampling point numbers in a shared memory ring buffer. The shared memory is the on-chip shared RAM in the dual-core heterogeneous processor. The real-time core and the application core can directly access each other through memory mapping without data copying. S2. The application core reads the sampling points, encapsulates them into an optical fiber frame containing the transmission time and the first sampling point sequence number, and sends it to the other side. S3. After receiving the optical fiber frame from the other side, calculate the channel transmission delay and sampling deviation based on the timestamp within the frame, and fine-tune the local sampling period from the slave end based on the sampling deviation. S4. Based on the difference between the current sampling point number on this side and the first point number in the frame on the other side, perform a cyclic shift on the sampling point array received from the other side to achieve physical time alignment of the sampling points on both sides. The cyclic shift specifically involves: Offset = (Current sampling point number on this side - First sampling point number on the opposite side) % Number of sampling points per frame; After cyclically shifting the sampling point array on the opposite side by the offset, they are sequentially matched with the subsequent sampling points on this side. S5. Calculate the differential current and braking current based on the aligned sampling points, and determine whether to trip.

2. The method for fiber optic differential protection synchronization and data alignment for ring main units according to claim 1, characterized in that, In step S1, the sampling point number is a monotonically increasing integer, which is used cyclically in the shared memory circular buffer, and each frame carries the first point number for alignment calculation.

3. The method for fiber optic differential protection synchronization and data alignment for ring main units according to claim 1, characterized in that, In S3, the normalization formula for the sampling deviation is: If Ts > Ts_max / 2, then Ts -= Ts_max; if Ts < -Ts_max / 2, then Ts += Ts_max, where Ts_max is the sampling period.

4. The method for fiber optic differential protection synchronization and data alignment for ring main units according to claim 1, characterized in that, In step S3, the slave end makes a fine adjustment step of 2 microseconds based on the sampling deviation, and the adjustment direction is opposite to the sign of the sampling deviation, until the absolute value of the deviation is less than 10 microseconds.

5. The method for fiber optic differential protection synchronization and data alignment for ring main units according to claim 1, characterized in that, It also includes S6 and TA disconnection detection interlock. When the differential current is greater than 0.8 times its low set value and the current on one side is less than the no-current threshold while the current on the other side is greater than the current-current threshold, the TA disconnection flag is set after a 10-second delay confirmation, and the differential output is interlocked.

6. A fiber optic differential protection device for a ring main unit, used to implement the method described in any one of claims 1-5, characterized in that, include: The real-time sampling module, executed by the real-time processor core, is used to control the ADC to acquire current and voltage, and write the sampling points and sequence numbers into shared memory. The communication module, executed by the application processor core, is used to encapsulate / decapsulate fiber frames, calculate channel delay and sampling deviation, and perform slave-end sampling period adjustment. The alignment module is used to perform cyclic shift alignment on the received data based on the difference in the sampling point sequence numbers; The differential calculation module is used to calculate the differential current and braking current based on the aligned data. The output module is used to drive the relay when the tripping conditions are met.

Citation Information

Patent Citations

  • Data synchronization method for digitized fiber differential protection device

    CN101534003A

  • Synchronization method and device for longitudinal differential protection sampling of power transmission line

    CN112993949A