In-vehicle networking data transmission

WO2026103586A1PCT designated stage Publication Date: 2026-05-21ZHEJIANG GEELY HLDG GRP CO LTD +1
View PDF 4 Cites 0 Cited by

Patent Information

Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
ZHEJIANG GEELY HLDG GRP CO LTD
Filing Date
2025-11-05
Publication Date
2026-05-21

Smart Images

  • Figure CN2025132701_21052026_PF_FP_ABST
    Figure CN2025132701_21052026_PF_FP_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of vehicle control. Disclosed are an in-vehicle networking data transmission method and apparatus, and a switch, a vehicle and a storage medium. The method is applied to a switch in a vehicle, and specifically comprises: acquiring a network selection instruction, which instructs selection of a wireless hotspot network provider or a cellular network provider; on the basis of the network selection instruction, determining the wireless hotspot network provider or the cellular network provider to be a target network provider; receiving networking uplink traffic data sent by a networking controller; acquiring the category of the networking uplink traffic data as a traffic data category; on the basis of the traffic data category, determining a target forwarding policy; and on the basis of the target forwarding policy, forwarding the networking uplink traffic data to the target network provider. The present application enables transmission of in-vehicle networking data, and can reduce network bandwidth losses.
Need to check novelty before this filing date? Find Prior Art

Description

Vehicle-to-everything (V2X) data transmission Cross-references to related applications

[0001] This application claims priority to Chinese Patent Application No. 202411607521.3, filed on November 12, 2024, entitled "Vehicle Network Data Transmission Method, Apparatus, Switch, Vehicle and Storage Medium", the entire contents of which are incorporated herein by reference. Technical Field

[0002] This application relates to, but is not limited to, the field of vehicle control technology, and particularly to a vehicle-mounted network data transmission method, device, switch, vehicle, and storage medium. Background Technology

[0003] Vehicles typically have internet connectivity. Connectivity methods primarily include cellular networks (4G / 5G) and Wi-Fi. Considering cellular data costs, unless Wi-Fi is switched off, it's generally recommended to prioritize using Wi-Fi to access the internet for data transmission.

[0004] The relevant technology typically uses a separate networking module TBOX for network arbitration. All outgoing traffic (also known as uplink traffic) must pass through the TBOX, which decides whether to use the cellular network or the Wi-Fi network.

[0005] Considering the risk of single points of failure in vehicle networks, the cellular network module and the Wi-Fi network module are deployed separately on different devices to prevent a single device failure from causing the entire vehicle's networking function to fail completely. This results in two outgoing traffic exit devices. Because of these two exit devices, using a network module TBOX for network arbitration is not suitable, as it would result in a loss of network bandwidth. Summary of the Invention

[0006] This application proposes a method, device, switch, vehicle, and storage medium for transmitting vehicle network data, which can transmit vehicle network data and reduce network bandwidth loss.

[0007] A first aspect of this application proposes a method for in-vehicle network data transmission, applied to a switch in a vehicle. The vehicle is equipped with a wireless hotspot network provider, a cellular network provider, and a network controller connected to the switch. The method includes: obtaining a network selection instruction, the network selection instruction indicating the selection of the wireless hotspot network provider or the cellular network provider; determining the wireless hotspot network provider or the cellular network provider as a target network provider based on the network selection instruction; receiving network uplink traffic data sent by the network controller; obtaining the category of the network uplink traffic data as a traffic data category; determining a target forwarding strategy based on the traffic data category; and forwarding the network uplink traffic data to the target network provider according to the target forwarding strategy.

[0008] Optionally, the switch stores a set of forwarding policies; determining the target forwarding policy based on the traffic data category includes: filtering category-related policies from the forwarding policy set based on the traffic data category; obtaining forwarding policies supported by the network controller as reference forwarding policies; comparing the reference forwarding policies with the category-related policies to obtain a policy comparison result; the policy comparison result is used to characterize whether the reference forwarding policy is the same as or different from the category-related policies; and filtering the target forwarding policy from the forwarding policy set based on the policy comparison result.

[0009] Optionally, the forwarding policy set includes a LAN identifier forwarding policy, a LAN address forwarding policy, and a multicast packet forwarding policy; the step of filtering category-related policies from the forwarding policy set according to the traffic data category includes: if the traffic data category is an encrypted data category, then the LAN identifier forwarding policy is determined as the category-related policy; if the traffic data category is an instruction data category, then at least one of the LAN identifier forwarding policy and the LAN address forwarding policy is determined as the category-related policy; if the traffic data category is a log data category, then the multicast packet forwarding policy is determined as the category-related policy.

[0010] Optionally, the step of selecting the target forwarding strategy from the forwarding strategy set based on the strategy comparison result includes: if the strategy comparison result indicates that the reference forwarding strategy is the same as the category-associated strategy, then the category-associated strategy is determined as the target forwarding strategy; if the strategy comparison result indicates that the reference forwarding strategy is not the same as the category-associated strategy, then a category-general strategy is extracted from the forwarding strategy set as the target forwarding strategy; wherein the category-general strategy does not include the category-associated strategy.

[0011] Optionally, the step of determining the category-associated policy as the target forwarding policy if the policy comparison result indicates that the reference forwarding policy is the same as the category-associated policy includes: if the reference forwarding policy includes a LAN address forwarding policy, then the LAN address forwarding policy is determined as the target forwarding policy; if the reference forwarding policy includes a LAN identifier forwarding policy but does not include the LAN address forwarding policy, then the LAN identifier forwarding policy is determined as the target forwarding policy.

[0012] Optionally, after forwarding the network uplink traffic data to the target network providing device according to the target forwarding policy, the method further includes: if the reference forwarding policy includes the LAN identifier forwarding policy and the LAN address forwarding policy, detecting the load of data forwarding according to the target forwarding policy; if the load is greater than a preset load threshold, switching the target forwarding policy from the LAN address forwarding policy to the LAN identifier forwarding policy, or switching the target forwarding policy from the LAN identifier forwarding policy to the LAN address forwarding policy.

[0013] Optionally, when the target forwarding policy is a LAN identifier forwarding policy, the step of forwarding the network uplink traffic data to the target network providing device according to the target forwarding policy includes: obtaining the destination LAN identifier of the network uplink traffic data as an initial destination LAN identifier; if the target network providing device is the Wi-Fi hotspot network providing device, modifying the initial destination LAN identifier to a first LAN identifier in the LAN identifier forwarding policy to obtain a target destination LAN identifier, wherein the first LAN identifier is associated with the Wi-Fi hotspot network providing device; if the target network providing device is the cellular network providing device, modifying the initial destination LAN identifier to a second LAN identifier in the LAN identifier forwarding policy to obtain a target destination LAN identifier, wherein the second LAN identifier is associated with the cellular network providing device; and forwarding the network uplink traffic data to the target network providing device according to the target destination LAN identifier.

[0014] Optionally, forwarding the network uplink traffic data to the target network providing device based on the target destination LAN identifier includes: obtaining an identifier interface mapping table, wherein the identifier interface mapping table indicates that the wireless hotspot network providing device associated with the first LAN identifier is connected to a first interface of the switch, and the cellular network providing device associated with the second LAN identifier is connected to a second interface of the switch; searching the identifier interface mapping table based on the target destination LAN identifier to determine that the first interface or the second interface is the target interface; and forwarding the network uplink traffic data from the target interface to the target network providing device.

[0015] Optionally, when the target forwarding policy is a local area network (LAN) address forwarding policy, forwarding the network uplink traffic data to the target network providing device according to the target forwarding policy includes: obtaining the destination LAN address of the network uplink traffic data as an initial destination LAN address; if the target network providing device is the wireless hotspot network providing device, modifying the initial destination LAN address to a first LAN address in the LAN address forwarding policy to obtain a target destination LAN address, wherein the first LAN address is associated with the wireless hotspot network providing device; if the target network providing device is the cellular network providing device, modifying the initial destination LAN address to a second LAN address in the LAN address forwarding policy to obtain a target destination LAN address, wherein the second LAN address is associated with the cellular network providing device; and forwarding the network uplink traffic data to the target network providing device according to the target destination LAN address.

[0016] Optionally, forwarding the network uplink traffic data to the target network providing device according to the target local area network address includes: obtaining an address interface mapping table, wherein the address interface mapping table indicates that the wireless hotspot network providing device associated with the first local area network address is connected to a first interface of the switch, and the cellular network providing device associated with the second local area network address is connected to a second interface of the switch; determining the first interface or the second interface as the target interface by searching the address interface mapping table according to the local area network address; and forwarding the network uplink traffic data from the target interface to the target network providing device.

[0017] Optionally, when the target forwarding policy is a multicast forwarding policy, forwarding the network uplink traffic data to the target network providing device according to the target forwarding policy includes: if the target network providing device is the wireless hotspot network providing device, then dividing the network uplink traffic data into the wireless hotspot multicast packet and determining the wireless hotspot multicast packet as the target packet; if the target network providing device is the cellular network providing device, then dividing the network uplink traffic data into the cellular multicast packet and determining the cellular multicast packet as the target packet; and forwarding the network uplink traffic data to the target network providing device according to the target packet.

[0018] A second aspect of this application discloses an in-vehicle network data transmission device applied to a switch in a vehicle. The vehicle is equipped with a wireless hotspot network provider, a cellular network provider, and a network controller connected to the switch. The device includes: an instruction acquisition module for acquiring a network selection instruction, the network selection instruction indicating the selection of the wireless hotspot network provider or the cellular network provider; a device selection module for determining the wireless hotspot network provider or the cellular network provider as the target network provider based on the network selection instruction; a data receiving module for receiving network uplink traffic data sent by the network controller; a category determination module for acquiring the category of the network uplink traffic data as the traffic data category; a policy determination module for determining a target forwarding policy based on the traffic data category; and a data forwarding module for forwarding the network uplink traffic data to the target network provider according to the target forwarding policy.

[0019] A third aspect of this application provides a switch including at least one processor and a memory for communicatively connecting with the processor; the memory stores instructions executable by the at least one processor to cause the at least one processor to perform the vehicle networking data transmission method as described in the first aspect.

[0020] A fourth aspect of this application provides a vehicle including a switch as described in the third aspect; a wireless hotspot network providing device, a cellular network providing device, and a network controller connected to the switch.

[0021] A fifth aspect of this application provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the vehicle networking data transmission method described in the first aspect.

[0022] The present application discloses a method, apparatus, switch, vehicle, and storage medium for in-vehicle network data transmission. The method is executed by the switch, which, upon receiving a network selection command, determines the target network provider based on the command. If the command indicates the selection of a Wi-Fi hotspot network provider, the target network provider is the Wi-Fi hotspot network provider; if the command indicates the selection of a cellular network provider, the target network provider is the cellular network provider. The switch also receives uplink traffic data from the network controller and obtains the traffic data category. Then, the switch determines a forwarding strategy, i.e., a target forwarding strategy, based on the traffic data category. Finally, the switch forwards the uplink traffic data to the target network provider according to the target forwarding strategy, thus transmitting data from the network controller to the target network provider. This application, by executing Layer 2 dynamic data transmission within the switch (the process from receiving the network selection command to forwarding the uplink traffic data to the target network provider according to the target forwarding strategy), can minimize the cost of network handover, i.e., reduce network bandwidth loss.

[0023] Additional aspects and advantages of this application will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of the application. Other aspects will become apparent upon reading and understanding the accompanying drawings and detailed description. Attached Figure Description

[0024] Figure 1 is a flowchart of the vehicle network data transmission method provided in an embodiment of this application.

[0025] Figure 2 is a structural schematic diagram of the vehicle provided in an embodiment of this application.

[0026] Figure 3 is a schematic diagram of a switch provided in an embodiment of this application.

[0027] Figure 4 is a flowchart illustrating the local area network identifier forwarding strategy provided in an embodiment of this application.

[0028] Figure 5 is a flowchart illustrating the local area network address forwarding strategy provided in an embodiment of this application.

[0029] Figure 6 is a flowchart illustrating the multicast forwarding strategy provided in an embodiment of this application.

[0030] Figure 7 is a schematic diagram of the support strategy confirmation process provided in the embodiments of this application.

[0031] Figure 8 is a schematic diagram of the process for determining the target forwarding strategy provided in an embodiment of this application.

[0032] Figure 9 is another structural schematic diagram of the switch provided in an embodiment of this application. Detailed Implementation

[0033] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0034] It should be noted that although functional modules are divided in the device schematic diagram and a logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the device or the order in the flowchart. The terms "first," "second," etc., in the specification, claims, and the aforementioned drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence.

[0035] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein is for the purpose of describing embodiments of this application only and is not intended to limit this application.

[0036] Before providing a further detailed description of the embodiments of this application, the nouns and terms involved in the embodiments of this application will be explained, and the nouns and terms involved in the embodiments of this application shall be interpreted as follows.

[0037] Wireless Fidelity (Wifi): A wireless network that connects devices to the internet via wireless signals. It allows devices (such as mobile phones, computers, tablets, etc.) to communicate and access the internet via wireless networks without the need for a wired connection.

[0038] Cellular networks (such as 4G / 5G) are mobile communication network technologies that utilize base stations and radio spectrum to provide communication services to mobile devices (such as mobile phones, tablets, laptops, etc.). Cellular networks are currently the mainstream technology in the field of mobile communications, and networks including 4G and 5G fall under the category of cellular networks.

[0039] Single point of failure: This refers to the failure of a single device. For example, the device that provides both cellular and Wi-Fi networks may malfunction. Considering the risk of single point of failure in vehicle networks, the cellular network module and the Wi-Fi network module are deployed separately on different devices to avoid the complete failure of the vehicle's networking function due to the failure of a single device.

[0040] A connected controller is a hardware device specifically designed for in-vehicle computer systems, often referred to as an in-vehicle communication module or controller. In one example, a connected controller can be an ECU (Electronic Control Unit), such as a vehicle infotainment system or a driver assistance controller. This type of controller typically integrates wireless communication technologies, such as 4G / 5G and Wi-Fi, allowing the vehicle to connect to external networks via the internet, enabling data exchange and communication between the in-vehicle system and external services. Connected controllers in vehicles can be used for many applications, including but not limited to: providing real-time vehicle location information, allowing owners to manage their vehicles through remote monitoring and remote start; supporting in-vehicle internet services such as online map navigation, music streaming, and real-time traffic information; supporting vehicle diagnostics and remote vehicle monitoring, making vehicle maintenance more convenient and timely; and supporting communication between in-vehicle devices, such as data exchange between in-vehicle entertainment and navigation systems. Connected controllers in vehicles are a product of the trend towards automotive intelligence and interconnectivity, contributing to improved vehicle safety, convenience, and connectivity.

[0041] Currently, vehicles generally have internet connectivity, primarily through cellular networks and Wi-Fi hotspots. Considering the cost of cellular data traffic, unless Wi-Fi is disabled, it's generally recommended to prioritize using Wi-Fi for internet access and data transmission, then switch connectivity methods based on actual needs. For example, this could be based on user network preferences or network quality. However, conventional connectivity switching algorithms are implemented on Layer 3 routers, which limits the application of Layer 2 devices like switches and makes them unsuitable for in-vehicle Ethernet networks, resulting in limited applicability.

[0042] Based on this, embodiments of this application provide a method, apparatus, switch, vehicle, and storage medium for in-vehicle network data transmission. The method is executed by the switch, and after receiving a network selection instruction, it determines the target network provider based on the instruction. Specifically, if the network selection instruction indicates the selection of a Wi-Fi hotspot network provider, the target network provider is a Wi-Fi hotspot network provider; if the instruction indicates the selection of a cellular network provider, the target network provider is a cellular network provider. The switch also receives uplink traffic data sent by the network controller and obtains the traffic data category. Then, the switch determines a forwarding strategy for forwarding the uplink traffic data, i.e., the target forwarding strategy, based on the traffic data category. Finally, the switch forwards the uplink traffic data to the target network provider according to the target forwarding strategy, thereby switching the network connection mode. This application addresses the potential for data transmission interruptions during network handover by implementing dynamic Layer 2 link data transmission within the switch (the process by which the switch receives network selection instructions and forwards uplink traffic data to the target network provider according to the target forwarding policy). Other in-vehicle controllers (such as Wi-Fi hotspot providers, cellular network providers, and network controllers) do not modify packet tuple parameters (e.g., MAC (Media Access Control), Port, VLAN (Virtual Local Area Network)). Therefore, this application minimizes the cost of network handover, i.e., reduces network bandwidth loss.

[0043] The vehicle-to-everything (V2X) data transmission method, device, switch, vehicle, and storage medium provided in this application are specifically described through the following embodiments. First, the V2X data transmission method in this application is described.

[0044] Please refer to Figure 1, which discloses an optional flowchart of a vehicle-to-everything (V2X) data transmission method. In this embodiment, the method is executed by a switch. The method in Figure 1 may include, but is not limited to, steps 101 to 106.

[0045] Step 101: Obtain network selection instructions, which instruct you to select either a wireless hotspot network provider or a cellular network provider.

[0046] Step 102: Based on the network selection instruction, determine the wireless hotspot network provider or the cellular network provider as the target network provider;

[0047] Step 103: Receive network uplink traffic data sent by the network controller;

[0048] Step 104: Obtain the category of the network uplink traffic data as the traffic data category;

[0049] Step 105: Determine the target forwarding strategy based on the traffic data category;

[0050] Step 106: Forward the network uplink traffic data to the target network provider device according to the target forwarding policy.

[0051] Steps 101 to 106 as shown in the embodiments of this application enable the transmission of vehicle network data and reduce network bandwidth loss.

[0052] In computer networks, a switch is a network device used to connect multiple computers or network devices, enabling data packet forwarding and routing for communication between devices. In this embodiment, the switch is a device in a vehicle. Besides the switch, the vehicle also has other devices. Please refer to Figure 2, which shows a schematic diagram of a vehicle's structure. The vehicle includes a switch 201, a wireless hotspot network providing device 202, a cellular network providing device 203 connected to the switch 201, and multiple network controllers. In Figure 2, there are a total of n network controllers, specifically including network controller 1, network controller 2, ..., network controller n, where n is a positive integer. The wireless hotspot network providing device 202 provides a wireless hotspot network. The cellular network providing device 203 provides a cellular network.

[0053] In step 101 of some embodiments, the network selection command is a messaging mechanism for vehicles used to send notifications or reminders to the switch. The network selection command instructs the selection of a Wi-Fi hotspot network provider or a cellular network provider. In one example, the network selection command is "Current network connection mode is Wi-Fi hotspot network," indicating that the network selection command instructs the selection of a Wi-Fi hotspot network provider. In another example, the network selection command is "Current network connection mode is cellular network," indicating that the network selection command instructs the selection of a cellular network provider.

[0054] In one embodiment, the network selection instruction is obtained in ways including but not limited to the following: (1) The switch obtains the network selection instruction sent by the wireless hotspot network provider, which is generated by the wireless hotspot network based on the network bandwidth of the wireless hotspot network and the network bandwidth of the cellular network. (2) The switch obtains the network selection instruction sent by the human-computer interaction system, which is generated by the human-computer interaction system based on the user's network preference information.

[0055] In method (1), the wireless hotspot network provider can integrate network sniffing software to send sniffing packets to the cellular network provider and its own Wi-Fi module (used for accessing the wireless hotspot network) to detect network bandwidth. By default, when both the Wi-Fi network and the cellular network are enabled, the Wi-Fi network is prioritized for accessing the external network. Once the effective bandwidth of the Wi-Fi network is less than half of the effective bandwidth of the cellular network, the wireless hotspot network provider will set the network mode to cellular network; otherwise, it will maintain the network mode as Wi-Fi network and simultaneously send a network selection command to the switch to trigger the switch to select and switch the network path.

[0056] In method (2), the user can input network preference information into the human-computer interaction system. For example, the network preference information is "the user prefers a wireless hotspot network". Or, the network preference information is "the user prefers a cellular network". The human-computer interaction system is a control system used to interact with the user. The human-computer interaction system sets the network mode to cellular network according to the network preference information "the user prefers a cellular network", otherwise it maintains the network mode as Wi-Fi network, and at the same time sends a network selection command to the switch to trigger the switch to select and switch the network path.

[0057] In step 102 of some embodiments, if the network selection instruction indicates the selection of a wireless hotspot network providing device, then the target network providing device is a wireless hotspot network providing device; if the network selection instruction indicates the use of a cellular network providing device, then the target network providing device is a cellular network providing device.

[0058] In one example, if the network selection command is "Current network connection mode is Wi-Fi hotspot network", then the Wi-Fi hotspot network provider will be selected as the target network provider. In another example, if the network selection command is "Current network connection mode is cellular network", then the cellular network provider will be selected as the target network provider.

[0059] In step 103 of some embodiments, network uplink traffic data refers to data sent from the network controller to the target network providing device. If the data is sent from the target network providing device to the network controller, it is called network downlink traffic data. Referring to FIG2, in one example, switch 201 receives network uplink traffic data sent by the network controller (e.g., network controller 1).

[0060] In step 104 of some embodiments, the traffic data category refers to the category of network uplink traffic data. In this embodiment, the traffic categories are divided into four categories: encrypted data category, log data category, command data category, and general data category.

[0061] Encrypted data, also known as special encrypted data, generally involves sensitive user information and requires prior anonymization. If network uplink traffic data contains sensitive user information, it falls under the category of encrypted data.

[0062] Log data categories generally involve data that records the activity of a system, application, or device. This data typically includes timestamps, event descriptions, operator information, etc. For example, if network uplink traffic data includes network controller logs, operation logs, or network traffic logs, it falls under the category of log data.

[0063] Command data generally refers to data used to instruct a system or device to perform a certain operation or control a certain behavior. This data can include commands, parameters, instruction sets, and other information. For example, commands sent to devices by a network controller, remote control commands, and sensor data acquisition commands all fall under the category of control command data.

[0064] General data categories refer to categories without specific domain or usage restrictions. Data in general data categories is data that can be widely applied and processed. It is not dependent on a specific domain or application and can be used by different types of systems, applications, and analytical tools.

[0065] In one example, the switch can pre-store a parsing algorithm and then use this algorithm to categorize the network uplink traffic data to obtain the traffic category. In another example, the network uplink traffic data has a category tag, which the switch identifies to determine the traffic category. The category tag indicates one of the following: encrypted, log, control command, or general category.

[0066] Before describing step 105, the data interaction between the switch and the network controller will be described first. Referring to Figure 3, the switch 201 includes a first interface 301, a second interface 302, multiple digital interfaces (including Port1 to Port6), and a network path selector 304. The network path selector 304 determines the network path and calls the API (Application Programming Interface) inside the switch 201 to perform packet routing and forwarding. The first interface 301 represents the interface connecting to the wireless hotspot network providing device, the second interface 302 represents the interface connecting to the cellular network providing device, and the digital interfaces represent the interfaces connecting to the network controller. In some embodiments, the number of digital interfaces is the same as the number of network controllers. The network path selector 304 involves three forwarding strategies. A forwarding strategy refers to a strategy for forwarding network uplink traffic data to the target network providing device.

[0067] Referring to Figures 2 and 3, the following working logic exists in the network path selector 304: (1) For downlink network traffic data, the network path selector 304 does not perform data filtering and forwards data according to the statically configured interface mapping relationship (e.g., forwarding from the first interface 301 to port1). (2) For uplink network traffic data, the information corresponding to the network controller (e.g., network controller 1 to network controller 6) is first required to be registered in the network path selector 304. The specific registered information includes the digital interface (port1 to port6) where the network controller is located, the source LAN identifier (VLAN1 to VLAN6), the source LAN address (MAC1 to MAC6), the supported forwarding policy, and the network protocol (Internet Protocol, IP). Then, the target forwarding policy is determined according to the category of the uplink network traffic data, and then the data is forwarded based on the target forwarding policy (e.g., forwarding from port1 to the first interface 301).

[0068] The switch stores three forwarding strategies: LAN identifier forwarding strategy (strategy a), LAN address forwarding strategy (strategy b), and multicast forwarding strategy (strategy c). These three strategies are applicable to different scenarios. For example, strategy a is suitable for cross-VLAN interaction and secure data isolation scenarios; strategy b is suitable for time-sensitive interaction scenarios and is also applicable to all scenarios; strategy c is suitable for low-frequency transmission scenarios.

[0069] Referring to Figure 4, for strategy a, a specific source LAN identifier (i.e., the VLAN of the network controller) is identified at each digital interface of the switch. In the network path selector, the destination LAN identifier of the uplink network traffic data is modified to a different destination LAN identifier based on the target network provider. For example, if the selected network is a wireless hotspot (i.e., the target network is Wi-Fi), the destination LAN identifier for all uplink network traffic data is modified to VLAN 101. Similarly, if the selected network is a cellular network (i.e., the target network is not Wi-Fi), the destination LAN identifier for all uplink network traffic data is switched to VLAN 102. Finally, Layer 2 data forwarding is performed based on the mapping relationship between the interface and the LAN identifier (e.g., the interface identifier mapping table described below).

[0070] Referring to Figure 5, for strategy b, a specific source LAN identifier (i.e., the VLAN of the network controller) is identified at each digital interface of the switch. By default, the destination LAN address (also known as DMAC) of the network controller is filled with the LAN address of the network card of the cellular network provider. Once the network path selector detects that the vehicle network mode is selected as Wi-Fi (i.e., the target network provider is a wireless hotspot network provider), the destination LAN address of the corresponding Layer 2 data frame is modified to the LAN address of the wireless hotspot network provider. Otherwise, the original destination LAN address of the data frame is maintained as the LAN address of the cellular network provider. Finally, the switch forwards Layer 2 data according to the mapping relationship between the interface and the LAN address (such as the interface address mapping table).

[0071] Referring to Figure 6, two separate multicast packets are created within the vehicle: a wireless hotspot multicast packet and a cellular multicast packet. Two new multicast ARP (Address Resolution Protocol) entries are added to all network controllers and switches. The wireless hotspot network provider is then assigned to the wireless hotspot multicast packet, and the cellular network provider is assigned to the cellular multicast packet. After the data frame from the network controller reaches the switch via multicast, the network path selector actively determines the current target network provider and forwards the corresponding data frame to the appropriate packet.

[0072] Based on the above, the network path selector stores the registration information corresponding to each network controller. When the vehicle starts, the registration information can be confirmed as follows: Referring to Figure 7, at the digital interface where the network controller is located, the network path selector initiates three Layer 2 broadcast verification messages under a specific VLAN (the specific number can be adjusted according to requirements, and the interval between each request can be calibrated and adjusted according to the startup time of each network controller). The content of the verification message includes the code of each network controller and the forwarding policy code. For example, if the content of the verification message is "1001:abc", it means that network controller 1001 supports three forwarding policies: a, b, and c. As another example, if the content of the verification message is "1002:bc", it means that network controller 1002 supports two forwarding policies: b and c.

[0073] After sending three requests to the network controller, if the network controller has not yet started normally and cannot respond to the requests, the sending interval needs to be adjusted (this is only for debugging during the development phase). Referring to Figure 7, once the network controller starts successfully, if the network controller's configuration information matches the requested verification information, the network controller will reply with a positive response; otherwise, it will reply with a negative response and send the specific supported forwarding policy to the switch.

[0074] In step 105 of some embodiments, it is necessary to determine the target forwarding strategy based on the traffic category. As can be seen from the above, the traffic category includes one of the following: encrypted traffic, log traffic, control command traffic, and general traffic.

[0075] In one embodiment, step 105 includes:

[0076] Based on traffic data categories, filter out category-related strategies from the forwarding strategy set;

[0077] Obtain the forwarding policies supported by the network controller as a reference forwarding policy;

[0078] The reference forwarding strategy is compared with the category association strategy to obtain the strategy comparison result; the strategy comparison result is used to indicate whether the reference forwarding strategy and the category association strategy are the same or different.

[0079] The target forwarding strategy is selected from the forwarding strategy set based on the strategy comparison results.

[0080] Category-based forwarding policies refer to forwarding policies associated with traffic data categories. Switches store a set of forwarding policies, including LAN identifier forwarding policies (policy a), LAN address forwarding policies (policy b), and multicast forwarding policies (policy c).

[0081] In one embodiment, if the traffic data category is encrypted data, the LAN identifier forwarding policy is determined as a category-associated policy; if the traffic data category is command data, at least one of the LAN identifier forwarding policy and the LAN address forwarding policy is determined as a category-associated policy; if the traffic data category is log data, the multicast packet forwarding policy is determined as a category-associated policy.

[0082] Referring to the above, different forwarding strategies are applicable in different scenarios. This embodiment determines different category association strategies based on traffic data categories, and then determines the target forwarding strategy based on the category association strategies, which has high applicability and flexibility.

[0083] The switch stores the registration information of the network controllers and can retrieve the forwarding policies supported by the network controllers from the registration information as reference forwarding policies. The supported forwarding policies refer to the rules that the network controller can implement or configure. For example, if network controller 1 supports forwarding policy a, the switch will prioritize forwarding the network uplink traffic data of network controller 1 according to policy a. Similarly, if network controller 2 supports forwarding policy b, the switch will prioritize forwarding the network uplink traffic data of network controller 2 according to policy b.

[0084] The strategy comparison result refers to the comparison result between the reference forwarding strategy and the category-associated strategy. For example, if the reference forwarding strategy is strategy a and the category-associated strategy is strategy b, then the strategy comparison result indicates that the reference forwarding strategy and the category-associated strategy are the same. Conversely, if the reference forwarding strategy is strategy a and the category-associated strategy is strategy b, then the strategy comparison result indicates that the reference forwarding strategy and the category-associated strategy are not the same. After obtaining the strategy comparison result, the target forwarding strategy needs to be selected from the forwarding strategy set based on the strategy comparison result.

[0085] In one embodiment, the process of selecting a target forwarding strategy from the forwarding strategy set based on the strategy comparison result may include: if the strategy comparison result indicates that the reference forwarding strategy is the same as the category-related strategy, then the category-related strategy is extracted from the forwarding strategy set and the category-related strategy is determined as the target forwarding strategy; if the strategy comparison result indicates that the reference forwarding strategy is not the same as the category-related strategy, then a category-general strategy is extracted from the forwarding strategy set and the category-general strategy is determined as the target forwarding strategy; wherein, the category-general strategy does not include the category-related strategy.

[0086] In one example, if the reference forwarding policy is policy a, and the category-associated policy is also policy a, then the policy comparison result indicates that the reference forwarding policy and the category-associated policy are the same. The category-associated policy is then extracted from the forwarding policy set as policy a, and policy a is determined as the target forwarding policy. If the reference forwarding policy is not policy a, but the category-associated policy is policy a, then the policy comparison result indicates that the reference forwarding policy and the category-associated policy are different. The category-general policy is then extracted from the forwarding policy set as policy b (or policy c), and policy b (or policy c) is determined as the target forwarding policy.

[0087] The advantage of the above embodiments is that the forwarding policy supported by the network controller can be given priority as the target forwarding policy, which helps to improve the efficiency of data forwarding.

[0088] In one embodiment, the category association policy includes a LAN identifier forwarding policy and a LAN address forwarding policy. The process described above, where the policy comparison result indicates that the reference forwarding policy is the same as the category association policy, involves extracting the category association policy from the forwarding policy set and determining the category association policy as the target forwarding policy. This process may include: if the reference forwarding policy includes a LAN address forwarding policy, then extracting the LAN address forwarding policy from the forwarding policy set and determining the LAN address forwarding policy as the target forwarding policy; if the reference forwarding policy includes a LAN identifier forwarding policy but does not include a LAN address forwarding policy, then extracting the LAN identifier forwarding policy from the forwarding policy set and determining the LAN identifier forwarding policy as the target forwarding policy.

[0089] In this embodiment, the reference forwarding policy including a LAN address forwarding policy can be either a LAN address forwarding policy that only includes a LAN address forwarding policy, or a LAN identifier forwarding policy that includes both a LAN address forwarding policy and a LAN identifier forwarding policy. If the reference forwarding policy includes a LAN address forwarding policy, the LAN address forwarding policy is preferentially selected as the target forwarding policy. Conversely, if the reference forwarding policy does not include a LAN address forwarding policy, but includes a LAN identifier forwarding policy, then the LAN identifier forwarding policy is determined as the target forwarding policy.

[0090] The advantage of the above embodiments is that, when the reference forwarding strategy may include multiple strategies, the local area network address forwarding strategy is preferentially selected as the target forwarding strategy, which can effectively reduce the data forwarding load.

[0091] In one embodiment, after step 106, the vehicle-to-everything (V2X) data transmission method further includes:

[0092] If the reference forwarding policy includes a LAN identifier forwarding policy and a LAN address forwarding policy, detect the load of data forwarding according to the target forwarding policy;

[0093] If the load exceeds the preset load threshold, the target forwarding policy will be switched from LAN address forwarding policy to LAN identifier forwarding policy, or the target forwarding policy will be switched from LAN identifier forwarding policy to LAN address forwarding policy.

[0094] If the load exceeds the preset load threshold, it indicates that forwarding data according to the target forwarding policy is not appropriate, and a policy switch is required. The policy switch can be performed by changing from a LAN identifier forwarding policy to a LAN address forwarding policy, or vice versa.

[0095] The advantage of the above embodiments is that the target forwarding strategy based on load dynamic switching improves the flexibility of data forwarding.

[0096] Referring to Figure 8, in one example, determining the target forwarding policy includes the following scenarios:

[0097] (1) For traffic data of the general data category: Policy b is determined as the target forwarding policy. Specifically, regardless of whether all network controllers support policy b, the switch will prioritize using policy b for forwarding network uplink traffic data.

[0098] (2) For traffic data categories that are encrypted:

[0099] If the reference forwarding strategy is strategy a, and the category-associated strategy is also strategy a, then the strategy comparison result indicates that the reference forwarding strategy is the same as the category-associated strategy (i.e., it supports strategy a). Then, the category-associated strategy is extracted from the forwarding strategy set as strategy a, and strategy a is determined as the target forwarding strategy.

[0100] If the reference forwarding strategy is not strategy a, but the category-associated strategy is strategy a, then the strategy comparison result indicates that the reference forwarding strategy and the category-associated strategy are different (i.e., strategy a is not supported). Then, the category-general strategy is extracted from the forwarding strategy set as strategy b, and strategy b is determined as the target forwarding strategy.

[0101] (3) For traffic data of the instruction data type:

[0102] If the reference forwarding strategy is strategy a, and the category-associated strategy includes strategy a, then the strategy comparison result indicates that the reference forwarding strategy is the same as the category-associated strategy (i.e., only strategy a is supported). Then, the category-associated strategy is extracted from the forwarding strategy set as strategy a, and strategy a is determined as the target forwarding strategy.

[0103] If the reference forwarding strategy is strategy b, and the category-associated strategy includes strategy b, then the strategy comparison result indicates that the reference forwarding strategy is the same as the category-associated strategy (i.e., only strategy b is supported). Then, the category-associated strategy is extracted from the forwarding strategy set as strategy b, and strategy b is determined as the target forwarding strategy.

[0104] If the reference forwarding policies are policies a and b, and the category-associated policies include policies a and b, then the policy comparison result indicates that the reference forwarding policies are the same as the category-associated policies (i.e., both policies a and b are supported). In this case, the policy is switched according to the load of the target forwarding policy. Specifically, this includes: determining the LAN address forwarding policy as the target forwarding policy; then detecting the load of data forwarding according to the target forwarding policy; if the load is greater than a preset load threshold, then switching the target forwarding policy from the LAN address forwarding policy to the LAN identifier forwarding policy, or switching the target forwarding policy from the LAN identifier forwarding policy to the LAN address forwarding policy.

[0105] (4) For traffic data of the log data type:

[0106] If the reference forwarding strategy is strategy c, and the category-associated strategy is also strategy c, then the strategy comparison result indicates that the reference forwarding strategy is the same as the category-associated strategy (i.e., it supports strategy c). Then, the category-associated strategy is extracted from the forwarding strategy set as strategy c, and strategy c is determined as the target forwarding strategy.

[0107] If the reference forwarding policy is policy b and the category-associated policy is policy c, the policy comparison result indicates that the reference forwarding policy and the category-associated policy are different (i.e., policy c is not supported). Then, the category-general policy is extracted from the forwarding policy set as policy b, and policy b is determined as the target forwarding policy. Specifically, network uplink traffic data is sent by the network controller in multicast mode. The switch determines whether each network controller supports policy c. If policy c is supported, policy c is used; otherwise, the default policy b is used.

[0108] In step 106 of some embodiments, the switch forwards the network uplink traffic data to the target network providing device according to the target forwarding policy. The specific forwarding process is described below from three aspects.

[0109] Firstly, the target forwarding strategy is a local area network (LAN) identifier forwarding strategy. The LAN identifier forwarding strategy includes a first LAN identifier and a second LAN identifier. The first LAN identifier is associated with a wireless hotspot network providing device, and the second LAN identifier is associated with a cellular network providing device. In one embodiment, step 106 includes: obtaining the destination LAN identifier of the network uplink traffic data as an initial destination LAN identifier; if the target network providing device is a wireless hotspot network providing device, modifying the initial destination LAN identifier to the first LAN identifier to obtain a target destination LAN identifier; if the target network providing device is a cellular network providing device, modifying the initial destination LAN identifier to the second LAN identifier to obtain a target destination LAN identifier; and forwarding the network uplink traffic data to the target network providing device according to the target destination LAN identifier.

[0110] Referring to Figures 2, 3, and 4, in one example, assume that the first network controller VLAN1 sends network uplink traffic data to switch 201 from the digital interface (Port1). Switch 201 obtains the LAN identifier of the first network controller VLAN1 as the initial destination LAN identifier (e.g., VLAN1). If the target network provider is a wireless hotspot network provider (i.e., the current network mode is WiFi), then switch 201 modifies the initial destination LAN identifier (e.g., VLAN102) to the first LAN identifier (e.g., VLAN101) to obtain the target destination LAN identifier (e.g., VLAN101). Switch 201 forwards the network uplink traffic data to the wireless hotspot network provider based on the target destination LAN identifier (e.g., VLAN101). If the target network provider is a cellular network provider (i.e., the current network mode is cellular), then switch 201 modifies the initial destination LAN identifier (e.g., VLAN 101) to a second LAN identifier (e.g., VLAN 102) to obtain the target destination LAN identifier (e.g., VLAN 102). Switch 201 then forwards the network uplink traffic data to the cellular network provider based on the target destination LAN identifier (e.g., VLAN 102).

[0111] In one embodiment, the process of forwarding network uplink traffic data to the target network providing device based on the target local area network identifier may include: obtaining an identifier interface mapping table; searching the identifier interface mapping table based on the target local area network identifier to obtain the target interface; and forwarding the network uplink traffic data from the target interface to the target network providing device.

[0112] As described above, the switch includes a first interface and a second interface. The wireless hotspot network provider connects to the first interface, and the cellular network provider connects to the second interface. The interface identifier mapping table indicates the relationship between the first LAN identifier and the first interface, and the relationship between the second LAN identifier and the second interface. For example, it indicates that the wireless hotspot network provider associated with the first LAN identifier is connected to the first interface of the switch, and the cellular network provider associated with the second LAN identifier is connected to the second interface of the switch, as shown in Table 1: Table 1

[0113] In Table 1, if the target local area network is identified as VLAN 101, then the target interface is the first interface; if the target local area network is identified as VLAN 102, then the target interface is the second interface.

[0114] The advantage of the above-described embodiment of determining the target interface for data forwarding is that it can improve the efficiency of data forwarding.

[0115] Secondly, the target forwarding strategy is a local area network (LAN) address forwarding strategy. The LAN address forwarding strategy includes a first LAN address and a second LAN address. The first LAN address is associated with a wireless hotspot network providing device, and the second LAN address is associated with a cellular network providing device. In one embodiment, step 106 further includes: obtaining the destination LAN address of the network uplink traffic data as the initial destination LAN address; if the target network providing device is a wireless hotspot network providing device, modifying the initial destination LAN address to the first LAN address to obtain the target destination LAN address; if the target network providing device is a cellular network providing device, modifying the initial destination LAN address to the second LAN address to obtain the target destination LAN address; and forwarding the network uplink traffic data to the target network providing device according to the target destination LAN address.

[0116] Referring to Figures 2, 3, and 5, in one example, assume that the first network controller VLAN2 sends network uplink traffic data from the digital interface (Port2) to switch 201. Switch 201 obtains the LAN address of the first network controller VLAN2 as the initial destination LAN address (e.g., MAC102). If the target network provider is a wireless hotspot network provider (i.e., the current network mode is WiFi), then switch 201 modifies the initial destination LAN address (e.g., MAC102) to the first LAN address (e.g., MAC101), thus obtaining the target destination LAN address (e.g., MAC101). Switch 201 forwards the network uplink traffic data to the wireless hotspot network provider based on the target destination LAN address (e.g., MAC101). If the target network provider is a cellular network provider (i.e., the current network mode is cellular), then switch 201 modifies the initial destination LAN address (e.g., MAC101) to a second LAN address (e.g., MAC102) to obtain the target destination LAN address (e.g., MAC102). Switch 201 then forwards the network uplink traffic data to the cellular network provider based on the target destination LAN address (e.g., MAC102).

[0117] In one embodiment, the process of forwarding network uplink traffic data to the target network providing device based on the target local area network address may include: obtaining an address interface mapping table; searching the interface identifier mapping table according to the local area network address to obtain the target interface; and forwarding the network uplink traffic data from the target interface to the target network providing device.

[0118] As described above, the switch includes a first interface and a second interface. The wireless hotspot network provider connects to the first interface, and the cellular network provider connects to the second interface. The address interface mapping table indicates the relationship between a first LAN address and the first interface, and the relationship between a second LAN address and the second interface. For example, it indicates that the wireless hotspot network provider associated with the first LAN address is connected to the first interface of the switch, and the cellular network provider associated with the second LAN address is connected to the second interface of the switch, as shown in Table 2: Table 2

[0119] In Table 2, if the target LAN address is MAC101, then the target interface is the first interface; if the target LAN address is MAC102, then the target interface is the second interface.

[0120] The advantage of the above-described embodiment of determining the target interface for data forwarding is that it can improve the efficiency of data forwarding.

[0121] Thirdly, the target forwarding strategy is a multicast forwarding strategy. The multicast forwarding strategy includes wireless hotspot multicast packets and cellular multicast packets. Wireless hotspot multicast packets are associated with wireless hotspot network providing devices, and cellular multicast packets are associated with cellular network providing devices. In one embodiment, step 106 includes: if the target network providing device is a wireless hotspot network providing device, then the network uplink traffic data is divided into wireless hotspot multicast packets to obtain a target packet; if the target network providing device is a cellular network providing device, then the network uplink traffic data is divided into cellular multicast packets to obtain a target packet; and the network uplink traffic data is forwarded to the target network providing device according to the target packet.

[0122] Referring to Figures 2, 3, and 6, in one example, assume that uplink network traffic data is sent from the digital interface (Port2) to switch 201 by the first network controller VLAN2. If the target network provider is a wireless hotspot network provider, switch 201 segments the uplink network traffic data into wireless hotspot multicast packets and then forwards the uplink network traffic data to the wireless hotspot network provider based on the wireless hotspot multicast packets. If the target network provider is a cellular network provider, switch 201 segments the uplink network traffic data into cellular multicast packets and then forwards the uplink network traffic data to the cellular network provider based on the wireless hotspot multicast packets.

[0123] The advantage of the above-described embodiment of data forwarding based on the target forwarding strategy is that it achieves switching of networking modes by making full use of the connection relationship between the switch and the network controller, the wireless hotspot network provider and the cellular network provider, and has high versatility.

[0124] The various technical features in the above embodiments can be combined arbitrarily, as long as there is no conflict or contradiction between the combinations of features. However, due to space limitations, they are not described one by one. Therefore, the arbitrary combination of various technical features in the above embodiments is also within the scope of this specification.

[0125] This application also discloses an in-vehicle network data transmission device, applied to a switch in a vehicle. The vehicle is equipped with a wireless hotspot network provider, a cellular network provider, and a network controller connected to the switch. The wireless hotspot network provider is used to provide a wireless hotspot network. The cellular network provider is used to provide a cellular network. The in-vehicle network data transmission device includes: an instruction acquisition module for acquiring a network selection instruction, which indicates whether to select a wireless hotspot network provider or a cellular network provider; a device selection module for determining the wireless hotspot network provider or the cellular network provider as the target network provider based on the network selection instruction; a data receiving module for receiving network uplink traffic data sent by the network controller; a category determination module for acquiring the category of the network uplink traffic data as the traffic data category; a policy determination module for determining a target forwarding policy based on the traffic data category; and a data forwarding module for forwarding the network uplink traffic data to the target network provider according to the target forwarding policy.

[0126] It should be noted that the specific implementation method of the vehicle network data transmission device is basically the same as the specific implementation method of the above-mentioned vehicle network data transmission method, and will not be repeated here.

[0127] Referring to Figure 9, this application embodiment also discloses a switch, including at least one processor and a memory for communicating with the processor; the memory stores instructions that can be executed by at least one processor, and the instructions are executed by at least one processor to cause at least one processor to perform the vehicle networking data transmission method as described above.

[0128] The specific implementation method of the processor for executing vehicle network data transmission is basically the same as the specific embodiment of the vehicle network data transmission method described above, and will not be repeated here.

[0129] This application also discloses a vehicle, which includes: a switch for performing a vehicle-to-everything (V2X) data transmission method, and a wireless hotspot network provider, a cellular network provider, and a network controller connected to the switch.

[0130] It should be noted that the specific implementation method of the vehicle is basically the same as the specific implementation method of the above-mentioned vehicle network data transmission method, and will not be repeated here.

[0131] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the above-described vehicle network data transmission method.

[0132] Memory, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs and non-transitory computer-executable programs. Furthermore, memory may include high-speed random access memory, and may also include non-transitory memory, such as at least one disk storage device, flash memory device, or other non-transitory solid-state storage device. In some embodiments, memory may optionally include memory remotely located relative to the processor, and these remote memories can be connected to the processor via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.

[0133] The embodiments described in this application are for the purpose of more clearly illustrating the technical solutions of the embodiments of this application, and do not constitute a limitation on the technical solutions provided by the embodiments of this application. As those skilled in the art will know, with the evolution of technology and the emergence of new application scenarios, the technical solutions provided by the embodiments of this application are also applicable to similar technical problems.

[0134] Those skilled in the art will understand that the technical solutions shown in the figures do not constitute a limitation on the embodiments of this application, and may include more or fewer steps than shown, or combine certain steps, or different steps.

[0135] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.

[0136] Those skilled in the art will understand that all or some of the steps in the methods disclosed above, as well as the functional modules / units in the systems and devices, can be implemented as software, firmware, hardware, or suitable combinations thereof.

[0137] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in the specification and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms “comprising” and “having,” and any variations thereof, are intended to cover 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.

[0138] It should be understood that in this application, "at least one (item)" means one or more, and "more than" means two or more. "And / or" is used to describe the relationship between related objects, indicating that three relationships can exist. For example, "A and / or B" can represent three cases: only A exists, only B exists, and both A and B exist simultaneously, where A and B can be singular or plural. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. "At least one (item) of the following" or similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one (item) of a, b, or c can represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, and c can be single or multiple.

[0139] 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 the units described above 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 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; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.

[0140] The units described above 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.

[0141] 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.

[0142] 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 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 multiple 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 programs, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0143] The preferred embodiments of the present application have been described above with reference to the accompanying drawings, but this does not limit the scope of the claims of the present application. Any modifications, equivalent substitutions, and improvements made by those skilled in the art without departing from the scope and substance of the embodiments of the present application shall be within the scope of the claims of the present application.

Claims

1. A vehicle-mounted network data transmission method, applied to a switch in a vehicle, wherein the vehicle is equipped with a wireless hotspot network providing device, a cellular network providing device, and a network controller connected to the switch, the method comprising: Obtain a network selection instruction, which instructs the selection of the wireless hotspot network providing device or the cellular network providing device; Based on the network selection instruction, the wireless hotspot network providing device or the cellular network providing device is determined as the target network providing device; Receive network uplink traffic data sent by the network controller; Obtain the category of the network uplink traffic data and use it as the traffic data category; Based on the traffic data category, determine the target forwarding strategy; The network uplink traffic data is forwarded to the target network providing device according to the target forwarding policy.

2. The method according to claim 1, wherein, The switch stores a set of forwarding policies; determining the target forwarding policy based on the traffic data category includes: Based on the traffic data category, category-related strategies are selected from the forwarding strategy set; Obtain the forwarding policy supported by the network controller as a reference forwarding policy; The reference forwarding strategy is compared with the category association strategy to obtain a strategy comparison result; the strategy comparison result is used to indicate whether the reference forwarding strategy and the category association strategy are the same or different. The target forwarding strategy is selected from the forwarding strategy set based on the strategy comparison results.

3. The method according to claim 2, wherein, The forwarding strategy set includes LAN identifier forwarding strategy, LAN address forwarding strategy and multicast packet forwarding strategy; The step of filtering category-related policies from the forwarding policy set based on the traffic data category includes: If the traffic data category is an encrypted data category, then the LAN identifier forwarding policy is determined as the category association policy; If the traffic data category is the instruction data category, then at least one of the LAN identifier forwarding policy and the LAN address forwarding policy is determined as the category association policy; If the traffic data category is log data category, then the multicast packet forwarding strategy is determined as the category association strategy.

4. The method according to claim 2, wherein, The step of selecting the target forwarding strategy from the forwarding strategy set based on the strategy comparison result includes: If the strategy comparison result indicates that the reference forwarding strategy is the same as the category association strategy, then the category association strategy is determined as the target forwarding strategy; If the strategy comparison result indicates that the reference forwarding strategy is different from the category-associated strategy, then a category-general strategy is extracted from the forwarding strategy set as the target forwarding strategy; wherein, the category-general strategy does not include the category-associated strategy.

5. The method according to claim 4, wherein, If the policy comparison result indicates that the reference forwarding policy is the same as the category association policy, then the category association policy is determined as the target forwarding policy, including: If the reference forwarding policy includes a local area network address forwarding policy, then the local area network address forwarding policy is determined as the target forwarding policy; If the reference forwarding policy includes a LAN identifier forwarding policy but does not include the LAN address forwarding policy, then the LAN identifier forwarding policy is determined as the target forwarding policy.

6. The method according to claim 4 or 5, wherein, After forwarding the network uplink traffic data to the target network providing device according to the target forwarding policy, the method further includes: If the reference forwarding policy includes the LAN identifier forwarding policy and the LAN address forwarding policy, detect the load of data forwarding according to the target forwarding policy; If the load exceeds a preset load threshold, the target forwarding policy is switched from the LAN address forwarding policy to the LAN identifier forwarding policy, or the target forwarding policy is switched from the LAN identifier forwarding policy to the LAN address forwarding policy.

7. The method according to any one of claims 1 to 5, wherein, When the target forwarding policy is a local area network identifier forwarding policy, the step of forwarding the network uplink traffic data to the target network providing device according to the target forwarding policy includes: Obtain the destination LAN identifier of the network uplink traffic data and use it as the initial destination LAN identifier; If the target network providing device is the wireless hotspot network providing device, then the initial destination LAN identifier is modified to the first LAN identifier in the LAN identifier forwarding policy to obtain the target destination LAN identifier, wherein the first LAN identifier is associated with the wireless hotspot network providing device; If the target network providing device is the cellular network providing device, then the initial destination LAN identifier is modified to the second LAN identifier in the LAN identifier forwarding policy to obtain the target destination LAN identifier, wherein the second LAN identifier is associated with the cellular network providing device; The network uplink traffic data is forwarded to the target network provider device based on the target local area network identifier.

8. The method according to claim 7, wherein, The step of forwarding the network uplink traffic data to the target network providing device according to the target destination LAN identifier includes: Obtain an identifier interface mapping table, which indicates that the wireless hotspot network providing device associated with the first local area network identifier is connected to the first interface of the switch, and the cellular network providing device associated with the second local area network identifier is connected to the second interface of the switch; By searching the identifier interface mapping table according to the target local area network identifier, the first interface or the second interface is determined to be the target interface; The network uplink traffic data is forwarded from the target interface to the target network providing device.

9. The method according to any one of claims 1 to 5, wherein, When the target forwarding policy is a local area network address forwarding policy, the step of forwarding the network uplink traffic data to the target network providing device according to the target forwarding policy includes: Obtain the destination LAN address of the network uplink traffic data and use it as the initial destination LAN address; If the target network providing device is the wireless hotspot network providing device, then the initial destination LAN address is modified to the first LAN address in the LAN address forwarding policy to obtain the target destination LAN address, wherein the first LAN address is associated with the wireless hotspot network providing device; If the target network providing device is the cellular network providing device, then the initial destination LAN address is modified to the second LAN address in the LAN address forwarding policy to obtain the target destination LAN address, wherein the second LAN address is associated with the cellular network providing device; The network uplink traffic data is forwarded to the target network provider device according to the target local area network address.

10. The method according to claim 9, wherein, The step of forwarding the network uplink traffic data to the target network providing device according to the target destination LAN address includes: Obtain an address interface mapping table, which indicates that the wireless hotspot network providing device associated with the first local area network address is connected to the first interface of the switch, and the cellular network providing device associated with the second local area network address is connected to the second interface of the switch. By searching the address interface mapping table according to the target local area network address, the first interface or the second interface is determined to be the target interface; The network uplink traffic data is forwarded from the target interface to the target network providing device.

11. The method according to any one of claims 1 to 5, wherein, When the target forwarding policy is a multicast forwarding policy, forwarding the network uplink traffic data to the target network providing device according to the target forwarding policy includes: If the target network provider is the wireless hotspot network provider, then the network uplink traffic data is divided into wireless hotspot multicast packets, and the wireless hotspot multicast packets are identified as target packets; If the target network provider is the cellular network provider, then the network uplink traffic data is divided into cellular multicast packets, and the cellular multicast packets are identified as target packets; The network uplink traffic data is forwarded to the target network providing device according to the target packet.

12. A vehicle-mounted network data transmission device, applied to a switch in a vehicle, wherein the vehicle is equipped with a wireless hotspot network providing device, a cellular network providing device, and a network controller connected to the switch, the device comprising: The instruction acquisition module is used to acquire a network selection instruction, which indicates whether to select the wireless hotspot network providing device or the cellular network providing device. The device selection module is used to determine the wireless hotspot network providing device or the cellular network providing device as the target network providing device based on the network selection instruction; The data receiving module is used to receive network uplink traffic data sent by the network controller; The category determination module is used to obtain the category of the network uplink traffic data as the traffic data category; The strategy determination module is used to determine the target forwarding strategy based on the traffic data category; The data forwarding module is used to forward the network uplink traffic data to the target network providing device according to the target forwarding strategy.

13. A switch, comprising at least one processor and a memory for communicatively connecting to the processor; the memory storing instructions executable by the at least one processor, the instructions being executed by the at least one processor to cause the at least one processor to perform the vehicle networking data transmission method as described in any one of claims 1 to 11.

14. A vehicle comprising: The switch as described in claim 13; A wireless hotspot network provider, a cellular network provider, and a network controller are connected to the switch.

15. A computer-readable storage medium storing a computer program, which, when executed, implements the vehicle-to-everything (V2X) data transmission method as described in any one of claims 1 to 11.