Single-mode and multi-mode optical transceiver switching method, device, equipment and medium

Through the software definition data link method, change the single multi -mode conversion relationship, realize non -destructive switching, solve the problem of pollution caused by frequent plugging in a single multi -mode conversion device in a damp -hot smoke or dust environment. sex.

CN119382796APending Publication Date: 2025-01-28CHENGDU AORUIKE ELECTRONIC TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411501096.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-25
Publication Date
2025-01-28

AI Technical Summary

Technical Problem

Existing single multi-mode conversion devices frequently unplug external optical cables in humid and hot smoke or dust environments, resulting in the optical transmission components being contaminated by liquid, salt spray and dust, affecting the quality of the communication link.

Method used

Define the data link of the software, change the conversion relationship between the single multi -mode, use FIFO to send the cache and receive the cache connection single -mode signal to the switching output of the multi -mode signal, or the multi -mode signal input to the switching output of the single -mode signal Realize non -destructive switching to avoid inserting external cables.

Benefits of technology

Achieved lossless switching, protecting the optical component is not affected by environmental pollution, improves the stability of the optical transmission component, and the switching port during link switching is not affected by environmental factors.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119382796A_ABST
    Figure CN119382796A_ABST
Patent Text Reader

Abstract

The invention discloses a single-mode and multi-mode optical transceiver switching method, device and equipment and a medium, and relates to the technical field of computer communication. The switching method comprises the following steps: receiving a single-mode electric signal or a multi-mode electric signal, and decoding; a decoding signal of the single-mode electric signal is cached in a single-mode FIFO receiving unit, and a decoding signal of the multi-mode electric signal is cached in a multi-mode FIFO receiving unit; according to the conversion relation information, the cache signal in the single-mode FIFO receiving unit is forwarded to the corresponding multi-mode FIFO sending unit, and the cache signal in the multi-mode FIFO receiving unit is forwarded to the corresponding single-mode FIFO sending unit; the cache signal in the multi-mode FIFO sending unit is sent through the multi-mode high-speed transceiver after being coded, and the cache signal in the single-mode FIFO sending unit is sent through the single-mode high-speed transceiver after being coded. According to the invention, lossless switching is realized in a mode of defining a data link through software, and the optical component is protected from being polluted by environmental factors.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of computer communications, and in particular to a single-mode and multi-mode optical terminal switching method, device, equipment and medium. Background Art

[0002] At present, the single-to-multimode conversion device is mainly composed of some optical component parts and a single-channel conversion unit, and the switching is achieved by plugging and unplugging the external optical cable. The single-to-multimode conversion device is mainly used in application scenarios such as data link shipboard equipment, ground station equipment and data processing centers, which are generally in a hot and humid smoke environment or a dusty environment. The optical components and single-channel conversion units do not have the ability to resist hot and humid smoke and dust. Frequent plugging and unplugging of external optical cables leads to contamination by liquids, salt spray and dust. When the optical transmission components are contaminated by liquids, smoke, dust, etc., the quality of the communication link drops sharply, affecting the system function and performance. Summary of the invention

[0003] The present invention provides a single-mode and multi-mode optical terminal switching method, device, equipment and medium to achieve lossless switching of single and multi-mode to solve the problem of switching pollution caused by environmental reasons.

[0004] The present invention is achieved through the following technical solutions:

[0005] A first aspect of the present invention provides a method for switching between a single-mode and a multi-mode optical terminal, comprising:

[0006] Receive single-mode electrical signals or multi-mode electrical signals and decode them;

[0007] Buffering the decoded signal of the single-mode electrical signal in a single-mode FIFO receiving unit, and buffering the decoded signal of the multi-mode electrical signal in a multi-mode FIFO receiving unit;

[0008] According to the conversion relationship information, the buffered signal in the single-mode FIFO receiving unit is forwarded to the corresponding multi-mode FIFO sending unit, and the buffered signal in the multi-mode FIFO receiving unit is forwarded to the corresponding single-mode FIFO sending unit;

[0009] The buffered signal in the multi-mode FIFO sending unit is encoded and sent through a multi-mode high-speed transceiver, and the buffered signal in the single-mode FIFO sending unit is encoded and sent through a single-mode high-speed transceiver.

[0010] The present invention changes the conversion relationship between single-mode and multi-mode by means of software-defined data links. The switching output of the single-mode signal to the multi-mode signal is connected through the FIFO sending buffer and the receiving buffer, or the switching output of the multi-mode signal input to the single-mode signal is connected. According to the conversion relationship, the single-mode / multi-mode FIFO receiving buffer data is forwarded to the corresponding multi-mode / single-mode FIFO sending buffer unit, and then sent out through the single-mode / multi-mode high-speed transceiver. Therefore, there is no need to plug and unplug external cables, and the enclosure of the chassis is maintained to achieve lossless switching. When the link is switched, the switching port is not affected by environmental factors.

[0011] Further, forwarding the buffered signal in the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit and forwarding the buffered signal in the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit according to the conversion relationship information includes:

[0012] If the conversion relationship information indicates that the current switching state is entered, stop forwarding the cache signal, connect the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit according to the matrix mapping table, and connect the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit;

[0013] After completing the connection switching, change the conversion relationship information, end the switching state, and execute the steps of forwarding the cache signal in the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit, and forwarding the cache signal in the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit.

[0014] Furthermore, the method further comprises: receiving conversion relationship information input by a user through a user control unit.

[0015] Further, the connecting the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit includes: connecting and switching the single-mode FIFO receiving unit and the multi-mode FIFO sending unit in sequence one by one;

[0016] The connecting the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit includes: connecting and switching the multi-mode FIFO receiving unit and the single-mode FIFO sending unit in sequence one by one.

[0017] A second aspect of the present invention provides a single-mode multi-mode optical terminal switching device, comprising:

[0018] A single-mode high-speed transceiver, used for receiving and decoding single-mode electrical signals;

[0019] A multi-mode high-speed transceiver for receiving and decoding multi-mode electrical signals;

[0020] A single-mode FIFO receiving unit, used for buffering a decoded signal of the single-mode electrical signal;

[0021] A multi-mode FIFO receiving unit, used for buffering the decoded signal of the multi-mode electrical signal;

[0022] A single-mode FIFO sending unit, used for caching single-mode signals to be forwarded;

[0023] A multi-mode FIFO sending unit, used for caching multi-mode electrical signals to be forwarded;

[0024] A matrix switching unit, configured to forward the buffered signal in the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit, and forward the buffered signal in the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit according to the conversion relationship information;

[0025] The multi-mode high-speed transceiver is also used to encode and then send the buffered signal in the multi-mode FIFO sending unit;

[0026] The single-mode high-speed transceiver is also used to encode and then send the buffered signal in the single-mode FIFO sending unit.

[0027] Further, a matrix mapping table is stored in the matrix switching unit. If the conversion relationship information indicates that the current switching state is entered, the forwarding of the cache signal is stopped, and according to the matrix mapping table, the single-mode FIFO receiving unit is connected to the corresponding multi-mode FIFO sending unit, and the multi-mode FIFO receiving unit is connected to the corresponding single-mode FIFO sending unit;

[0028] After completing the connection switching, change the conversion relationship information, end the switching state, and execute the steps of forwarding the cache signal in the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit, and forwarding the cache signal in the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit.

[0029] Furthermore, it also includes a user control unit, which is used to receive conversion relationship information input by a user.

[0030] Further, the user control unit includes a UART unit, a command parsing unit, a register control unit and a register group;

[0031] The UART unit is used to convert the conversion relationship information from serial data to parallel data according to the UART protocol;

[0032] The command parsing unit is used to parse the parallel data according to the register read and write command format, and output the parsed data to the register control unit;

[0033] The register control unit is used to modify the value of the corresponding register in the register group if the address, write command, and write data are parsed to form an updated matrix mapping table; if the address and read command are parsed, the value of the corresponding register in the register group is read and returned to the user serial port unit.

[0034] The third aspect of the present invention provides a single-mode or multi-mode optical terminal switching device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the single-mode or multi-mode optical terminal switching method described in any one of the first aspects of the present invention when executing the computer program.

[0035] A fourth aspect of the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the single-mode and multi-mode optical terminal switching method described in any one of the first aspects of the present invention.

[0036] Compared with the prior art, the present invention has the following advantages and beneficial effects:

[0037] 1. By defining the data link through software, the conversion relationship between single mode and multimode is changed to achieve lossless switching. Since there is no need to plug and unplug external cables and the chassis is kept closed, the switching port is not affected by environmental factors during link switching, which improves the stability of the optical transmission component.

[0038] 2. Data is cached between the high-speed transceiver and the link switch, and a switching mechanism is used. When the link is switched, the cached data is stopped from being forwarded, and the data is continued to be sent after the switch is completed. This achieves the purpose of lossless switching of the data link without restarting the chassis when the single-mode and multi-mode conversion relationship states change.

[0039] 3. Based on the matrix switching design concept, it has the ability to define data links by software and change the single-mode and multi-mode conversion relationships by software, and realize link switching without changing the external optical cable connection relationship.

[0040] 4. The switching program adopts a modular design, and the number of channels can be customized according to product requirements. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] In order to more clearly illustrate the technical solutions of the exemplary embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments. It should be understood that the following drawings only illustrate certain embodiments of the present invention and should not be regarded as limiting the scope. For those of ordinary skill in the art, other relevant drawings can be obtained based on these drawings without creative work. In the drawings:

[0042] Figure 1It is a schematic diagram of a single-mode multi-mode optical terminal hardware system according to an embodiment of the present invention;

[0043] Figure 2 It is a software module schematic diagram of a single-mode and multi-mode optical terminal switching method according to an embodiment of the present invention;

[0044] Figure 3 is a schematic diagram of a receiving FIFO according to an embodiment of the present invention;

[0045] Figure 4 is a schematic diagram of a transmit FIFO according to an embodiment of the present invention;

[0046] Figure 5 is a schematic diagram of a high-speed port transceiver according to an embodiment of the present invention;

[0047] Figure 6 is a software flow chart of a switching matrix unit according to an embodiment of the present invention;

[0048] Figure 7 is a schematic diagram of a default conversion relationship of a switching matrix unit in an embodiment of the present invention;

[0049] Figure 8 This is a schematic diagram of a household control unit according to an embodiment of the present invention. DETAILED DESCRIPTION

[0050] In order to make the objectives, technical solutions and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with embodiments and drawings. The exemplary embodiments of the present invention and their description are only used to explain the present invention and are not intended to limit the present invention.

[0051] It should be noted that the terms "including" and "having" and any variations thereof in the specification and claims of the present invention and the above-mentioned drawings are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to or inherent to other steps or units of the device.

[0052] The terms used in the various embodiments of the application are only used to describe the purpose of specific embodiments and are not intended to limit the various embodiments of the application. As used herein, the singular form is intended to also include the plural form, unless the context clearly indicates otherwise. Unless otherwise limited, all terms used here (including technical terms and scientific terms) have the same meaning as the meanings commonly understood by ordinary technicians in the field of the various embodiments of the application. The terms (such as the terms defined in the dictionary generally used) will be interpreted as having the same meaning as the contextual meaning in the relevant technical field and will not be interpreted as having an idealized meaning or an overly formal meaning, unless clearly defined in the various embodiments of the application.

[0053] The embodiments of the present invention provide a single-mode and multi-mode optical terminal switching method, device, equipment and medium, which are suitable for single-mode and multi-mode switching application scenarios, are conducive to achieving lossless switching, and protect optical components from environmental pollution during switching.

[0054] The single-mode and multi-mode optical terminal switching solution proposed by the present invention is composed of hardware and software. Figure 1 , Figure 2 As shown, Figure 1 is a schematic diagram of a single-mode multi-mode optical terminal hardware system according to an embodiment of the present invention. Figure 2 This is a software module diagram of a single-mode and multi-mode optical terminal switching method according to an embodiment of the present invention. The hardware design mainly includes FPGA, single-mode optical module, and multi-mode optical module. The optical signals derived from the single-mode optical module and the multi-mode optical module are connected to the optical connector of the chassis through optical fiber jumpers, and the single-mode optical module and the multi-mode optical module complete the photoelectric signal conversion. A matrix mapping table is built into the FPGA, and the FPGA completes the matrix switching of the electrical signal data according to the matrix mapping table. The built-in matrix mapping table can be manually configured and modified.

[0055] In one implementation, the hardware system provides a user serial port connected to the FPGA, and completes external UART serial port communication through the user serial port to achieve switching control and configuration, reading or modification of the matrix mapping table. The number of single-mode and multi-mode channels of the hardware can be equal or unequal. When data is transparently transmitted, single-mode or multi-mode channels that are not on the matrix mapping table are in an inoperative state.

[0056] In the hardware system, the materials of the optical connector and the chassis shell are made of salt spray-proof materials, such as passivated stainless steel. The PCB circuit board inside the chassis is sprayed with polyurethane varnish, left to solidify under high temperature conditions, and sprayed with multiple layers in sequence to make the PCB circuit board mildew-proof, moisture-proof, and salt spray-proof.

[0057] The software design scheme consists of a single-mode high-speed transceiver, a single-mode FIFO unit, a switching matrix unit, a multi-mode FIFO unit and a multi-mode high-speed transceiver. Among them, the single-mode FIFO unit includes a single-mode FIFO receiving unit and a single-mode FIFO sending unit, and the multi-mode FIFO unit includes a multi-mode FIFO receiving unit and a multi-mode FIFO sending unit. In the software module, a single-mode FIFO unit corresponds to a single-mode high-speed transceiver, and a multi-mode FIFO unit corresponds to a multi-mode high-speed transceiver. In the hardware system, a single-mode high-speed transceiver corresponds to a single-mode optical module, and a multi-mode high-speed transceiver corresponds to a multi-mode optical module. Through the modular design of the software, the number of channels can be customized according to product requirements. It only needs to define the same number of single-mode optical modules, multi-mode optical modules, registers, single-mode FIFO send / receive units and multi-mode FIFO send / receive units, single-mode high-speed port transceivers and single-mode high-speed port transceivers.

[0058] The present invention is based on a software-defined single-mode and multi-mode optical terminal switching method, which specifically includes the following steps.

[0059] S1, receiving a single-mode electrical signal or a multi-mode electrical signal and decoding it;

[0060] S2, buffering the decoded signal of the single-mode electrical signal in the single-mode FIFO receiving unit, and buffering the decoded signal of the multi-mode electrical signal in the multi-mode FIFO receiving unit;

[0061] S3, forwarding the buffered signal in the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit according to the conversion relationship information, and forwarding the buffered signal in the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit;

[0062] S4, after encoding the buffered signal in the multi-mode FIFO sending unit, send it through the multi-mode high-speed transceiver, and after encoding the buffered signal in the single-mode FIFO sending unit, send it through the single-mode high-speed transceiver.

[0063] Among them, after the single-mode high-speed port transceiver receives a single-mode electrical signal, or the multi-mode high-speed port transceiver receives a multi-mode electrical signal, correspondingly, according to the switching relationship, the received single-mode electrical signal needs to be converted into a multi-mode electrical signal and output through a multi-mode optical module, and the received multi-mode electrical signal needs to be converted into a single-mode electrical signal and output through a single-mode optical module. In this solution, the physical optical signal is converted into an electrical signal recognizable by the software system through a hardware optical module, and the converted electrical signal is decoded and processed in the corresponding single-mode high-speed port transceiver or multi-mode high-speed port transceiver, and the decoded single-mode electrical signal is transmitted to the single-mode FIFO receiving unit for data caching, and the decoded multi-mode electrical signal is transmitted to the multi-mode FIFO receiving unit for caching of received data.

[0064] The receiving cache data of the single-mode FIFO receiving unit and the multi-mode FIFO receiving unit are read by the switching matrix unit, and are transmitted to the corresponding multi-mode FIFO sending unit or the single-mode FIFO sending unit for caching the sending data according to the conversion relationship. A matrix mapping table is pre-stored in the switching matrix unit, mapping the corresponding relationship between each single-mode FIFO receiving unit and the multi-mode FIFO sending unit, and the multi-mode FIFO receiving unit and the single-mode FIFO sending unit.

[0065] Among them, the single-mode FIFO receiving unit and the multi-mode FIFO receiving unit are both composed of multiple receiving FIFOs, and the single-mode FIFO sending unit and the multi-mode FIFO sending unit are also respectively composed of multiple sending FIFOs. The number of receiving FIFOs and sending FIFOs is equal. The single-mode FIFO receiving / sending unit and the multi-mode FIFO receiving / sending unit are mainly used to switch the data buffer between the matrix unit and the high-speed port transceiver. The receiving FIFO and sending FIFO of the single-mode FIFO receiving / sending unit and the multi-mode FIFO receiving / sending unit are realized by calling the asynchronous FIFO IP integrated in the FPGA. Figure 3 The figure shows a schematic diagram of the receiving FIFO. The receiving FIFO is cached by writing electrical signal data into the single-mode or multi-mode high-speed port transceiver, and the cached electrical signal data is then read by the switching matrix unit. Figure 4 The figure shows a schematic diagram of a transmit FIFO. The transmit FIFO is cached by writing electrical signal data into the switching matrix unit. The cached electrical signal data is then read by a single-mode high-speed port transceiver or a multi-mode high-speed port transceiver, and the electrical signal is finally sent out.

[0066] Finally, the buffered data of the single-mode FIFO sending unit is encoded and sent by the single-mode high-speed transceiver, and the buffered data of the multi-mode FIFO sending unit is encoded and sent by the multi-mode high-speed transceiver. Figure 5 The figure shows a schematic diagram of a high-speed port transceiver. The single-mode / multi-mode high-speed port transceiver internally calls the serial high-speed transceiver IP integrated in the FPGA to realize the decoding and encoding of the electrical signal. The high-speed port transceiver receives the electrical signal data of the single-mode optical module or the multi-mode optical module, decodes it, and transmits it to the single-mode FIFO receiving unit or the multi-mode FIFO receiving unit. It receives the electrical signal data of the single-mode FIFO sending unit or the multi-mode FIFO sending unit, encodes it, and transmits it to the single-mode optical module or the multi-mode optical module.

[0067] See also Figure 6 In the switching matrix unit software flow chart shown, a specific implementation of step S3 includes: if the conversion relationship information indicates that the current switching state is entered, stop forwarding the cache signal, and connect the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit, and connect the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit according to the matrix mapping table; after completing the connection switching, change the conversion relationship information, end the switching state, and execute the steps of forwarding the cache signal in the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit, and forwarding the cache signal in the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit.

[0068] In the above switching steps, the lossless switching conversion relationship and data forwarding are implemented by FPGA code, and the switching matrix unit executes the lossless switching conversion relationship to forward data between the single-mode FIFO receiving / transmitting unit and the multi-mode FIFO transmitting / receiving unit. The code flow is that when the value of the conversion change effective register is 1, it enters the switching state, stops the forwarding of cached data between the single-mode / multi-mode FIFO units, and avoids data loss due to the switching conversion relationship. According to the matrix mapping table, for the received data is a single-mode electrical signal, the single-mode FIFO receiving unit is connected to the corresponding multi-mode FIFO transmitting unit in the matrix mapping table. For the received data is a multi-mode electrical signal, the multi-mode FIFO receiving unit is connected to the corresponding single-mode FIFO transmitting unit in the matrix mapping table. The single-mode or multi-mode channel not on the matrix mapping table is in an inoperative state. After the switching conversion relationship is completed, the conversion change effective register automatically returns to 0, the switching state ends, and the switching matrix unit restarts the cache data forwarding. If the value of the conversion change effective register is 0, there is no need to switch the connection, and forwarding can be performed according to the current mapping relationship.

[0069] In one embodiment, the default conversion relationship of the switching matrix unit is that the single-mode FIFO receiving unit and the multi-mode FIFO sending unit are connected and switched in sequence one by one, and the multi-mode FIFO receiving unit and the single-mode FIFO sending unit are connected and switched in sequence one by one. Figure 7 The schematic diagram of the default conversion relationship of the switching matrix unit shown in the figure shows that the multiple receiving FIFOs and multiple transmitting FIFOs of the single-mode and multi-mode can be numbered, and the switching conversion is completed in sequence according to the numbers as the default switching order. In addition, the order can also be configured.

[0070] In one embodiment, a user input is provided to input conversion relationship information, and the switching state and matrix mapping table can be edited. Figure 8 The user control unit is shown in the figure. The user control unit consists of four sub-units: UART unit, command parsing unit, register control unit, and register group. The register group consists of multiple registers, and the value of each register constitutes the mapping relationship between the single-mode FIFO unit and the multi-mode FIFO unit. The switching matrix unit performs connection switching according to the value of the register group.

[0071] Specifically, the user inputs the conversion relationship information through the user serial port, and the input data is serial data. The serial data is transmitted to the UART unit, and the serial-to-parallel conversion is performed according to the UART communication protocol. The converted parallel data is parsed by the command parsing unit according to the register read and write command format. If the address, write command, and write data are obtained by parsing, they are output to the register control unit, and the register control unit modifies the corresponding register value in the register group to form an updated matrix mapping table. If the address and read command are obtained by parsing, they are output to the register control unit, and the register control unit reads the corresponding register value in the register group. The register control unit returns the read data to the command parsing unit, and the parallel data is output to the UART unit according to the register read and write command format. The UART unit converts it into parallel data and outputs it to the user interface. Among them, the read and write command format refers to Table 1.

[0072] Table 1 Command format planning reference table.

[0073]

[0074] The address, value meaning and number of channels of the internal registers can be planned and modified according to the actual situation. A planning scheme for a register group can be referred to Table 2.

[0075] Table 2 Register group planning reference table.

[0076]

[0077]

[0078] The embodiment of the present invention further provides a single-multimode optical terminal switching device corresponding to the single-multimode optical terminal switching method of the above embodiment of the present invention, comprising:

[0079] A single-mode high-speed transceiver, used for receiving and decoding single-mode electrical signals;

[0080] A multi-mode high-speed transceiver for receiving and decoding multi-mode electrical signals;

[0081] A single-mode FIFO receiving unit, used for buffering a decoded signal of the single-mode electrical signal;

[0082] A multi-mode FIFO receiving unit, used for buffering the decoded signal of the multi-mode electrical signal;

[0083] A single-mode FIFO sending unit, used for caching single-mode signals to be forwarded;

[0084] A multi-mode FIFO sending unit, used for caching multi-mode electrical signals to be forwarded;

[0085] A switching matrix unit, configured to forward the buffered signal in the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit, and forward the buffered signal in the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit according to the conversion relationship information;

[0086] The multi-mode high-speed transceiver is also used to encode and then send the buffered signal in the multi-mode FIFO sending unit;

[0087] The single-mode high-speed transceiver is also used to encode and then send the buffered signal in the single-mode FIFO sending unit.

[0088] Further, a matrix mapping table is stored in the matrix switching unit. If the conversion relationship information indicates that the current switching state is entered, the forwarding of the cache signal is stopped, and according to the matrix mapping table, the single-mode FIFO receiving unit is connected to the corresponding multi-mode FIFO sending unit, and the multi-mode FIFO receiving unit is connected to the corresponding single-mode FIFO sending unit;

[0089] After completing the connection switching, change the conversion relationship information, end the switching state, and execute the steps of forwarding the cache signal in the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit, and forwarding the cache signal in the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit.

[0090] Furthermore, it also includes a user control unit, which is used to receive conversion relationship information input by a user.

[0091] Specifically, the user control unit includes a UART unit, a command parsing unit, a register control unit and a register group;

[0092] The UART unit is used to convert the conversion relationship information from serial data to parallel data according to the UART protocol;

[0093] The command parsing unit is used to parse the parallel data according to the register read and write command format, and output the parsed data to the register control unit;

[0094] The register control unit is used to modify the value of the corresponding register in the register group to form an updated matrix mapping table if the address, write command, and write data are parsed; if the address and read command are parsed, the value of the corresponding register in the register group is read and returned to the user serial port unit.

[0095] The embodiment of the present invention further provides a single-mode multi-mode optical terminal switching device, comprising a memory and a processor, wherein when the processor executes a computer program stored in the memory, the single-mode multi-mode optical terminal switching method of any of the above embodiments of the present invention is implemented. The memory may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system and an application required for at least one function; the data storage area may store data created according to the use of the terminal, etc. In addition, the memory may include a high-speed random access memory and may also include a non-volatile memory.

[0096] The embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the single-mode and multi-mode optical terminal switching method of any of the above embodiments of the present invention is implemented. The storage medium can be ROM / RAM, a magnetic disk, an optical disk, etc.

[0097] An embodiment of the present invention further provides a computer program product. When the computer program product is run on a processor, the device executes the single-mode and multi-mode optical terminal switching method of any of the above embodiments of the present invention.

[0098] The specific implementation methods described above further illustrate the objectives, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above description is only a specific implementation method of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.

Claims

1. A single-mode multi-mode optical terminal switching method, characterized in that: include: Receive single-mode electrical signals or multi-mode electrical signals and decode them; Buffering the decoded signal of the single-mode electrical signal in a single-mode FIFO receiving unit, and buffering the decoded signal of the multi-mode electrical signal in a multi-mode FIFO receiving unit; According to the conversion relationship information, the buffered signal in the single-mode FIFO receiving unit is forwarded to the corresponding multi-mode FIFO sending unit, and the buffered signal in the multi-mode FIFO receiving unit is forwarded to the corresponding single-mode FIFO sending unit; The buffered signal in the multi-mode FIFO sending unit is encoded and sent through a multi-mode high-speed transceiver, and the buffered signal in the single-mode FIFO sending unit is encoded and sent through a single-mode high-speed transceiver.

2. The single-mode and multi-mode optical terminal switching method according to claim 1, characterized in that: The method of forwarding the buffered signal in the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit and forwarding the buffered signal in the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit according to the conversion relationship information includes: If the conversion relationship information indicates that the current switching state is entered, stop forwarding the cache signal, connect the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit according to the matrix mapping table, and connect the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit; After completing the connection switching, change the conversion relationship information, end the switching state, and execute the steps of forwarding the cache signal in the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit, and forwarding the cache signal in the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit.

3. The single-mode and multi-mode optical terminal switching method according to claim 2, characterized in that: The method further includes: receiving conversion relationship information input by a user through a user control unit.

4. The single-mode and multi-mode optical terminal switching method according to claim 2, characterized in that: The connecting the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit comprises: connecting and switching the single-mode FIFO receiving unit and the multi-mode FIFO sending unit in sequence one by one; The connecting the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit includes: connecting and switching the multi-mode FIFO receiving unit and the single-mode FIFO sending unit in sequence one by one.

5. A single-mode multi-mode optical terminal switching device, characterized in that: include: A single-mode high-speed transceiver, used for receiving and decoding single-mode electrical signals; A multi-mode high-speed transceiver for receiving and decoding multi-mode electrical signals; A single-mode FIFO receiving unit, used for buffering a decoded signal of the single-mode electrical signal; A multi-mode FIFO receiving unit, used for buffering the decoded signal of the multi-mode electrical signal; A single-mode FIFO sending unit, used for caching single-mode signals to be forwarded; A multi-mode FIFO sending unit, used for caching multi-mode electrical signals to be forwarded; A switching matrix unit, configured to forward the buffered signal in the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit, and forward the buffered signal in the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit according to the conversion relationship information; The multi-mode high-speed transceiver is also used to encode and then send the buffered signal in the multi-mode FIFO sending unit; The single-mode high-speed transceiver is also used to encode and then send the buffered signal in the single-mode FIFO sending unit.

6. The single-mode multi-mode optical terminal switching device according to claim 5, characterized in that: The matrix switching unit stores a matrix mapping table. If the conversion relationship information indicates that the current switching state is entered, the forwarding of the cache signal is stopped. According to the matrix mapping table, the single-mode FIFO receiving unit is connected to the corresponding multi-mode FIFO sending unit, and the multi-mode FIFO receiving unit is connected to the corresponding single-mode FIFO sending unit; After completing the connection switching, change the conversion relationship information, end the switching state, and execute the steps of forwarding the cache signal in the single-mode FIFO receiving unit to the corresponding multi-mode FIFO sending unit, and forwarding the cache signal in the multi-mode FIFO receiving unit to the corresponding single-mode FIFO sending unit.

7. The single-mode multi-mode optical terminal switching device according to claim 6, characterized in that: It also includes a user control unit, which is used to receive conversion relationship information input by a user.

8. The single-mode multi-mode optical terminal switching device according to claim 7, characterized in that: The user control unit includes a UART unit, a command parsing unit, a register control unit and a register group; The UART unit is used to convert the conversion relationship information from serial data to parallel data according to the UART protocol; The command parsing unit is used to parse the parallel data according to the register read and write command format, and output the parsed data to the register control unit; The register control unit is used to modify the value of the corresponding register in the register group if the address, write command, and write data are parsed to form an updated matrix mapping table; if the address and read command are parsed, the value of the corresponding register in the register group is read and returned to the user serial port unit.

9. A single-mode multi-mode optical terminal switching device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the single-mode and multi-mode optical terminal switching method described in any one of claims 1-4 is implemented.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the single-mode and multi-mode optical terminal switching method described in any one of claims 1 to 4 is implemented.