Method and apparatus for recording transient faults of an optical module

CN122969656APending Publication Date: 2026-10-23ACCELINK TECHNOLOGIES CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611144895.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-07-30
Publication Date
2026-10-23

AI Technical Summary

Technical Problem

[0004]然而,上述方法存在以下不足:由于ADC采用百毫秒量级的周期性轮询采样方式,两次采样之间存在较大的时间盲区,对于电源电压瞬时小幅跌落迅速恢复、发射光功率瞬时异常跌落迅速恢复、APD高压瞬时异常迅速恢复等持续时间仅为微秒至毫秒量级的瞬时故障,现有技术难以有效捕获,导致小概率瞬时故障重现的时间成本和人工成本大大增加

Benefits of technology

[0017]与现有技术相比,本发明的有益效果在于:比较器是直接将瞬时监控参数与预设阈值比较,这个过程是纯硬件级运算,可以实现瞬时故障的实时判别;在发生瞬时故障时,立即触发模数转换器进行瞬时采样,可以实现瞬时故障发生时刻的精准锁定;后续的非易失性存储,可以实现瞬时故障的现场固化,从而支持返厂后的直接查询定位,避免小概率瞬时故障的反复重现调试,显著降低故障排查的时间成本与人工成本。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122969656A_ABST
    Figure CN122969656A_ABST
Patent Text Reader

Abstract

The application relates to the technical field of optical modules, in particular to a recording method and device for instantaneous failure of an optical module. The method comprises the following steps: using an analog-to-digital converter to perform ordinary sampling on ordinary monitoring parameters of the optical module at a preset period; continuously monitoring instantaneous monitoring parameters of the optical module; when an instantaneous failure is monitored, triggering the analog-to-digital converter to perform instantaneous sampling on the instantaneous monitoring parameters and performing non-volatile storage. The application can effectively capture the instantaneous failure of the optical module and reduce the time cost and labor cost of small-probability instantaneous failure reappearance.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of optical module technology, and in particular to a method and apparatus for recording transient faults in optical modules. Background Technology

[0002] Optical modules are the core optoelectronic conversion devices in optical communication systems. Real-time monitoring and fault alarms of optical module operation status are crucial for ensuring the reliability of communication links. Optical modules typically integrate acquisition circuits for various monitoring parameters such as temperature, power supply voltage, and optical power. The system host obtains this monitoring data and fault alarm information through a standard interface (such as I²C, or Inter-Integrated Circuit) to achieve real-time monitoring of the optical communication equipment's operating status.

[0003] like Figure 1 As shown, existing optical modules typically use the analog-to-digital converter (ADC) built into the microcontroller unit (MCU) to periodically sample common monitoring parameters such as temperature, power supply voltage, received optical power, transmitted optical power, and APD (Avalanche Photo Diode) high voltage. The process involves: the ADC acquiring the common monitoring parameters and converting them into digital values; an alarm unit comparing the digital values ​​with corresponding thresholds and setting alarm states based on the comparison results; a storage unit storing the digital values ​​and alarm flags in corresponding volatile registers; and a reporting unit querying the corresponding volatile registers via an I²C interface to retrieve the digital values ​​and alarm states. The ADC relies on an external trigger signal to initiate sampling. If the sampling period is set too short, the number of triggers per unit time will surge, overloading the ADC and preventing timely responses. Therefore, the sampling period is typically extended to the order of hundreds of milliseconds to ensure stable and reliable sampling.

[0004] However, the above method has the following shortcomings: Since the ADC adopts a periodic polling sampling method on the order of hundreds of milliseconds, there is a large time blind zone between two samplings. For transient faults with a duration of only microseconds to milliseconds, such as the power supply voltage sudden small drop and rapid recovery, the transmitted optical power sudden abnormal drop and rapid recovery, and the APD high voltage sudden abnormal rapid recovery, the existing technology is difficult to effectively capture, which greatly increases the time and labor costs of reproducing low-probability transient faults.

[0005] Therefore, overcoming the shortcomings of the existing technology is an urgent problem to be solved in this technical field. Summary of the Invention

[0006] In view of the above-mentioned defects or improvement needs of the existing technology, the present invention proposes a method and device for recording instantaneous faults of optical modules, which can effectively capture instantaneous faults of optical modules and reduce the time and labor costs of reproducing low-probability instantaneous faults.

[0007] The embodiments of the present invention adopt the following technical solutions: In a first aspect, the present invention provides a method for recording instantaneous faults of an optical module, specifically: using an analog-to-digital converter to perform ordinary sampling of the ordinary monitoring parameters of the optical module at a preset period; The instantaneous monitoring parameters of the optical module are continuously monitored; when an instantaneous fault is detected, the analog-to-digital converter is triggered to sample the instantaneous monitoring parameters and store them non-volatilely.

[0008] Preferably, the method further includes: When a sampling conflict occurs between instantaneous sampling and normal sampling, the normal sampling being performed by the analog-to-digital converter is interrupted, and instantaneous sampling is performed instead. After the instantaneous sampling is completed, normal sampling is restarted.

[0009] Preferably, the method further includes: Use a comparator to quickly obtain the comparison results between instantaneous monitoring parameters and preset thresholds; The comparison results of all comparators are ORed using programmable logic circuits to obtain the output result. If the output is high, the analog-to-digital converter is triggered to perform instantaneous sampling and set an instantaneous fault flag.

[0010] Preferably, the storage architecture includes a data cache area, a non-volatile data storage area, and a data identification area; The method further includes: The system continuously checks whether the instantaneous fault flag has been set. If the transient fault flag is set, clear the transient fault flag and store the transient sampling results in the data buffer area; Determine whether the instantaneous fault corresponding to the instantaneous sampling result is the first occurrence. If it is the first occurrence, set a fault record flag in the data identification area so as to determine whether to store the instantaneous sampling result in the data storage area through the fault record flag, and then perform non-volatile storage.

[0011] Preferably, the method further includes: If the instantaneous fault corresponding to the instantaneous sampling result is not the first occurrence, then there is no need to set a fault record flag.

[0012] Preferably, the method further includes: The system continuously checks whether the fault record flag has been set. If the fault record flag is set, then clear the fault record flag, erase the data in the data storage area, and write the data in the data cache area into the data storage area; If the fault record flag is not set, proceed to the next cycle.

[0013] Preferably, the data identification area is further configured with a write-to-be-written flag, and user data and fault data share the same data storage area; the method further includes: After user data is written to the data cache area, the write-pending flag of the data identifier area is set; The system continuously checks whether the write-to-be-written flag and / or the fault record flag are set. If the write-to-be-written flag and / or fault record flag are set, then the write-to-be-written flag and / or fault record flag are cleared, the data in the data storage area is erased, and the data in the data cache area is written to the data storage area.

[0014] Preferably, the method further includes: A single physical page of the data storage area is divided into a first data block and a second data block; wherein the first data block is used to store user data; the second data block is used to store fault data; the first data block and the second data block have fixed address boundaries within the physical page.

[0015] In a second aspect, the present invention provides a recording device for transient optical module failures, the device comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the processor for performing the recording method for transient optical module failures in the first aspect.

[0016] Thirdly, the present invention also provides a non-volatile computer storage medium storing computer-executable instructions that are executed by one or more processors to perform the recording method for transient optical module failures described in the first aspect.

[0017] Compared with existing technologies, the advantages of this invention are as follows: the comparator directly compares the instantaneous monitoring parameters with the preset threshold. This process is a pure hardware-level operation, which can realize the real-time identification of instantaneous faults. When an instantaneous fault occurs, the analog-to-digital converter is immediately triggered to perform instantaneous sampling, which can realize the precise locking of the moment of occurrence of the instantaneous fault. The subsequent non-volatile storage can realize the on-site solidification of the instantaneous fault, thereby supporting direct query and location after returning to the factory, avoiding repeated reproduction and debugging of low-probability instantaneous faults, and significantly reducing the time and labor costs of fault diagnosis. Attached Figure Description

[0018] To more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings used in the embodiments of the present invention will be briefly described below. Obviously, the drawings described below are merely some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without any creative effort.

[0019] Figure 1 This is a flowchart of a common sampling method provided in an embodiment of the present invention; Figure 2 This is a flowchart illustrating a method for recording instantaneous faults of an optical module provided in an embodiment of the present invention; Figure 3 This is a flowchart of the instantaneous sampling method in a method for recording instantaneous faults of an optical module provided in an embodiment of the present invention; Figure 4 This is a flowchart of a non-volatile storage method in a method for recording transient optical module faults provided in an embodiment of the present invention; Figure 5 This is a flowchart of a method for determining whether to perform non-volatile storage in a method for recording transient optical module faults provided in an embodiment of the present invention; Figure 6 This is a storage architecture diagram of a method for recording transient optical module failures provided in an embodiment of the present invention; Figure 7 This is a flowchart of a method for recording instantaneous faults of an optical module provided in an embodiment of the present invention; Figure 8 This is a flowchart of the instantaneous sampling method in a method for recording instantaneous faults of an optical module provided in an embodiment of the present invention; Figure 9 This is a flowchart of the non-volatile storage in a method for recording transient failures of an optical module provided in an embodiment of the present invention; Figure 10 This is a flowchart illustrating the process of determining whether to perform non-volatile storage in a method for recording transient optical module faults provided in an embodiment of the present invention. Figure 11 This is a schematic diagram of a recording device for instantaneous optical module failure provided in an embodiment of the present invention. Detailed Implementation

[0020] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention.

[0021] Unless the context otherwise requires, throughout the specification and claims, the term "comprising" is interpreted as openly inclusive, meaning "including, but not limited to." In the description of the specification, terms such as "one embodiment," "some embodiments," "exemplary embodiment," "example," "specific example," or "some examples" are intended to indicate that a particular feature, structure, material, or characteristic associated with that embodiment or example is included in at least one embodiment or example of this disclosure. The illustrative representations of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics mentioned may be included in any suitable manner in any one or more embodiments or examples; that is, although they may be incorporated into embodiments or examples using the above terms for reasons such as order and position, it does not limit them to be incorporated in combination by a single embodiment or example.

[0022] In the description of this invention, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, a feature defined with "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of embodiments of this disclosure, unless otherwise stated, "a plurality of" means two or more. Furthermore, for example, the description may use the prefix "A" or "B" to describe the same type of nouns as two independent entities. In this case, the corresponding features defined with "A" and "B" are used only to distinguish between similar entities and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features.

[0023] In the description of this invention, the expression “A and / or B” (where A and B are used to formally represent specific features) will be used. The corresponding expression includes the following three combinations: only A, only B, and a combination of A and B.

[0024] As used in this invention, “about,” “approximately,” or “approximately” includes the stated value and the average value within an acceptable range of deviation from a particular value, wherein the acceptable range of deviation is determined by a person skilled in the art taking into account the measurement under discussion and the error associated with the measurement of the particular quantity (i.e., the limitations of the measurement system).

[0025] Furthermore, the technical features involved in the various embodiments of the present invention described below can be combined with each other as long as they do not conflict with each other.

[0026] Example 1: like Figure 2 As shown, Embodiment 1 of the present invention provides a method for recording transient faults of an optical module, which specifically includes the following steps: Step 101: Use an analog-to-digital converter to perform routine sampling of the optical module's routine monitoring parameters at a preset period.

[0027] Among them, ordinary monitoring parameters refer to the monitoring parameters that are polled and reported to the host, such as temperature, power supply voltage, received optical power and transmitted optical power.

[0028] Specifically, an analog-to-digital converter (ADC) is used to sample the common monitoring parameters of the optical module at a preset period, obtaining the sampled values ​​of these parameters. These sampled values ​​are then converted into digital values, compared with a preset threshold to determine the alarm status, and stored along with the alarm flag in a designated storage area of ​​the MCU. The host computer can access this designated storage area to retrieve the digital values ​​and alarm flag. The preset period is typically in the hundreds of milliseconds range. The designated storage area for the MCU is a volatile register.

[0029] Alarm status can be represented by 0 and 1. 0 indicates that no fault occurred during the current normal sampling, and 1 indicates that a fault occurred during the current normal sampling.

[0030] Step 102: Continuously monitor the instantaneous monitoring parameters of the optical module; when an instantaneous fault is detected, trigger the analog-to-digital converter to sample the instantaneous monitoring parameters instantaneously and store them non-volatilely.

[0031] In one embodiment, a capture unit is used to continuously monitor the instantaneous monitoring parameters of the optical module. The capture unit can be a comparator or other device. The following description uses the capture unit as a comparator.

[0032] The analog-to-digital converter used for both normal sampling and instantaneous sampling is the same.

[0033] Instantaneous monitoring parameters refer to monitoring parameters that are abnormal and recover rapidly within a short period of time, such as power supply voltage and APD high voltage. Because there is a large time blind zone (on the order of hundreds of milliseconds) between two normal samplings, while instantaneous faults such as a small instantaneous drop in power supply voltage followed by rapid recovery, an abnormal instantaneous drop in transmitted optical power followed by rapid recovery, and an abnormal instantaneous recovery of APD high voltage last only on the order of microseconds to milliseconds, these instantaneous faults may occur precisely between two normal samplings, leading to missed detection.

[0034] In practical operation, instantaneous monitoring parameters are continuously and in real-time input to the comparator. The comparator compares the instantaneous monitoring parameters with preset thresholds and determines whether there is an anomaly based on the comparison result. If an anomaly is found, it indicates that a transient fault has occurred. This process is purely hardware-level computation, enabling real-time detection of transient faults. Once a transient fault occurs, the analog-to-digital converter is immediately activated to sample the corresponding instantaneous monitoring parameters.

[0035] Since there are usually multiple instantaneous monitoring parameters to be monitored, the monitoring results corresponding to each instantaneous monitoring parameter are input into the programmable logic circuit, which performs an OR operation. As long as any instantaneous monitoring parameter is abnormal, instantaneous sampling is initiated.

[0036] It should be noted that the same monitoring parameter may be used for both regular and instantaneous monitoring. For example, power supply voltage is both a regular and instantaneous monitoring parameter. When the power supply voltage is abnormal for a short period of time and then recovers quickly, instantaneous sampling will be triggered to record this instantaneous fault.

[0037] In one embodiment, the comparator can be a comparator built into the MCU or a dedicated external comparator.

[0038] In one embodiment, the analog-to-digital converter (ADC) performing both instantaneous sampling and normal sampling is the same ADC. Since the period of normal sampling is on the order of hundreds of milliseconds, while the process of acquiring and converting normal sample values ​​by the ADC usually does not take hundreds of milliseconds, there is a certain idle period between two normal sampling operations. If instantaneous sampling is triggered during this period, the ADC can be directly invoked to perform instantaneous sampling.

[0039] In a preferred embodiment, instantaneous sampling and normal sampling can be performed independently using two analog-to-digital converters.

[0040] In this embodiment, the comparator directly compares the instantaneous monitoring parameters with a preset threshold. This process is a pure hardware-level operation, which can realize the real-time identification of instantaneous faults. When an instantaneous fault occurs, the analog-to-digital converter is immediately triggered to perform instantaneous sampling, which can accurately pinpoint the moment of occurrence of the instantaneous fault. Subsequent non-volatile storage can realize the on-site solidification of the instantaneous fault, thereby supporting direct query and location after returning to the factory, avoiding repeated reproduction and debugging of low-probability instantaneous faults, and significantly reducing the time and labor costs of fault diagnosis.

[0041] The method for recording transient faults of the optical module further includes: when a sampling conflict occurs between transient sampling and normal sampling, interrupting the normal sampling being performed by the analog-to-digital converter (ADC) and switching to transient sampling; after the transient sampling is completed, restarting normal sampling. In other words, transient sampling has higher priority than normal sampling. Normal sampling is performed by the ADC, and the ADC's execution process includes an acquisition process and a conversion process. If transient sampling is triggered while the ADC is performing the conversion process for normal sampling, the ADC will interrupt the ongoing conversion process and switch to transient sampling; after the transient sampling is completed, it will restart to complete the conversion process for normal sampling. That is, interrupting the normal sampling being performed by the ADC as described above refers to interrupting the conversion process for normal sampling.

[0042] The method for recording instantaneous faults of the optical module further includes triggering the analog-to-digital converter to instantaneously sample the instantaneous monitoring parameters, see [reference]. Figure 3 Triggering the analog-to-digital converter to perform instantaneous sampling specifically includes the following steps: Step 201: Use a comparator to quickly obtain the comparison results between the instantaneous monitoring parameters and the preset threshold.

[0043] In one implementation, each instantaneous monitoring parameter is independently connected to a comparator and compared with a preset threshold. The comparison result is 0 or 1. 0 indicates that the analog value corresponding to the instantaneous monitoring parameter is less than or equal to the preset threshold, meaning no instantaneous fault has occurred. 1 indicates that the analog value corresponding to the instantaneous monitoring parameter is greater than the comparator's preset threshold, meaning an instantaneous fault has occurred.

[0044] Step 202: Use programmable logic circuits to perform an OR operation on the comparison results of all comparators to obtain the output result.

[0045] Programmable logic circuits are a type of logic unit; in other embodiments, other types of logic units may also be used for logic comparisons.

[0046] Specifically, the programmable logic circuit performs an OR operation on the comparison results of all comparators. When any comparison result is 1, the programmable logic circuit outputs a high level, indicating that a momentary fault has occurred. Only when all comparison results are 0 will the programmable logic circuit output a low level, indicating that no momentary fault has occurred.

[0047] Step 203: If the output result is high, the analog-to-digital converter is triggered to perform instantaneous sampling and an instantaneous fault flag is set.

[0048] The transient fault flag is a general flag used to identify transient faults that have occurred within a preset period.

[0049] In one embodiment, there are multiple instantaneous monitoring parameters. Analog values ​​of each instantaneous monitoring parameter are collected to identify instantaneous faults. When non-volatile storage is subsequently performed, only the instantaneous sampling results corresponding to the first instantaneous fault are stored. Manufacturers can then locate the problem using the instantaneous sampling results.

[0050] Since user data and fault data share the same data storage area, simultaneous write / erase operations can lead to write overwriting and data loss. Fault data includes both instantaneous sampling results and their types; the design determines which area of ​​the data storage area stores which type of instantaneous sampling result. The method for recording instantaneous faults in the optical module also includes employing a storage architecture to implement non-volatile storage. This storage architecture includes a data cache area, a non-volatile data storage area, and a data identification area. (See [reference needed]). Figure 4Non-volatile storage includes the following steps: Step 301: Repeatedly determine whether the instantaneous fault flag is set.

[0051] Step 302: If the instantaneous fault flag is set, clear the instantaneous fault flag and store the instantaneous sampling results in the data buffer.

[0052] If the transient fault flag is not set, the normal sampling result will be updated to the optical module protocol interface register. The optical module protocol interface register is the standard data channel for interaction between the host and the optical module. The host can obtain the normal sampling result through the I²C interface to perceive the current operating status of the optical module in real time.

[0053] In one embodiment, the data buffer is a static random-access memory (SRAM).

[0054] Step 303: Determine whether the instantaneous fault corresponding to the instantaneous sampling result is the first occurrence. If it is the first occurrence, set the fault record flag in the data identification area so as to determine whether to store the instantaneous sampling result in the data storage area through the fault record flag, and then perform non-volatile storage.

[0055] If the instantaneous fault corresponding to the instantaneous sampling result is not the first occurrence, then there is no need to set a fault record flag.

[0056] It should be noted that all instantaneous sampling results are stored in the data buffer, but in order to reduce the frequency of data storage area erasure and rewriting, for the same type of instantaneous fault, only the first instantaneous sampling result is stored in the non-volatile data storage area.

[0057] In one implementation, the data storage area can be either Flash or EEPROM (Electrically Erasable Programmable Read-Only Memory) chip.

[0058] The method for recording transient faults of the optical module further includes determining whether to store the transient sampling results in the data storage area through a fault recording flag, and then performing non-volatile storage. (See [reference]). Figure 5 Determining whether to perform non-volatile storage involves the following steps: Step 401: Repeatedly check whether the fault record flag is set.

[0059] Step 402: If the fault record flag is set, clear the fault record flag, erase the data in the data storage area, and write the data in the data cache area into the data storage area.

[0060] Step 403: If the fault record flag is not set, proceed to the next cycle.

[0061] The data identification area of ​​the present invention is also configured with a write-to-be-written flag. After user data is written to the data cache area, the write-to-be-written flag of the data identification area is set; the write-to-be-written flag and / or the fault record flag are cyclically determined; if the write-to-be-written flag and / or the fault record flag are set, the write-to-be-written flag and / or the fault record flag are cleared, the data in the data storage area is erased, and the data in the data cache area is written to the data storage area.

[0062] Writing data from the data cache to the data storage area means writing all the data from the data cache to the data storage area.

[0063] In one embodiment, the data buffer contains user data and fault data. Regardless of whether the write flag or the fault record flag is set, all data (user data and fault data) in the data buffer is read and written to the data storage area.

[0064] In one implementation, if the instantaneous sampling result of the same type of transient fault is updated, the new instantaneous sampling result is written to the data buffer to overwrite the old instantaneous sampling result, but no fault record flag is set. That is, for a transient fault of the same type that already has a record, the subsequent new instantaneous sampling result will not be written to the data storage area.

[0065] In one embodiment, the present invention divides a single physical page of a data storage area into a first data block and a second data block; wherein the first data block is used to store user data; the second data block is used to store fault data; and the first data block and the second data block have fixed address boundaries within the physical page.

[0066] See Figure 6 The storage architecture includes a data storage area, a data cache area, a data write area, and a data flag area. The data storage area is physically partitioned into a first data block for storing user data and a second data block for storing instantaneous sampling results. The data cache area and the data write area are divided by logical addresses. The data cache area is divided into a user-dedicated cache area and a fault-dedicated cache area, and the data write area is divided into a user-dedicated write area and a fault-dedicated write area.

[0067] The user-dedicated write area and the fault-dedicated write area serve as intermediate buffers. During operation, data from the user-dedicated buffer area is copied to the user-dedicated write area, and data from the fault-dedicated buffer area is copied to the fault-dedicated write area. After erasing the data in the data storage area, the data from both the user-dedicated write area and the fault-dedicated write area are written to the data storage area as a whole.

[0068] For user data and fault data, this invention can perform non-volatile storage with only a single erase and a single write operation, significantly shortening the overall operation time. It can control the entire process within a short time (e.g., 40ms), thereby meeting the timing requirement that the data storage area write time is less than 40ms in certain scenarios.

[0069] The overall flow of the method for recording transient optical module faults provided by this invention is as follows: Figure 7 As shown, specifically: monitoring parameters are divided into ordinary monitoring parameters and instantaneous monitoring parameters. On one hand, an analog-to-digital converter is used to sample the ordinary monitoring parameters of the optical module at a preset period. On the other hand, a comparator is used to continuously monitor the instantaneous monitoring parameters of the optical module. A programmable logic circuit (i.e., an optional type of logic unit) is used to perform an OR operation on the comparison results of all comparators to obtain the output result. If the output result is high, instantaneous sampling is triggered. Subsequently, data processing and storage are performed through a data processing unit and a data storage unit. The ordinary sampling results and instantaneous sampling results are stored in the optical module protocol interface register. In addition, the instantaneous sampling results are also stored non-volatilely.

[0070] The comparator can be an MCU comparator, and the programmable logic circuit can be an MCU programmable logic circuit, such as... Figure 8 As shown, the instantaneous monitoring parameters are compared with preset thresholds using MCU comparators to quickly obtain the comparison results. The comparison results of all comparators are input into the MCU programmable logic circuit, which performs an OR operation on the output results of all comparators. When the output result of the programmable logic circuit is high, it indicates a signal abnormality. At this time, the MCU is interrupted, triggering the analog-to-digital converter to sample the instantaneous monitoring parameters.

[0071] like Figure 9 As shown, the non-volatile storage using the storage architecture specifically involves: cyclically checking whether the transient fault flag is set; if the transient fault flag is set, clearing the transient fault flag and storing the transient sampling result in the data buffer; determining whether the transient fault corresponding to the transient sampling result is the first occurrence; if it is the first occurrence, setting the fault record flag in the data identifier area and entering the data storage node; if it is not the first occurrence, directly entering the data storage node. If the transient fault flag is not set, updating the ordinary sampling result to the optical module protocol interface register.

[0072] After user data is written to the data cache, the write-pending flag in the data identifier area is set. For example... Figure 10 As shown, determining whether to perform non-volatile storage involves: cyclically checking whether the write-to-be-written flag and / or fault record flag are set; if the write-to-be-written flag and / or fault record flag are set, then clearing the write-to-be-written flag and / or fault record flag, copying the data from the user-dedicated cache to the user-dedicated write area, copying the data from the fault-dedicated cache to the fault-dedicated write area, erasing the data in the data storage area, and writing the data from the user-dedicated write area and the data from the fault-dedicated write area together into the data storage area.

[0073] In summary, the method provided by this invention has the following specific effects: This invention can record and store instantaneous faults generated by the optical module, facilitating subsequent problem localization. This invention utilizes the comparator and programmable logic circuit of the MCU to record and store multiple concurrent instantaneous faults. This invention can store and record faults in specific application scenarios of optical modules where the optical module passively receives data from the host and ensures that the storage time is less than 40ms.

[0074] Example 2: Based on the method for recording transient optical module faults provided in the foregoing embodiments, the present invention also provides a device for recording transient optical module faults that can be used to implement the above method, such as... Figure 11 The diagram shown is a schematic representation of the device architecture according to an embodiment of the present invention. The recording device for transient optical module failures in this embodiment includes one or more processors 21 and a memory 22. Figure 11 Take a processor 21 as an example.

[0075] Processor 21 and memory 22 can be connected via a bus or other means. Figure 11 Taking the example of a connection between China and Israel via a bus.

[0076] The memory 22 serves as a non-volatile computer-readable storage medium for recording a transient optical module fault, and can be used to store non-volatile software programs and non-volatile computer-executable programs, such as the method for recording transient optical module faults in the foregoing embodiments. The processor 21 executes various functional applications and data processing of the recording device for transient optical module faults by running the non-volatile software programs, instructions, and modules stored in the memory 22, thereby implementing the method for recording transient optical module faults in the foregoing embodiments.

[0077] Memory 22 may include high-speed random access memory, and may also include non-volatile memory, such as at least one disk storage device, flash memory device, or other non-volatile solid-state storage device. In some embodiments, memory 22 may include memory remotely located relative to processor 21, which may be connected to processor 21 via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.

[0078] The program instructions / modules are stored in memory 22 and, when executed by one or more processors 21, execute the method for recording transient failures of the optical module in the aforementioned embodiment.

[0079] This invention also provides a non-volatile computer storage medium storing computer-executable instructions that are executed by one or more processors, for example... Figure 11 One of the processors 21 enables the one or more processors to execute the recording method for transient optical module failures in the foregoing embodiments.

[0080] It is worth noting that the information interaction and execution process between the modules and units in the above-mentioned device and system are based on the same concept as the processing method embodiment of the present invention. For details, please refer to the description in the method embodiment of the present invention, and will not be repeated here.

[0081] Those skilled in the art will understand that all or part of the steps in the various methods of the embodiments can be implemented by a program instructing related hardware. The program can be stored in a computer-readable storage medium, which may include: read-only memory (ROM), random access memory (RAM), disk or optical disk, etc.

[0082] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, and improvements 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 recording transient faults in an optical module, characterized in that, include: The common monitoring parameters of the optical module are sampled at a preset period using an analog-to-digital converter. Continuously monitor the instantaneous monitoring parameters of the optical module; When a transient fault is detected, the analog-to-digital converter is triggered to sample the transient monitoring parameters and store them non-volatilely.

2. The method for recording instantaneous faults of an optical module according to claim 1, characterized in that, The method further includes: When a sampling conflict occurs between instantaneous sampling and normal sampling, the normal sampling being performed by the analog-to-digital converter is interrupted, and instantaneous sampling is performed instead. After the instantaneous sampling is completed, normal sampling is restarted.

3. The method for recording transient optical module faults according to claim 1, characterized in that, The method further includes: Use a comparator to quickly obtain the comparison results between instantaneous monitoring parameters and preset thresholds; The comparison results of all comparators are ORed using programmable logic circuits to obtain the output result. If the output is high, the analog-to-digital converter is triggered to perform instantaneous sampling and set an instantaneous fault flag.

4. The method for recording transient optical module faults according to claim 3, characterized in that, The storage architecture includes a data cache, a non-volatile data storage area, and a data identification area; The method further includes: The system continuously checks whether the instantaneous fault flag has been set. If the transient fault flag is set, clear the transient fault flag and store the transient sampling results in the data buffer area; Determine whether the instantaneous fault corresponding to the instantaneous sampling result is the first occurrence. If it is the first occurrence, set a fault record flag in the data identification area so as to determine whether to store the instantaneous sampling result in the data storage area through the fault record flag, and then perform non-volatile storage.

5. The method for recording transient optical module faults according to claim 3, characterized in that, The method further includes: If the instantaneous fault corresponding to the instantaneous sampling result is not the first occurrence, then there is no need to set a fault record flag.

6. The method for recording transient optical module faults according to claim 4, characterized in that, The method further includes: The system continuously checks whether the fault record flag has been set. If the fault record flag is set, then clear the fault record flag, erase the data in the data storage area, and write the data in the data cache area into the data storage area; If the fault record flag is not set, proceed to the next cycle.

7. The method for recording transient optical module faults according to claim 6, characterized in that, The data identification area is also configured with a write-to-be-written flag, and user data and fault data share the same data storage area; the method further includes: After user data is written to the data cache area, the write-pending flag of the data identifier area is set; The system continuously checks whether the write-to-be-written flag and / or the fault record flag are set. If the write-to-be-written flag and / or fault record flag are set, then the write-to-be-written flag and / or fault record flag are cleared, the data in the data storage area is erased, and the data in the data cache area is written to the data storage area.

8. The method for recording transient optical module faults according to claim 7, characterized in that, The method further includes: A single physical page of the data storage area is divided into a first data block and a second data block; wherein the first data block is used to store user data; the second data block is used to store fault data; the first data block and the second data block have fixed address boundaries within the physical page.

9. A recording device for transient optical module failure, characterized in that, include: At least one processor; And a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the processor for performing the recording method for instantaneous optical module failure as described in any one of claims 1-8.

10. A non-volatile computer storage medium, characterized in that, The computer storage medium stores computer-executable instructions, which are executed by one or more processors to perform the recording method for instantaneous optical module failures as described in any one of claims 1-8.