Inter-device two-layer communication method and device, and storage medium

By encapsulating Layer 2 data packets into Layer 3 data packets using UPF network elements and transmitting them wirelessly through a Layer 3 tunnel, the problem of high data transmission costs for Layer 2 communication devices in IoT scenarios is solved, and maintenance costs are reduced.

CN116614460BActive Publication Date: 2026-04-07CHINA UNITED NETWORK COMM GRP CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-05-29
Publication Date
2026-04-07

AI Technical Summary

Technical Problem

In IoT scenarios, the data transmission cost of Layer 2 communication devices is high, requiring the deployment of a large number of cables and optical fibers, which increases operation and maintenance costs.

Method used

The UPF network element receives and encapsulates Layer 2 data packets to form Layer 3 data packets, which are then transmitted wirelessly through a Layer 3 tunnel, avoiding the deployment of cables and optical fibers.

Benefits of technology

It reduces operation and maintenance costs, enables wireless Layer 2 data packet transmission, and reduces reliance on cables and optical fibers.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116614460B_ABST
    Figure CN116614460B_ABST
Patent Text Reader

Abstract

The application provides a kind of inter-device layer 2 communication method, device and storage medium, related to communication technical field, for solving the problem of high data transmission cost of layer 2 communication device in Internet of Things scene.The method comprises: UPF network element receives layer 2 data packet from the first device, and the first device is the device based on Ethernet mode communication.Afterwards, UPF network element encapsulates layer 2 data packet to obtain layer 3 data packet.Then, UPF network element sends layer 3 data packet to target device through layer 3 tunnel channel.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of communications, and more particularly to a two-layer communication method, apparatus, and storage medium between devices. Background Technology

[0002] With the in-depth development of technologies such as the Industrial Internet, the Internet of Vehicles, and the Internet of Things, different terminal devices can establish connections through communication technologies to complete data transmission between them. For example, Layer 2 communication devices (i.e., devices based on Ethernet communication), such as Programmable Logic Controllers (PLCs), Data Transfer Units (DTUs), cameras, and industrial controllers, can use unicast, multicast, and broadcast modes for Layer 2 communication.

[0003] Currently, in IoT scenarios, Layer 2 communication devices can connect to the sending end's data communication device (such as a router) and transmit data to the receiving end device (such as a server or terminal) via a wired connection through the receiving end's data communication device. However, the above technical solution requires the deployment of a large number of cables and optical fibers, increasing operation and maintenance costs. Summary of the Invention

[0004] This application provides a two-layer communication method, apparatus, and storage medium between devices to solve the problem of high data transmission costs for two-layer communication devices in IoT scenarios.

[0005] To achieve the above objectives, this application adopts the following technical solution:

[0006] Firstly, this application provides a Layer 2 communication method between devices. In this method, a User Port Function (UPF) network element receives Layer 2 data packets from a first device, which is a device communicating in Ethernet mode. Then, the UPF network element encapsulates the Layer 2 data packets to obtain Layer 3 data packets. Finally, the UPF network element sends the Layer 3 data packets to the target device through a Layer 3 tunnel path.

[0007] Based on the above technical solution, the UPF network element receives Layer 2 data packets from a first device, which is a device that communicates in Ethernet mode. The UPF network element then encapsulates the Layer 2 data packets to obtain Layer 3 data packets. The UPF network element can then send these Layer 3 data packets to the target device through a Layer 3 tunnel. In this way, in the technical solution of this application, the first device can wirelessly forward Layer 2 data packets through the target device and the Layer 3 tunnel, eliminating the need to deploy a large number of cables and optical fibers, thus reducing operation and maintenance costs.

[0008] In one possible design, the UPF network element constructs a three-layer tunnel path based on a three-layer tunnel path protocol. The three-layer tunnel path includes: Ethernet over GRE (EoGRE) tunnel or Network Virtualization using Generic Routing Encapsulation (NVGRE) tunnel.

[0009] In one possible design, the target device is a data communication device with a 5G module; or, the target device includes: a data communication device and a 5G terminal device, with the data communication device connected to the 5G terminal device, and the data communication device used to parse three-layer data packets.

[0010] In one possible design, the UPF network element receives Protocol Data Unit (PDU) sessions from a second device. The PDU session includes Layer 2 data packets, and the second device is connected to the first device.

[0011] In one possible design, the UPF network element is based on the N6 interface and sends three-layer data to the target device through a three-layer tunnel path.

[0012] Secondly, this application provides a two-layer communication device between devices, applied to a UPF network element. The device includes a receiving unit, a processing unit, and a transmitting unit.

[0013] The receiving unit receives Layer 2 data packets from a first device, which is a device that communicates based on Ethernet. The processing unit encapsulates the Layer 2 data packets to obtain Layer 3 data packets. The sending unit transmits the Layer 3 data packets to the target device through a Layer 3 tunnel.

[0014] In one possible design, the processing unit is used to construct a three-layer tunnel path based on a three-layer tunneling protocol, which includes an EoGRE tunnel or an NVGRE tunnel.

[0015] In one possible design, the target device is a data communication device with a 5G module; or, the target device includes: a data communication device and a 5G terminal device, with the data communication device connected to the 5G terminal device, and the data communication device used to parse three-layer data packets.

[0016] In one possible design, a receiving unit is used to receive Protocol Data Unit (PDU) sessions from a second device. The PDU sessions include Layer 2 data packets, and the second device is connected to the first device.

[0017] In one possible design, the transmitting unit is used to send Layer 3 data to the target device via a Layer 3 tunnel path based on the N6 interface.

[0018] Thirdly, this application provides a two-layer communication device between devices, the device comprising: a processor and a memory; the processor and the memory being coupled; the memory being used to store one or more programs, the one or more programs including computer-executable instructions, wherein when the two-layer communication device between devices is running, the processor executes the computer-executable instructions stored in the memory to implement the two-layer communication method between devices as described in the first aspect and any possible implementation thereof.

[0019] Fourthly, this application provides a computer-readable storage medium storing instructions that, when executed on a computer, cause the computer to perform the two-layer communication method between devices described in the first aspect and any possible implementation thereof.

[0020] Fifthly, this application provides a chip including a processor and a communication interface, the communication interface being coupled to the processor, the processor being used to run computer programs or instructions to implement a two-layer communication method between devices as described in the first aspect and any possible implementation thereof.

[0021] The technical problems and effects that the two-layer communication devices, computer equipment, computer storage media or chips between devices can solve and achieve in the above solution can be found in the technical problems and effects solved in the first aspect above, and will not be repeated here. Attached Figure Description

[0022] Figure 1 A system architecture diagram of a communication system provided in this application embodiment;

[0023] Figure 2 A system architecture diagram of another communication system provided in this application embodiment;

[0024] Figure 3 A schematic flowchart illustrating a Layer 2 communication method between devices provided in an embodiment of this application;

[0025] Figure 4 A schematic diagram of a two-layer communication device between devices provided in an embodiment of this application;

[0026] Figure 5 A schematic diagram of another layer-two communication device between devices provided in this application embodiment;

[0027] Figure 6 A conceptual partial view of a computer program product provided for an embodiment of this application. Detailed Implementation

[0028] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0029] In this article, the character " / " generally indicates that the objects before and after it are in an "or" relationship. For example, A / B can be understood as A or B.

[0030] The terms “first” and “second” in the specification and claims of this application are used to distinguish different objects, rather than to describe a specific order of objects.

[0031] Furthermore, the terms "comprising" and "having," and any variations thereof, used in the description of this application are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or modules is not limited to the steps or modules listed, but may optionally include other steps or modules not listed, or may optionally include other steps or modules inherent to such process, method, product, or device.

[0032] Furthermore, in the embodiments of this application, the words "exemplary" or "for example" are used to indicate that they are examples, illustrations, or descriptions. Any embodiment or design that is described as "exemplary" or "for example" in this application should not be construed as being more preferred or advantageous than other embodiments or design options. Specifically, the use of the words "exemplary" or "for example" is intended to present concepts in a concrete manner.

[0033] Before providing a detailed description of the device-to-device Layer 2 communication method of the embodiments of this application, the implementation environment and application scenarios of the embodiments of this application will be introduced first.

[0034] First, the application scenarios of the embodiments of this application will be introduced.

[0035] The Layer 2 communication method between devices in this application is applied to scenarios where devices perform Layer 2 communication. In related technologies, Layer 2 communication devices (i.e., devices based on Ethernet communication), such as Programmable Logic Controllers (PLCs), Data Transfer Units (DTUs), cameras, and industrial controllers, can perform Layer 2 communication using unicast, multicast, and broadcast modes. Specifically, Layer 2 communication devices can communicate in the following ways.

[0036] In the first method, the Layer 2 communication device can connect to the data communication device at the sending end (such as a router) and transmit data to the receiving end device (such as a server, terminal, etc.) via a wired connection through the data communication device at the receiving end.

[0037] For example, the Layer 2 communication device is connected via a wired connection through the sending end data communication device, and then via a short-range local wireless connection through WIFI or other means. The data is then aggregated to the intranet egress aggregation device, and connected to the data communication device via a fixed wired leased line (including Internet VPN leased lines and private network wired leased lines, etc.), and transmitted to the receiving end device through the data communication device.

[0038] However, the first technical solution requires the deployment of a large number of cables and optical fibers, which increases the operation and maintenance costs.

[0039] Method 2: The Layer 2 communication device uses a proprietary data network name (DNN) / access point name (APN) to access the mobile core network through the operator's mobile radio access network. It is then routed to the exit gateway device of the proprietary core network of the DNN / APN, and then connected to the data communication device through a private wired leased line (assigned a dedicated VLAN). The data is then transmitted to the receiving device through the data communication device.

[0040] For example, the N6 interface is located between the operator's UPF network element and the data communication equipment, and is usually connected by wired methods such as direct fiber optic cable connection or hard conduit transmission.

[0041] However, the use of VxLAN tunnels for Layer 2 communication in Method 2 results in a fixed data packet format. This can lead to the transmission of critical information such as MAC addresses in plaintext, making it highly vulnerable to sniffing, tampering, and attacks.

[0042] Method 3: In 5G networks, a Layer 2 tunnel is established by deploying routers on the transmitting and receiving devices to achieve the conversion between Layer 2 and Layer 3 communication. The transmitting router can be configured with virtual Layer 2 interfaces, tunnel interfaces, and point-to-point EoGRE tunnels. The receiving router can be configured with a static WAN IP address, virtual Layer 2 interfaces, tunnel interfaces, point-to-point EoGRE tunnels, and routing. In this way, the Layer 2 communication devices can perform point-to-point Layer 2 communication, multiple virtual LANs, and service isolation.

[0043] For example, such as Figure 1As shown, a Layer 2 tunnel between the transmitting device 101 and the receiving device 107 can be constructed through router 102, CPE 103, base station 104, UPF network element 105, and router 106. The transmitting device (such as camera 101) is connected to router 102, and router 102 is connected to Customer Premise Equipment (CPE) 103. CPE 103 can be connected to UPF network element 105 through base station 104. UPF network element 105 can be connected to router 106. Router 106 can be connected to receiving device 107.

[0044] However, implementing Layer 2 communication in Method 3 requires the operator to allocate IP addresses to the terminal devices, which can easily disrupt the user's original network topology and IP address planning. At the same time, it requires the deployment of routers to establish Layer 2 tunnels on both the sending and receiving terminal devices to achieve the conversion between Layer 2 and Layer 3 communication. The networking and configuration are complex, and the deployment is difficult.

[0045] To address the aforementioned issues, this application provides a Layer 2 communication method between devices. A UPF network element receives Layer 2 data packets from a first device, which is a device communicating in Ethernet mode. The UPF network element then encapsulates the Layer 2 data packets to obtain Layer 3 data packets. The UPF network element can then send the Layer 3 data packets to a target device through a Layer 3 tunnel. In this way, in the technical solution of this application, the first device can wirelessly forward Layer 2 data packets through the target device and the Layer 3 tunnel, eliminating the need to deploy a large number of cables and optical fibers, thus reducing maintenance costs.

[0046] The implementation environment of the embodiments of this application is described below.

[0047] like Figure 2 As shown, a communication system provided in an embodiment of this application is provided. The communication system includes: at least one Layer 2 communication device 201, a transmitting terminal device 202, at least one access network device (such as a transmitting access network device 203 and a receiving access network device 204), a core network device (such as a UPF network element 205), and a target device.

[0048] The Layer 2 communication device 201 is an Ethernet-based communication device. For example, the Layer 2 communication device 201 can be a PLC, DTU, camera, or industrial controller. The Layer 2 communication device 201 carries a MAC address. The Layer 2 communication device 201 can connect to the terminal device via wired or wireless means.

[0049] A terminal device can be a device with transceiver capabilities. Terminals can be deployed on land, including indoors or outdoors, handheld or vehicle-mounted; they can also be deployed on water (such as on ships); and they can be deployed in the air (e.g., on airplanes, balloons, and satellites). Terminals include handheld devices, vehicle-mounted devices, wearable devices, or computing devices with wireless communication capabilities. For example, a terminal can be a mobile phone, a tablet computer, or a computer with wireless transceiver capabilities. Terminal devices can also be virtual reality (VR) terminal devices, augmented reality (AR) terminal devices, wireless terminals in industrial control, wireless terminals in autonomous driving, wireless terminals in telemedicine, wireless terminals in smart grids, wireless terminals in smart cities, wireless terminals in smart homes, customer premises equipment (CPE), etc.

[0050] In this embodiment, the terminal device supports 5G networks and Ethernet-type PDU sessions. Furthermore, the terminal device is configured with network slicing and a DNN.

[0051] Access network equipment can be base stations. Base stations can include various forms, such as macro base stations, micro base stations (also known as small stations), relay stations, access points, etc. Specifically, they can be: access points (APs) in Wireless Local Area Networks (WLANs), base stations (BTSs) in Global System for Mobile Communications (GSM) or Code Division Multiple Access (CDMA), base stations (NodeBs, NBs) in Wideband Code Division Multiple Access (WCDMA), evolved base stations (eNBs or eNodeBs) in LTE, relay stations or access points, or vehicle-mounted equipment, wearable devices, and next-generation Node Bs (gNBs) in future 5G networks, or base stations in future evolved Public Land Mobile Networks (PLMNs), etc.

[0052] In this embodiment, UPF network element 203 is configured with a Layer 2 interface, a tunnel interface, Layer 3 tunnel path parameters, and related routes. UPF network element 205 can communicate with other core network devices (such as 5G core network devices).

[0053] In one possible design, the target device is a data communication device with a 5G module, which can be a 5G daughter card or an internal module. The 5G module supports Ethernet-type PDU sessions. Furthermore, the 5G module is configured with network slicing, DNN, and static IP addresses. The data communication device may include switching equipment and transmission equipment. A Layer 3 tunnel path can be established between the UPF network element 205 and the target device to carry Layer 2 data packets.

[0054] In another possible design, the target device includes: 5G terminal device 206 and data communication device 207.

[0055] Understandably, the target device can activate a 5G session through network slicing and DNN, be assigned a static IP address, and access the 5G base station wirelessly to achieve Layer 3 service interoperability between the target device and the UPF network element.

[0056] In this embodiment of the application, a three-layer tunnel path can be constructed between the UPF network element 205 and the data communication device 207 to carry layer 2 data packets.

[0057] The embodiments of this application will now be described in detail with reference to the accompanying drawings.

[0058] like Figure 3 As shown in the figure, a Layer 2 communication method between devices is provided in an embodiment of this application. The method includes:

[0059] S301, the UPF network element receives Layer 2 data packets from the first device.

[0060] The first device is a device that communicates via Ethernet. The first device is a terminal with a MAC address.

[0061] For example, the first device can be an Internet of Things (IoT) device, such as a Programmable Logic Controller (PLC), a Data Transfer Unit (DTU), a camera, an Automated Guided Vehicle (AGV), and an industrial controller.

[0062] In this embodiment of the application, the Layer 2 data packet includes the MAC address of the receiving device (i.e., the data communication device). The Layer 2 data packet also includes the MAC address of the first device.

[0063] In one possible implementation, a first device is connected to a second device. The second device is a terminal device (i.e., a device with transceiver capabilities). The first device can send Layer 2 data packets to the second device. The second device then receives the Layer 2 data packets and sends them to the UPF network element via a PDU session. The UPF network element can then receive Protocol Data Unit (PDU) sessions from the second device, where each PDU session includes Layer 2 data packets.

[0064] For example, a PDU session can be an Ethernet-type PDU session. After the first device (such as a camera) sends Layer 2 data packets to the second device (such as an access 5G device), the access 5G device can send Layer 2 data packets to the base station through the air interface between the access 5G device and the base station. Subsequently, the base station can send Layer 2 data packets to the UPF network element through the N3 interface between the base station and the UPF network element.

[0065] In some embodiments, before the UPF network element receives Layer 2 data packets from the first device, the second device may initiate a PDU session creation request message of type Ethernet to the AMF network element. This PDU session creation request message carries information elements such as TAI, SUPI, DNN, slice identifier, and PDU session type (Ethernet). Then, the AMF selects the SMF network element based on the DNN and TAI, and initiates a PDU session creation request to the SMF network element, transparently transmitting the aforementioned information elements to the SMF. Subsequently, the SMF network element and the UDM network element exchange information to obtain user subscription information, which includes parameters such as SUPI, DNN, slice identifier, PDU session type (Ethernet), and 5G LAN group session identifier. The SMF network element selects the UPF network element based on the DNN, slice identifier, and PDU session type, and instructs the UPF network element to create a 5G LAN group session and a UE session.

[0066] After receiving the PDU session creation request message, the UPF network element maps the UE session and the 5G LAN group session, allocates the uplink TEID for the N3 interface, and carries the TEID in the response message to the SMF. Then, the SMF network element initiates a Namf_Communication_N1N2MessageTransfer message to the AMF network element, carrying the uplink TEID of the N3 interface, to notify the base station to update the uplink peer tunnel information of the N3 tunnel to the UPF network element. The AMF network element then requests the establishment of a PDU session from the second device through the base station, including the N3 uplink tunnel information, to create the PDU session.

[0067] The S302 and UPF network elements encapsulate the Layer 2 data packets to obtain Layer 3 data packets.

[0068] In one possible implementation, when the UPF network element receives the Layer 2 data packet, the UPF network element can encapsulate it from the inside out by constructing a Generic Routing Encapsulation (GRE) header, an external IP header, and an external MAC header to form a Layer 3 data packet.

[0069] In another possible implementation, when the UPF network element receives the Layer 2 data packet, it can encapsulate the data packet by constructing a GRE header and an outer IP header from the inside out (or the UPF network element can encapsulate the data packet by constructing a GRE header, a User Datagram Protocol (UDP) header, and an outer IP header from the inside out).

[0070] The S303 and UPF network elements send three-layer data packets to the target device through a three-layer tunnel path.

[0071] In this embodiment, the target device is a data communication device equipped with a 5G module. Alternatively, the target device includes a data communication device and a 5G terminal device, wherein the data communication device is connected to the 5G terminal device and is used to parse Layer 3 data packets. This target device can wirelessly communicate with access network equipment (such as a base station).

[0072] In one possible design, the three-level tunnel passage could be an NVGRE tunnel or an EoGRE tunnel.

[0073] In one possible implementation, the UPF network element can send Layer 3 data to the target device via a Layer 3 tunnel path based on the N6 interface.

[0074] In some embodiments, after the UPF network element sends a Layer 3 data packet to the target device through a Layer 3 tunnel path, the target device can decapsulate the Layer 3 data packet to obtain a Layer 2 data packet.

[0075] It is understood that the UPF network element receives Layer 2 data packets from the first device, which is a device that communicates in Ethernet mode. The UPF network element then encapsulates the Layer 2 data packets to obtain Layer 3 data packets. The UPF network element can then send these Layer 3 data packets to the target device through a Layer 3 tunnel. In this way, in the technical solution of this application, the first device can wirelessly forward Layer 2 data packets through the target device and the Layer 3 tunnel, eliminating the need to deploy a large number of cables and optical fibers, thus reducing operation and maintenance costs.

[0076] The foregoing primarily describes the solutions provided in the embodiments of this application from the perspective of computer devices. It is understood that, in order to achieve the aforementioned functions, the computer device includes corresponding hardware structures and / or software modules for executing each function. Those skilled in the art should readily recognize that, based on the device-to-device two-layer communication method steps described in conjunction with the embodiments disclosed in this application, this application can be implemented in hardware or a combination of hardware and computer software. Whether a function is executed in hardware or by computer software driving hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0077] This application also provides a Layer 2 communication device between devices. This Layer 2 communication device can be a computer device, a CPU within the aforementioned computer device, a processing module within the aforementioned computer device for Layer 2 communication between devices, or a client within the aforementioned computer device for Layer 2 communication between devices.

[0078] This application embodiment can divide the Layer 2 communication between devices into functional modules or functional units according to the above method example. For example, each function can be divided into a separate functional module or functional unit, or two or more functions can be integrated into one processing module. The integrated module can be implemented in hardware or in software functional modules or functional units. The module or unit division in this application embodiment is illustrative and only represents one logical functional division; other division methods may be used in actual implementation.

[0079] like Figure 4 The diagram shown is a structural schematic of a Layer 2 communication device between devices according to an embodiment of this application. The Layer 2 communication device between devices is used to perform... Figure 3 The illustrated method for Layer 2 communication between devices. The Layer 2 communication device may include: a receiving unit 401, a processing unit 402, and a transmitting unit 403.

[0080] The receiving unit 401 is used to receive Layer 2 data packets from a first device, which is a device that communicates based on Ethernet mode. The processing unit 402 is used to encapsulate the Layer 2 data packets to obtain Layer 3 data packets. The sending unit 403 is used to send the Layer 3 data packets to the target device through a Layer 3 tunnel path.

[0081] In one possible design, the processing unit 402 is used to construct a three-layer tunnel path based on a three-layer tunneling protocol, which includes an EoGRE tunnel or an NVGRE tunnel.

[0082] In one possible design, the target device is a data communication device with a 5G module; or, the target device includes: a data communication device and a 5G terminal device, with the data communication device connected to the 5G terminal device, and the data communication device used to parse three-layer data packets.

[0083] In one possible design, the receiving unit 401 is used to receive a Protocol Data Unit (PDU) session from a second device. The PDU session includes a Layer 2 data packet, and the second device is connected to the first device.

[0084] In one possible design, the transmitting unit 403 is used to transmit Layer 3 data to the target device via a Layer 3 tunnel path based on the N6 interface.

[0085] Figure 5 This is a schematic diagram of the hardware structure of a Layer 2 inter-device communication device according to an exemplary embodiment. The Layer 2 inter-device communication device may include a processor 502, which executes application code to implement the Layer 2 inter-device communication method of this application.

[0086] The processor 502 may be a central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits used to control the execution of the program of the present application.

[0087] like Figure 5 As shown, the Layer 2 communication device between devices may further include a memory 503. The memory 503 stores the application code that executes the scheme of this application, and its execution is controlled by the processor 502.

[0088] Memory 503 may be a read-only memory (ROM) or other type of static storage device capable of storing static information and instructions, random access memory (RAM) or other type of dynamic storage device capable of storing information and instructions, or electrically erasable programmable read-only memory (EEPROM), compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (including compressed optical discs, laser discs, optical discs, digital versatile optical discs, Blu-ray discs, etc.), magnetic disk storage media or other magnetic storage devices, or any other medium capable of carrying or storing desired program code in the form of instructions or data structures and accessible by a computer, but not limited thereto. Memory 503 may exist independently and be connected to processor 502 via bus 504. Memory 503 may also be integrated with processor 502.

[0089] like Figure 5 As shown, the Layer 2 communication device between devices may further include a communication interface 501, wherein the communication interface 501, processor 502, and memory 503 may be coupled to each other, for example, through a bus 504. The communication interface 501 is used for information exchange with other devices, for example, supporting information exchange between the Layer 2 communication device and other devices.

[0090] It should be pointed out that, Figure 5 The device structure shown does not constitute a limitation on the Layer 2 communication devices between these devices, except Figure 5 In addition to the components shown, the Layer 2 communication devices between these devices may include more or fewer components than shown, or combine certain components, or have different component arrangements.

[0091] In actual implementation, the functions implemented by processing unit 402 can be derived by... Figure 5 The processor 502 shown calls the program code in memory 503 to implement this.

[0092] This application also provides a computer-readable storage medium storing instructions that, when executed by a processor of a computer device, enable the computer to perform the inter-device layer 2 communication method provided in the embodiments described above. For example, the computer-readable storage medium may be a memory 503 including instructions, which may be executed by a processor 502 of a computer device to complete the method. Optionally, the computer-readable storage medium may be a non-transitory computer-readable storage medium, such as a ROM, RAM, CD-ROM, magnetic tape, floppy disk, or optical data storage device.

[0093] Figure 6 A conceptual partial view of a computer program product provided in an embodiment of this application is shown schematically. The computer program product includes a computer program for executing computer processes on a computing device.

[0094] In one embodiment, a computer program product is provided using a signal bearer medium 600. The signal bearer medium 600 may include one or more program instructions that, when executed by one or more processors, can provide the above-mentioned... Figure 3 The described function or part of the function. Therefore, for example, refer to... Figure 3 In the embodiment shown, one or more features of S301 to S303 can be fulfilled by one or more instructions associated with the signal carrying medium 600. Furthermore, Figure 6 The program instructions in the document also describe example instructions.

[0095] In some examples, the signal carrying medium 600 may include a computer-readable medium 601, such as, but not limited to, a hard disk drive, a compact disc (CD), a digital video disc (DVD), a digital magnetic tape, a memory, a read-only memory (ROM), or a random access memory (RAM), etc.

[0096] In some implementations, the signal carrying medium 600 may include a computer recordable medium 602, such as, but not limited to, a memory, a read / write (R / W) CD, a R / W DVD, and so on.

[0097] In some implementations, the signal carrying medium 600 may include a communication medium 603, such as, but not limited to, digital and / or analog communication media (e.g., fiber optic cables, waveguides, wired communication links, wireless communication links, etc.).

[0098] The signal-bearing medium 600 can be transmitted by a wireless communication medium 603. One or more program instructions may be, for example, computer-executable instructions or logical implementation instructions.

[0099] In some examples, such as targeting Figure 4 The described two-layer communication device can be configured to provide various operations, functions, or actions in response to one or more program instructions in a computer-readable medium 601, a computer-recordable medium 602, and / or a communication medium 603.

[0100] Through the above description of the embodiments, those skilled in the art can clearly understand that, for the sake of convenience and brevity, only the division of the above functional modules is used as an example. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.

[0101] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another apparatus, or some features may be ignored or not executed. Furthermore, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.

[0102] The units described as separate components may or may not be physically separate. A component shown as a unit can be one or more physical units; that is, it can be located in one place or distributed in multiple different locations. Some or all of the constituent units can be selected to achieve the purpose of this embodiment, depending on actual needs.

[0103] Furthermore, the functional units in the various 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 functional unit.

[0104] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solution of the embodiments of this application, essentially, or the part that contributes to the prior art, or a complete or partial classification of the technical solution, can be embodied in the form of a software product. This software product is stored in a storage medium and includes several instructions to cause a device (which may be a microcontroller, chip, etc.) or processor 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, ROM, RAM, magnetic disks, or optical disks.

[0105] The above are merely specific embodiments of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. A Layer 2 communication method between devices, characterized in that, The method is applied to a User Plane Function (UPF) network element, which is pre-configured with Layer 2 interfaces, tunnel interfaces, and Layer 3 tunnel path parameters; the method includes: The device receives a Layer 2 data packet from a first device, which is a device that communicates based on Ethernet mode; the Layer 2 data packet is carried in an Ethernet-type Protocol Data Unit (PDU) session and is obtained by the UPF network element from the PDU session. The second-layer data packet is encapsulated to obtain a third-layer data packet; The three-layer tunneling pathway is constructed based on a three-layer tunneling pathway protocol, and the three-layer tunneling pathway includes: an EoGRE tunnel or an NVGRE tunnel; Based on the N6 interface, the three-layer data packets are sent to the target device through a three-layer tunnel path; The encapsulation of the Layer 2 data packet to obtain a Layer 3 data packet includes: The Layer 2 data packet is encapsulated from the inside out by constructing a general routing encapsulation header, an external IP header, and an external MAC header to form the Layer 3 data packet. or, On the outer side of the Layer 2 data packet, a general routing encapsulation header and an external IP header are constructed from the inside out for encapsulation. Alternatively, a general routing encapsulation header, a user datagram protocol header, and an external IP header can be constructed from the inside out on the outer side of the Layer 2 data packet for encapsulation.

2. The method according to claim 1, characterized in that, The target device is a data communication device with a 5G module; or, the target device includes: a data communication device and a 5G terminal device, wherein the data communication device is connected to the 5G terminal device, and the data communication device is used to parse the three-layer data packets.

3. The method according to claim 1 or 2, characterized in that, The receiving of Layer 2 data packets from the first device includes: Receive Protocol Data Unit (PDU) session from a second device, the PDU session including the Layer 2 data packet, the second device being connected to the first device.

4. A two-layer communication device between devices, characterized in that, Applied to a UPF network element, the UPF network element is pre-configured with Layer 2 interface, tunnel interface, and Layer 3 tunnel path parameters; the device includes: The receiving unit is used to receive Layer 2 data packets from a first device, which is a device that communicates based on Ethernet mode; the Layer 2 data packets are carried in an Ethernet-type Protocol Data Unit (PDU) session and are obtained by the UPF network element from the PDU session; The processing unit is used to encapsulate the Layer 2 data packets to obtain Layer 3 data packets; The processing unit is used to construct the three-layer tunnel path based on the three-layer tunnel path protocol, the three-layer tunnel path including: EoGRE tunnel or NVGRE tunnel; the sending unit is used to send the three-layer data packets to the target device through the three-layer tunnel path based on the N6 interface; The processing unit is used to encapsulate the Layer 2 data packet to obtain a Layer 3 data packet, including: The Layer 2 data packet is encapsulated from the inside out by constructing a general routing encapsulation header, an external IP header, and an external MAC header to form the Layer 3 data packet. or, On the outer side of the Layer 2 data packet, a general routing encapsulation header and an external IP header are constructed from the inside out for encapsulation. or, On the outer side of the Layer 2 data packet, from the inside out, a general routing encapsulation header, a user datagram protocol header, and an external IP header are constructed for encapsulation.

5. The apparatus according to claim 4, characterized in that, The target device is a data communication device with a 5G module; or, the target device includes: a data communication device and a 5G terminal device, wherein the data communication device is connected to the 5G terminal device, and the data communication device is used to parse the three-layer data packets.

6. The apparatus according to claim 5, characterized in that, The receiving unit is used to receive Protocol Data Unit (PDU) sessions from the second device, the PDU sessions including the Layer 2 data packets, and the second device is connected to the first device.

7. A two-layer communication device between devices, characterized in that, include: Processor and memory; The processor and the memory are coupled; The memory is used to store one or more programs, which include computer-executable instructions. When the inter-device layer 2 communication device is running, the processor executes the computer-executable instructions stored in the memory to cause the inter-device layer 2 communication device to perform the method as described in any one of claims 1-3.

8. A computer-readable storage medium storing instructions, characterized in that, When the computer executes the instruction, the computer performs the method as described in any one of claims 1-3.

Citation Information

Patent Citations

  • Local area network communication method and apparatus, terminal, electronic device and storage medium

    WO2023000767A1