Optical fiber port detection method, device, electronic device and storage medium

By combining the hardware and software of the optical cross detection device, accurate detection of the optical fiber port status is achieved, solving the problem of inaccurate optical cross box detection in the prior art, and improving the recognition rate and system scalability.

CN115728873BActive Publication Date: 2025-10-03CHINA TELECOM CORP LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211521011.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-11-30
Publication Date
2025-10-03
Estimated Expiration
2042-11-30

AI Technical Summary

Technical Problem

Existing optical cross-connect boxes cannot accurately detect the status of fiber ports, especially in the case of chaotic wiring. The recognition rate is low and it is easy to misjudge "falsely occupied" ports, resulting in increased performance overhead.

Method used

An optical intersection detection device is used, including a data collector, a detection terminal and a web server. The detection terminal contains a detection sensor and an electronic tag. The hardware detects the occupancy status of the optical fiber interface and records the port location information. Combined with software recording and displaying the port status table, the accuracy and robustness of port detection are achieved.

Benefits of technology

The accuracy and robustness of optical fiber port detection are improved, misjudgment is reduced, detection complexity is reduced, and the scalability of the system is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115728873B_ABST
    Figure CN115728873B_ABST
Patent Text Reader

Abstract

An embodiment of the present invention provides a method, device, electronic device and storage medium for detecting an optical fiber port, the method comprising: the data collector acquiring a port status identifier transmitted by the detection terminal and port location information corresponding to the electronic tag, the port status identifier being a signal generated by the detection sensor according to whether the optical fiber interface on the optical cross-box is occupied; the web server receiving the port status identifier and port location information corresponding to each optical fiber interface sent by the data collector from the starting time point of the current recording cycle, and writing the port status identifier and port location information corresponding to each optical fiber interface into a port status table corresponding to the optical cross-box at the end time point of the current recording cycle, and recording the time period corresponding to the current recording cycle.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of electronic communication technology, and in particular to a method for detecting an optical fiber port, an optical intersection detection device, an electronic device, and a computer-readable storage medium. Background Art

[0002] Optical cable junction boxes (OCBs), also commonly known as street cabinets, are generally placed on trunk optical cables and are used for the connection, distribution, and scheduling of trunk optical cables and distribution optical cables in communication networks for communication systems, power systems, traffic control systems, and cable TV systems. Existing OCBs are generally passive systems, meaning it is impossible to directly apply measurement and control circuits to the OCBs to detect the status of their optical fiber ports. Instead, the OCBs can only be used to take photos of the optical fiber interfaces of the OCBs and use corresponding image recognition technology to determine whether the optical ports are occupied. However, while this process is technically easy to implement, it is easily limited by usage scenarios. For example, for ports with simple wiring, the recognition rate is high, but for ports with chaotic wiring, the recognition accuracy is greatly reduced, and adjusting parameters cannot effectively improve the recognition accuracy. At the same time, due to the fact that ports that should not be plugged in have optical fibers plugged in or inserted improperly during construction operations, "falsely occupied" ports are often misjudged as occupied, increasing the performance overhead of the OCBs and port occupancy. Summary of the Invention

[0003] The embodiments of the present invention provide a method, device, electronic device, and computer-readable storage medium for detecting optical fiber ports to solve or partially solve the problems of inaccurate detection, poor robustness, and poor scalability of the detection method during optical fiber port detection on an optical cross-connect box.

[0004] An embodiment of the present invention discloses a method for detecting an optical fiber port, which is applied to an optical intersection detection device. The optical intersection detection device includes at least a data collector, a detection terminal communicatively connected to the data collector, and a web server. The detection terminal includes a detection sensor and an electronic tag associated with the detection sensor. Each electronic tag is bound to an optical fiber interface on an optical cross-connect box. The method includes:

[0005] The data collector obtains the port status identifier transmitted by the detection terminal and the port position information corresponding to the electronic tag, wherein the port status identifier is a signal generated by the detection sensor according to whether the optical fiber interface on the optical cross-connect box is occupied;

[0006] The web server receives the port status identifiers and port location information corresponding to each of the optical fiber interfaces sent by the data collector from the starting time point of the current recording cycle, and writes the port status identifiers and port location information corresponding to each of the optical fiber interfaces into the port status table corresponding to the optical cross-connect box at the end time point of the current recording cycle, and records the time period corresponding to the current recording cycle.

[0007] Optionally, the web server runs a Django web application, the Django web application provides a status data interface, the optical intersection detection device further includes a resource orchestration system communicatively connected to the web server, and the method further includes:

[0008] The resource orchestration system obtains the port status table through the status data interface and displays the port status table.

[0009] Optionally, the Django web application further provides a start / stop interface, and the method further includes:

[0010] The resource orchestration system sends a start / stop instruction for the data collector to the web server through the start / stop interface, wherein the start / stop instruction includes an enable instruction or a disable instruction;

[0011] The web server transmits the port status table to the resource orchestration system according to the enable instruction, or stops transmitting the port status table to the resource orchestration system according to the disable instruction.

[0012] Optionally, before acquiring, by the data collector, the port status identifier transmitted by the detection terminal and the port location information corresponding to the electronic tag, the method further includes:

[0013] The detection sensor generates an occupancy status signal for indicating that the optical fiber port is occupied in response to the optical fiber crystal head being inserted into the optical fiber port corresponding to the optical cross-connect box;

[0014] Or, when it is not detected that the optical fiber crystal plug is inserted into the optical fiber port corresponding to the optical cross-connect box, an unoccupied state signal is generated to indicate that the optical fiber interface is not occupied.

[0015] Optionally, the detection terminal further includes an LED light communicatively connected to the detection sensor, and the method further includes:

[0016] In response to acquiring the occupancy status signal, the LED lamp outputs a high level signal corresponding to the occupancy status signal;

[0017] Alternatively, when the LED lamp continuously obtains the unoccupied state signal for a period greater than or equal to a preset threshold, a low-level signal corresponding to the unoccupied state signal is output.

[0018] Optionally, the data collector acquires the port status identifier transmitted by the detection terminal and the port location information corresponding to the electronic tag, including:

[0019] In response to receiving the high-level signal, the data collector generates a port occupation identifier corresponding to the high-level signal, determines a first electronic tag to which the high-level signal belongs, and obtains first port location information corresponding to the first electronic tag;

[0020] And / or, in response to receiving the low-level signal, the data collector generates a port unoccupied identifier corresponding to the low-level signal, determines the second electronic tag to which the low-level signal belongs, and obtains the second port location information corresponding to the second electronic tag.

[0021] Optionally, the data collector includes a communication module, and the method further includes:

[0022] The communication module packages the port status identifier and port location information corresponding to each of the optical fiber ports into a Json format and transmits the package to the web server.

[0023] The embodiment of the present invention further discloses an optical intersection detection device, which includes at least a data collector, a detection terminal connected to the data collector, and a web server. The detection terminal includes a detection sensor and an electronic tag associated with the detection sensor. Each electronic tag is bound to an optical fiber interface on an optical cross-connect box; wherein,

[0024] The data collector is used to obtain the port status identifier transmitted by the detection terminal and the port position information corresponding to the electronic tag, wherein the port status identifier is a signal generated by the detection sensor according to whether the optical fiber interface on the optical cross-connect box is occupied;

[0025] The web server is used to receive the port status identifiers and port location information corresponding to each of the optical fiber interfaces sent by the data collector from the starting time point of the current recording cycle, and write the port status identifiers and port location information corresponding to each of the optical fiber interfaces into the port status table corresponding to the optical cross-connect box at the end time point of the current recording cycle, and record the time period corresponding to the current recording cycle.

[0026] Optionally, the web server runs a Django web application, the Django web application provides a state data interface, and the optical intersection detection device further includes a resource orchestration system in communication with the web server; wherein,

[0027] The resource orchestration system is used to obtain the port status table through the status data interface and display the port status table.

[0028] Optionally, the Django web application also provides a start / stop interface; wherein,

[0029] The resource orchestration system is further configured to send a start / stop instruction for the data collector to the web server via the start / stop interface, wherein the start / stop instruction includes an enable instruction or a disable instruction;

[0030] The web server is configured to transmit the port status table to the resource orchestration system according to the enable instruction, or stop transmitting the port status table to the resource orchestration system according to the disable instruction.

[0031] Optionally, the detection sensor is used to generate an occupied status signal indicating that the optical fiber port is occupied in response to the insertion of an optical fiber crystal head into the optical fiber port corresponding to the optical cross-box; or, when no optical fiber crystal head is detected to be inserted into the optical fiber port corresponding to the optical cross-box, generate an unoccupied status signal indicating that the optical fiber interface is not occupied.

[0032] Optionally, the detection terminal further includes an LED light that is communicatively connected to the detection sensor; wherein,

[0033] The LED lamp is used to output a high-level signal corresponding to the occupied status signal in response to obtaining the occupied status signal; or, when the LED lamp continuously obtains the unoccupied status signal for a time period greater than or equal to a preset threshold, output a low-level signal corresponding to the unoccupied status signal.

[0034] Optionally, the data collector is specifically used to generate a port occupied identifier corresponding to the high-level signal in response to receiving the high-level signal, and determine the first electronic tag to which the high-level signal belongs, and obtain the first port location information corresponding to the first electronic tag; and / or, the data collector is used to generate a port unoccupied identifier corresponding to the low-level signal in response to receiving the low-level signal, and determine the second electronic tag to which the low-level signal belongs, and obtain the second port location information corresponding to the second electronic tag.

[0035] Optionally, the data collector includes a communication module; wherein,

[0036] The communication module is used to package the port status identifier and port location information corresponding to each of the optical fiber ports into a Json format and transmit the package to the web server.

[0037] An embodiment of the present invention further discloses an electronic device, comprising a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other via the communication bus;

[0038] The memory is used to store computer programs;

[0039] The processor is configured to implement the method described in the embodiment of the present invention when executing the program stored in the memory.

[0040] An embodiment of the present invention further discloses a computer-readable storage medium having instructions stored thereon. When executed by one or more processors, the processors are enabled to execute the method according to the embodiment of the present invention.

[0041] The embodiments of the present invention include the following advantages:

[0042] In an embodiment of the present invention, it can be applied to an optical cross-detection device, which may include a data collector, a detection terminal connected to the data collector for communication, and a web server. The detection terminal includes a detection sensor and an electronic tag associated with the detection sensor. Each electronic tag is bound to an optical fiber interface on the optical cross-box. In the process of detecting the optical fiber port of the optical cross-box, the data collector of the optical cross-detection device can obtain the port status identifier transmitted by the detection terminal and the port position information corresponding to the electronic tag. The port status identifier is a signal generated by the detection sensor according to whether the optical fiber interface on the optical cross-box is occupied. Accordingly, the web server can receive the port status identifiers corresponding to each optical fiber interface sent by the data collector from the starting time point of the current recording period. And the port position information, and at the end time of the current recording cycle, the port status identifier and port position information corresponding to each optical fiber interface are written into the port status table corresponding to the optical cross-box and the time period corresponding to the current recording cycle is recorded. Through the cooperation between hardware and software, a hardware-based data collector is implemented to detect the optical fiber port of the optical cross-box, and based on the software-based data recording, on the one hand, based on the correspondence between "optical fiber port-detection terminal-electronic label", the optical fiber port is detected from the source, which can effectively detect the occupancy of the optical fiber port and ensure the accuracy of the port detection. On the other hand, the detection method of hardware and software can detect the optical fiber port without complex algorithms, which improves the robustness and scalability of the detection method. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] Figure 1This is a flowchart of a method for detecting an optical fiber port provided in an embodiment of the present invention;

[0044] Figure 2 1 is a structural diagram of a data collector provided in an embodiment of the present invention;

[0045] Figure 3 1 is a schematic structural diagram of an optical intersection detection device provided in an embodiment of the present invention;

[0046] Figure 4 is a schematic diagram of the principle of the sensor module provided in an embodiment of the present invention;

[0047] Figure 5 is a schematic diagram of a working circuit of an electronic tag provided in an embodiment of the present invention;

[0048] Figure 6 is a schematic diagram of a working circuit of an electronic tag provided in an embodiment of the present invention;

[0049] Figure 7 is a schematic diagram of data interaction provided in an embodiment of the present invention;

[0050] Figure 8 is a structural block diagram of an optical intersection detection device provided in an embodiment of the present invention;

[0051] Figure 9 This is a block diagram of an electronic device provided in an embodiment of the present invention. DETAILED DESCRIPTION

[0052] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.

[0053] As an example, given that the existing optical cross-box is a passive system, it is impossible to directly apply measurement and control circuits to the optical cross-box, resulting in the inability to collect the optical fiber port status electrical signal. It is technically easy to take pictures of the optical cross-box port and then use AI (artificial intelligence) recognition technology to determine whether the optical fiber port is occupied. The recognition rate is high for ports with simple wiring, but the accuracy of recognition using this method will be greatly reduced when encountering ports with chaotic wiring. Adjusting parameters may not necessarily improve the accuracy of recognition. At the same time, due to the insertion of ports that should not be inserted with optical fibers or the improper insertion during construction operations, "falsely occupied" ports are often misjudged as occupied.

[0054] In this regard, one of the core invention points of the present invention is to construct an optical cross-box detection device for optical cross-boxes. The device may include a data collector, a detection terminal connected to the data collector for communication, and a web server. The detection terminal includes a detection sensor and an electronic tag associated with the detection sensor. Each electronic tag is bound to the optical fiber interface on the optical cross-box. In the process of detecting the optical fiber port of the optical cross-box, the data collector of the optical cross-box detection device can obtain the port status identifier transmitted by the detection terminal and the port position information corresponding to the electronic tag. The port status identifier is a signal generated by the detection sensor according to whether the optical fiber interface on the optical cross-box is occupied. Accordingly, the web server can receive the port status information corresponding to each optical fiber interface sent by the data collector from the starting time point of the current recording period. The port status identification and port location information are stored in the data logger, and at the end time of the current recording cycle, the port status identification and port location information corresponding to each optical fiber interface are written into the port status table corresponding to the optical cross-box, and the time period corresponding to the current recording cycle is recorded. Through the cooperation between hardware and software, a hardware-based data collector is used to detect the optical fiber port of the optical cross-box, and data recording is performed based on software. On the one hand, based on the correspondence between "optical fiber port-detection terminal-electronic tag", the optical fiber port is detected from the source, which can effectively detect the occupancy of the optical fiber port and ensure the accuracy of the port detection. On the other hand, the detection method of hardware and software can detect the optical fiber port without complex algorithms, which improves the robustness and scalability of the detection method.

[0055] Reference Figure 1 , shows a flowchart of the steps of a method for detecting an optical fiber port provided in an embodiment of the present invention, which is applied to an optical intersection detection device, wherein the optical intersection detection device includes at least a data collector, a detection terminal communicatively connected to the data collector, and a web server, wherein the detection terminal includes a detection sensor and an electronic tag associated with the detection sensor, and each electronic tag is bound to an optical fiber interface on an optical cross-connect box. Specifically, the method may include the following steps:

[0056] Step 101: The data collector obtains the port status identifier transmitted by the detection terminal and the port position information corresponding to the electronic tag, wherein the port status identifier is a signal generated by the detection sensor according to whether the optical fiber interface on the optical cross-connect box is occupied;

[0057] In an embodiment of the present invention, the optical cross-connection detection device may at least include a data collector, a detection terminal communicatively connected to the data collector, and a web server, wherein the data collector can detect the occupancy of the optical fiber port on the optical cross-connection box through the detection terminal, and generate status information corresponding to the optical fiber port to indicate whether the optical fiber interface is occupied; the detection terminal can be externally connected to the data collector, and multiple detection terminals can be led out from the data collector through corresponding expansion slots and cables, and the detection terminals can be directly placed on the side of each optical fiber port of the optical cross-connection box. When a corresponding optical fiber crystal head is inserted into the optical fiber port, the detection terminal can detect that the optical fiber port is occupied and output a corresponding signal; the web server can be a background data processing device, which can insert the data sent by the data collector into the corresponding MYSQL database table at a regular interval through the data acquisition and positioning task, so as to display the occupancy status of each optical fiber port of the optical cross-connection box in real time, so as to facilitate the timely management of the optical cross-connection box by the corresponding personnel.

[0058] Among them, for the data collector, it can be a Raspberry Pi development board, refer to Figure 2 , shows a schematic diagram of the structure of the data collector provided in an embodiment of the present invention. For a Raspberry Pi data collector, it can include at least dual-band WiFi / Bluetooth 5.0, a processor, a memory chip, a network card, a Poe (Power Over Ethernet) interface, an Ethernet port, a USB interface, a USB management chip, an audio interface, a camera interface, an HDMI (High Definition Multimedia Interface) interface, a power supply port, and a DSI (Digital-Speech Interpolation) display connector. The Raspberry Pi data collector can detect the status of the optical fiber port. Specifically, refer to Figure 3 , showing a structural schematic diagram of the optical cross detection device provided in an embodiment of the present invention, the optical cross box port detection module of the hardware part consists of a Raspberry Pi data collector (with a built-in Raspbian operating system, a small server similar to Debian) and an external detection terminal, wherein the detection terminal is mainly composed of a digital capacitive touch button sensor module (i.e., a detection sensor), an electronic tag, and an RGB primary color LED light. Multiple detection terminals can be led out from the collector through expansion slots and cables. The detection terminal is directly placed on the side of each optical fiber port. If a crystal head is inserted into the port, it will touch the sensor surface of the detection terminal (digital capacitive touch button sensor module), thereby triggering the high and low level changes of the LED light.

[0059] Optionally, refer to Figure 4, shows a schematic diagram of the principle of a sensor module provided in an embodiment of the present invention. For a digital capacitive touch button sensor module, it can be based on the TTP233. Under normal circumstances, the module outputs "LOW" and maintains low power consumption. If touch information is detected in the circular marked area of ​​the module, it outputs "HIGH" and switches to a fast response state. When the module is mounted on a non-metallic surface, if no touch information is detected for 12 seconds, it switches back to a low power state. The TTP233 is an integrated circuit for a touchpad detector and provides a touch button. The digital capacitive touch button sensor can sense when a finger is very close to the surface of an object (a few millimeters), thereby triggering a key press like a key. The digital capacitive touch button sensor can be used in any scenario where contact can be sensed without touching (very close). By placing the detection terminal directly on the corresponding optical fiber port, the use of the optical fiber port can be detected. At the same time, the position of the optical fiber port can be located in conjunction with the corresponding electronic tag. Based on the corresponding relationship between "optical fiber port-detection terminal-electronic tag", the optical fiber port can be detected from the source, effectively detecting the occupancy of the optical fiber port and ensuring the accuracy of port detection.

[0060] Specifically, the Raspberry Pi data collector collects the corresponding electrical signal data and can detect the location information of the optical fiber port of the optical cross-connect box through the electronic tag. In an example, assuming that the signal of the electronic chip is xx, such as Figure 5 、 6 As shown, it shows a schematic diagram of the working circuit of the electronic tag provided in the embodiment of the present invention, xx can be a 1024-bit The EEPROM chip consists of four memory pages, each with 256 bits. Data is first written to an 8-byte scratchpad and, after verification, copied to the EEPROM (Electrically Erasable Programmable Read-Only Memory) memory. Its unique feature is that the four memory pages are independent and can be individually configured for write protection or EPROM emulation mode, in which all bits can only change from 1 to 0. The xx communicates via a 1-Wire bus, using the Dallas Semiconductor standard 1-Wire protocol. Each device has a unique, unchangeable 64-bit ROM address code, which is laser-etched into the chip at the factory. This address code is used to address the device in a multi-drop 1-Wire network. The xx can contain 1024 bits of EEPROM, with a user-readable and writable 8-byte register / control page of up to 7 bytes, and integrates a full-featured 1-Wire interface in a single chip. Each xx has a 64-bit ROM address code laser-etched into the chip at the factory to ensure absolute traceability. Data is transferred serially using the 1-Wire protocol, requiring only a single data line and a ground return. The xx can have an additional storage area called a scratchpad, which serves as a buffer when writing data to main memory or register pages. Data is first written to the scratchpad and can be read back from there. After verification, the CopyScratchpad command transfers the data to the final memory location.

[0061] Based on the above structure, when an optical cross-connection detection device is used to detect the occupancy of the optical fiber port of the optical cross-connection box, the detection sensor in the optical cross-connection detection device can generate an occupied state signal indicating that the optical fiber port is occupied in response to the insertion of an optical fiber connector into the optical fiber port corresponding to the optical cross-connection box; or, if the insertion of an optical fiber connector into the optical fiber port corresponding to the optical cross-connection box is not detected, generate an unoccupied state signal indicating that the optical fiber interface is unoccupied. At the same time, because the detection sensor is connected to a corresponding LED light, the LED light outputs a high-level signal corresponding to the occupied state signal in response to obtaining the occupied state signal; or, if the LED light continuously obtains the unoccupied state signal for a period greater than or equal to a preset threshold, it outputs a low-level signal corresponding to the unoccupied state signal. Accordingly, the data collector can generate a port occupied identifier corresponding to the high-level signal in response to receiving a high-level signal, determine the first electronic tag to which the high-level signal belongs, and obtain the first port position information corresponding to the first electronic tag in response to receiving a low-level signal; and / or, the data collector can generate a port unoccupied identifier corresponding to the low-level signal in response to receiving a low-level signal, determine the second electronic tag to which the low-level signal belongs, and obtain the second port position information corresponding to the second electronic tag, thereby detecting the optical fiber port from the source based on the correspondence between "optical fiber port-detection terminal-electronic tag", effectively detecting the occupancy of the optical fiber port, and ensuring the accuracy of the port detection.

[0062] After the data collector collects the status information corresponding to each optical fiber port of the optical cross-connect box, it can package the port status identification and port location information corresponding to each optical fiber port into Json format through the corresponding communication module and transmit it to the web server so that the web server can record the corresponding data in the corresponding background database for archiving.

[0063] Step 102: the web server receives the port status identifier and port location information corresponding to each of the optical fiber interfaces sent by the data collector from the starting time point of the current recording cycle, and writes the port status identifier and port location information corresponding to each of the optical fiber interfaces into the port status table corresponding to the optical cross-connect box at the end time point of the current recording cycle, and records the time period corresponding to the current recording cycle.

[0064] In an embodiment of the present invention, the web server may be configured with a corresponding data acquisition timing task to periodically obtain the port occupancy data corresponding to the optical cross-box transmitted by the data collector, and write the port occupancy data into the corresponding port status table, so as to monitor the status of the optical ports in the optical cross-box in real time. Specifically, the web server receives the port status identifier and port location information corresponding to each optical fiber interface sent by the data collector from the starting time point of the current recording cycle, and writes the port status identifier and port location information corresponding to each optical fiber interface into the port status table corresponding to the optical cross-box and records the time period corresponding to the current recording cycle at the end time point of the current recording cycle, thereby facilitating the subsequent tracing of the port occupancy status of the optical cross-box by recording the port status corresponding to the optical cross-box and the corresponding time period.

[0065] In addition, a Django web application can be run on the web server, and the Django web application provides a status data interface. The optical intersection detection device also includes a resource orchestration system that is communicatively connected to the web server. After the web server records the port occupancy data in the corresponding port status table, it can also send the port status table to the resource orchestration system through the status data interface. The resource orchestration system can obtain the port status table through the status data interface and display the port status table. At the same time, the Django web application can also provide a start-stop interface. The resource orchestration system also sends start-stop instructions for the data collector to the web server through the start-stop interface. The start-stop instructions include an enable instruction or a disable instruction, so that the web server transmits the port status table to the resource orchestration system according to the enable instruction, or stops transmitting the port status table to the resource orchestration system according to the disable instruction.

[0066] In the specific implementation, refer to Figure 7, showing a schematic diagram of the data interaction provided in an embodiment of the present invention. A corresponding Python socket program can be written in the Raspberry Pi data collector host as a communication module for data communication with the web server. This module has two functions: communication and data collection. The port status data and location information data collected by the detection terminal are combined and sent to the web server. The web server can insert this data into the MYSQL database table through a data collection timer task. At the same time, the Django web application running in the web server can connect to the corresponding database, thereby providing interface service capabilities to the resource orchestration system. The resource orchestration system can monitor the status of the optical fiber ports of the optical cross-connect box in real time. At the same time, during non-essential time periods, the resource orchestration system can remotely control the start and stop of the communication module in the Raspberry Pi system at the hardware layer through the start and stop capabilities provided by the Django web service in the software layer, thereby controlling the collection and transmission of remote data. This allows for flexible control of data collection and transmission at the remote detection terminal, reducing unnecessary resource consumption.

[0067] It should be noted that in the above process, the corresponding Django web application is configured on the web server through the Django framework, and the corresponding interface is provided to realize data interaction between the web server and the resource orchestration system, so as to display the occupancy status of the optical fiber port of the optical cross-connect box and control the data collection of the data collector. The detection method based on software and hardware can detect the optical fiber port without complex algorithms, which improves the robustness and scalability of the detection method.

[0068] In one example, detecting the occupancy status of an optical fiber port of an optical cross-connect box may specifically include:

[0069] Step 1: Insert the optical fiber crystal head into the port and contact the sensor surface of the detection terminal, triggering the level signal of the LED light to change from low to high, thereby indirectly determining whether the optical fiber port is occupied. The port location information is recorded by the electronic tag bound to the optical fiber and connected to the detection terminal.

[0070] Step 2: The socket communication module program developed in the Raspberry Pi data acquisition system packages the collected LED light level signal and the location information recorded by the electronic tag into JSON format and transmits it to the web server. The data acquisition scheduled task in the web server will insert the data into the background database table at intervals and record the corresponding time period.

[0071] Step 3: The Django web application running on the web server connects to the database and provides a status data interface to the resource orchestration system. This allows the resource orchestration system to monitor the status of each fiber port at different time periods, thus enabling automated detection of fiber port status in the optical cross-connect box. The Django web service also provides a start / stop interface. This interface allows the resource orchestration system to control the start / stop of the Raspberry Pi system's socket communication service during non-essential time periods, thereby stopping the transmission of port status data. This saves resources and reduces unnecessary system outages.

[0072] It should be noted that the embodiments of the present invention include but are not limited to the above examples. It is understandable that those skilled in the art can also make settings according to actual needs under the guidance of the ideas of the embodiments of the present invention, and the present invention does not limit this.

[0073] In an embodiment of the present invention, it can be applied to an optical cross-detection device, which may include a data collector, a detection terminal connected to the data collector for communication, and a web server. The detection terminal includes a detection sensor and an electronic tag associated with the detection sensor. Each electronic tag is bound to an optical fiber interface on the optical cross-box. In the process of detecting the optical fiber port of the optical cross-box, the data collector of the optical cross-detection device can obtain the port status identifier transmitted by the detection terminal and the port position information corresponding to the electronic tag. The port status identifier is a signal generated by the detection sensor according to whether the optical fiber interface on the optical cross-box is occupied. Accordingly, the web server can receive the port status identifiers corresponding to each optical fiber interface sent by the data collector from the starting time point of the current recording period. And the port position information, and at the end time of the current recording cycle, the port status identifier and port position information corresponding to each optical fiber interface are written into the port status table corresponding to the optical cross-box and the time period corresponding to the current recording cycle is recorded. Through the cooperation between hardware and software, a hardware-based data collector is implemented to detect the optical fiber port of the optical cross-box, and based on the software-based data recording, on the one hand, based on the correspondence between "optical fiber port-detection terminal-electronic label", the optical fiber port is detected from the source, which can effectively detect the occupancy of the optical fiber port and ensure the accuracy of the port detection. On the other hand, the detection method of hardware and software can detect the optical fiber port without complex algorithms, which improves the robustness and scalability of the detection method.

[0074] It should be noted that for the sake of simplicity, the method embodiments are described as a series of actions. However, those skilled in the art should be aware that the embodiments of the present invention are not limited by the order of the actions described, because according to the embodiments of the present invention, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in this specification are all preferred embodiments, and the actions involved are not necessarily required by the embodiments of the present invention.

[0075] Reference Figure 8 , shows a structural block diagram of an optical intersection detection device provided in an embodiment of the present invention, the optical intersection detection device at least includes a data collector, a detection terminal connected to the data collector for communication, and a web server, the detection terminal includes a detection sensor and an electronic tag associated with the detection sensor, each of the electronic tags is bound to the optical fiber interface on the optical cross box; wherein,

[0076] The data collector is used to obtain the port status identifier transmitted by the detection terminal and the port position information corresponding to the electronic tag, wherein the port status identifier is a signal generated by the detection sensor according to whether the optical fiber interface on the optical cross-connect box is occupied;

[0077] The web server is used to receive the port status identifiers and port location information corresponding to each of the optical fiber interfaces sent by the data collector from the starting time point of the current recording cycle, and write the port status identifiers and port location information corresponding to each of the optical fiber interfaces into the port status table corresponding to the optical cross-connect box at the end time point of the current recording cycle, and record the time period corresponding to the current recording cycle.

[0078] In an optional embodiment, the web server runs a Django web application, the Django web application provides a state data interface, and the optical intersection detection device further includes a resource orchestration system in communication with the web server; wherein,

[0079] The resource orchestration system is used to obtain the port status table through the status data interface and display the port status table.

[0080] In an optional embodiment, the Django web application also provides a start and stop interface; wherein,

[0081] The resource orchestration system is further configured to send a start / stop instruction for the data collector to the web server via the start / stop interface, wherein the start / stop instruction includes an enable instruction or a disable instruction;

[0082] The web server is configured to transmit the port status table to the resource orchestration system according to the enable instruction, or stop transmitting the port status table to the resource orchestration system according to the disable instruction.

[0083] In an optional embodiment, the detection sensor is used to generate an occupied status signal for indicating that the optical fiber port is occupied in response to the insertion of the optical fiber crystal head into the optical fiber port corresponding to the optical cross-box; or, in the case where the optical fiber crystal head is not detected to be inserted into the optical fiber port corresponding to the optical cross-box, generate an unoccupied status signal for indicating that the optical fiber interface is not occupied.

[0084] In an optional embodiment, the detection terminal further includes an LED light that is communicatively connected to the detection sensor; wherein,

[0085] The LED lamp is used to output a high-level signal corresponding to the occupied status signal in response to obtaining the occupied status signal; or, when the LED lamp continuously obtains the unoccupied status signal for a time period greater than or equal to a preset threshold, output a low-level signal corresponding to the unoccupied status signal.

[0086] In an optional embodiment, the data collector is specifically used to generate a port occupied identifier corresponding to the high-level signal in response to receiving the high-level signal, and determine the first electronic tag to which the high-level signal belongs, and obtain the first port location information corresponding to the first electronic tag; and / or, the data collector is used to generate a port unoccupied identifier corresponding to the low-level signal in response to receiving the low-level signal, and determine the second electronic tag to which the low-level signal belongs, and obtain the second port location information corresponding to the second electronic tag.

[0087] In an optional embodiment, the data collector includes a communication module; wherein,

[0088] The communication module is used to package the port status identifier and port location information corresponding to each of the optical fiber ports into a Json format and transmit the package to the web server.

[0089] As for the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.

[0090] In addition, an embodiment of the present invention further provides an electronic device, comprising: a processor, a memory, and a computer program stored in the memory and runnable on the processor. When the computer program is executed by the processor, the various processes of the above-mentioned optical fiber port detection method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.

[0091] An embodiment of the present invention further provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, the computer program implements the various processes of the above-mentioned optical fiber port detection method embodiment and can achieve the same technical effect. To avoid repetition, the description is omitted here. The computer-readable storage medium is, for example, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.

[0092] Figure 9 A schematic diagram of the hardware structure of an electronic device for implementing various embodiments of the present invention.

[0093] The electronic device 900 includes but is not limited to components such as a radio frequency unit 901, a network module 902, an audio output unit 903, an input unit 904, a sensor 905, a display unit 906, a user input unit 907, an interface unit 908, a memory 909, a processor 910, and a power supply 911. It will be understood by those skilled in the art that the electronic device structure involved in the embodiments of the present invention does not constitute a limitation on the electronic device, and the electronic device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently. In the embodiments of the present invention, the electronic device includes but is not limited to a mobile phone, a tablet computer, a laptop computer, a PDA, a vehicle-mounted terminal, a wearable device, and a pedometer.

[0094] It should be understood that in this embodiment of the present invention, the RF unit 901 can be used to receive and transmit signals during information transmission or calls. Specifically, it receives downlink data from the base station and transmits it to the processor 910 for processing; in addition, it transmits uplink data to the base station. Generally, the RF unit 901 includes but is not limited to an antenna, at least one amplifier, a transceiver, a coupler, a low-noise amplifier, a duplexer, and the like. Furthermore, the RF unit 901 can communicate with the network and other devices via a wireless communication system.

[0095] The electronic device provides users with wireless broadband Internet access through the network module 902, such as helping users to send and receive emails, browse web pages, and access streaming media.

[0096] The audio output unit 903 can convert audio data received by the RF unit 901 or the network module 902 or stored in the memory 909 into an audio signal and output it as sound. In addition, the audio output unit 903 can also provide audio output related to a specific function performed by the electronic device 900 (for example, a call signal reception sound, a message reception sound, etc.). The audio output unit 903 includes a speaker, a buzzer, a receiver, etc.

[0097] The input unit 904 is used to receive audio or video signals. The input unit 904 may include a graphics processing unit (GPU) 9041 and a microphone 9042. The graphics processor 9041 processes image data of a still picture or video obtained by an image capture device (such as a camera) in a video capture mode or an image capture mode. The processed image frames can be displayed on the display unit 906. The image frames processed by the graphics processor 9041 can be stored in the memory 909 (or other storage medium) or transmitted via the radio frequency unit 901 or the network module 902. The microphone 9042 can receive sound and can process such sound into audio data. The processed audio data can be converted into a format that can be sent to a mobile communication base station via the radio frequency unit 901 in the case of a telephone call mode.

[0098] The electronic device 900 also includes at least one sensor 905, such as a light sensor, a motion sensor, and other sensors. Specifically, the light sensor includes an ambient light sensor and a proximity sensor, wherein the ambient light sensor can adjust the brightness of the display panel 9061 according to the brightness of the ambient light, and the proximity sensor can turn off the display panel 9061 and / or the backlight when the electronic device 900 is moved to the ear. As a type of motion sensor, the accelerometer sensor can detect the magnitude of acceleration in all directions (generally three axes), and can detect the magnitude and direction of gravity when stationary. It can be used to identify the posture of the electronic device (such as horizontal and vertical screen switching, related games, magnetometer posture calibration), vibration recognition related functions (such as pedometer, tapping), etc.; the sensor 905 can also include a fingerprint sensor, a pressure sensor, an iris sensor, a molecular sensor, a gyroscope, a barometer, a hygrometer, a thermometer, an infrared sensor, etc., which will not be repeated here.

[0099] The display unit 906 is used to display information input by the user or information provided to the user. The display unit 906 may include a display panel 9061, which may be configured in the form of a liquid crystal display (LCD), an organic light-emitting diode (OLED), or the like.

[0100] The user input unit 907 can be used to receive input digital or character information, and to generate key signal input related to the user settings and function control of the electronic device. Specifically, the user input unit 907 includes a touch panel 9071 and other input devices 9072. The touch panel 9071, also known as a touch screen, can collect user touch operations on or near it (such as operations performed by the user using any suitable object or accessory such as a finger, stylus, etc. on or near the touch panel 9071). The touch panel 9071 may include two parts: a touch detection device and a touch controller. Among them, the touch detection device detects the user's touch direction and detects the signal caused by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device and converts it into contact point coordinates, which are then sent to the processor 910, which receives the command sent by the processor 910 and executes it. In addition, the touch panel 9071 can be implemented using various types such as resistive, capacitive, infrared and surface acoustic wave. In addition to the touch panel 9071, the user input unit 907 may also include other input devices 9072. Specifically, other input devices 9072 may include but are not limited to a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, and a joystick, which will not be repeated here.

[0101] Furthermore, the touch panel 9071 may be overlaid on the display panel 9061. When the touch panel 9071 detects a touch operation on or near it, it transmits the information to the processor 910 to determine the type of touch event. The processor 910 then provides a corresponding visual output on the display panel 9061 based on the type of touch event. It will be understood that in one embodiment, the touch panel 9071 and the display panel 9061 are two independent components to implement the input and output functions of the electronic device. However, in some embodiments, the touch panel 9071 and the display panel 9061 may be integrated to implement the input and output functions of the electronic device. The specific details are not limited here.

[0102] The interface unit 908 is an interface for connecting external devices to the electronic device 900. For example, the external devices may include a wired or wireless headset port, an external power supply (or battery charger) port, a wired or wireless data port, a memory card port, a port for connecting a device with an identification module, an audio input / output (I / O) port, a video I / O port, a headphone port, etc. The interface unit 908 may be used to receive input (e.g., data information, power, etc.) from the external device and transmit the received input to one or more elements within the electronic device 900, or may be used to transmit data between the electronic device 900 and the external device.

[0103] Memory 909 can be used to store software programs and various data. Memory 909 may primarily include a program storage area and a data storage area. The program storage area may store an operating system and at least one application required for a function (such as a sound playback function or an image playback function); the data storage area may store data generated based on the use of the mobile phone (such as audio data, a phone book, etc.). Furthermore, memory 909 may include high-speed random access memory and non-volatile memory, such as at least one disk storage device, flash memory device, or other volatile solid-state storage device.

[0104] The processor 910 is the control center of the electronic device. It connects the various components of the electronic device using various interfaces and circuits. By running or executing software programs and / or modules stored in the memory 909 and accessing data stored in the memory 909, it performs various functions of the electronic device and processes data, thereby monitoring the electronic device as a whole. The processor 910 may include one or more processing units; preferably, the processor 910 may integrate an application processor and a modem processor, wherein the application processor primarily processes the operating system, user interface, and application programs, while the modem processor primarily handles wireless communications. It is understood that the modem processor may not be integrated into the processor 910.

[0105] The electronic device 900 may also include a power supply 911 (such as a battery) to supply power to each component. Preferably, the power supply 911 may be logically connected to the processor 910 through a power management system, thereby managing functions such as charging, discharging, and power consumption through the power management system.

[0106] In addition, the electronic device 900 includes some functional modules not shown, which will not be described here.

[0107] It should be noted that, in this document, the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, article, or apparatus comprising a series of elements includes not only those elements but also other elements not explicitly listed, or elements inherent to such process, method, article, or apparatus. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of other identical elements in the process, method, article, or apparatus comprising the element.

[0108] Through the description of the above embodiments, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus the necessary general hardware platform, and of course can also be implemented by hardware, but in many cases the former is a better embodiment. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes a number of instructions for enabling a terminal (which can be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in each embodiment of the present invention.

[0109] The embodiments of the present invention are described above in conjunction with the accompanying drawings, but the present invention is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present invention, ordinary technicians in this field can also make many forms without departing from the scope of protection of the present invention and the claims, all of which are protected by the present invention.

[0110] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed in the embodiments of the present invention can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.

[0111] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0112] In the embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of the units is merely a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0113] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.

[0114] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.

[0115] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes various media that can store program code, such as a USB flash drive, a mobile hard drive, ROM, RAM, a magnetic disk, or an optical disk.

[0116] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any modifications or substitutions that can be easily conceived by a person skilled in the art within the technical scope disclosed in the present invention should be included within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be based on the scope of protection of the claims.

Claims

1. A method for detecting an optical fiber port, characterized in that: Applied to an optical intersection detection device, the optical intersection detection device includes at least a data collector, a detection terminal communicatively connected to the data collector, and a web server, the detection terminal includes a detection sensor and an electronic tag associated with the detection sensor, each of the electronic tags is bound to an optical fiber interface on an optical cross-connect box, and the method includes: The detection sensor generates an occupied state signal for indicating that the optical fiber port is occupied in response to the insertion of an optical fiber crystal plug into the optical fiber port corresponding to the optical cross-box; or generates an unoccupied state signal for indicating that the optical fiber port is unoccupied in the case where no optical fiber crystal plug is detected to be inserted into the optical fiber port corresponding to the optical cross-box; The data collector obtains the port status identifier transmitted by the detection terminal and the port position information corresponding to the electronic tag, wherein the port status identifier is a signal generated by the detection sensor according to whether the optical fiber interface on the optical cross-connect box is occupied; The web server receives the port status identifiers and port location information corresponding to each of the optical fiber interfaces sent by the data collector from the starting time point of the current recording cycle, and writes the port status identifiers and port location information corresponding to each of the optical fiber interfaces into the port status table corresponding to the optical cross-connect box at the end time point of the current recording cycle, and records the time period corresponding to the current recording cycle.

2. The method according to claim 1, characterized in that The web server runs a Django web application, and the Django web application provides a status data interface. The optical intersection detection device also includes a resource orchestration system that is communicatively connected to the web server. The method further includes: The resource orchestration system obtains the port status table through the status data interface and displays the port status table.

3. The method according to claim 2, characterized in that The Django web application also provides a start and stop interface, and the method further includes: The resource orchestration system sends a start / stop instruction for the data collector to the web server through the start / stop interface, wherein the start / stop instruction includes an enable instruction or a disable instruction; The web server transmits the port status table to the resource orchestration system according to the enable instruction, or stops transmitting the port status table to the resource orchestration system according to the disable instruction.

4. The method according to claim 1, wherein The detection terminal further includes an LED light in communication with the detection sensor, and the method further includes: In response to acquiring the occupancy status signal, the LED lamp outputs a high level signal corresponding to the occupancy status signal; Alternatively, when the LED lamp continuously obtains the unoccupied state signal for a period greater than or equal to a preset threshold, a low-level signal corresponding to the unoccupied state signal is output.

5. The method according to claim 4, characterized in that The data collector obtains the port status identifier transmitted by the detection terminal and the port location information corresponding to the electronic tag, including: In response to receiving the high-level signal, the data collector generates a port occupation identifier corresponding to the high-level signal, determines a first electronic tag to which the high-level signal belongs, and obtains first port location information corresponding to the first electronic tag; And / or, in response to receiving the low-level signal, the data collector generates a port unoccupied identifier corresponding to the low-level signal, determines the second electronic tag to which the low-level signal belongs, and obtains the second port location information corresponding to the second electronic tag.

6. The method according to claim 1, characterized in that The data collector includes a communication module, and the method further includes: The communication module packages the port status identifier and port location information corresponding to each of the optical fiber ports into a Json format and transmits the package to the web server.

7. An optical intersection detection device, characterized in that: The optical cross detection device at least includes a data collector, a detection terminal connected to the data collector, and a web server. The detection terminal includes a detection sensor and an electronic tag associated with the detection sensor. Each electronic tag is bound to the optical fiber interface on the optical cross box; wherein, The detection sensor is used to generate an occupied state signal for indicating that the optical fiber port is occupied in response to the insertion of an optical fiber crystal plug into the optical fiber port corresponding to the optical cross-box; or, in the case where no optical fiber crystal plug is detected to be inserted into the optical fiber port corresponding to the optical cross-box, generate an unoccupied state signal for indicating that the optical fiber interface is not occupied; The data collector is used to obtain the port status identifier transmitted by the detection terminal and the port position information corresponding to the electronic tag, wherein the port status identifier is a signal generated by the detection sensor according to whether the optical fiber interface on the optical cross-connect box is occupied; The web server is used to receive the port status identifiers and port location information corresponding to each of the optical fiber interfaces sent by the data collector from the starting time point of the current recording cycle, and write the port status identifiers and port location information corresponding to each of the optical fiber interfaces into the port status table corresponding to the optical cross-connect box at the end time point of the current recording cycle, and record the time period corresponding to the current recording cycle.

8. An electronic device, characterized in that: comprising a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus; The memory is used to store computer programs; The processor is configured to implement the method according to any one of claims 1 to 6 when executing a program stored in the memory.

9. A computer-readable storage medium having instructions stored thereon, which, when executed by one or more processors, cause the processors to perform the method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Method and device for generating data records

    CN103441861A

  • Realization method and device of intelligentization of optical network intelligentization

    CN105338432A