Data transmission method, system and equipment based on Ethernet channel and medium

By adopting the data transmission method based on Ethernet channel in cars, the data transmission interruption caused by the complex on-board network environment is solved, and efficient and reliable data transmission is achieved, which is suitable for the data transmission needs of modern cars.

CN119135695APending Publication Date: 2024-12-13CHONGQING SELIS PHOENIX INTELLIGENT INNOVATION TECH CO LTD
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202411100964.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-12
Publication Date
2024-12-13

AI Technical Summary

Technical Problem

The in-vehicle network environment in modern cars is complex, resulting in problems such as electromagnetic interference, physical connection instability and network congestion during data transmission. Common data transmission methods are easily interrupted during vehicle driving and cannot meet the growing data transmission needs.

Method used

Using the data transmission method based on the Ethernet channel, by obtaining the data packet to be sent, an Ethernet connection channel between the sending end and the receiving end is established, and the communication status is stored and monitored based on the preset data structure. If an abnormality occurs, it will be re- Connect channels to ensure the continuity and accuracy of data transmission.

Benefits of technology

It improves the efficiency and accuracy of data transmission, reduces the communication failure rate, enhances the robustness of the system, and ensures the stability and reliability of data transmission.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119135695A_ABST
    Figure CN119135695A_ABST
Patent Text Reader

Abstract

The invention provides a data transmission method, system and device based on an Ethernet channel and a medium, and the method comprises the steps: obtaining a to-be-sent data message, building an Ethernet connection channel between a sending end and a receiving end, storing the to-be-sent data message based on a preset data structure, recording the sending and receiving states of each data message, and transmitting the to-be-sent data message to the receiving end. If the communication state is abnormal, the Ethernet connection channel is connected again until the Ethernet connection channel is recovered, a target data message is determined based on the current data message position, and the target data message is sent to the receiving end; by optimizing the Ethernet data transmission process, stable and reliable data communication between the data transmitting end and the data receiving end is realized, the efficiency and accuracy of data transmission are effectively improved, the communication failure rate is reduced, and the robustness of the system is enhanced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of intelligent automobile technology, and in particular to a data transmission method, system, device and medium based on an Ethernet channel. Background Art

[0002] In modern cars, on-board devices such as ECU (Electronic Control Unit) and VGW (Vehicle Gateway) play a vital role. They are responsible for monitoring and controlling various functions of the vehicle. In order to achieve remote control and update of these functions, these on-board devices need to transmit data through the network. This data transmission not only involves communication within the vehicle, but may also include interaction with remote servers to achieve software updates, fault diagnosis and performance optimization.

[0003] However, due to the complexity of the in-vehicle network environment, the data transmission process is not smooth sailing. In-vehicle networks need to deal with multiple challenges, such as electromagnetic interference, unstable physical connections, and network congestion. These problems may lead to failures in the data transmission process, such as unstable connections, data loss, or transmission delays. Especially during vehicle driving, due to bumps and vibrations, the network connection may be affected, resulting in interruption of data transmission. Therefore, the commonly used data transmission method is limited by the fact that it needs to start from scratch after interruption, and is not very suitable for the growing data transmission needs of modern cars. Summary of the invention

[0004] In view of the above-mentioned shortcomings of the prior art, the present application provides a data transmission method, system, device and medium based on Ethernet channel to solve the above-mentioned technical problems.

[0005] The present application provides a data transmission method based on an Ethernet channel, the method comprising: obtaining a data message to be sent; establishing an Ethernet connection channel between a sending end and a receiving end; storing the data message to be sent based on a preset data structure, and recording the sending and receiving status of each data message to obtain a current data message position; monitoring the communication status of the Ethernet connection channel, and if the communication status is abnormal, reconnecting the Ethernet connection channel until it is restored; determining a target data message based on the current data message position, and sending the target data message to the receiving end, the target data message being used to characterize the data message to be sent with data transmission interruption.

[0006] In one embodiment of the present application, an Ethernet connection channel is established between a transmitting end and a receiving end, including: respectively querying the initial channel status of the transport layer and the link layer; if the initial channel status of the link layer is abnormal, resetting the physical layer component to initialize the physical layer component, and re-driving the physical layer component until the initial channel status of the link layer returns to normal; if the initial channel status of the transport layer is abnormal, switching the Ethernet connection port and re-establishing the Ethernet connection channel until the initial channel status of the transport layer returns to normal.

[0007] In one embodiment of the present application, data packets to be sent are stored based on a preset data structure, including: storing the data packets to be sent in a preset cache space, and determining the data packets in the current cache and the preset cache space as the current data packets; if the status of the current data packet is that the transmission is completed, clearing the current data packet from the preset cache space, and receiving a new data packet and caching it in the preset cache space.

[0008] In one embodiment of the present application, the communication status of the Ethernet connection channel is monitored, including: respectively querying the current channel status of the transport layer and the link layer; if the current channel status of the link layer is abnormal, resetting the physical layer component to initialize the physical layer component, and re-driving the physical layer component until the current channel status of the link layer returns to normal; if the current channel status of the transport layer is abnormal, switching the Ethernet connection port and re-establishing the Ethernet connection channel, if the target port after switching is occupied, switching a new port again until the current channel status of the transport layer returns to normal.

[0009] In one embodiment of the present application, the transmitting end is a remote vehicle management system, and the receiving end is at least one of a vehicle electronic control system and a cloud network architecture.

[0010] The present application provides a data transmission system based on an Ethernet channel, the system comprising: an Ethernet channel control module, used to establish an Ethernet connection channel between a sending end and a receiving end, and used to monitor the link layer channel status; a data transceiver cache module, used to store data messages to be sent based on a preset data structure; a data transceiver calculation module, used to record the sending and receiving status of each data message to obtain a current data message position, and synchronize the current data message position to the data transceiver cache module; an Ethernet monitoring module, used to monitor the communication status of the Ethernet connection channel; a data transceiver control module, used to determine a target data message based on the current data message position, and send the target data message to the receiving end, the target data message being used to characterize the data message to be sent with data transmission interruption.

[0011] In one embodiment of the present application, the Ethernet monitoring module includes: an Ethernet transport layer monitoring module for monitoring the communication status of the Ethernet connection channel of the transport layer; and an Ethernet link layer monitoring module for monitoring the communication status of the Ethernet connection channel of the link layer.

[0012] In one embodiment of the present application, when the Ethernet monitoring module detects that the communication status of any Ethernet connection channel is abnormal, the obtained abnormal information is sent to the Ethernet channel control module to reconnect the Ethernet connection channel until it is restored.

[0013] The present application provides an electronic device, characterized in that it includes a processor, a memory and a communication bus; the communication bus is used to connect the processor and the memory; the processor is used to execute a computer program stored in the memory to implement the data transmission method based on the Ethernet channel as described above.

[0014] The present application provides a computer-readable storage medium, characterized in that a computer program is stored thereon, and the computer program is used to enable a computer to execute the data transmission method based on the Ethernet channel as described above.

[0015] Beneficial effects of the present application: The present application proposes a data transmission method, system, device and medium based on Ethernet channel. The core of the method is to first obtain the data message to be sent, and establish an Ethernet connection channel between the sending end and the receiving end, so as to lay a solid foundation for subsequent data transmission; then use a preset data structure to store these data messages to be sent, and accurately record the sending and receiving status of each data message, so as to be able to track the location of the current data message in real time; during the data transmission process, the communication status of the Ethernet connection channel is continuously monitored. Once an abnormality is found in the communication status, such as connection interruption or data transmission error, the system will immediately start the reconnection mechanism until the Ethernet connection channel returns to normal; in addition, according to the location of the current data message, the next target data message to be sent is intelligently determined and accurately sent to the receiving end. In general, by optimizing the Ethernet data transmission process, the present application not only significantly improves the efficiency and accuracy of data transmission, but also effectively reduces the communication failure rate and enhances the robustness of the entire system.

[0016] It should be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present application. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] The drawings herein are incorporated into the specification and constitute a part of the specification, showing embodiments consistent with the present application, and together with the specification, are used to explain the principles of the present application. Obviously, the drawings described below are only some embodiments of the present application, and for those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative work. In the drawings:

[0018] Figure 1 is a schematic diagram of OTA upgrade data transmission shown in an exemplary embodiment of the present application;

[0019] Figure 2 is a connection diagram of an Ethernet communication link shown in an exemplary embodiment of the present application;

[0020] Figure 3 is a schematic diagram of a data transmission process shown in an exemplary embodiment of the present application;

[0021] Figure 4 is a flow chart of a data transmission method based on an Ethernet channel shown in an exemplary embodiment of the present application;

[0022] Figure 5 is a schematic diagram of the system structure of a data transmission system based on an Ethernet channel shown in an exemplary embodiment of the present application;

[0023] Figure 6 A schematic diagram of the structure of a computer system suitable for implementing an electronic device of an embodiment of the present application is shown. DETAILED DESCRIPTION

[0024] The following will describe the implementation methods of the present application with reference to the accompanying drawings and preferred embodiments. Those skilled in the art can easily understand other advantages and effects of the present application from the contents disclosed in this specification. The present application can also be implemented or applied through other different specific implementation methods, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present application. It should be understood that the preferred embodiments are only for illustrating the present application, not for limiting the scope of protection of the present application.

[0025] It should be noted that the illustrations provided in the following embodiments are only schematic illustrations of the basic concept of the present application, and thus the drawings only show components related to the present application rather than being drawn according to the number, shape and size of components in actual implementation. In actual implementation, the type, quantity and proportion of each component may be changed at will, and the component layout may also be more complicated.

[0026] In the following description, a large number of details are discussed to provide a more thorough explanation of the embodiments of the present application. However, it is obvious to those skilled in the art that the embodiments of the present application can be implemented without these specific details. In other embodiments, well-known structures and devices are shown in the form of block diagrams rather than in detail to avoid making the embodiments of the present application difficult to understand.

[0027] First of all, it needs to be explained that the full name of OTA in English is Over the Air Technology, which means space download technology. Car OTA upgrade refers to firmware upgrade and software upgrade using air download technology.

[0028] In addition, CDC (Cockpit Domain Controller) is the smart cockpit, VDC (Vehicle Domain Controller) is the whole vehicle control, ADC (ADASDomain Controller) is the intelligent driving, VIU (Vehicle Integration Unit) is the whole vehicle integration gateway, and VGW (whole vehicle gateway).

[0029] Ethernet DOIP protocol, full name Diagnostic communication over Internet Protocol, is an IP-based diagnostic communication protocol that transmits diagnostic data via Ethernet and is regulated by ISO 13400 standard.

[0030] VGW (Vehicle Gateway) refers to the vehicle gateway.

[0031] The Unified Diagnostic Services (UDS) message is a universal automotive diagnostic protocol message defined by ISO 14229 and ISO 15765 and is located at the application layer of the OSI model.

[0032] Socket, also known as socket, is a basic concept in network programming. It is an abstraction of network communication endpoints in the TCP / IP protocol family. A socket represents a combination of an IP address and a port number. Through the socket, the application layer can interact with the transport layer to send and receive data.

[0033] PHY (Physical Layer Interface Devices) chip, also known as physical layer interface device, is a key component that connects each network element to the physical medium and is responsible for completing the functions in the first layer of the OSI model (Open System Interconnection Reference Model).

[0034] In view of the OTA download and upgrade processing technology mentioned in this application, which mainly involves the OTA upgrade master control (UMC), OTA upgrade agent (UA) and OTA upgrade slave control (US), the technology is mainly implemented in the VBOX (vehicle remote communication module), VGW (vehicle gateway) and the ECU (electronic control unit) that are respectively carried. Therefore, in one embodiment of the present application, as Figure 1 As shown, in order to achieve the purpose of downloading OTA upgrade packages and upgrading ECU components, VBOX and VGW are connected via Ethernet, and VGW is connected to each ECU component under it via CAN bus, and one or more ECU components are mounted below it.

[0035] In addition, if Figure 2 As shown in the figure, when the OTA master control (UMC) upgrades and flashes the target ECU, for ECUs that support Ethernet, the OTA master control and the target ECU establish a TCP communication connection through the VGW for link layer transparent transmission, and use the DOIP protocol for data communication transmission and upgrade flashing; for ECUs that do not support Ethernet, the OTA master control establishes a TCP communication connection with the VGW (UA), and the VGW (UA) parses the ECU target address (TA) of the message, converts the UDS message through the ETH message format, and forwards the message to the target ECU for data communication and upgrade flashing.

[0036] Specific as Figure 3 As shown in the figure, ECU1 and ECU2 support the Ethernet DOIP protocol. The OTA master directly establishes a TCP (transport layer) communication connection with ECU1 and ECU2 through VGW for data transmission via Layer 2 (link layer) transparent transmission. In this way, OTA directly connects to the target ECU for data transmission. Among them, ECUx and ECUz do not support the Ethernet DOIP protocol. The OTA master transmits the data to VGW for caching by establishing a TCP (transport layer) connection with VGW. VGW then parses the data packet and converts it into the UDS message format, and then forwards it to the target ECU for upgrade and flashing.

[0037] Figure 4 It is a flowchart of a data transmission method based on an Ethernet channel shown in an exemplary embodiment of the present application.

[0038] like Figure 4 As shown, in an exemplary embodiment, the data transmission method based on the Ethernet channel includes at least steps S410 to S450, which are described in detail as follows:

[0039] Step S410, obtaining a data message to be sent.

[0040] In one embodiment of the present application, in a modern automobile communication system, the ECU (electronic control unit) often needs to send data messages to the VGW (vehicle gateway) to achieve remote control and status updates of various vehicle functions. First, the system needs to obtain the data message to be sent, which may contain real-time status information of the vehicle, sensor data, control instructions, etc. In this embodiment, taking the example that the ECU needs to send a set of data messages about the vehicle engine status to the VGW, the ECU collects data about the engine status, such as speed, temperature, fuel consumption, etc. through its internal sensors and control system; then the obtained data is converted into a data message that conforms to a predetermined data structure according to a preset standard format for subsequent processing and transmission.

[0041] Figure 5 It is a schematic diagram of the system structure of a data transmission system based on an Ethernet channel shown in an exemplary embodiment of the present application.

[0042] like Figure 5 As shown, in one embodiment of the present application, the data transmission system of the Ethernet channel is divided into a data sending end and a receiving end, and the sending end and the receiving end respectively include a data transceiver control module, a data transceiver calculation module, an Ethernet channel control module, an Ethernet transport layer monitoring module, an Ethernet link layer monitoring module, a data transceiver storage module, a sending module, and a receiving module.

[0043] Among them, the Ethernet channel control module is used to establish an Ethernet connection channel between the sending end and the receiving end, and is used to monitor the link layer channel status; the data transceiver cache module is used to store the data messages to be sent based on the preset data structure; the data transceiver calculation module is used to record the sending and receiving status of each data message to obtain the current data message position, and synchronize the current data message position to the data transceiver cache module; the data transceiver control module is used to determine the target data message based on the current data message position, and send the target data message to the receiving end, and the target data message is used to characterize the data message to be sent with data transmission interruption. In addition, it also includes an Ethernet transport layer monitoring module for monitoring the communication status of the Ethernet connection channel of the transport layer, and an Ethernet link layer monitoring module for monitoring the communication status of the Ethernet connection channel of the link layer.

[0044] It should be noted that the data transmission system based on the Ethernet channel provided in the above embodiment and the data transmission method based on the Ethernet channel provided in the following embodiment belong to the same concept, wherein the specific manner in which each module and unit performs the operation has been described in detail in the method embodiment, and will not be repeated here. In practical applications, the data transmission system based on the Ethernet channel provided in the above embodiment can allocate the above functions to different functional modules as needed, that is, divide the internal structure of the device into different functional modules to complete all or part of the functions described above, and this is not limited here.

[0045] Step S420: Establish an Ethernet connection channel between the sending end and the receiving end.

[0046] In one embodiment of the present application, the transmitting end is a remote vehicle management system, and the receiving end is at least one of a vehicle electronic control system and a cloud network architecture. Establishing an Ethernet connection channel between the transmitting end and the receiving end includes: respectively querying the initial channel status of the transport layer and the link layer; if the initial channel status of the link layer is abnormal, resetting the physical layer component to initialize the physical layer component, and re-driving the physical layer component until the initial channel status of the link layer returns to normal; if the initial channel status of the transport layer is abnormal, switching the Ethernet connection port and re-establishing the Ethernet connection channel until the initial channel status of the transport layer returns to normal.

[0047] In one embodiment of the present application, the remote vehicle management system queries the initial channel status of the transport layer and the link layer respectively. If the initial channel status of the link layer is abnormal (such as connection interruption, unstable signal, etc.), the physical layer component is reset to initialize the physical layer component; thereafter, the physical layer component is redriven, and the link layer status is continuously monitored until the initial channel status of the link layer returns to normal. If the initial channel status of the transport layer is abnormal (such as data transmission error, protocol mismatch, etc.), the Ethernet connection port is switched and the Ethernet connection channel is re-established. The transport layer status is continuously monitored until the initial channel status of the transport layer returns to normal.

[0048] In a specific embodiment of the present application, the OTA master communicates with the target ECU or VGW by establishing a Socket connection (the connection is carried on the transport layer, as shown in Figure 7), and the data message is transmitted through the DOIP protocol. The DOIP protocol message is carried on the Socket for data transmission. The transport layer data is encapsulated through the link layer for data forwarding, and vice versa. In addition, the OTA master establishes a Socket connection with the target ECU or VGW. If it cannot be established normally at this time, the Ethernet channel control module of the OTA UMC and the ECU UA / US will query the transport layer and link layer channel status information. If the link layer status is "LinkDown", the Ethernet channel control module will reset the PHY chip, so that the PHY chip is reinitialized, and the driver configuration is performed to restore the link layer to normal. The query status is "LinkUP". If it is still "Linkdown", it prompts "Is the network cable correctly inserted?" The Ethernet transport layer module monitors the current status of the transport layer. When the link layer status is "LinkUP", the Ethernet channel control module switches to another port to re-establish the Socket connection. If the link layer status is "LinkDown", the link status is queried until it is "LinkUP".

[0049] Step S430, storing the data messages to be sent based on the preset data structure, and recording the sending and receiving status of each data message to obtain the current data message position.

[0050] In one embodiment of the present application, data packets to be sent are stored based on a preset data structure, including: storing the data packets to be sent in a preset cache space, and determining the data packets in the current cache and the preset cache space as the current data packets; if the status of the current data packet is that the transmission is completed, the current data packet is cleared from the preset cache space, and a new data packet is received and cached in the preset cache space.

[0051] In one embodiment of the present application, after the Ethernet connection channel is successfully established, the remote vehicle management system begins to store the data messages to be sent based on the preset data structure. The data messages to be sent are stored in a preset cache space, which is specifically used to temporarily store the data messages to be sent; and the data messages in the current cache and the preset cache space are determined as the current data messages, that is, the data messages that need to be sent are determined. In addition, if the status of the current data message is that the transmission is completed (that is, it has been successfully sent to the receiving end), the current data message is cleared from the preset cache space, and after clearing, a new data message is received and cached in the preset cache space for subsequent transmission.

[0052] In a specific embodiment of the present application, when the OTA master communicates with the target ECU or VGW for data transmission, the data message is temporarily stored in the "data transceiver cache module" (to save cache module space, the data message length is stored up to 64K bytes). When the data message in the cache module is sent successfully or the application layer is received successfully, the new data message is stored in the cache module. If there is a repeated data access operation, the "data transceiver calculation module" records the number of bytes sent and received by the current data message.

[0053] Step S440, monitoring the communication status of the Ethernet connection channel, if the communication status is abnormal, reconnecting the Ethernet connection channel until it is restored.

[0054] In one embodiment of the present application, the communication status of the Ethernet connection channel is monitored, including: querying the current channel status of the transport layer and the link layer respectively; if the current channel status of the link layer is abnormal, resetting the physical layer component to initialize the physical layer component, and re-driving the physical layer component until the current channel status of the link layer returns to normal; if the current channel status of the transport layer is abnormal, switching the Ethernet connection port and re-establishing the Ethernet connection channel, if the target port after switching is occupied, switching a new port again until the current channel status of the transport layer returns to normal.

[0055] In one embodiment of the present application, the system periodically queries the current channel status of the transport layer and the link layer respectively to monitor the communication status of the channel. If the current channel status of the link layer is abnormal, the physical layer component is reset for initialization processing, and the physical layer component is redriven until the current channel status of the link layer returns to normal. If the current channel status of the transport layer is abnormal, the Ethernet connection port is switched and the Ethernet connection channel is reestablished; when switching ports, if the target port after switching is occupied, the system will switch a new port again until the current channel status of the transport layer returns to normal.

[0056] In a specific embodiment of the present application, when the OTA master communicates with the target ECU or VGW for data transmission, the Ethernet transport layer monitoring module and the Ethernet link layer monitoring module monitor the status of the communication channel and feed back the current channel status to the Ethernet channel control module in real time. When the link layer fails, that is, "linkdown" (the transport layer cannot perceive the on-off information during the period of 30 to 90 seconds, and is still retrying to send or receive data messages), the Ethernet channel control module immediately resets the PHY chip, so that the PHY chip is reinitialized and the driver configuration is performed, so that the link layer communication status is restored to normal, and the communication is also normal. In addition, the Ethernet transport layer monitoring module and the Ethernet link layer monitoring module monitor the status of the communication channel and feed back the current channel status to the Ethernet channel control module in real time. When the transport layer fails (that is, the communication status is abnormal), the Ethernet channel control module closes the current Socket connection and reconnects. If the current port number is returned to be reused, the current port number is automatically increased by one to connect until success.

[0057] Step S450, determining a target data message based on the current data message position, and sending the target data message to the receiving end, wherein the target data message is used to represent the data message to be sent with data transmission interrupted.

[0058] In one embodiment of the present application, when data transmission is interrupted, the system determines the target data message in the preset cache space based on the position of the current data message. The target data message refers to the data message to be sent that failed to be successfully sent due to the interruption of transmission. Once the target data message is determined, the system attempts to resend these data messages. It should be emphasized that before resending, the system may first check the communication status of the Ethernet connection channel to ensure that the channel is normal. If the channel status is abnormal, the system will first perform channel recovery operations (such as physical layer component reset, port switching, etc. in the above technical solution), and then try to send the target data message. In addition, when the Ethernet connection channel status is normal, the system will send the target data message to the receiving end, and after sending, update the status of the data message, such as marking it as "retransmitted" or "pending confirmation". Finally, after receiving the target data message, the receiving end (vehicle electronic control system or cloud network architecture) performs data processing and sends confirmation information to the sending end. When the sending end receives the confirmation information, it automatically updates the corresponding data message status to "received".

[0059] In addition, after the above data transmission is completed, the system can also continuously monitor the sending status of the data message and the communication status of the Ethernet connection channel. If any abnormality is encountered, such as data loss again, abnormal channel status, etc., the system will perform predetermined error handling operations, such as trying to send again, recording logs, or performing channel recovery.

[0060] In a specific embodiment of the present application, the data transceiver calculation module sends the number of bytes of the currently sent or received data message (i.e., the current data message position) to the data transceiver cache module, and the data transceiver cache module obtains the data message according to the data message position sent by the data transceiver calculation module, and the data transceiver control module commands the sending module to send data, or commands the receiving module to receive data. It should be noted that this processing of the link layer is not felt by the application layer, so as to achieve the purpose of making the user feel that the communication channel is "unimpeded".

[0061] It should be noted that based on the data transmission method proposed in the above embodiment, the remote vehicle management system can determine the target data message based on the current data message position and send it to the receiving end when data transmission is interrupted, thereby ensuring the integrity and reliability of the data and improving the stability and availability of the system.

[0062] In a completed specific embodiment of the present application, the remote vehicle management system is used as the sending end, and the vehicle electronic control system or cloud network architecture is used as the receiving end. First, an Ethernet connection channel is established between the sending end and the receiving end. During the establishment process, the system will query the initial channel status of the transport layer and the link layer respectively to ensure the normality of the channel. If the link layer or the transport layer status is abnormal, the system will perform corresponding initialization processing or port switching until the channel status returns to normal. Secondly, once the Ethernet connection channel is successfully established, the remote vehicle management system begins to store the data message to be sent based on the preset data structure, and stores the data message to be sent to the preset cache space to determine the data message that needs to be sent at present. In addition, the system regularly queries the current channel status of the transport layer and the link layer respectively to monitor the communication status of the channel. If the link layer or the transport layer status is abnormal, the system will take corresponding measures to restore the channel, such as resetting the physical layer component, switching the port, etc., until the channel status returns to normal. When the communication status of the Ethernet connection channel is normal, the system takes out the current data message from the preset cache space and sends it to the receiving end, and updates the status of the data message after sending, such as marking it as "sent" or "pending confirmation". It should be noted that during the data transmission process, if the system detects that the data transmission is interrupted (such as due to channel failure, the receiving end timeout and no response, etc.), the interrupted data message position and status are recorded, and based on the current data message position, the target data message is determined in the preset cache space, that is, those data messages to be sent that have not been successfully sent due to the transmission interruption, and then the target data message is tried to be resent. However, before resending, the communication status of the Ethernet connection channel needs to be checked and the channel needs to be ensured to be normal. When the channel status is normal, the system sends the target data message to the receiving end and updates the status of the data message to "re-sent" or "pending confirmation". Finally, after receiving the data message (including the target data message), the receiving end will process the data and send a confirmation message to the sending end. After receiving the confirmation message, the sending end updates the corresponding data message status to "received". In addition, the sending status of the data message and the communication status of the Ethernet connection channel can be continuously monitored. If any abnormality is encountered, such as data loss, abnormal channel status, etc., the system will perform a predetermined error handling operation, such as retrying to send, recording logs or performing channel recovery.

[0063] It should be noted that, based on the embodiments proposed in this application, stable and reliable data communication is achieved between the remote vehicle management system and the vehicle electronic control system and / or the cloud network architecture; at the same time, by continuously monitoring the communication status of the Ethernet connection channel and handling data transmission interruptions, the integrity and reliability of the data are ensured, and the stability and availability of the system are improved.

[0064] An embodiment of the present application also provides an electronic device, comprising: one or more processors; a storage device for storing one or more programs, when the one or more programs are executed by one or more processors, the electronic device implements the data transmission method based on the Ethernet channel provided in the above-mentioned embodiments.

[0065] Figure 6 The structure diagram of the computer system suitable for implementing the electronic device of the embodiment of the present application is shown. It should be noted that: Figure 6 The computer system 600 of the electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.

[0066] like Figure 6 As shown, the computer system 600 includes a central processing unit (CPU) 601, which can perform various appropriate actions and processes according to the program stored in the read-only memory (ROM) 602 or the program loaded from the storage part 608 to the random access memory (RAM) 603, such as executing the method in the above embodiment. In the RAM 603, various programs and data required for system operation are also stored. The CPU 601, ROM 602 and RAM 603 are connected to each other through a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.

[0067] The following components are connected to the I / O interface 605: an input section 606 including a keyboard, a mouse, etc.; an output section 607 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 608 including a hard disk, etc.; and a communication section 609 including a network interface card such as a LAN (Local Area Network) card, a modem, etc. The communication section 609 performs communication processing via a network such as the Internet. A drive 610 is also connected to the I / O interface 605 as needed. A removable medium 611, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 610 as needed so that a computer program read therefrom is installed into the storage section 608 as needed.

[0068] In particular, according to an embodiment of the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present application includes a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a computer program for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication section 609, and / or installed from a removable medium 611. When the computer program is executed by a central processing unit (CPU) 601, various functions defined in the system of the present application are executed.

[0069] It should be noted that the computer-readable medium shown in the embodiment of the present application can be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium can be, for example, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media can include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM), a flash memory, an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present application, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, wherein a computer-readable computer program is carried. This propagated data signal can take a variety of forms, including but not limited to an electromagnetic signal, an optical signal, or any suitable combination of the above. A computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. A computer program contained on a computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wired, etc., or any suitable combination of the above.

[0070] The flowchart and block diagram in the accompanying drawings illustrate the possible architecture, functions and operations of the system, method and computer program product according to various embodiments of the present application. Wherein, each box in the flowchart or block diagram can represent a module, a program segment, or a part of the code, and the above-mentioned module, program segment, or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flowchart, and the combination of boxes in the block diagram or flowchart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0071] The units involved in the embodiments described in this application may be implemented by software or hardware, and the units described may also be set in a processor. The names of these units do not, in some cases, constitute limitations on the units themselves.

[0072] Another aspect of the present application also provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor of a computer, the computer executes the data transmission method based on the Ethernet channel as described above. The computer-readable storage medium may be included in the electronic device described in the above embodiment, or may exist independently without being assembled into the electronic device.

[0073] Another aspect of the present application also provides a computer program product or a computer program, which includes a computer instruction stored in a computer-readable storage medium. A processor of a computer device reads the computer instruction from the computer-readable storage medium, and the processor executes the computer instruction, so that the computer device executes the data transmission method based on the Ethernet channel provided in each of the above embodiments.

[0074] The above embodiments are merely illustrative of the principles and effects of the present application, and are not intended to limit the present application. Anyone familiar with the technology may modify or change the above embodiments without violating the spirit and scope of the present application. Therefore, all equivalent modifications or changes made by a person of ordinary skill in the art without departing from the spirit and technical ideas disclosed in the present application shall still be covered by the claims of the present application.

Claims

1. A data transmission method based on Ethernet channel, characterized in that: The method comprises: Get the data message to be sent; Establish an Ethernet connection channel between the sender and the receiver; The data packets to be sent are stored based on a preset data structure, and the sending and receiving status of each data packet is recorded to obtain the current data packet position; Monitoring the communication status of the Ethernet connection channel, and if the communication status is abnormal, reconnecting the Ethernet connection channel until it is restored; A target data message is determined based on the current data message position, and the target data message is sent to the receiving end, wherein the target data message is used to represent a data message to be sent with data sending interrupted.

2. The data transmission method based on Ethernet channel according to claim 1, characterized in that: Establishing an Ethernet connection channel between the sender and the receiver, including: Query the initial channel status of the transport layer and link layer respectively; If the initial channel state of the link layer is abnormal, resetting the physical layer component to initialize the physical layer component, and re-driving the physical layer component until the initial channel state of the link layer returns to normal; If the initial channel state of the transport layer is abnormal, the Ethernet connection port is switched and the Ethernet connection channel is reestablished until the initial channel state of the transport layer returns to normal.

3. The data transmission method based on Ethernet channel according to claim 1, characterized in that: The data message to be sent is stored based on a preset data structure, including: Storing the data message to be sent in a preset cache space, and determining the data message in the current cache and the preset cache space as the current data message; If the status of the current data message is that the transmission is completed, the current data message is cleared from the preset cache space, and a new data message is received and cached in the preset cache space.

4. The data transmission method based on Ethernet channel according to claim 1, characterized in that: Monitoring the communication status of the Ethernet connection channel includes: Query the current channel status of the transport layer and link layer respectively; If the current channel state of the link layer is abnormal, resetting the physical layer component to initialize the physical layer component, and re-driving the physical layer component until the current channel state of the link layer returns to normal; If the current channel state of the transport layer is abnormal, the Ethernet connection port is switched and the Ethernet connection channel is reestablished. If the target port after switching is occupied, a new port is switched again until the current channel state of the transport layer returns to normal.

5. The data transmission method based on Ethernet channel according to any one of claims 1 to 4, characterized in that: The sending end is a remote vehicle management system, and the receiving end is at least one of a vehicle electronic control system and a cloud network architecture.

6. A data transmission system based on Ethernet channel, characterized in that: The system comprises: The Ethernet channel control module is used to establish an Ethernet connection channel between the transmitter and the receiver, and to monitor the link layer channel status; A data transmission and reception buffer module, used for storing data messages to be sent based on a preset data structure; A data transceiver calculation module, used for recording the sending and receiving status of each data message to obtain the current data message position, and synchronizing the current data message position to the data transceiver buffer module; An Ethernet monitoring module, used to monitor the communication status of the Ethernet connection channel; The data transceiver control module is used to determine a target data message based on the current data message position and send the target data message to the receiving end, wherein the target data message is used to represent a data message to be sent with data transmission interrupted.

7. The data transmission system based on Ethernet channel according to claim 6, characterized in that: The Ethernet monitoring module comprises: The Ethernet transport layer monitoring module is used to monitor the communication status of the Ethernet connection channel of the transport layer; The Ethernet link layer monitoring module is used to monitor the communication status of the Ethernet connection channel of the link layer.

8. The data transmission system based on Ethernet channel according to any one of claims 6 to 7, characterized in that: When the Ethernet monitoring module detects that the communication status of any Ethernet connection channel is abnormal, the obtained abnormal information is sent to the Ethernet channel control module to reconnect the Ethernet connection channel until it is restored.

9. An electronic device, characterized in that: It comprises a processor, a memory and a communication bus; the communication bus is used to connect the processor and the memory; the processor is used to execute a computer program stored in the memory to implement the data transmission method based on the Ethernet channel as described in any one of claims 1 to 5.

10. A computer-readable storage medium, characterized in that: A computer program is stored thereon, and the computer program is used to enable a computer to execute the data transmission method based on the Ethernet channel as described in any one of claims 1-5.

Citation Information

Cited By

  • Vehicle diagnosis method and device, electronic equipment and storage medium

    CN121028746A

  • Vehicle diagnosis method and device, electronic equipment and storage medium

    CN121028746B