Communication method and apparatus
By sending specific data packets for detection before channel wake-up, the problem of poor data transmission quality after channel wake-up in FlexLane technology is solved, and efficient energy consumption management is achieved under low or zero traffic conditions.
Patent Information
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- HUAWEI TECH CO LTD
- Filing Date
- 2025-12-18
- Publication Date
- 2026-06-25
AI Technical Summary
The poor data transmission quality of FlexLane technology after channel wake-up results in wasted power and low efficiency of network devices during low or zero traffic periods.
By sending specific data packets before channel wake-up, including alignment and indication information, data transmission is only performed after ensuring that the channel quality meets the requirements. Channel status detection is optimized using methods such as PCS code blocks and fast alignment flags.
It improves the data transmission quality of the awakened channel, reduces power consumption waste of network devices when traffic is low or zero, and improves the energy efficiency of network devices.
Smart Images

Figure CN2025143385_25062026_PF_FP_ABST
Abstract
Description
A communication method and apparatus
[0001] This application claims priority to Chinese Patent Application No. 2024118873913, filed with the State Intellectual Property Office of China on December 18, 2024, entitled "A Communication Method and Apparatus", the entire contents of which are incorporated herein by reference. Technical Field
[0002] This application relates to the field of communications, and in particular to a communication method and apparatus. Background Technology
[0003] In digital communication networks, especially campus networks, traffic exhibits typical tidal characteristics; for example, traffic during the night is generally much lower than the network's bandwidth. Currently, even when there is no traffic on the network, Ethernet interface devices need to remain operational. For instance, the physical layer (PHY), serializer / deserializer (SERDES), and optical modules of Ethernet interface devices remain active, resulting in significant power consumption waste.
[0004] In the Ethernet protocol defined by the Institute of Electrical and Electronics Engineers (IEEE), Energy-Efficient Ethernet (EEE) technology is used to put the physical layer into a low-power idle (LPI) mode to save power on Ethernet interface devices when traffic is low. Flexible Lane technology is another energy-saving technology developed based on EEE. Using Flexible Lane, only a few channels can be used to transmit data during low traffic. At zero traffic, Flexible Lane technology supports shutting down all channels, further saving energy.
[0005] The current FlexLane technology suffers from poor data transmission quality when a closed channel is reopened. Therefore, a solution is urgently needed to address this issue. Summary of the Invention
[0006] This application provides a communication method and apparatus that can guarantee the data transmission quality of the awakened channel.
[0007] Firstly, this application provides a communication method applied to a first device. The first device and a second device are connected via a first channel and a second channel, forming a transceiver channel. The first channel is the channel between the transmitting component of the first device and the receiving component of the second device, and the second channel is the channel between the receiving component of the first device and the transmitting component of the second device. The first device can send first data to the second device via the first channel. The first data triggers the second device to detect the first channel. After sending the first data, the first device receives a first response from the second device via the second channel. The first response can, for example, indicate the channel quality of the first channel. In one example, the first channel may be a channel that was originally in a closed state and needs to be woken up. In this application, the first device can send first data to the second device via the first channel, allowing the second device to detect the channel quality of the first channel based on the first data. Thus, if the channel quality of the first channel meets the requirements, the first device and the second device can then use the first channel to transmit data, thereby ensuring the data transmission quality of the first channel.
[0008] In one possible implementation, the first data includes first alignment information for the second device to lock the first data sent by the first device. Accordingly, the second device can lock the first data based on the first alignment information and further detect the first communication based on the first data to determine the channel quality of the first channel.
[0009] In one possible implementation, the first data includes, in addition to the first alignment information, first indication information, which is used to indicate the state of the receiving component of the first device. In this scenario, the first device can use the first indication information to notify the second device of the state of its receiving component, so that the second device can perform corresponding operations based on the state of the receiving component of the first device.
[0010] In one possible implementation,
[0011] The first indication information includes a first code block or a second code block, wherein the first code block indicates that the receiving component of the first device is in a working state, and the second code block indicates that the receiving component of the first device is in a non-working state. The first code block and the second code block are different. That is, different code blocks are used to indicate different states of the receiving component of the first device, thereby notifying the second device of the state of the receiving component of the first device.
[0012] In one possible implementation, the first code block includes a first physical coding sublayer (PCS) code block. That is, the first device can use the first PCS code block to notify the second device of the status of the receiving component of the first device.
[0013] In one possible implementation, the first PCS code block can be an idle code block or an order sequence (O) code block. That is, an IDLE code block or an O code block is used to indicate that the receiving component of the first device is in an active state.
[0014] In one possible implementation, the second code block includes: a second PCS code block.
[0015] In one possible implementation, the second PCS code block includes a remote fault (RF) code block or an O code block. That is, an RF code block or an O code block is used to indicate that the receiving component of the first device is in a non-operating state.
[0016] In one possible implementation, the first alignment information includes a first rapid alignment marker (RAM) to enable the second device to quickly lock onto the first data sent by the first device.
[0017] In one possible implementation, the specific information in the first alignment information is a first numerical value. This application does not specifically limit the exact value of this first numerical value; it can be any numerical value. As a specific example, the first numerical value is 255.
[0018] In one possible implementation, when the first alignment information is a first RAM, specific information in the first alignment information is obtained through the countdown (CD) 3 of the first RAM or the CD7 of the first RAM. Alternatively, specific information in the first RAM can be obtained through either the CD3 or the CD7 of the first RAM.
[0019] In one possible implementation, if the first indication information indicates that the receiving component of the first device is in a non-operating state, the first device can also receive second data sent by the second device through the second channel before receiving the first response. The second data is used to trigger the first device to detect the second channel. That is, when the first receiving component is in a non-operating state, the second channel cannot be directly used to receive data. In this scenario, the first device receives second data through the second channel to detect the second channel.
[0020] In one possible implementation, after receiving the second data, the first device can detect the second channel in response to receiving the second data. Furthermore, after detecting the second channel, it sends a second response to the second device through the first channel. The second response can, for example, be used to indicate the channel quality of the second channel.
[0021] In one possible implementation, the first device may send the second response to the second device through the first channel when the transmission quality of the second data is greater than or equal to a first threshold. In this scenario, the second response can be used to indicate that the channel quality of the second channel meets the requirements.
[0022] In one possible implementation, since the first channel has not yet switched to an active state, it cannot yet transmit media access control (MAC) messages. Therefore, the second response can be a code block that can be transmitted at the physical layer. As a specific example, the second response includes second alignment information and a third code block, wherein the third code block is used to indicate that the receiving component of the first device is in an active state. In this scenario, the second device can lock the second response using the second alignment information and determine that the channel quality of the second channel meets the requirements based on the third code block indicating that the receiving component of the first device is in an active state.
[0023] In one possible implementation, the first response may be a MAC message. For example, in the scenario where the receiving component of the aforementioned first device is in a working state, the first response may be a MAC message.
[0024] In one possible implementation, the first response may include third alignment information and a fourth code block, wherein the fourth code block is used to indicate that the receiving component of the second device is in an operational state. In this scenario, the first device can lock the first response using the third alignment information and determine that the channel quality of the first channel meets the requirements based on the fourth code block indicating that the receiving component of the second device is in an operational state.
[0025] In one possible implementation, after receiving the first response, the first device can determine that the channel quality of the first channel meets the requirements. Further, the first device can also send third data to the second device through the first channel. The third data includes fourth alignment information, where a specific value in the fourth alignment information is a second numerical value. The third data is used to notify the second device that the first device is about to send a data stream to the second device through the first channel. As an example, the second numerical value is 1.
[0026] In one possible implementation, the first device can send M third data to the second device through the first channel, where M is an integer greater than 1. In one example, the value of M can be a different value than the aforementioned first value; for example, the value of M can be 36. In this application, each third data includes fourth alignment information. For any third data, the fourth alignment information includes the sequence number of the third data. Furthermore, for the i-th third data sent among the M third data, its sequence number is M-i+1, where i is an integer greater than or equal to 1 and less than or equal to M.
[0027] In one possible implementation, after the first device channel sends M third data points to the second device, it can further send a data stream to the second device through the first channel. At this point, the first channel has completed the full switching process from a non-working state to a working state.
[0028] In one possible implementation, after sending a second response to the second device through the first channel, the first device can also receive fourth data sent by the second device through the second channel. The fourth data includes fifth alignment information, and the characteristic information of the fifth alignment information is a second value.
[0029] In one possible implementation, before sending the first data to the second device via the first channel, the first device may further control its transmitting component to enter an operational state, so as to send the first data to the second device using the transmitting component. Here, sending the first data to the second device using the transmitting component of the first device refers to sending the first data to the second device via the first channel.
[0030] In one possible implementation, after sending first data to the second device through the first channel, the first device may activate a timer to wait for a response to the first data. Based on the time recorded by the timer, it is determined whether the first device has received a first response within a certain period of time. If the first device receives a first response within a certain period of time, the first device can determine that the channel quality of the first channel meets the requirements.
[0031] Secondly, this application provides a communication method applied to a second device. The second device can receive first data sent by a first device through a first channel, wherein the first device and the second device include a first channel and a second channel, which form a set of transceiver channels. The first channel is the channel between the transmitting component of the first device and the receiving component of the second device, and the second channel is the channel between the receiving component of the first device and the transmitting component of the second device. In response to receiving the first data, the second device detects the first channel. After detecting the first channel, the second device can send a first response to the first channel through the second channel. The first response can, for example, be used to indicate the channel quality of the first channel. In one example, the first channel may be a channel that was originally in a closed state and needs to be woken up. In this application, the first device can send the first data to the second device through the first channel, so that the second device can detect the channel quality of the first channel based on the first data. In this way, the first device and the second device can use the first channel to transmit data again if the channel quality of the first channel meets the requirements, thereby ensuring the data transmission quality of the first channel.
[0032] In one possible implementation, the first data includes: first alignment information, or the first alignment information and first indication information, wherein the first indication information is used to indicate the state of the receiving component of the first device.
[0033] In one possible implementation, the first indication information includes a first code block indicating that the receiving component of the first device is in a working state, or the first indication information includes a second code block indicating that the receiving component of the first device is in a non-working state, wherein the first code block and the second code block are different.
[0034] In one possible implementation, the first code block includes: a first physical coding sublayer (PCS) code block.
[0035] In one possible implementation, the first PCS code block includes: an idle IDLE code block or a predetermined sequence O code block.
[0036] In one possible implementation, the second code block includes: a second PCS code block.
[0037] In one possible implementation, the second PCS code block includes: a remote fault RF code block or an O code block.
[0038] In one possible implementation, the first alignment information includes: a first fast alignment flag RAM.
[0039] In one possible implementation, the specific information in the first alignment information is a first numerical value.
[0040] In one possible implementation, the first value is 255.
[0041] In one possible implementation, the first alignment information is a first RAM, and specific information in the first alignment information is obtained through the countdown CD3 of the first RAM or the CD7 of the first RAM.
[0042] In one possible implementation, the first indication information indicates that the receiving component of the first device is in a non-operating state. Before sending the first response, the method further includes: sending second data to the first device through the second channel, the second data being used to trigger the first device to detect the second channel; and receiving the second response sent by the first device through the first channel.
[0043] In one possible implementation, the second response includes: second alignment information and a third code block, the third code block indicating that the receiving component of the first device is in an operational state.
[0044] In one possible implementation, the first response includes: third alignment information and a fourth code block, the fourth code block indicating that the receiving component of the second device is in an operational state.
[0045] In one possible implementation, the method further includes: receiving third data sent by the first device through the first channel, the third data including fourth alignment information, wherein a specific piece of information in the fourth alignment information is a second value.
[0046] In one possible implementation, the second value is 1.
[0047] In one possible implementation, the method further includes: after receiving the M third data sent by the first device through the first channel, receiving a data stream sent by the second device through the first channel.
[0048] In one possible implementation, after receiving a second response sent by the first device through the first channel, the method further includes: sending fourth data to the first device through the second channel, the fourth data including fifth alignment information, the characteristic information of the fifth alignment information being a second value.
[0049] In one possible implementation, sending fourth data to the first device via the second channel includes: sending M fourth data to the first device via the second channel, each of the fourth data including fifth alignment information, wherein for any fourth data, the fifth alignment information includes the sequence number of the fourth data, wherein the sequence number of the i-th fourth data sent among the M fourth data is equal to M-i+1, and i is an integer greater than or equal to 1 and less than or equal to M.
[0050] In one possible implementation, the method further includes: after sending M fourth data to the first device through the second channel, sending a data stream to the first device through the second channel.
[0051] In one possible implementation, sending a first response to the first device via the second channel includes: sending the first response to the first device via the second channel when the transmission quality of the first data is greater than or equal to a first threshold.
[0052] In one possible implementation, the first data is sent to the second device after being encoded by the first device using forward-error correction (FEC). The transmission quality of the first data can be the error rate of the first data. Specifically, the first data can be FEC decoded to obtain the error rate of the first data, and the error rate of the first data is used to indicate the transmission quality of the first data.
[0053] In one possible implementation, before sending the second data to the second device via the second channel, the method further includes controlling the transmitting component of the second device to enter an operational state.
[0054] In one possible implementation, after sending the second data to the second device via the second channel, the method further includes: activating a timer to wait for a response to the second data.
[0055] Thirdly, this application provides a communication device applied to a first device, the device comprising: a transmitting unit for transmitting first data to a second device via a first channel, wherein the first channel and the second channel are transceiver channels between the first device and the second device, the first channel is a channel between a transmitting component of the first device and a receiving component of the second device, and the second channel is a channel between a receiving component of the first device and a transmitting component of the second device, wherein the first data is used to trigger the second device to detect the first channel; and a receiving unit for receiving a first response transmitted by the second device via the second channel.
[0056] In one possible implementation, the first data includes: first alignment information, or; the first alignment information and first indication information, wherein the first indication information is used to indicate the state of the receiving component of the first device.
[0057] In one possible implementation, the first indication information includes a first code block indicating that the receiving component of the first device is in a working state, or the first indication information includes a second code block indicating that the receiving component of the first device is in a non-working state, and the first code block and the second code block are different.
[0058] In one possible implementation, the first code block includes: a first physical coding sublayer (PCS) code block.
[0059] In one possible implementation, the first PCS code block includes: an idle IDLE code block or a predetermined sequence O code block.
[0060] In one possible implementation, the second code block includes: a second PCS code block.
[0061] In one possible implementation, the second PCS code block includes: a remote fault RF code block or an O code block.
[0062] In one possible implementation, the first alignment information includes: a first fast alignment flag RAM.
[0063] In one possible implementation, the specific information in the first alignment information is a first numerical value.
[0064] In one possible implementation, the first value is 255.
[0065] In one possible implementation, the first alignment information is a first RAM, and specific information in the first alignment information is obtained through the countdown CD3 of the first RAM or the CD7 of the first RAM.
[0066] In one possible implementation, the first indication information indicates that the receiving component of the first device is in a non-operating state. The receiving unit is further configured to receive second data sent by the second device through the second channel before receiving the first response. The second data is used to trigger the first device to detect the second channel.
[0067] In one possible implementation, the apparatus further includes: a processing unit configured to detect the second channel in response to receiving the second data; and a sending unit configured to send a second response to the second apparatus via the first channel.
[0068] In one possible implementation, sending the second response to the second device through the first channel includes: sending the second response to the second device through the first channel when the transmission quality of the second data is greater than or equal to a first threshold.
[0069] In one possible implementation, the second response includes: second alignment information and a third code block, the third code block indicating that the receiving component of the first device is in an operational state.
[0070] In one possible implementation, the first response includes: a Media Access Control (MAC) message; or, third alignment information and a fourth code block, the fourth code block indicating that the receiving component of the second device is in an operational state.
[0071] In one possible implementation, the sending unit is further configured to: send third data to the second device through the first channel, the third data including fourth alignment information, wherein a specific piece of information in the fourth alignment information is a second numerical value.
[0072] In one possible implementation, the second value is 1.
[0073] In one possible implementation, sending third data to the second device through the first channel includes: sending M pieces of third data to the second device through the first channel, each piece of third data including fourth alignment information, wherein for any piece of third data, the fourth alignment information includes a sequence number of the third data, wherein the sequence number of the i-th piece of third data sent among the M pieces of third data is equal to M-i+1, and i is an integer greater than or equal to 1 and less than or equal to M.
[0074] In one possible implementation, the sending unit is further configured to: after sending the M third data to the second device through the first channel, send a data stream to the second device through the first channel.
[0075] In one possible implementation, the receiving unit is further configured to receive fourth data sent by the second device through the second channel after sending a second response to the second device through the first channel, the fourth data including fifth alignment information, the characteristic information of the fifth alignment information being a second value.
[0076] In one possible implementation, the processing unit of the device is further configured to, before sending the first data to the second device via the first channel,
[0077] The transmitting component of the first device is controlled to enter the working state.
[0078] In one possible implementation, the device includes a processing unit further configured to, after sending the first data to the second device via the first channel, activate a timer to wait for a response to the first data.
[0079] Fourthly, this application provides a communication device applied to a second device, the device comprising: a receiving unit for receiving first data transmitted by a first device through a first channel, wherein the first channel and a second channel are transceiver channels between the first device and the second device, the first channel being a channel between a transmitting component of the first device and a receiving component of the second device, and the second channel being a channel between a receiving component of the first device and a transmitting component of the second device; a processing unit for detecting the first channel in response to receiving the first data; and a transmitting unit for transmitting a first response to the first channel through the second channel.
[0080] In one possible implementation, the first data includes: first alignment information, or the first alignment information and first indication information, wherein the first indication information is used to indicate the state of the receiving component of the first device.
[0081] In one possible implementation, the first indication information includes a first code block indicating that the receiving component of the first device is in a working state, or the first indication information includes a second code block indicating that the receiving component of the first device is in a non-working state, wherein the first code block and the second code block are different.
[0082] In one possible implementation, the first code block includes: a first physical coding sublayer (PCS) code block.
[0083] In one possible implementation, the first PCS code block includes: an idle IDLE code block or a predetermined sequence O code block.
[0084] In one possible implementation, the second code block includes: a second PCS code block.
[0085] In one possible implementation, the second PCS code block includes: a remote fault RF code block or an O code block.
[0086] In one possible implementation, the first alignment information includes: a first fast alignment flag RAM.
[0087] In one possible implementation, the specific information in the first alignment information is a first numerical value.
[0088] In one possible implementation, the first value is 255.
[0089] In one possible implementation, the first alignment information is a first RAM, and specific information in the first alignment information is obtained through the countdown CD3 of the first RAM or the CD7 of the first RAM.
[0090] In one possible implementation, the first indication information indicates that the receiving component of the first device is in a non-operating state. The sending unit is further configured to send second data to the first device through the second channel before sending the first response. The second data is used to trigger the first device to detect the second channel. The receiving unit is further configured to receive the second response sent by the first device through the first channel.
[0091] In one possible implementation, the second response includes: second alignment information and a third code block, the third code block indicating that the receiving component of the first device is in an operational state.
[0092] In one possible implementation, the first response includes: third alignment information and a fourth code block, the fourth code block indicating that the receiving component of the second device is in an operational state.
[0093] In one possible implementation, the receiving unit is further configured to: receive third data sent by the first device through the first channel, the third data including fourth alignment information, wherein a specific piece of information in the fourth alignment information is a second value.
[0094] In one possible implementation, the second value is 1.
[0095] In one possible implementation, the receiving unit is further configured to: after receiving the M third data sent by the first device through the first channel, receive the data stream sent by the second device through the first channel.
[0096] In one possible implementation, the sending unit is further configured to send fourth data to the first device via the second channel after receiving a second response sent by the first device via the first channel, the fourth data including fifth alignment information, the characteristic information of the fifth alignment information being a second value.
[0097] In one possible implementation, sending fourth data to the first device via the second channel includes: sending M fourth data to the first device via the second channel, each of the fourth data including fifth alignment information, wherein for any fourth data, the fifth alignment information includes the sequence number of the fourth data, wherein the sequence number of the i-th fourth data sent among the M fourth data is equal to M-i+1, and i is an integer greater than or equal to 1 and less than or equal to M.
[0098] In one possible implementation, the sending unit is further configured to send a data stream to the first device via the second channel after sending M fourth data to the first device via the second channel.
[0099] In one possible implementation, sending a first response to the first device via the second channel includes: sending the first response to the first device via the second channel when the transmission quality of the first data is greater than or equal to a first threshold.
[0100] In one possible implementation, the first data is sent to the second device after being encoded by forward error correction (FEC) by the first device. The transmission quality of the first data is determined by performing FEC decoding on the first data to obtain the error rate of the first data, and the error rate of the first data is used to indicate the transmission quality of the first data.
[0101] In one possible implementation, the processing unit is further configured to control the transmitting component of the second device to enter a working state before transmitting the second data to the second device via the second channel.
[0102] In one possible implementation, the processing unit is further configured to, after sending the second data to the second device via the second channel, open a timer for waiting for a response to the second data.
[0103] Fifthly, this application provides a communication device, including a communication interface and a processor connected to the communication interface.
[0104] The communication interface is used to perform the send and receive operations in the first aspect and any one of the methods described in the first aspect above, and the processor is used to perform other operations in the first aspect and any one of the methods described in the first aspect above besides the send and receive operations. Alternatively,
[0105] The communication interface is used to perform the send and receive operations in the second aspect and any one of the methods described in the second aspect above, and the processor is used to perform other operations in the second aspect and any one of the methods described in the second aspect above, except for the send and receive operations.
[0106] Sixthly, this application provides a computer-readable storage medium including instructions or a computer program that, when executed on a processor, implements the method described in the first aspect and any one of the first aspects above, or implements the method described in the second aspect and any one of the second aspects above.
[0107] In a seventh aspect, this application provides a computer program product, which, when run on a processor, implements the method described in the first aspect and any one of the first aspects above, or implements the method described in the second aspect and any one of the second aspects above.
[0108] Eighthly, this application provides a chip for implementing the method described in the first aspect and any one of the first aspects above, or for implementing the method described in the second aspect and any one of the second aspects above.
[0109] In one possible implementation, the chip is a PHY chip, or a chip in an optical module. Attached Figure Description
[0110] Figure 1 is a schematic diagram of an exemplary application scenario provided by an embodiment of this application;
[0111] Figure 2 is a schematic diagram of signaling interaction of a communication method provided in an embodiment of this application;
[0112] Figure 3 is a signaling interaction diagram of another communication method provided in an embodiment of this application;
[0113] Figure 4 is a schematic diagram of a communication method provided in an embodiment of this application;
[0114] Figure 5 is a schematic diagram of another communication method provided in an embodiment of this application;
[0115] Figure 6 is a schematic diagram of the structure of a communication device provided in an embodiment of this application;
[0116] Figure 7 is a schematic diagram of another communication device provided in an embodiment of this application;
[0117] Figure 8 is a schematic diagram of another communication device provided in an embodiment of this application. Detailed Implementation
[0118] This application provides a communication method and apparatus that can guarantee the data transmission quality of the awakened channel.
[0119] Currently, FlexLane technology allows the use of only a few channels for data transmission during periods of low traffic. At zero traffic, FlexLane technology supports shutting down all channels for further energy savings. When a channel is shut down, the circuit clock may be gated or powered off. When a channel is woken up, the parameters of the devices associated with that channel need to be readjusted. Therefore, if a channel is used directly for data transmission after being woken up, the data transmission quality may be poor because the parameters of some devices may not yet be fully readjusted.
[0120] To address the aforementioned problems, embodiments of this application provide a communication method and apparatus that can guarantee the data transmission quality of the awakened channel. The solution provided by the embodiments of this application will now be described in conjunction with the accompanying drawings.
[0121] Referring to Figure 1, this figure is a schematic diagram of an exemplary application scenario provided by an embodiment of this application. As shown in Figure 1, devices 110 and 120 include channels 101 and 102, wherein channel 101 is the channel between the transmitting component of device 110 and the receiving component of device 120, and channel 102 is the channel between the receiving component of device 110 and the transmitting component of device 120. In Figure 1, the "transmitting component" is abbreviated as "TX" and the "receiving component" is abbreviated as "RX".
[0122] The devices mentioned in this application may be network devices such as switches and routers, or components of network devices, such as single boards, line cards, or chips (e.g., PHY chips) on network devices. This application does not impose specific limitations on these devices. The devices may be connected via, but are not limited to, cables. The cables mentioned in this application may be electrical cables or optical fibers.
[0123] In one example, channel 101 and channel 102 can be a set of transceiver channels between device 110 and device 120. Channel 101 and channel 102 can share the same cable or use different cables; this application embodiment does not impose specific limitations.
[0124] Although only channels 101 and 102 are shown in Figure 1, Figure 1 is shown for ease of understanding only and does not constitute a limitation on the application scenario of this application. The channels between device 110 and device 120 are not limited to channels 101 and 102.
[0125] In the case where multiple transceiver channels are included between device 110 and device 120, the method provided in the embodiments of this application can be executed for any one of the transceiver channels.
[0126] Referring to Figure 2, this figure is a signaling interaction diagram of a communication method provided in an embodiment of this application. The method shown in Figure 2 can be applied to the application scenario shown in Figure 1. The first device in Figure 2 can correspond to device 110 in Figure 1, and the second device in Figure 2 can correspond to device 120 in Figure 1. Correspondingly, the first channel in Figure 2 can correspond to channel 101 in Figure 1, and the second channel in Figure 2 can correspond to channel 102 in Figure 1.
[0127] The method shown in Figure 2 includes S101-S105.
[0128] S101: The first device sends first data to the second device through the first channel. The first channel and the second channel are transceiver channels between the first device and the second device. The first channel is the channel between the transmitting component of the first device and the receiving component of the second device, and the second channel is the channel between the receiving component of the first device and the transmitting component of the second device. The first data is used to trigger the second device to detect the first channel.
[0129] In one example, the first channel is the channel to be woken up. Before executing S101, the first device can control the transmitting component of the first device to enter the working state. That is, the first device can control the transmitting component of the first device to switch from the power-saving state to the working state, where the working state can be understood as the non-power-saving state. In one example, the "power-saving state" can also be called the "non-working state". The power-saving state includes, but is not limited to, one or more of the following states: clock gating, power gating, and dynamic voltage and frequency scaling (DVFS). Clock gating refers to turning off the clock, power gating refers to turning off the power supply, and DVFS refers to adjusting the operating clock and frequency of the circuit according to the actual flow rate.
[0130] In this application, the first data is used to trigger the second device to detect the first channel. This application does not limit the format of the first data, but the first data may be data with a specific structure.
[0131] In one specific example, the first data includes first alignment information for the second device to quickly lock onto the first data sent by the first device. As an example, the first alignment information may be a first alignment marker (AM). As another example, to reduce the time the second device spends locking onto the first data and improve the efficiency of the second device in detecting the first channel, the first alignment information may be a first RAM.
[0132] In one example, the specific information in the first alignment information is a first numerical value. This application does not specifically limit the exact value of this first numerical value; it can be any value. As a specific example, the first numerical value is 255.
[0133] In this application, the specific information can be obtained through a specific field in the first alignment information. When the first alignment information is a first RAM, the specific field can be CD3 or CD7 of the first RAM. In other words, the specific information in the first RAM can be obtained through CD3 or CD7 of the first RAM. Obtaining the specific information in the first RAM through CD3 or CD7 can mean that the specific information is carried in CD3 or CD7 of the first RAM, or that the content carried in CD3 or CD7 of the first RAM is obtained after specific calculations. This application does not impose specific limitations on this embodiment.
[0134] In another specific example, the first data includes not only the first alignment information but also first indication information, which indicates the state of the receiving component of the first device. In this scenario, the first device can use the first indication information to notify the second device of the state of its receiving component, so that the second device can perform corresponding operations based on the state of the receiving component of the first device.
[0135] In this application, the state of the receiving component of the first device can include an active state and a non-active state. In one example, if the receiving component of the first device is in an active state, the first indication information can include a first code block, which indicates that the receiving component of the first device is in an active state. In another example, if the receiving component of the first device is in a non-active state, the first indication information can include a second code block, which indicates that the receiving component of the first device is in a non-active state. The first code block and the second code block are two different code blocks.
[0136] The embodiments of this application do not specifically limit the first code block and the second code block. The first code block and the second code block can be any two different code blocks. The first code block and the second module can be existing code blocks or newly extended code blocks. The embodiments of this application do not make specific limitations.
[0137] In a specific example, both the first code block and the second code block are PCS code blocks. Specifically, the first code block can be a first PCS code block, and the second code block can be a second PCS code block. In a specific example, the first PCS code block can include an 0 code block or an IDLE code block. The second PCS code block can include an RF code block or an 0 code block. For example: the first code block is an IDLE code block, and the second code block is an RF code block. Or, the first code block is an IDLE code block, and the second code block is an 0 code block. Or, the first code block is an 0 code block, and the second code block is an RF code block.
[0138] S102: The second device receives the first data sent by the first device through the first channel.
[0139] S103: In response to receiving the first data, the second device detects the first channel.
[0140] The second device can receive first data sent by the first device through the first channel, and in response to receiving the first data, the second device performs detection on the first channel. As a specific example, the second device can perform detection on the first channel based on the first data. Specifically, detecting the first channel based on the first data can involve detecting the transmission quality of the first data, which can be used to characterize the channel quality of the first channel.
[0141] In one example, the second device can detect the error rate of the first data to obtain the transmission quality of the first data. There is a certain mapping relationship between the error rate of the first data and the transmission quality of the first data; specifically, the higher the error rate of the first data, the higher the transmission quality of the first data, and vice versa.
[0142] In a specific example, the first data is sent to the second device after being FEC encoded by the first device. In this scenario, the second device detects the error rate of the first data. In a specific implementation, the first data can be FEC decoded to obtain the error rate of the first data. The specific implementation of FEC decoding of the first data to obtain the error rate of the first data can use existing FEC decoding technology, and will not be repeated here.
[0143] The error rates mentioned in this application include, but are not limited to, one or more of the following: codeword error ratio (CER), symbol error ratio (SER), and bit error ratio (BER).
[0144] S104: The second device sends a first response to the first device through the second channel.
[0145] S105: The first device receives the first response sent by the second device through the second channel.
[0146] After detecting the first channel, the second device can send a first response to the first device through the second channel. This first response indicates the channel quality of the first channel. In a specific example, the second device can send the first response to the first device through the second channel when the transmission quality of the first data is greater than or equal to a first threshold. In this scenario, the first response indicates that the channel quality of the first channel meets the requirements. Meeting the requirements for the channel quality of the first channel can be understood as ensuring the data transmission quality of the first channel. This application does not specifically limit the first threshold; the first threshold can be set according to actual conditions.
[0147] Correspondingly, the first device can receive the first response sent by the second device through the second channel.
[0148] In one example, after the first device sends first data to the second device through the first channel, it may start a timer to wait for a response to the first data.
[0149] In one example, the timer is used to record the time difference between the first device sending first data and receiving a response from the second device for the first data. In this scenario, if the first device has not received a response from the second device for the first data when the value of the timer is greater than or equal to a first threshold, the first device can consider that the channel quality of the first channel does not meet the requirements. Conversely, if the first response is sent to the first device by the second device when the transmission quality of the aforementioned first data is greater than or equal to the first threshold, then if the value of the timer is less than the first threshold and the first device receives a response from the second device for the first data, the first device can consider that the channel quality of the first channel meets the requirements.
[0150] In another example, the timer is a countdown timer. In this scenario, if the timer value is 0 and the first device has not yet received a response from the second device regarding the first data, the first device can consider that the channel quality of the first channel does not meet the requirements. Conversely, if the first response is sent by the second device to the first device when the transmission quality of the aforementioned first data is greater than or equal to a first threshold, then if the timer value is greater than 0 and the first device has received a response from the second device regarding the first data, the first device can consider that the channel quality of the first channel meets the requirements.
[0151] In one example, the first response may be a MAC message, and the contents carried in the MAC message are not specifically limited in this embodiment. For example, the target field in the MAC message may be used to indicate that the MAC message is a response message to the first data. The target field may be an Ethernet type field, a destination address field, or other fields in the MAC message, which are not limited here.
[0152] In another example, the first response may include third alignment information and a fourth code block, wherein the fourth code block is used to indicate that the receiving component of the second device is in an operational state. In this scenario, the first device can lock the first response using the third alignment information and determine that the channel quality of the first channel meets the requirements based on the fourth code block indicating that the receiving component of the second device is in an operational state. Wherein:
[0153] Similar to the first alignment information, the third alignment information can also be the third AM or the third RAM, which will not be repeated here.
[0154] In one example, the fourth code block is the same as the first code block mentioned above. For example, if the first code block is an IDLE code block, then the fourth code block is also an IDLE code block; if the first code block is an O code block, then the fourth code block is also an O code block.
[0155] In one example, after receiving the first response, the first device can determine that the channel quality of the first channel meets the requirements. Furthermore, the first device can also send third data to the second device through the first channel. The third data includes fourth alignment information, where a specific value is a second value. The third data is used to notify the second device that the first device is about to send a data stream to the second device through the first channel.
[0156] Similar to the first alignment information, the fourth alignment information can also be the fourth AM or the fourth RAM, which will not be repeated here.
[0157] Regarding the specific information in the fourth alignment information, similar to the specific information in the first alignment information, when the fourth alignment information is the fourth RAM, the specific information in the fourth alignment information can be obtained from CD3 or CD7 in the fourth RAM.
[0158] In this application, the third data may include other information in addition to the fourth alignment information, such as a specific code block (e.g., the IDLE code block). This application does not impose specific limitations on the embodiments.
[0159] This application does not specifically limit the second value to any particular value; the second value is an integer. In a specific example, the second value is 1.
[0160] In a specific example, the first device can send M third data items to the second device through the first channel, where M is an integer greater than 1. In one example, the value of M can be a different value than the aforementioned first value; for example, the value of M can be 36. In this application, each third data item includes fourth alignment information. For any third data item, the fourth alignment information includes the sequence number of the third data item. Furthermore, for the i-th third data item sent among the M third data items, its sequence number is M-i+1, where i is an integer greater than or equal to 1 and less than or equal to M. Example:
[0161] If M is 36, then the first device sends 36 third data to the second device through the first channel. The fourth alignment information in the first third data carries the sequence number 36, the fourth alignment information in the second third data carries the sequence number 35, the fourth alignment information in the third third data carries the sequence number 34, and so on. The fourth alignment information in the 35th third data carries the sequence number 2, and the fourth alignment information in the 36th third data carries the sequence number 1.
[0162] In one example, the fourth alignment information carries the sequence number of the third data, which can be a specific piece of information in the fourth information that is the sequence number of the third data. For details about the specific information in the fourth information, please refer to the description of the specific information in the first alignment information above, which will not be repeated here.
[0163] In one example, after the first device channel sends M third data points to the second device, it can further send a data stream to the second device through the first channel. At this point, the first channel has completed the full switching process from a non-working state to a working state.
[0164] In this application, the first device sends M third data points to the second device before sending a data stream to the second device through the first channel. This allows the second device sufficient time to parse the AM data inserted into the data stream, thus correctly recovering the data stream sent by the first device. Furthermore, the first device can also use the M third data points to transmit other auxiliary information to the second device.
[0165] As described above, the first indication information indicates the state of the receiving component of the first device. The state of the receiving component of the first device may be an active state or a non-active state. In one example, if the first indication information indicates that the receiving component of the first device is in a non-active state, then after S101 and before S104, the first device and the second device can also jointly execute the steps shown in FIG3. FIG3 is a signaling interaction diagram of another communication method provided by an embodiment of this application. The method shown in FIG3 includes the following S201-S204.
[0166] S201: The second device sends second data to the first device through the second channel, and the second data is used to trigger the first device to detect the second channel.
[0167] In one specific example, the second data includes sixth alignment information, used by the first device to quickly lock onto the second data sent by the second device. Similar to the first alignment information, the sixth alignment information can be AM or RAM.
[0168] In one example, similar to the first alignment information, the specific information in the sixth alignment information is a first numerical value. Regarding the first numerical value, please refer to the relevant description above; it will not be repeated here. Regarding the specific information in the sixth alignment information, please refer to the description of the specific information in the first alignment information above; it will not be repeated here.
[0169] In a specific example, the second data includes, in addition to the sixth alignment information, second indication information, which indicates the state of the receiving component of the second device. Since the first channel has not yet fully switched to the working state when the second device sends the second data to the first device, the second indication information indicates that the receiving component of the second device is in a non-working state. As a specific example, the second indication information may include a second code block for indicating that the receiving component of the second device is in a non-working state. Regarding the second code block, please refer to the relevant description above; it will not be repeated here.
[0170] S202: The first device receives the second data sent by the second device through the second channel.
[0171] S203: In response to receiving the second data, the first device detects the second channel.
[0172] The first device can receive second data sent by the second device through the second channel, and in response to receiving the second data, the first device detects the second channel. As a specific example, the first device can detect the second channel based on the second data. Specifically, detecting the second channel based on the second data can involve detecting the transmission quality of the second data, which can be used to characterize the channel quality of the second channel.
[0173] In one example, the first device can detect the error rate of the second data to obtain the transmission quality of the second data. There is a certain mapping relationship between the error rate of the second data and the transmission quality of the second data; specifically, the higher the error rate of the second data, the higher the transmission quality of the second data, and vice versa.
[0174] In a specific example, the second data is sent to the first device after being FEC encoded by the second device. In this scenario, the first device detects the error rate of the second data. In a specific implementation, the second data can be FEC decoded to obtain the error rate of the second data. The specific implementation of FEC decoding of the second data to obtain the error rate of the second data can use existing FEC decoding technology, and will not be repeated here.
[0175] S204: The first device sends a second response to the second device through the first channel.
[0176] S205: The second device receives the second response sent by the first device through the first channel.
[0177] After detecting the second channel, the first device can send a second response to the second device through the first channel. This second response indicates the channel quality of the second channel. In a specific example, the first device can send the second response to the second device through the first channel when the transmission quality of the second data is greater than or equal to a first threshold. In this scenario, the second response indicates that the channel quality of the second channel meets the requirements. Meeting the requirements for the channel quality of the second channel can be understood as ensuring the data transmission quality of the second channel.
[0178] Correspondingly, the second device can receive the second response sent by the first device through the first channel.
[0179] In one example, after the second device sends the second data to the first device through the second channel, it may start a timer to wait for a response to the second data.
[0180] Regarding the "timer for waiting for a response to the second data", its function is the same as that of the "timer for waiting for a response to the first data" mentioned above. Therefore, for the "timer for waiting for a response to the second data", please refer to the description of the "timer for waiting for a response to the first data" mentioned above, and it will not be repeated here.
[0181] In this application, since the first channel has not yet switched to an operational state, it cannot transmit MAC messages. Therefore, the second response can be a code block that can be transmitted at the physical layer. As a specific example, the second response includes second alignment information and a third code block, wherein the third code block is used to indicate that the receiving component of the first device is in an operational state. In this scenario, the second device can lock the second response using the second alignment information and determine that the channel quality of the second channel meets the requirements based on the third code block indicating that the receiving component of the first device is in an operational state. Wherein:
[0182] Similar to the first alignment information, the second alignment information can also be the third AM or the third RAM, which will not be repeated here.
[0183] In one example, the third code block is the same as the first code block mentioned above. For example, if the first code block is an IDLE code block, then the fourth code block is also an IDLE code block; if the first code block is an O code block, then the fourth code block is also an O code block.
[0184] In one example, after receiving the second response, the second device can determine that the channel quality of the second channel meets the requirements. Furthermore, the second device can also send fourth data to the first device through the second channel. This fourth data includes fifth alignment information, where a specific value is a second value. The fourth data is used to notify the first device that the second device is about to send a data stream to the first device through the second channel.
[0185] Similar to the first alignment information, the fifth alignment information can also be the fifth AM or the fifth RAM, which will not be repeated here.
[0186] Regarding the specific information in the fifth alignment information, similar to the specific information in the first alignment information, when the fifth alignment information is the fourth RAM, the specific information in the fifth alignment information can be obtained from CD3 or CD7 in the fifth RAM.
[0187] In this application, the fourth data may include other information in addition to the fifth alignment information, such as a specific code block (e.g., the IDLE code block). This application does not impose specific limitations on the embodiments.
[0188] In a specific example, the second device can send M fourth data to the first device through the second channel. The value of M can be referred to the previous description and will not be repeated here. In this application, each fourth data includes fifth alignment information. For any fourth data, the fifth alignment information included in the fourth data carries the sequence number of the fourth data. Furthermore, for the i-th fourth data sent among the M fourth data, its sequence number is M-i+1, where i is an integer greater than or equal to 1 and less than or equal to M.
[0189] Regarding the method of carrying the serial number in the fifth alignment information, please refer to the previous description of carrying the serial number in the fourth alignment information, which will not be repeated here.
[0190] In one example, after the second device channel sends M fourth data points to the first device, it can further send a data stream back to the first device through the second channel. At this point, the second channel has completed the full switching process from a non-operating state to an operating state.
[0191] In this application, the second device sends M fourth data points to the first device before sending a data stream to the first device via a second channel. This allows the first device sufficient time to parse the AM data inserted into the data stream, thus correctly recovering the data stream sent by the second device. Furthermore, the second device can also utilize the M fourth data points to transmit other auxiliary information to the first device.
[0192] The solutions provided by the embodiments of this application have been described above. Next, with reference to Figures 4 and 5, two possible embodiments of the embodiments of this application will be described.
[0193] In one example, if the first channel is in a non-working state and the second channel is in a working state, and the first device and the second device need to switch the first channel to a working state, then the first device and the second device can perform the steps shown in Figure 4.
[0194] Figure 4 is a schematic diagram of a communication method provided in an embodiment of this application.
[0195] In Figure 4, A represents the first device and B represents the second device. The method shown in Figure 4 includes the following process:
[0196] 1. The first device begins lane check process only for the TX direction.
[0197] The phrase "start performing channel detection processing for the sending direction" mentioned here refers to performing channel detection processing on the aforementioned first channel.
[0198] 2. The MAC of the first device notifies the PCS of the first device to start sending "RAM(255)+IDLE code block". The serializer / deserializer (serdes) of the first device in the transmission direction enters the working state, and starts the timer lane_check_wait_rsp_timer (TXMAC informs TXPCS of start sending RAM(255)+IDLE, serdes TX enter EE0, start lane_check_wait rsp_timer) for waiting for response.
[0199] Among them, RAM(255) refers to RAM carrying the value 255, and EE0 indicates the working state.
[0200] The “RAM(255)+IDLE” mentioned here corresponds to the first data in the above embodiment.
[0201] 3. The serdes signal detection circuit of the second device detects a signal, or the second device detects a failure in the EE1 state of the pseudo random binary sequence (PRBS) detection (check fail), and reports it to the processor of the second device. The second device then starts to perform channel detection processing in the receiving direction (if received alos from serdes, report to processor, processor start lane check processing only RX direction).
[0202] Among them, EE1 state is a non-working state, in which the first device sends PRBS to the second device through the first channel.
[0203] 4. The second device completes RAM locking and, before the timer expires, determines that the received data's SER (Sequence Parameter) is less than a certain threshold. The PCS (Processing System) of the second device informs the MAC (Machine Interface) of the second device: RAM locking is successful, and the SER of the first channel is low. The MAC of the second device instructs the PCS of the second device to send a channel detection response LANE_CHECK_RSP message to the first device. Specifically, the PCS of the second device can inform the MAC of successful RAM locking via the subphy_status signal. (When RAM is locked and SER check is OK before timeout, pass the subphy_status signal.) to RXMAC,RXPCS receive IDLE before wait timer done,indicates the lane is OK and raise the lane check pass ,When both subphy_st and lane check pass are true, RXMAC notices TXMAC to send LANE CHECK RSP message).
[0204] The LANE_CHECK_RSP message mentioned here corresponds to the first response in the above embodiments.
[0205] 5. Before the timer lane_check_wait_rsp_timer expires, the first device receives a LANE_CHECK_RSP message, indicating that the channel quality of the first channel meets the requirements. (RXMAC receives LANE CHK RSP before lane_check_wait_rsp_timer does, indicating the lane is OK).
[0206] 6. The first device's receiving MAC notification: The first device's sending MAC itself has received a lane check response message. The first device's MAC starts the speed-up process and begins sending multiple RAMs and an AM. (RXMAC notice TXMAC: it received a lane check response message, TXMAC start speed up produce: send RAMs and an AM).
[0207] In one example, the first device continuously sends 36 "RAM(36-i+1)+IDLE" to the second device through the first channel, where RAM(36-i+1) represents a specific value 36-i+1 carried in RAM, and i is a value greater than or equal to 1 and less than or equal to 36. After sending "RAM(1)+IDLE", AM and data stream are sent to the second device through the first channel.
[0208] 7. After the PCS of the second device receives RAM carrying the value 1, it notifies the MAC and PMA of the second device. The MAC of the second device locks AM and starts receiving data stream. (RXPCS receives RAM with down count = 1, notifies RXMAC and RXPMA, RXPMA locks AM and switches the traffic on).
[0209] 8. The second device locks the AM and begins receiving the data stream. (RXPMA locks the AM and switches the traffic on.)
[0210] In another example, if both the first and second channels are in a non-working state, and the first and second devices need to switch the first and second channels to a working state, then the first and second devices can perform the steps shown in Figure 5.
[0211] Figure 5 is a schematic diagram of another communication method provided in an embodiment of this application.
[0212] In Figure 5, A represents the first device, B represents the second device, TX represents transmitting, and RX represents receiving. The channel between A TX and B RX corresponds to the first channel in the above embodiments, and the channel between B TX and A RX corresponds to the second channel in the above embodiments. The method shown in Figure 5 includes the following process:
[0213] 1. The first device begins lane check process only for the TX direction.
[0214] The phrase "start performing channel detection processing for the sending direction" mentioned here refers to performing channel detection processing on the aforementioned first channel.
[0215] 2. The first device sends a MAC notification to the first device's PCS to start sending "RAM(255)+RF code block". The serdes in the sending direction of the first device enters the working state, and the timer lane_check_wait_rsp_timer for waiting for a response is started (TXMAC informs TXPCS of start sending RAM(255)+RF, serdes TX enter EE0, start lane_check_wait rsp_timer).
[0216] The "RAM(255)+RF code block" mentioned here corresponds to the first data in the above embodiment.
[0217] 3. The second device's serdes signal detection circuit detects a signal in state EE2 or EE3, or the second device detects a PRBS check fail in state EE1.
[0218] Among them, EE1 is a non-working state in which the first device sends PRBS to the second device through the first channel. EE2 and EE3 are the other two non-working states.
[0219] 3.1: The receiving component of the second device exits the non-operating mode. (SubPHY RX exits EE 1 / EE2 / EE3 mode).
[0220] 3.2: If the receiving component of the second device starts working, the receiving PMA of the second device starts locking the RAM and outputs the bit stream to the receiving PCS of the second device.
[0221] If the second device is in state EE2 or EE3 before executing 3.1, the receiving component of the second device will start working from the non-working state. If the second device is in state EE1 before executing 3.1, the receiving component of the second device will always be in the working state.
[0222] 3.3: The second device completes RAM locking and confirms that SER is low. (RAM is locked and SER check is OK).
[0223] 4. The second device receives the MAC notification. The second device sends the MAC "RAM(255)+IDLE".
[0224] The "RAM(255)+IDLE" mentioned here corresponds to the first response in the above embodiment. 5. Before the timer lane_check_wait_rsp_timer expires, the first device receives IDLE, indicating that the channel quality of the first channel meets the requirements. The receiving MAC of the first device notifies the receiving PMA to restart the RAM lock to avoid loss of lock. (RXMAC receives IDLE before lane_check_wait_rsp_timer done, indicates the lane is OK, RXMAC notifies RXPMA to restart RAM lock to aign, which leads to temporary unlock).
[0225] 6. Upon receiving a lane check response block (IDLE), the receiving MAC of the first device notifies the transmitting MAC of the first device to begin the speed-up process: starting to send multiple RAMs and AMs.
[0226] In one example, the first device continuously sends 36 "RAM(36-i+1)+IDLE" to the second device through the first channel, where RAM(36-i+1) represents a specific value 36-i+1 carried in RAM, and i is a value greater than or equal to 1 and less than or equal to 36. After sending "RAM(1)+IDLE", AM and data stream are sent to the second device through the first channel.
[0227] 7. After the receiving PCS of the second device receives RAM carrying the value 1, it notifies the receiving MAC and receiving PMA of the second device. The receiving MAC of the second device locks AM and starts receiving the data stream. (RXPCS receives RAM with down count = 1, notifies RXMAC and RXPMA, RXPMA locks AM and switches the traffic on).
[0228] 8. The receiving PMA of the second device locks the AM and begins receiving the data stream. (RXPMA locks the AM and switches the traffic on).
[0229] In addition, between steps 3 and 4, B TX performs the same operation as A TX, corresponding to steps 1 and 2, that is, the second device also starts to perform channel detection processing for the transmission direction, which will not be repeated here.
[0230] Similarly, after B TX performs the same operation as A TX, the first device will also perform the same operation as the second device, corresponding to the aforementioned steps 3, 3.1, 3.2 and 3.3, that is: the first device performs RAM locking and SER detection for the data sent by the second device.
[0231] Similarly, the first device receives a MAC notification and sends a MAC message "RAM(255)+IDLE".
[0232] The "RAM(255)+IDLE" sent by the first device corresponds to the second response in the above embodiment.
[0233] Furthermore, the operation of the second device after receiving the second response is basically the same as the operation of the first device after receiving the first response, except that the roles of the first device and the second device are interchanged, which will not be described again here.
[0234] It should be noted that, for the sake of greater simplicity and clarity in the accompanying drawings, Figure 5 shows the complete steps for the first channel to switch from a non-working state to a working state. For the second channel to switch from a non-working state to a working state, the steps are "#Step 1" to "#Step 8" in Figure 5.
[0235] Based on the communication method provided in the above embodiments, this application also provides a corresponding device, which will be described below with reference to the accompanying drawings.
[0236] Referring to Figure 6, this figure is a schematic diagram of the structure of a communication device provided in an embodiment of this application. The communication device shown in Figure 6 can be applied to the first device mentioned in the above embodiments to execute the method steps performed by the first device.
[0237] As shown in Figure 6, the communication device 600 includes a transmitting unit 601 and a receiving unit 602.
[0238] The transmitting unit 601 is used to transmit first data to the second device through a first channel. The first channel and the second channel are transceiver channels between the first device and the second device. The first channel is a channel between the transmitting component of the first device and the receiving component of the second device, and the second channel is a channel between the receiving component of the first device and the transmitting component of the second device. The first data is used to trigger the second device to detect the first channel.
[0239] The receiving unit 602 is used to receive the first response sent by the second device through the second channel.
[0240] In one possible implementation, the first data includes: first alignment information, or; the first alignment information and first indication information, wherein the first indication information is used to indicate the state of the receiving component of the first device.
[0241] In one possible implementation, the first indication information includes a first code block indicating that the receiving component of the first device is in a working state, or the first indication information includes a second code block indicating that the receiving component of the first device is in a non-working state, and the first code block and the second code block are different.
[0242] In one possible implementation, the first code block includes: a first physical coding sublayer (PCS) code block.
[0243] In one possible implementation, the first PCS code block includes: an idle IDLE code block or a predetermined sequence O code block.
[0244] In one possible implementation, the second code block includes: a second PCS code block.
[0245] In one possible implementation, the second PCS code block includes: a remote fault RF code block or an O code block.
[0246] In one possible implementation, the first alignment information includes: a first fast alignment flag RAM.
[0247] In one possible implementation, the specific information in the first alignment information is a first numerical value.
[0248] In one possible implementation, the first value is 255.
[0249] In one possible implementation, the first alignment information is a first RAM, and specific information in the first alignment information is obtained through the countdown CD3 of the first RAM or the CD7 of the first RAM.
[0250] In one possible implementation, the first indication information indicates that the receiving component of the first device is in a non-operating state, and the receiving unit 602 is further configured to receive second data sent by the second device through the second channel before receiving the first response, the second data being used to trigger the first device to detect the second channel.
[0251] In one possible implementation, the apparatus further includes: a processing unit, configured to detect the second channel in response to receiving the second data; and a sending unit 601, configured to send a second response to the second apparatus via the first channel.
[0252] In one possible implementation, sending the second response to the second device through the first channel includes: sending the second response to the second device through the first channel when the transmission quality of the second data is greater than or equal to a first threshold.
[0253] In one possible implementation, the second response includes: second alignment information and a third code block, the third code block indicating that the receiving component of the first device is in an operational state.
[0254] In one possible implementation, the first response includes: a Media Access Control (MAC) message; or, third alignment information and a fourth code block, the fourth code block indicating that the receiving component of the second device is in an operational state.
[0255] In one possible implementation, the sending unit 601 is further configured to: send third data to the second device through the first channel, the third data including fourth alignment information, wherein a specific piece of information in the fourth alignment information is a second value.
[0256] In one possible implementation, the second value is 1.
[0257] In one possible implementation, sending third data to the second device through the first channel includes: sending M pieces of third data to the second device through the first channel, each piece of third data including fourth alignment information, wherein for any piece of third data, the fourth alignment information includes a sequence number of the third data, wherein the sequence number of the i-th piece of third data sent among the M pieces of third data is equal to M-i+1, and i is an integer greater than or equal to 1 and less than or equal to M.
[0258] In one possible implementation, the sending unit 601 is further configured to: after sending the M third data to the second device through the first channel, send a data stream to the second device through the first channel.
[0259] In one possible implementation, the receiving unit 602 is further configured to receive fourth data sent by the second device through the second channel after sending a second response to the second device through the first channel, the fourth data including fifth alignment information, the characteristic information of the fifth alignment information being a second value.
[0260] In one possible implementation, the processing unit of the device is further configured to control the transmitting component of the first device to enter a working state before transmitting the first data to the second device via the first channel.
[0261] In one possible implementation, the device includes a processing unit further configured to, after sending the first data to the second device via the first channel, activate a timer to wait for a response to the first data.
[0262] Referring to Figure 7, this figure is a schematic diagram of another communication device provided in an embodiment of this application. The communication device shown in Figure 7 can be applied to the second device mentioned in the above embodiments to execute the method steps performed by the second device.
[0263] As shown in Figure 7, the communication device 700 includes: a receiving unit 701, a processing unit 702, and a sending unit 703.
[0264] The receiving unit 701 is used to receive first data sent by the first device through a first channel. The first channel and the second channel are transceiver channels between the first device and the second device. The first channel is a channel between the transmitting component of the first device and the receiving component of the second device, and the second channel is a channel between the receiving component of the first device and the transmitting component of the second device.
[0265] The processing unit 702 is configured to detect the first channel in response to receiving the first data.
[0266] The sending unit 703 is used to send a first response to the first channel through the second channel.
[0267] In one possible implementation, the first data includes: first alignment information, or the first alignment information and first indication information, wherein the first indication information is used to indicate the state of the receiving component of the first device.
[0268] In one possible implementation, the first indication information includes a first code block indicating that the receiving component of the first device is in a working state, or the first indication information includes a second code block indicating that the receiving component of the first device is in a non-working state, wherein the first code block and the second code block are different.
[0269] In one possible implementation, the first code block includes: a first physical coding sublayer (PCS) code block.
[0270] In one possible implementation, the first PCS code block includes: an idle IDLE code block or a predetermined sequence O code block.
[0271] In one possible implementation, the second code block includes: a second PCS code block.
[0272] In one possible implementation, the second PCS code block includes: a remote fault RF code block or an O code block.
[0273] In one possible implementation, the first alignment information includes: a first fast alignment flag RAM.
[0274] In one possible implementation, the specific information in the first alignment information is a first numerical value.
[0275] In one possible implementation, the first value is 255.
[0276] In one possible implementation, the first alignment information is a first RAM, and specific information in the first alignment information is obtained through the countdown CD3 of the first RAM or the CD7 of the first RAM.
[0277] In one possible implementation, the first indication information indicates that the receiving component of the first device is in a non-operating state. The sending unit 703 is further configured to send second data to the first device via the second channel before sending the first response. The second data is used to trigger the first device to detect the second channel. The receiving unit 701 is further configured to receive the second response sent by the first device via the first channel.
[0278] In one possible implementation, the second response includes: second alignment information and a third code block, the third code block indicating that the receiving component of the first device is in an operational state.
[0279] In one possible implementation, the first response includes: third alignment information and a fourth code block, the fourth code block indicating that the receiving component of the second device is in an operational state.
[0280] In one possible implementation, the receiving unit 701 is further configured to: receive third data sent by the first device through the first channel, the third data including fourth alignment information, wherein a specific piece of information in the fourth alignment information is a second value.
[0281] In one possible implementation, the second value is 1.
[0282] In one possible implementation, the receiving unit 701 is further configured to: after receiving the M third data sent by the first device through the first channel, receive the data stream sent by the second device through the first channel.
[0283] In one possible implementation, the sending unit 703 is further configured to send fourth data to the first device via the second channel after receiving the second response sent by the first device via the first channel, the fourth data including fifth alignment information, the characteristic information of the fifth alignment information being a second value.
[0284] In one possible implementation, sending fourth data to the first device via the second channel includes: sending M fourth data to the first device via the second channel, each of the fourth data including fifth alignment information, wherein for any fourth data, the fifth alignment information includes the sequence number of the fourth data, wherein the sequence number of the i-th fourth data sent among the M fourth data is equal to M-i+1, and i is an integer greater than or equal to 1 and less than or equal to M.
[0285] In one possible implementation, the sending unit 703 is further configured to send a data stream to the first device via the second channel after sending M fourth data to the first device via the second channel.
[0286] In one possible implementation, sending a first response to the first device via the second channel includes: sending the first response to the first device via the second channel when the transmission quality of the first data is greater than or equal to a first threshold.
[0287] In one possible implementation, the first data is sent to the second device after being encoded by forward error correction (FEC) by the first device. The transmission quality of the first data is determined by performing FEC decoding on the first data to obtain the error rate of the first data, and the error rate of the first data is used to indicate the transmission quality of the first data.
[0288] In one possible implementation, the processing unit 702 is further configured to control the transmitting component of the second device to enter a working state before transmitting the second data to the second device via the second channel.
[0289] In one possible implementation, the processing unit 702 is further configured to, after sending the second data to the second device via the second channel, open a timer for waiting for a response to the second data.
[0290] Furthermore, this application also provides a communication device 800, as shown in FIG8, which is a schematic diagram of the structure of a communication device provided in this application embodiment. The communication device 800 includes a communication interface 801 and a processor 802 connected to the communication interface 801. The communication device 800 can be used to perform the steps executed by the first device or the second device in the above embodiments.
[0291] When the communication device 800 performs the steps executed by the first device, the communication interface 801 performs the receiving and / or transmitting operations performed by the first device. The processor 802 performs other operations performed by the first device besides the receiving and / or transmitting operations. For example, the communication interface 801 is used to send first data to the second device through a first channel, where the first channel and the second channel are transceiver channels between the first device and the second device. The first channel is a channel between the transmitting component of the first device and the receiving component of the second device, and the second channel is a channel between the receiving component of the first device and the transmitting component of the second device. The first data is used to trigger the second device to detect the first channel; and the second device receives a first response sent by the second device through the second channel. Optionally, the processor 802 is used to detect the second channel in response to receiving the second data.
[0292] When the communication device 800 performs steps executed by the second device, the communication interface 801 performs receiving and / or transmitting operations performed by the second device. The processor 802 performs other operations performed by the second device besides receiving and / or transmitting operations. For example, the communication interface 801 receives first data transmitted by the first device through a first channel, where the first channel and the second channel are transceiver channels between the first device and the second device. The first channel is a channel between the transmitting component of the first device and the receiving component of the second device, and the second channel is a channel between the receiving component of the first device and the transmitting component of the second device. The processor 802 detects the first channel in response to receiving the first data. The communication interface 801 is also used to send a first response to the first channel through the second channel.
[0293] In one example, the processor 802 includes at least one circuit for performing some or all of the operations performed by the processor 802.
[0294] The circuits in the embodiments of this application include, but are not limited to, application-specific integrated circuits (ASICs) or field programmable gate arrays (FPGAs).
[0295] This application also provides a computer-readable storage medium storing instructions or computer programs that, when executed on a processor, can implement any one or more operations of the methods described in the foregoing embodiments (e.g., the methods shown in any one of Figures 2, 3, 4, or 5).
[0296] This application also provides a computer program product, including a computer program that, when run on a processor, can implement any one or more of the methods described in the foregoing embodiments (e.g., the methods shown in any one of Figures 2, 3, 4, or 5).
[0297] The terms "first," "second," "third," "fourth," etc. (if present) in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a particular order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments described herein can be implemented in a sequence other than that illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0298] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0299] In the embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical business division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces, indirect coupling or communication connection between apparatuses or units, and may be electrical, mechanical, or other forms.
[0300] The units described as separate components may or may not be physically separate. 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 the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0301] Furthermore, the various business units in the embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software business unit.
[0302] If the integrated unit is implemented as a software business unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all 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 to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0303] Those skilled in the art will recognize that, in one or more of the examples above, the services described in this application can be implemented using hardware, software, firmware, or any combination thereof. When implemented using software, these services can be stored in a computer-readable medium or transmitted as one or more instructions or code on a computer-readable medium. Computer-readable media include computer storage media and communication media, wherein communication media include any medium that facilitates the transfer of computer programs from one place to another. Storage media can be any available medium accessible to general-purpose or special-purpose computers.
[0304] The above specific embodiments further illustrate the purpose, technical solution and beneficial effects of this application. It should be understood that the above are only specific embodiments of this application.
[0305] The above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit it. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.
Claims
1. A communication method, characterized in that, Applied to a first device, the method includes: First data is sent to the second device through a first channel. The first channel and the second channel are transceiver channels between the first device and the second device. The first channel is a channel between the transmitting component of the first device and the receiving component of the second device, and the second channel is a channel between the receiving component of the first device and the transmitting component of the second device. The first data is used to trigger the second device to detect the first channel. The first response sent by the second device is received through the second channel.
2. The method according to claim 1, characterized in that, The first data includes: First alignment information, or; The first alignment information and the first indication information, wherein the first indication information is used to indicate the status of the receiving component of the first device.
3. The method according to claim 2, characterized in that, The first indication information includes a first code block, which indicates that the receiving component of the first device is in a working state, or; The first indication information includes a second code block, which indicates that the receiving component of the first device is in a non-operating state, and the first code block and the second code block are different.
4. The method according to claim 3, characterized in that, The first code block includes: the first physical coding sublayer PCS code block.
5. The method according to claim 4, characterized in that, The first PCS code block includes: an idle IDLE code block or a predetermined sequence O code block.
6. The method according to any one of claims 3-5, characterized in that, The second code block includes: the second PCS code block.
7. The method according to claim 6, characterized in that, The second PCS code block includes: a remote fault RF code block or an O code block.
8. The method according to any one of claims 1-7, characterized in that, The first alignment information includes: First fast alignment flag RAM.
9. The method according to any one of claims 1-8, characterized in that, The specific information in the first alignment information is the first numerical value.
10. The method according to claim 9, characterized in that, The first value is 255.
11. The method according to claim 9 or 10, characterized in that, The first alignment information is a first RAM, and specific information in the first alignment information is obtained through the countdown CD3 of the first RAM or the CD7 of the first RAM.
12. The method according to any one of claims 2-11, characterized in that, The first indication information indicates that the receiving component of the first device is in a non-operating state. Before receiving the first response, the method further includes: The second data sent by the second device is received through the second channel, and the second data is used to trigger the first device to detect the second channel.
13. The method according to claim 12, characterized in that, The method further includes: In response to receiving the second data, the second channel is detected; A second response is sent to the second device through the first channel.
14. The method according to claim 13, characterized in that, Sending a second response to the second device through the first channel includes: When the transmission quality of the second data is greater than or equal to the first threshold, the second response is sent to the second device through the first channel.
15. The method according to claim 13 or 14, characterized in that, The second response includes: The second alignment information and the third code block indicate that the receiving component of the first device is in an operational state.
16. The method according to any one of claims 1-15, characterized in that, The first response includes: Media access control MAC message; or, The third alignment information and the fourth code block, the fourth code block indicating that the receiving component of the second device is in an operational state.
17. The method according to any one of claims 1-16, characterized in that, The method further includes: The third data is sent to the second device through the first channel. The third data includes fourth alignment information, and the specific information in the fourth alignment information is a second value.
18. The method according to claim 17, characterized in that, The second value is 1.
19. The method according to claim 17 or 18, characterized in that, Sending third data to the second device through the first channel, including: M third data are sent to the second device through the first channel. Each third data includes fourth alignment information. For any third data, the fourth alignment information includes the sequence number of the third data. The sequence number of the i-th third data sent among the M third data is equal to M-i+1, where i is an integer greater than or equal to 1 and less than or equal to M.
20. The method according to claim 19, characterized in that, The method further includes: After sending the M third data items to the second device through the first channel, a data stream is sent to the second device through the first channel.
21. The method according to any one of claims 13-16, characterized in that, After sending a second response to the second device via the first channel, the method further includes: The fourth data sent by the second device is received through the second channel. The fourth data includes fifth alignment information, and the characteristic information of the fifth alignment information is a second value.
22. The method according to any one of claims 1-21, characterized in that, Before sending the first data to the second device via the first channel, the method further includes: The transmitting component of the first device is controlled to enter the working state.
23. The method according to any one of claims 1-22, characterized in that, After sending the first data to the second device via the first channel, the method further includes: Start a timer to wait for a response to the first data.
24. A communication method, characterized in that, Applied to a second device, the method includes: The system receives first data sent by the first device through a first channel. The first channel and the second channel are transceiver channels between the first device and the second device. The first channel is a channel between the transmitting component of the first device and the receiving component of the second device, and the second channel is a channel between the receiving component of the first device and the transmitting component of the second device. In response to receiving the first data, the first channel is detected; The first response is sent to the first channel through the second channel.
25. The method according to claim 24, characterized in that, The first data includes: First alignment information, or the first alignment information and first indication information, wherein the first indication information is used to indicate the state of the receiving component of the first device.
26. The method according to claim 25, characterized in that, The first indication information includes a first code block, which indicates that the receiving component of the first device is in a working state; or, the first indication information includes a second code block, which indicates that the receiving component of the first device is in a non-working state, and the first code block and the second code block are different.
27. The method according to claim 26, characterized in that, The first code block includes: the first physical coding sublayer PCS code block.
28. The method according to claim 27, characterized in that, The first PCS code block includes: an idle IDLE code block or a predetermined sequence O code block.
29. The method according to any one of claims 26-28, characterized in that, The second code block includes: the second PCS code block.
30. The method according to claim 29, characterized in that, The second PCS code block includes: a remote fault RF code block or an O code block.
31. The method according to any one of claims 24-30, characterized in that, The first alignment information includes: First fast alignment flag RAM.
32. The method according to any one of claims 24-31, characterized in that, The specific information in the first alignment information is the first numerical value.
33. The method according to claim 32, characterized in that, The first value is 255.
34. The method according to claim 32 or 33, characterized in that, The first alignment information is a first RAM, and specific information in the first alignment information is obtained through the countdown CD3 of the first RAM or the CD7 of the first RAM.
35. The method according to any one of claims 25-34, characterized in that, The first indication information indicates that the receiving component of the first device is in a non-operating state. Before sending the first response, the method further includes: The second data is sent to the first device through the second channel, and the second data is used to trigger the first device to detect the second channel; The second response sent by the first device is received through the first channel.
36. The method according to claim 35, characterized in that, The second response includes: The second alignment information and the third code block indicate that the receiving component of the first device is in an operational state.
37. The method according to any one of claims 24-36, characterized in that, The first response includes: The third alignment information and the fourth code block, the fourth code block indicating that the receiving component of the second device is in an operational state.
38. The method according to any one of claims 24-37, characterized in that, The method further includes: The third data sent by the first device is received through the first channel. The third data includes fourth alignment information, and the specific information in the fourth alignment information is a second value.
39. The method according to claim 38, characterized in that, The second value is 1.
40. The method according to claim 38 or 39, characterized in that, The method further includes: After receiving the M third data sent by the first device through the first channel, the data stream sent by the second device is received through the first channel.
41. The method according to claim 35 or 36, characterized in that, After receiving the second response sent by the first device through the first channel, the method further includes: The fourth data is sent to the first device through the second channel. The fourth data includes fifth alignment information, and the characteristic information of the fifth alignment information is a second value.
42. The method according to claim 41, characterized in that, Sending fourth data to the first device via the second channel, including: M fourth data are sent to the first device through the second channel. Each fourth data includes fifth alignment information. For any fourth data, the fifth alignment information includes the sequence number of the fourth data. The sequence number of the i-th fourth data sent among the M fourth data is equal to M-i+1, where i is an integer greater than or equal to 1 and less than or equal to M.
43. The method according to claim 42, characterized in that, The method further includes: After sending M fourth data points to the first device through the second channel, a data stream is sent to the first device through the second channel.
44. The method according to any one of claims 24-43, characterized in that, Sending a first response to the first device via the second channel, including: When the transmission quality of the first data is greater than or equal to the first threshold, the first response is sent to the first device through the second channel.
45. The method according to claim 44, characterized in that, The first data is transmitted to the second device after undergoing forward error correction (FEC) encoding by the first device. The transmission quality of the first data is determined in the following manner: The first data is FEC decoded to obtain the error rate of the first data, which is used to indicate the transmission quality of the first data.
46. The method according to claim 35 or 36, characterized in that, Before sending the second data to the second device via the second channel, the method further includes: The transmitting component of the second device is controlled to enter the working state.
47. The method according to claim 35 or 36, characterized in that, After sending the second data to the second device via the second channel, the method further includes: Start a timer to wait for a response to the second data.
48. A communication device, characterized in that, The apparatus includes at least one unit that performs the method according to any one of claims 1-47.
49. A communication device, characterized in that, It includes a processor and an interface circuit, the interface circuit being used to perform the receiving operation and / or transmitting operation as described in any one of claims 1-47, and the processor being used to perform operations other than the receiving operation and transmitting operation as described in any one of claims 1-47.
50. A computer-readable storage medium, characterized in that, Includes instructions or computer programs that, when executed on a processor, implement the method described in any one of claims 1-47.
51. A computer program product, characterized in that, The computer program product includes instructions or a computer program that, when run on a computer, causes the computer to perform the method described in any one of claims 1-47.