Method for optical wavelength conversion based on spi protocol and related device
By using an optical wavelength conversion method based on the SPI protocol, SPI protocol data is generated by utilizing the routing information of burst control packets to control a tunable laser to generate light waves. This solves the problem of insufficient flexibility in optical wavelength conversion in existing technologies and realizes improved flexibility and performance of high-speed optical burst switching.
Patent Information
- Application Number
- CN202210057508.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-01-18
- Publication Date
- 2025-11-04
- Estimated Expiration
- 2042-01-18
AI Technical Summary
Existing optical wavelength conversion methods mainly rely on inherent hardware implementation, which lacks flexibility and is difficult to meet the needs of high-speed optical burst switching scenarios.
A wavelength conversion method based on the SPI protocol is adopted. By obtaining the routing information of burst control packets, SPI protocol data is generated, and a tunable laser is controlled to generate different light waves, thereby realizing the conversion of light wavelength.
It improves the flexibility and communication performance of optical burst switching, meeting the needs of high-speed optical burst switching scenarios.
Smart Images

Figure CN114679641B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present disclosure relates to the field of optical communication technology, in particular to an optical wavelength conversion method based on SPI protocol and related equipment. BACKGROUND
[0002] With the rapid development of network technology, various data services are emerging and growing rapidly. The use of optical fibers has also been widely applied. It is of great significance to use wavelength division multiplexing technology on the optical layer to expand the transmission bandwidth of the network and improve the transmission efficiency. At present, there are three main switching technologies in optical networks, which are optical path switching, optical packet switching and optical burst switching. Optical path switching technology is stable, but the bandwidth utilization is not high, and it does not have the ability to bear complex big data networks. Optical packet switching has high requirements for devices in data processing. Optical burst switching is between the two technologies and combines their advantages.
[0003] The existing optical wavelength conversion mostly uses inherent hardware to realize, without using software protocol layer method to control optical wavelength conversion, so the flexibility is insufficient, and the application conditions are limited for high-speed optical burst switching scenarios. SUMMARY
[0004] Therefore, the purpose of the present disclosure is to provide an optical wavelength conversion method based on SPI protocol and related equipment.
[0005] To achieve the above purpose, the present disclosure provides an optical wavelength conversion method based on SPI protocol, comprising:
[0006] obtaining a burst control packet of to-be-sent data, and obtaining route information corresponding to the burst data packet according to the burst control packet;
[0007] in response to the route information being different from route information in current SPI protocol data, generating new SPI protocol data according to the route information; wherein the SPI protocol data comprises state information and route information;
[0008] in response to the state information of the new SPI protocol data being different from the state information of the current SPI protocol data, obtaining wavelength data of the burst data packet according to the route information of the new SPI protocol data;
[0009] generating optical waves carrying the burst data packet according to the wavelength data.
[0010] Based on the same inventive concept, the present disclosure further provides an optical wavelength conversion device based on SPI protocol, comprising:
[0011] a data acquisition module, configured to acquire a burst control packet of to-be-sent data, and obtain routing information corresponding to the burst data packet according to the burst control packet;
[0012] a control management module, configured to generate new SPI protocol data according to the routing information in response to the routing information being different from routing information in current SPI protocol data; wherein the SPI protocol data comprises state information and routing information;
[0013] a wavelength judgment module, configured to obtain wavelength data of the burst data packet according to the routing information of the new SPI protocol data in response to state information of the new SPI protocol data being different from state information of the current SPI protocol data;
[0014] a wavelength conversion module, configured to generate an optical wave carrying the burst data packet according to the wavelength data.
[0015] Based on the same inventive concept, the disclosure also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the method according to any one of the above when executing the program.
[0016] Based on the same inventive concept, the disclosure also provides a non-transitory computer readable storage medium, which stores computer instructions for causing a computer to execute the method according to any one of the above.
[0017] As can be seen from the above, the disclosure provides an optical wavelength conversion method based on SPI protocol and related equipment, wherein SPI protocol data is generated according to routing information in a received data burst control packet, and a tunable laser is controlled to generate different optical waves according to the routing information in the SPI protocol data to carry the burst data packet. Through the SPI protocol, the conversion of the optical wavelength is realized, the high-speed optical burst switching scenario is met, and the flexibility of optical burst switching is improved. BRIEF DESCRIPTION OF DRAWINGS
[0018] In order to more clearly illustrate the technical solutions in the disclosure or the related art, the following will briefly introduce the drawings needed to be used in the embodiments or related art description. Obviously, the drawings in the following description are only embodiments of the disclosure, and for those skilled in the art, other drawings can also be obtained without creative labor on the basis of these drawings.
[0019] Figure 1 Flow chart of the optical wavelength conversion method based on SPI protocol in the embodiments of the disclosure;
[0020] Figure 2A SPI protocol data structure schematic diagram of an embodiment of the present disclosure;
[0021] Figure 3 A light wavelength conversion device structure schematic diagram based on a SPI protocol of an embodiment of the present disclosure;
[0022] Figure 4 A method implementation flow schematic diagram of a light wavelength conversion device based on a SPI protocol of an embodiment of the present disclosure;
[0023] Figure 5 An electronic device structure schematic diagram of an embodiment of the present disclosure. DETAILED DESCRIPTION
[0024] In order to make the objectives, technical solutions and advantages of the present disclosure clearer, the present disclosure is further described in detail below with reference to specific embodiments and the accompanying drawings.
[0025] It should be noted that, unless otherwise defined, the technical terms or scientific terms used in the embodiments of the present disclosure should be understood as the general meaning understood by those skilled in the art to which the present disclosure belongs. The terms "first", "second", and similar terms used in the embodiments of the present disclosure do not represent any order, number, or importance, but are only used to distinguish different components. The terms "include", "contain", and similar terms mean that the elements or objects before the terms cover the elements or objects listed after the terms and their equivalents, and do not exclude other elements or objects. The terms "connect" or "connected" and similar terms are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect. The terms "up", "down", "left", "right", and the like only represent relative positional relationships, which may change accordingly when the absolute position of the described object changes.
[0026] As described in the background section, in the related art, the existing optical wavelength conversion is mostly implemented using inherent hardware, without using a software protocol layer method to control optical wavelength conversion, so the flexibility is insufficient, and the application conditions are limited for high-speed optical burst switching scenarios.
[0027] To solve the problems in the related art described above, the embodiments of the present disclosure provide a light wavelength conversion method based on a SPI protocol, generates SPI protocol data according to the routing information in the burst control packet of the received data, and controls the tunable laser to generate different optical waves carrying burst data packets according to the routing information in the SPI protocol data. The SPI protocol is used to realize the conversion of the optical wavelength, meet the high-speed optical burst switching scenario, and improve the flexibility of optical burst switching.
[0028] The technical solutions of the present disclosure are further described in detail below through specific embodiments.
[0029] First, one or more embodiments of this specification provide a method. (Refer to...) Figure 1 The method includes the following steps:
[0030] Step S101: Obtain the burst control packet of the data to be sent, and obtain the routing information corresponding to the burst data packet based on the burst control packet.
[0031] In this step, the data to be sent is transmitted using Optical Burst Switching (OBS) technology. A key feature of OBS is the independent transmission of Burst Data Packets (BDP) and Burst Control Packets (BCP). Burst Data Packets carry the data, while Burst Control Packets contain routing information, such as destination address, CRC, tag, burst size, and offset time, used for network control and data forwarding of the burst data packets. Burst Control Packets undergo photoelectric conversion and electronic processing at the core nodes of the OBS network, while Burst Data Packets do not require photoelectric / electro-optical conversion or node electronic processing and are transmitted directly in an end-to-end transparent transmission channel. Burst Data Packets and Burst Control Packets are separated in both time and channel. First, the Burst Control Packets of the data to be sent need to be obtained. Routing information is then retrieved from the Burst Control Packets through data lookup, allowing for data forwarding of the burst data packets based on this routing information.
[0032] The advantage of separating burst control packets and burst data packets is that burst control packets can be transmitted before burst data packets, compensating for the latency caused by optical / electrical / optical conversion and electrical processing during the processing of burst control packets at the switching node. Subsequent burst data packets are then transmitted transparently via all-optical switching at the switching node, reducing the need for optical buffers, even to zero, thus avoiding the shortcomings of current immature optical buffer technology. Furthermore, since the size of burst control packets is much smaller than that of burst data packets, the amount of data requiring optical / electrical / optical conversion and electrical processing is greatly reduced, shortening processing latency and significantly improving switching speed.
[0033] Before executing the optical wavelength conversion method based on the SPI protocol for the first time, the SPI protocol data needs to be initialized to a preset value. As a specific implementation method, the protocol data can be initialized to 0.
[0034] The SPI protocol data is initialized to a specific preset value. When performing the optical wavelength conversion method based on the SPI protocol for the first time, the obtained routing information can be compared with the initialized SPI protocol data.
[0035] The light wavelength conversion method in the embodiments of the present disclosure is implemented based on the SPI protocol. The SPI (Serial Peripheral Interface) protocol is mainly applied between EEPROM, FLASH, real-time clock, AD converter, digital signal processor and digital signal decoder. The SPI interface generally uses four lines for communication: MISO (master data input, slave data output), MOSI (master data output, slave data input), MISO and MOSI are both serial lines, that is, each SCLK clock signal transmits only 1 bit of data, SCLK clock signal is generated by the master device, and CS (chip select signal of slave device) is controlled by the master device and is effective at low level.
[0036] In the SPI protocol data structure, as shown in the table, there are two parts, the high eight-bit state information and the low eight-bit routing information. According to the obtained routing information, the routing information is compared with the last eight-bit routing information in the current SPI protocol. If they are different, new SPI protocol data is generated.
[0037] The light wavelength conversion is based on the SPI protocol, supports full-duplex operation, is simple to operate, and has a high data transmission rate. The light wavelength conversion is flexibly controlled through the software SPI protocol layer, and the optical burst switching communication performance is improved. In step S102, in response to the routing information being different from the routing information in the current SPI protocol data, new SPI protocol data is generated according to the routing information. The SPI protocol data includes state information and routing information.
[0038] In this step, according to Figure 2 In the SPI protocol data structure, as shown in the table, there are two parts, the high eight-bit state information and the low eight-bit routing information. According to the obtained routing information, the routing information is compared with the last eight-bit routing information in the current SPI protocol. If they are different, new SPI protocol data is generated.
[0039] According to the structure of the SPI protocol data, the state and the routing information of the data to be sent are distinguished. If the routing information in the burst control packet of the data to be sent is the same as the routing information of the data currently sent, it indicates that the data twice is the same destination address, that is, the states of the two are the same. If the routing information in the burst control packet of the data to be sent is different from the routing information of the data currently sent, it indicates that the data twice is not the same destination address, that is, the states of the two are different. The destination address can be inquired according to the routing information in the SPI protocol data, the optical wavelength conversion can be simply and quickly performed, and the communication performance of optical burst switching is improved.
[0040] The new SPI protocol data is generated according to the routing information, specifically including: obtaining the routing information, comparing the routing information with the routing information in the current SPI protocol data; in response to the routing information being different from the routing information in the current SPI protocol data, generating new routing information in the SPI protocol according to the routing information, and adding a predetermined value to the routing information in the current SPI protocol data to generate state information of the new SPI protocol data.
[0041] In the embodiment of the present disclosure, the routing information is obtained, and when the routing data and the last eight bits of the routing information in the currently reserved SPI protocol data are different, the routing data in the SPI protocol data is changed to the obtained routing information. Since the obtained routing information is different from the routing information in the last SPI protocol data, it indicates that the SPI protocol data is also different from the current protocol data. Therefore, a specific value is added to the first eight bits of the state information in the currently reserved SPI protocol data to generate new state information, and the state information in the SPI protocol data is changed to the new state information, thereby generating new SPI protocol data.
[0042] In a specific application scenario, the current SPI protocol data is that the first eight bits of the state information are 00000001, and the last eight bits of the routing information are 10011000. The obtained routing information is 01001000. The obtained routing information 01001000 is compared with the routing information 10011000 in the current SPI protocol data, and the two are different. Therefore, the routing information in the SPI protocol data is changed to 01001000, the current state information is increased by 1 to generate new state information 00000010, the state information in the SPI protocol data is changed to 00000010, and thereby new SPI protocol data is generated, the first eight bits of which are 00000010, and the last eight bits of which are 01001000.
[0043] Step S103, in response to the state information of the new SPI protocol data being different from the state information of the current SPI protocol data, obtaining wavelength data of the burst data packet according to routing information of the new SPI protocol data.
[0044] In this step, the state information in the new SPI protocol data is obtained, the state information in the current SPI protocol data is different, the routing information in the new SPI protocol data is obtained, and corresponding wavelength data is obtained.
[0045] According to the state information and the routing information in the SPI protocol, the optical wavelength conversion can be realized through the SPI protocol, without using inherent hardware, and the flexibility of optical wavelength conversion is improved.
[0046] In the embodiment of the present disclosure, the wavelength data of the burst data packet can be obtained through the routing information and the preset routing information and wavelength data association table.
[0047] In the embodiment of the present disclosure, each routing information corresponds to a wavelength data, and the wavelength data corresponding to the burst data packet can be obtained according to the routing information in the SPI protocol, so that the wavelength conversion can be realized.
[0048] In a specific application scenario, the routing information in the current SPI protocol is 10011000, the corresponding wavelength data is α, the routing information in the SPI protocol data is changed to 01001000, the corresponding wavelength data is β, and the wavelength data β is obtained according to the routing information in the SPI protocol data.
[0049] Step S104, generating an optical wave carrying the burst data packet according to the wavelength data.
[0050] In this step, the value of the wavelength data of the burst data packet is obtained, and the data value is input to the tunable laser, and the tunable laser can generate the optical wave of the burst data packet according to the value of the wavelength data. According to the value of the wavelength data, the optical wave carrying the burst data packet can be generated, the wavelength conversion is realized, the high-speed optical burst switching scenario is met, and the flexibility of optical burst switching is improved.
[0051] In the embodiment of the present disclosure, the burst control packet of the to-be-sent data is obtained, the burst control packet of the to-be-sent data is obtained, the routing information corresponding to the burst data packet is obtained according to the burst control packet, and then the method further comprises: in response to the routing information being the same as the routing information in the current SPI protocol data, obtaining wavelength data of the burst data packet according to the routing data; and generating an optical wave carrying the burst data packet according to the wavelength data.
[0052] In the embodiments of the present disclosure, when the route data and the last eight bits of the route information in the current reserved SPI protocol data are the same, the wavelength data of the burst data packet is obtained directly through the route information; the input value of the tunable laser is not required to be changed, and the optical wave carrying the burst data packet is generated according to the wavelength data of the last time.
[0053] Based on the same inventive concept, the present disclosure also provides an optical wavelength conversion device based on a SPI protocol, corresponding to the method of any of the above embodiments.
[0054] According to Figure 3 The optical wavelength conversion device based on the SPI protocol comprises:
[0055] The data acquisition module 301 is configured to acquire a burst control packet of to-be-sent data, and obtain route information of a corresponding burst data packet according to the burst control packet.
[0056] The control management module 302 is configured to generate new SPI protocol data according to the route information in response to the route information being different from route information in current SPI protocol data; wherein the SPI protocol data comprises state information and route information.
[0057] The wavelength judgment module 303 is configured to obtain wavelength data of the burst data packet according to the route information of the new SPI protocol data in response to the state information of the new SPI protocol data being different from the state information of the current SPI protocol data.
[0058] The wavelength conversion module 304 is configured to generate an optical wave carrying the burst data packet according to the wavelength data.
[0059] As an optional embodiment, the optical wavelength conversion device based on the SPI protocol further comprises:
[0060] The initialization module is configured to initialize the SPI protocol data to 0.
[0061] As an optional embodiment, the wavelength judgment module 303 is further configured to obtain the wavelength data of the burst data packet according to the route data in response to the route information being the same as the route information in the current SPI protocol data.
[0062] As an optional embodiment, the control management module 302 is further configured to acquire the route information, and compare the route information with route information in the current SPI protocol data.
[0063] In response to the route information and the route information in the current SPI protocol data being different, generating new route information in the new SPI protocol according to the route information, and adding a predetermined value to the route information in the current SPI protocol data to generate state information of the new SPI protocol data.
[0064] As an optional embodiment, the wavelength judging module 303 is further configured to obtain wavelength data of the burst data packet according to the route information and a preset association table of route information and wavelength data.
[0065] As an optional embodiment, the wavelength converting module 304 is further configured to input the wavelength data into a tunable laser to make the tunable laser generate an optical wave carrying the burst data packet.
[0066] The following describes a specific implementation process of the optical wavelength converting apparatus based on the SPI protocol to execute the above-mentioned optical wavelength converting method based on the SPI protocol according to a specific embodiment, as shown in the following table: Figure 4
[0067] Step S401: obtaining route information in a burst control packet.
[0068] First, the data obtaining module obtains a burst control packet of to-be-sent data, and the data searching module obtains route information in the burst control packet.
[0069] Step S402: judging whether the route information in the burst control packet is the same as route information in SPI protocol data; if yes, executing step S403; if no, executing step S404.
[0070] The control management module judges whether the route information in the control packet is the same as the route information in the SPI protocol data.
[0071] Step S403: keeping 16 bits of the SPI protocol data unchanged.
[0072] The control management module keeps 16 bits of the SPI protocol data unchanged. The route information in the burst control packet and the route information in the SPI protocol data are the same, indicating that the destination addresses of the two are the same, i.e., the states of the two are the same, and the 16-bit SPI protocol data does not need to be changed.
[0073] Step S404: generating new 16-bit SPI protocol data according to the route information in the burst control packet.
[0074] The new 16-bit SPI protocol data is generated by the control management module. The route information in the burst control packet is different from the route information in the SPI protocol data, indicating that the destination addresses of the two are different, i.e., the states of the two are also different. The high 8 bits of the SPI protocol data are added by 1, the route information in the burst control packet is written into the low 8 bits of the SPI protocol data, and the new 16-bit SPI protocol data is generated.
[0075] In step S405, the 16-bit SPI protocol data is sent through the SPI interface.
[0076] The 16-bit SPI protocol data is sent through the SPI interface of the control management module.
[0077] In step S406, the 16-bit SPI protocol data is received.
[0078] The 16-bit SPI protocol data is received through the SPI interface of the wavelength judgment module.
[0079] In step S407, it is judged whether the state information in the SPI protocol data is the same as the state information of the current SPI protocol data. If not, steps S408-S409 are executed. If yes, step S410 is executed.
[0080] It is judged by the wavelength judgment module whether the state information in the SPI protocol data is the same as the state information of the current SPI protocol data.
[0081] In step S408, the route information of the low 8 bits is read, and the wavelength data is obtained according to the route information.
[0082] The wavelength judgment module reads the route information of the low 8 bits. The state information in the received 16-bit SPI protocol data is different from the state information in the current SPI protocol data, indicating that the states of the two are different, i.e., the route information of the two is different, and the route information of the low 8 bits needs to be obtained to determine the specific destination address. According to the association table of the route information and the preset route information and wavelength data, the wavelength data of the burst data packet is obtained.
[0083] In step S409, the wavelength data is input to the tunable laser.
[0084] The wavelength data is input to the tunable laser by the wavelength conversion module.
[0085] In step S410, the input of the tunable laser is not changed.
[0086] The state information in the 16-bit SPI protocol data received by the control management module is the same as the state information in the current SPI protocol data, which indicates that the states of the two are the same, i.e., the routing information of the two is the same, and the wavelength data required by the two is also the same, so the tunable laser does not need to input the wavelength data. The wavelength conversion module inputs the original wavelength data into the tunable laser.
[0087] In step S411, the tunable laser outputs an optical wave carrying a burst data packet according to the wavelength data.
[0088] For the convenience of description, the above apparatus is described in various modules according to functions. Of course, the functions of the modules can be implemented in one or more software and / or hardware when the present disclosure is implemented.
[0089] The apparatus of the above embodiment is used to implement the ranking method of the autonomous domain system in any of the above embodiments, and has the beneficial effects of the corresponding method embodiments, which are not described here again.
[0090] Based on the same inventive concept, the present disclosure also provides an electronic device corresponding to the method of any of the above embodiments, which comprises a memory, a processor, and a computer program stored in the memory and executable on the processor, and the processor implements the ranking method of the autonomous domain system according to any of the above embodiments when executing the program.
[0091] Figure 5 A more specific hardware structure of an electronic device provided by the embodiment is shown, which can include a processor 1010, a memory 1020, an input / output interface 1030, a communication interface 1040, and a bus 1050. The processor 1010, the memory 1020, the input / output interface 1030, and the communication interface 1040 are connected to each other through the bus 1050 for communication within the device.
[0092] The processor 1010 can be implemented in the form of a general-purpose CPU (Central Processing Unit), a microprocessor, an ASIC (Application Specific Integrated Circuit), or one or more integrated circuits, etc., for executing related programs to implement the technical solutions provided by the embodiments of the present disclosure.
[0093] The memory 1020 can be implemented in the form of a ROM (Read Only Memory), a RAM (Random Access Memory), a static storage device, a dynamic storage device, etc. The memory 1020 can store an operating system and other application programs, and when the technical solutions provided in the embodiments of the present specification are implemented by software or firmware, the related program codes are stored in the memory 1020 and are called and executed by the processor 1010.
[0094] The input / output interface 1030 is configured to connect an input / output module to realize information input and output. The input / output module can be configured as a component in the device (not shown in the figure) or can be externally connected to the device to provide corresponding functions. The input device can include a keyboard, a mouse, a touch screen, a microphone, various sensors, etc., and the output device can include a display, a speaker, a vibrator, an indicator light, etc.
[0095] The communication interface 1040 is configured to connect a communication module (not shown in the figure) to realize communication interaction between the device and other devices. The communication module can realize communication through a wired manner (such as a USB, a network cable, etc.) or through a wireless manner (such as a mobile network, WIFI, Bluetooth, etc.).
[0096] The bus 1050 includes a channel for transmitting information between various components (such as the processor 1010, the memory 1020, the input / output interface 1030, and the communication interface 1040) of the device.
[0097] It should be noted that although the above device only shows the processor 1010, the memory 1020, the input / output interface 1030, the communication interface 1040, and the bus 1050, in the specific implementation process, the device can also include other components necessary for normal operation. In addition, those skilled in the art can understand that the above device can also only include components necessary for implementing the embodiments of the present specification, and does not have to include all the components shown in the figure.
[0098] The electronic device of the above embodiments is used to implement the corresponding method in any of the above embodiments, and has the beneficial effects of the corresponding method embodiments, which are not described here again.
[0099] Based on the same inventive concept, the present disclosure also provides a non-transitory computer-readable storage medium storing computer instructions for causing the computer to execute the method of any of the above embodiments.
[0100] The computer readable media of the present embodiments includes permanent and non-permanent, removable and non-removable media, which can be implemented by any method or technology to store information. The information can be computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassette, magnetic tape, magnetic disk storage or other magnetic storage device, or any other non-transmission medium that can be used to store information accessible to a computing device.
[0101] The storage medium of the above embodiments stores computer instructions for causing the computer to perform the method as described in any of the above embodiments, and has the beneficial effects of the corresponding method embodiments, which are not described here again.
[0102] Those skilled in the art should understand that the discussion of any of the above embodiments is only exemplary, and is not intended to imply that the scope of the present disclosure (including claims) is limited to these examples; the technical features in the above embodiments or different embodiments can also be combined, the steps can be implemented in any order, and there are many other changes of different aspects of the embodiments of the present disclosure as described above, which are not provided in detail for the sake of brevity.
[0103] In addition, in order to simplify the description and discussion, and so as not to make the embodiments of the present disclosure difficult to understand, the well-known power / ground connections of integrated circuit (IC) chips and other components can or can not be shown in the provided drawings. In addition, the devices can be shown in the form of block diagrams in order to avoid making the embodiments of the present disclosure difficult to understand, and this also takes into account the fact that the details of the implementation of these block diagram devices are highly dependent on the platform to be implemented to implement the embodiments of the present disclosure (i.e. these details should be fully within the understanding of those skilled in the art). Where specific details (e.g. circuits) are set forth in order to describe an exemplary embodiment of the present disclosure, it will be apparent to those skilled in the art that the embodiments of the present disclosure can be implemented without these specific details or with variations on these specific details. Therefore, these descriptions should be considered illustrative rather than limiting.
[0104] While the present disclosure has been described in connection with certain embodiments thereof, many modifications, substitutions, and variations will be apparent to those of ordinary skill in the art from the foregoing description. For instance, other memory architectures (e.g., dynamic RAM (DRAM)) can use the embodiments discussed.
[0105] Embodiments of the present disclosure are intended to cover all such alternatives, modifications, and variations as falling within the broad scope of the appended claims. Accordingly, any one or more of the above-described embodiments can be combined with any one or more of the other embodiments, and the application should not be construed as limited to only those embodiments described and shown in the attached drawings and following detailed description.
Claims
1. A method for optical wavelength conversion based on the SPI protocol, comprising: Obtain the burst control packets of the data to be sent, and obtain the routing information of the corresponding burst data packets based on the burst control packets; In response to the fact that the routing information differs from the routing information in the current SPI protocol data, new SPI protocol data is generated based on the routing information; wherein, the SPI protocol data includes: status information and routing information; In response to the fact that the status information of the new SPI protocol data is different from the status information of the current SPI protocol data, the wavelength data of the burst data packet is obtained according to the routing information of the new SPI protocol data; Based on the wavelength data, an optical wave carrying the burst data packet is generated; The step of generating new SPI protocol data based on the routing information specifically includes: Obtain the routing information and compare it with the routing information in the current SPI protocol data; In response to the difference between the routing information and the routing information in the current SPI protocol data, new routing information in the SPI protocol data is generated based on the routing information, and a predetermined value is added to the status information in the current SPI protocol data to generate the status information of the new SPI protocol data; Specifically, if the routing information of the burst data packet is different from the routing information of the lower eight bits in the current SPI protocol data, the predetermined value is added to the status information of the higher eight bits in the current SPI protocol data, and the routing information of the burst data packet is written to the lower eight bits in the current SPI protocol data to obtain new sixteen-bit SPI protocol data.
2. The method according to claim 1, wherein, When the method is executed for the first time, it includes: Initialize the SPI protocol data to preset values.
3. The method according to claim 1, wherein, The process of acquiring burst control packets for the data to be sent, obtaining routing information corresponding to the burst data packets based on the burst control packets, and then further including: In response to the routing information being identical to the routing information in the current SPI protocol data, the wavelength data of the burst data packet is obtained based on the routing information; Based on the wavelength data, an optical wave carrying the burst data packet is generated.
4. The method according to claim 1, wherein, The step of obtaining the wavelength data of the burst data packets based on the routing information of the new SPI protocol data includes: The wavelength data of the burst data packets is obtained based on the routing information and the preset association table between routing information and wavelength data.
5. The method according to claim 1, wherein, The step of generating the light wave carrying the burst data packet based on the wavelength data specifically includes: The wavelength data is input into a tunable laser, which then generates light waves carrying the burst data packets.
6. An optical wavelength conversion device based on the SPI interface protocol, comprising: The data acquisition module is used to acquire burst control packets of the data to be sent, and to obtain the routing information of the corresponding burst data packets based on the burst control packets; The control and management module is used to generate new SPI protocol data based on the routing information in response to the difference between the routing information and the routing information in the current SPI protocol data; wherein, the SPI protocol data includes: status information and routing information; The wavelength determination module is used to obtain the wavelength data of the burst data packet based on the routing information of the new SPI protocol data in response to the difference between the status information of the new SPI protocol data and the status information of the current SPI protocol data. A wavelength conversion module is used to generate an optical wave carrying the burst data packets based on the wavelength data. The control and management module is specifically used for: Obtain the routing information and compare it with the routing information in the current SPI protocol data; In response to the difference between the routing information and the routing information in the current SPI protocol data, new routing information in the SPI protocol data is generated based on the routing information, and a predetermined value is added to the status information in the current SPI protocol data to generate the status information of the new SPI protocol data; The control and management module is further used for: If the routing information of the burst data packet is different from the routing information of the lower eight bits in the current SPI protocol data, the predetermined value is added to the status information of the higher eight bits in the current SPI protocol data, and the routing information of the burst data packet is written to the lower eight bits in the current SPI protocol data to obtain a new sixteen-bit SPI protocol data.
7. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the program, implements the method as claimed in any one of claims 1 to 5.
8. A non-transitory computer-readable storage medium storing computer instructions for causing a computer to perform the method of any one of claims 1 to 5.