Redundancy control method, system and equipment for key functions of controller and medium
By using the CAN physical link in the vehicle network to transmit service data, the problem of communication interruption caused by hardware link failure in low-cost vehicles is solved, achieving redundant control and communication reliability of key functions, and improving the stability of the driving experience.
Patent Information
- Application Number
- CN202511071288.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-31
- Publication Date
- 2025-11-04
AI Technical Summary
Existing technologies suffer from communication interruptions in vehicular networks due to hardware link failures, especially in low-cost vehicles that do not employ a ring network strategy. These interruptions negatively impact user experience and reduce software flexibility.
Redundancy control is achieved by determining the Ethernet link communication status at the transmitting end controller, identifying the service type based on the service data label, using the CAN physical link to transmit service data in case of communication failure, and performing corresponding parsing and execution actions at the receiving end controller.
It achieves redundancy of key functions in the event of Ethernet communication link failure, ensuring communication reliability and driving experience stability, while avoiding high hardware costs and frequent software modifications, thus improving system flexibility.
Smart Images

Figure CN120896679A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application relates to the technical field of automobile network control, in particular to a redundancy control method, system and device for controller key functions and a medium. BACKGROUND
[0002] For the communication interruption problem caused by hardware link failure in the vehicle network, the traditional solution usually adopts ring network strategy for redundancy design (i.e. transmitting key data through two paths at the same time). The specific scheme is that the left area controller, the right area controller and the experience computer all communicate through Switch, and form a ring network. When a certain link is interrupted, it will quickly switch to the preset communication direction to ensure the integrity of the data. The disadvantage of this scheme is that it requires high hardware cost and software module cooperation. Therefore, low-end vehicles generally adopt another network topology, which cancels the Switch on the two area controllers and communicates with the experience computer through the Phy chip. The left and right area controllers cannot be directly connected and need to rely on the Switch on the experience computer to complete data interaction. When any link fails, the left and right communication will be interrupted, directly affecting the function experience.
[0003] At the same time, the ring network strategy needs to be designed redundantly on the CAN bus, but the current development based on service requires frequent changes of the protocol, modification of the application and signal interaction of the underlying software. The development will change frequently with the demand, which is not flexible. SUMMARY
[0004] Therefore, the application provides a redundancy control method, system, device and medium for controller key functions, aiming to solve or partially solve the problems in the background art.
[0005] The first aspect of the application provides a redundancy control method for controller key functions, which comprises:
[0006] When the sending end controller sends service data, the communication state of the Ethernet link is determined;
[0007] In the case of communication anomaly, the service type of the service data is determined according to the label of the service data, which is set in advance when the tool chain is deployed;
[0008] In the case of target service, the CAN communication sending function is called to transmit the service data to the receiving end controller through the CAN physical link;
[0009] According to the received service data, the corresponding actuator is controlled to perform the corresponding action by the receiving end controller.
[0010] Optionally, in the case of the service type being a target service, a CAN communication sending function is called to transmit the service data to a receiving end controller through a CAN physical link, including:
[0011] In the case of the service type being a target service, the service data is stored in a corresponding cache area according to the calling type of the service data.
[0012] The CAN communication sending function is called to read the service data from the corresponding cache area and transmit it to the receiving end controller through a CAN physical link.
[0013] Optionally, according to the received service data, the corresponding actuator is controlled to perform a corresponding action through the receiving end controller, including:
[0014] According to the received service data, a target parsing rule corresponding to the service data is determined.
[0015] The service data is parsed through the target parsing rule to obtain a corresponding parsing result.
[0016] According to the parsing result, the corresponding actuator is controlled to perform a corresponding action through the receiving end controller.
[0017] Optionally, the service data is stored in a corresponding cache area according to the calling type of the service data, including:
[0018] In the case of the calling type of the service data being an RPC call, the service data is stored in a single-frame cache area.
[0019] In the case of the calling type of the service data being an NTF notification, the service data is stored in a multi-frame cache area.
[0020] Optionally, in the case of the calling type of the service data being an NTF notification, the service data is stored in a multi-frame cache area, including:
[0021] In the case of the calling type of the service data being an NTF notification, the service data is data-split through a preset transmission strategy to generate corresponding first frame data, flow control frame data, and continuous frame data. The first frame data records the total number of data frames, the flow control frame data records the sending speed and frame interval, and the continuous frame data records the data segments of the service data.
[0022] The generated first frame data, flow control frame data, and continuous frame data are sequentially stored in a multi-frame cache area.
[0023] Optionally, in the case of the cache area for storing the service data being a multi-frame cache area, the receiving end controller receiving the service data comprises:
[0024] determining the total number of data frames of the service data according to the first frame data of the received service data;
[0025] determining the sending speed and frame interval of the continuous frame data of the service data according to the flow control frame data of the received service data;
[0026] determining the corresponding receiving strategy according to the sending speed and frame interval;
[0027] receiving and splicing the continuous frame data of the service data according to the receiving strategy and the total number of data frames to obtain the original service data.
[0028] Optionally, the method further comprises:
[0029] in the case of the service type being a target service, embedding a target CAN ID in the service data;
[0030] the parsing of the service data through the target parsing rule to obtain the corresponding parsing result comprises:
[0031] determining the target parsing rule corresponding to the target CAN ID in the service data according to the target CAN ID;
[0032] parsing the service data through the target parsing rule to obtain the corresponding parsing result.
[0033] The second aspect of the application provides a redundant control system of a controller key function, the system comprising:
[0034] a communication state determination module for determining the communication state of an Ethernet link when a sending end controller sends service data;
[0035] a service type determination module for determining the service type of the service data according to the label of the service data in the case of communication abnormality, the label of the service data being set in advance when a tool chain is deployed;
[0036] a service data sending module for calling a CAN communication sending function to transmit the service data to a receiving end controller through a CAN physical link in the case of the service type being a target service;
[0037] a control module for controlling a corresponding actuator to perform a corresponding action through the receiving end controller according to the received service data.
[0038] The third aspect of the present application provides an electronic device, comprising a processor, a memory, and a computer program stored on the memory and running on the processor, wherein the computer program, when executed by the processor, implements the steps in the redundancy control method of a controller key function according to the first aspect of the present application.
[0039] The fourth aspect of the present application provides a computer readable storage medium, wherein the computer readable storage medium stores a computer program, and the computer program, when executed by a processor, implements the steps in the redundancy control method of a controller key function according to the first aspect of the present application.
[0040] The redundancy control method of a controller key function provided by the present application has the following advantages:
[0041] The redundancy control method of a controller key function provided by the present application is as follows: when a sending end controller sends service data, the communication state of an Ethernet link is determined; in the case of communication abnormality, the service type of the service data is determined according to the label of the service data, which is set in advance when a tool chain is deployed; in the case of the service type being a target service, a CAN communication sending function is called to transmit the service data to a receiving end controller through a CAN physical link; and the corresponding actuator is controlled to perform a corresponding action through the receiving end controller according to the received service data. The redundancy control method of a controller key function provided by the present application is mainly applied to a vehicle which is currently low in cost, has an Ethernet link and a CAN link, can be used for service communication architecture, but does not use a ring network strategy due to cost considerations.
[0042] The core of the redundancy control method of a controller key function provided by the present application is to realize the robustness of communication through the existing design of the Ethernet and CAN hardware channels of the vehicle and the cooperation of the software strategy, so that the upper layer key application is not affected even when the Ethernet communication link channel fails, the reliability of the key communication data link is achieved, and the driving experience is improved. The redundancy control method of a controller key function provided by the present application realizes the redundancy of the key function at zero cost increase (i.e., when the Ethernet is abnormal, the service data originally transmitted by the Ethernet is transmitted to the receiving end controller without change through the CAN physical link), realizes communication redundancy while controlling the cost, and solves the problem of frequent code modification due to demand changes. BRIEF DESCRIPTION OF DRAWINGS
[0043] To more clearly illustrate the technical solutions of the embodiments of this application, the drawings used in the description of the embodiments of this application will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0044] Figure 1 A flowchart illustrating a redundancy control method for a key function of a controller, as shown in one embodiment of this application;
[0045] Figure 2 This is another flowchart illustrating a redundant control method for a key function of a controller, as shown in one embodiment of this application;
[0046] Figure 3 This is a schematic diagram illustrating a redundant control system for a controller's key functions, as shown in one embodiment of this application. Detailed Implementation
[0047] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this application. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0048] refer to Figure 1 , Figure 1 This is a flowchart illustrating a redundancy control method for a key function of a controller, as shown in one embodiment of this application. Figure 1 As shown, the method includes:
[0049] Step S1: When the sending controller sends service data, determine the communication status of the Ethernet link.
[0050] In this embodiment, when the sending controller needs to perform a corresponding functional service, it sends the corresponding service data to the corresponding receiving controller via Ethernet communication. When the sending controller sends the service data, it reads the communication status of the Ethernet link through its underlying layer.
[0051] Step S2: In the event of a communication failure, determine the service type of the service data based on the tag of the service data. The tag of the service data will be set in advance during toolchain deployment.
[0052] In this embodiment, all vehicle function and control communication services are pre-deployed on the toolchain webpage. Due to the limitations of CAN communication, this application only uses this method for redundant communication for particularly important communication services. Therefore, service data for important communication services is tagged in advance on the toolchain webpage. After downloading the toolchain code from the toolchain webpage, the vehicle-side code layer can automatically identify whether the transmitted service data belongs to an important communication service based on this tag. When an Ethernet communication anomaly is detected at the vehicle-side code layer, the system switches to the CAN network to send the service data belonging to the important communication service to the receiving controller. Compared to the previous design method (which requires defining the CAN communication protocol for redundant communication service data, additional CAN signal transmission and reception at the lower layer, and matching the service interface with the CAN interface at the application layer, resulting in very inflexible software implementation), this method offers greater flexibility because it eliminates the need for frequent modifications to the application layer software when software requirements change.
[0053] In this embodiment, when an Ethernet communication anomaly is determined by reading the Ethernet link's communication status at the sending end controller's underlying layer, the sending end controller's code level determines the tag of the service data currently being transmitted, and determines the service type of the service data based on this tag. The service type includes target services and non-target services. Target services are important communication services requiring redundant communication, while non-target services are ordinary communication services that do not require redundant communication. If the service type of the service data is determined to be a non-target service, the transmission of the service data is terminated, and corresponding prompts are displayed to the user via a screen and / or indicator lights, and the corresponding anomaly information is recorded in the log.
[0054] Step S3: When the service type is target service, call the CAN communication transmission function to transmit the service data to the receiving controller via the CAN physical link.
[0055] In this embodiment, when the service type of the service data is determined to be the target service, the CAN communication transmission function is called at the code level of the transmitting controller. Based on the called CAN communication transmission function, the service data is transmitted to the receiving controller via the CAN physical link without modification. "Without modification" means that the original format of the service data is not changed; that is, the service data is still transmitted to the receiving controller via the CAN physical link in the data format corresponding to Ethernet (i.e., including the service hash value and data content). The service data calls its corresponding transmission function TcpIp_UdpTransmit() on the Ethernet link and the transmission function Can_Write() on the CAN network. When transmitting via Ethernet, the service data format includes the service hash value and data content, while CAN communication typically defines a CANId and then defines valid signals in the data segment. This application transmits the service data that would originally be transmitted via Ethernet communication via the CAN physical link without modification, and transmits the service hash value and service content via CAN communication without modification. This solves the problem of frequent software modifications to the application layer caused by changes in software requirements. This method achieves redundancy of key functions through software without requiring frequent software updates.
[0056] Step S4: Based on the received service data, control the corresponding actuator to perform the corresponding action through the receiving end controller.
[0057] In this embodiment, after the receiving controller receives the service data, it parses the service data using the parsing rules corresponding to Ethernet communication, and controls the corresponding actuator to perform corresponding actions based on the parsing results, such as specific control actions, monitoring actions, and information feedback actions. If the Ethernet communication is normal, the service data is directly stored in the Ethernet buffer and then transmitted via the Ethernet channel.
[0058] This application provides a redundancy control method for key controller functions. When the transmitting controller sends service data, the communication status of the Ethernet link is determined. In case of communication abnormality, the service type of the service data is determined based on its tag, which is pre-set during toolchain deployment. If the service type is a target service, a CAN communication transmission function is called to transmit the service data to the receiving controller via the CAN physical link. Based on the received service data, the receiving controller controls the corresponding actuator to perform the corresponding action. This redundancy control method for key controller functions is primarily applicable to vehicles that currently have low costs, possess both Ethernet and CAN links, and can implement a service-oriented communication architecture, but do not employ a ring network strategy for cost reasons.
[0059] The core of the redundancy control method for key controller functions in this application lies in leveraging the existing design of the vehicle's Ethernet and CAN hardware channels, and through software strategies, to achieve robust communication. Even in the event of an Ethernet communication link failure, the upper-layer critical applications will not be affected, ensuring the reliability of critical communication data links and improving the driving experience. This redundancy control method for key controller functions achieves zero-cost redundancy of key functions through purely software-based strategy design (i.e., in the event of an Ethernet failure, the CAN physical link is used to transmit the service data originally transmitted via Ethernet to the receiving controller intact). This achieves communication redundancy while controlling costs, solving the problem of frequent code modifications due to changing requirements.
[0060] In conjunction with the above embodiments, in one implementation, this application also provides a redundancy control method for key controller functions. In this redundancy control method for key controller functions, step S3 may include: when the service type is a target service, storing the service data in a corresponding buffer according to the service data call type; calling a CAN communication transmission function to read the service data from the corresponding buffer and transmitting it to the receiving controller via the CAN physical link.
[0061] In this embodiment, due to the large size of the service data transmitted via Ethernet, different buffers are used to cache service data of different call types before transmission. Specifically, a correspondence between each call type and a buffer is pre-established, with one buffer corresponding to each call type. When the service type is a target service, the buffer corresponding to the call type is determined based on the pre-established correspondence. The service data is then stored in the buffer corresponding to that call type. After storing the service data in the buffer, the CAN communication transmission function is called at the code level of the transmitting controller. Based on the called CAN communication transmission function, the service data is read from the buffer storing the service data and transmitted intact to the receiving controller via the CAN physical link.
[0062] In conjunction with the above embodiments, in one implementation, this application also provides a redundancy control method for key controller functions. In this redundancy control method for key controller functions, step S4 may include: determining a target parsing rule corresponding to the received service data; parsing the service data using the target parsing rule to obtain a corresponding parsing result; and controlling the corresponding actuator to perform a corresponding action through the receiving end controller based on the parsing result.
[0063] In this embodiment, when the transmitting controller uses the CAN physical link to transmit service data, the service data is still transmitted in Ethernet communication format. Therefore, when the receiving controller receives this service data via the CAN physical link, it cannot parse it using the parsing rules corresponding to CAN communication, but must use the parsing rules corresponding to Ethernet communication. Accordingly, after receiving any service data, the receiving controller first determines the target parsing rule corresponding to the received service data. If the received service data was originally transmitted via CAN communication, the target parsing rule is the parsing rule corresponding to CAN communication; if the received service data was originally transmitted via Ethernet communication but is currently being transmitted via the CAN physical link, the target parsing rule is the parsing rule corresponding to Ethernet communication. After determining the target parsing rule corresponding to the service data, the service data is parsed using this target parsing rule to obtain the corresponding parsing result. Finally, based on the parsing result, the receiving controller controls the corresponding actuator to perform the corresponding action.
[0064] In conjunction with the above embodiments, in one implementation, this application also provides a redundancy control method for critical controller functions. In this redundancy control method for critical controller functions, storing the service data into a corresponding buffer based on the service data's call type includes: storing the service data into a single-frame buffer when the service data's call type is an RPC call; and storing the service data into a multi-frame buffer when the service data's call type is an NTF notification.
[0065] In this embodiment, as Figure 2 As shown, when the service data call type is an RPC call (Remote Procedure Call), the service data is stored in a single-frame buffer corresponding to the RPC call. However, when the service data call type is an NTF (Notification) notification, due to the large data volume of NTF, this application stores the service data in a multi-frame buffer corresponding to the NTF.
[0066] In conjunction with the above embodiments, in one implementation, this application also provides a redundancy control method for key controller functions. In this redundancy control method for key controller functions, when the service data call type is NTF notification, storing the service data in a multi-frame buffer includes: when the service data call type is NTF notification, splitting the service data according to a preset transmission strategy to generate corresponding first frame data, flow control frame data, and continuous frame data; the first frame data records the total number of data frames; the flow control frame data records the transmission speed and frame interval; the continuous frame data records data segments of the service data; and sequentially storing the generated first frame data, flow control frame data, and continuous frame data in the multi-frame buffer.
[0067] In this embodiment, for NTF notifications with large data volumes, this application pre-defines a preset transmission strategy. This strategy divides the service data into three categories: first frame data, flow control frame data, and continuous frame data. The first frame data records the total number of data frames into which the service data is divided, the flow control frame data records the data frame transmission speed and frame interval of the service data, and the continuous frame data consists of the various data segments that constitute the service data. When the service data call type is an NTF notification, the service data is split into corresponding first frame data, flow control frame data, and continuous frame data using this preset transmission strategy. Then, the generated first frame data, flow control frame data, and continuous frame data are sequentially stored in a multi-frame buffer, with the storage order being: first the first frame data, then the flow control frame data, and finally the continuous frame data. During transmission, the first frame data is first transmitted to the receiving controller, then the flow control frame data is transmitted, and finally, each continuous frame data is transmitted to the receiving controller sequentially.
[0068] In conjunction with the above embodiments, in one implementation, this application also provides a redundancy control method for key controller functions. In this redundancy control method for key controller functions, when the buffer where the service data is stored is a multi-frame buffer, the receiving end controller receives the service data, including: determining the total number of data frames of the service data based on the first frame of the received service data; determining the transmission speed and frame interval of consecutive frames of the service data based on the flow control frame data of the received service data; determining a corresponding receiving strategy based on the transmission speed and frame interval; and receiving and splicing the consecutive frames of the service data according to the receiving strategy and the total number of data frames to obtain the original service data.
[0069] In this embodiment, after receiving the first frame of service data, the receiving end controller determines the total number of data frames for the service data based on the first frame. Then, after receiving the flow control frame data of the service data, the receiving end controller determines the transmission rate and frame interval of the consecutive frames of the service data based on the flow control frame data. After determining the transmission rate and frame interval, the receiving end controller configures the decoding clock and synchronizes bit sampling based on the transmission rate (baud rate) to ensure that the received data can be correctly parsed and resources allocated; at the same time, it controls the receiving rhythm according to the frame interval to dynamically adapt the receiving capability and balance efficiency and stability. Finally, based on the determined total number of data frames, it can determine how many consecutive frames of the service data are left. After receiving all the subsequent consecutive frames of the service data, all the consecutive frames are spliced together to obtain the original service data that is the same as the service data before the initial transmission.
[0070] In conjunction with the above embodiments, in one implementation, this application also provides a redundancy control method for critical controller functions. In this redundancy control method for critical controller functions, when the service type is a target service, a target CANID is embedded in the service data; the step of parsing the service data using the target parsing rule to obtain the corresponding parsing result includes: determining a target parsing rule corresponding to the target CANID based on the target CANID in the service data; and parsing the service data using the target parsing rule to obtain the corresponding parsing result.
[0071] In this embodiment, the implementation method for determining the target parsing rule corresponding to the received service data provided by this application is as follows: When the service type is a target service, the transmitting controller embeds a target CANID in the service data before transmitting it. This target CANID is used to mark that the service data needs to be parsed using the parsing rule corresponding to Ethernet communication. After receiving the service data, the receiving controller first parses the service data using the parsing rule corresponding to CAN communication to determine the target CANID of the service data. Based on this CANID, the receiving controller can determine that the service data is transmitted in the format of Ethernet communication, that is, according to the target CANID in the service data, it determines that the target parsing rule corresponding to the target CANID is the parsing rule corresponding to Ethernet communication. Accordingly, the receiving controller parses the service data based on the parsing rule corresponding to Ethernet communication to obtain the corresponding parsing result for subsequent control actions.
[0072] Based on the same inventive concept, one embodiment of this application provides a redundant control system for key controller functions, such as... Figure 3As shown, the redundant control system 300 for the key functions of the controller includes:
[0073] The communication status determination module 301 is used to determine the communication status of the Ethernet link when the sending controller sends service data;
[0074] The service type determination module 302 is used to determine the service type of the service data based on the tag of the service data in the event of a communication anomaly. The tag of the service data will be set in advance during toolchain deployment.
[0075] The service data transmission module 303 is used to call the CAN communication transmission function when the service type is target service, and transmit the service data to the receiving end controller through the CAN physical link;
[0076] The control module 304 is used to control the corresponding actuator to perform the corresponding action through the receiving end controller based on the received service data.
[0077] Optionally, the service data sending module 303 includes:
[0078] The caching module is used to store the service data into the corresponding cache area according to the call type of the service data when the service type is the target service.
[0079] The service data transmission submodule is used to call the CAN communication transmission function to read the service data from the corresponding buffer and transmit it to the receiving controller via the CAN physical link.
[0080] Optionally, control module 304 includes:
[0081] The target parsing rule determination module is used to determine the target parsing rule corresponding to the received service data based on the service data.
[0082] The parsing module is used to parse the service data according to the target parsing rules and obtain the corresponding parsing results;
[0083] The control submodule is used to control the corresponding actuator to perform the corresponding action through the receiver controller based on the parsing result.
[0084] Optional caching modules include:
[0085] The first caching module is used to store the service data into a single-frame buffer when the service data call type is an RPC call.
[0086] The second caching module is used to store the service data into a multi-frame buffer when the service data call type is NTF notification.
[0087] Optional, the second cache module includes:
[0088] The data splitting module is used to split the service data according to a preset transmission strategy when the service data call type is NTF notification, and generate corresponding first frame data, flow control frame data and continuous frame data. The first frame data records the total number of data frames, the flow control frame data records the sending speed and frame interval, and the continuous frame data records the data segments of the service data.
[0089] The second caching submodule is used to sequentially store the generated first frame data, the flow control frame data, and the continuous frame data into a multi-frame buffer.
[0090] Optionally, the redundant control system 300 for the key functions of the controller also includes a service data receiving module, which is used to receive the service data when the buffer where the service data is stored is a multi-frame buffer.
[0091] The service data receiving module includes:
[0092] The data frame total number determination module is used to determine the total number of data frames of the service data based on the first frame of the received service data.
[0093] The transmission parameter determination module is used to determine the transmission speed and frame interval of the continuous frame data for transmitting the service data based on the received flow control frame data of the service data.
[0094] The receiving strategy determination module is used to determine the corresponding receiving strategy based on the transmission speed and frame interval;
[0095] The service data receiving submodule is used to receive and splice consecutive frames of the service data according to the receiving strategy and the total number of data frames to obtain the original service data.
[0096] Optionally, the redundant control system 300 for the controller's critical functions also includes
[0097] The data embedding module is used to embed a target CANID into the service data when the service type is a target service;
[0098] The parsing module includes:
[0099] The target parsing rule determination module is used to determine the target parsing rule corresponding to the target CANID based on the target CANID in the service data;
[0100] The parsing submodule is used to parse the service data according to the target parsing rules and obtain the corresponding parsing results.
[0101] Based on the same inventive concept, one embodiment of this application provides an electronic device, including: a processor, a memory, and a computer program stored in the memory and running on the processor. When the computer program is executed by the processor, it implements the steps in the redundant control method for a controller key function as described in the first aspect of this application.
[0102] Based on the same inventive concept, one embodiment of this application provides a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the steps in a redundant control method for a controller's key functions as described in the first aspect of this application.
[0103] As the system implementation is basically similar to the method implementation, it is described in a relatively simple way. For relevant details, please refer to the description of the method implementation.
[0104] It should be noted that, for the sake of simplicity, the method embodiments are all described as a series of actions. However, those skilled in the art should understand that the embodiments of this application are not limited to the described order of actions, because according to the embodiments of this application, some steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also understand that the embodiments described in the specification are all preferred embodiments, and the actions involved are not necessarily necessary for the embodiments of this application.
[0105] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on the differences from other embodiments. The same or similar parts between the various embodiments can be referred to each other.
[0106] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, embodiments of this application can take the form of entirely hardware embodiments, entirely software embodiments, or embodiments combining software and hardware aspects. Furthermore, embodiments of this application can take the form of computer program products implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0107] This application describes embodiments with reference to flowchart illustrations and / or block diagrams of methods, terminal devices (systems), and computer program products according to embodiments of this application. It should be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing terminal device to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing terminal device, generate instructions for implementing the flowchart illustrations. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0108] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing terminal device to operate in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0109] These computer program instructions can also be loaded onto a computer or other programmable data processing terminal equipment, causing a series of operational steps to be performed on the computer or other programmable terminal equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable terminal equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0110] Although preferred embodiments of the present application have been described, those skilled in the art, upon learning the basic inventive concept, can make other changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments as well as all changes and modifications falling within the scope of the embodiments of the present application.
[0111] Finally, it should be noted that in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or terminal device that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or terminal device. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or terminal device that includes said element.
[0112] The above provides a detailed description of a redundant control method, system, device, and medium for key functions of a controller provided in this application. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the above embodiments are only for the purpose of helping to understand the method and core ideas of this application. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this application. Therefore, the content of this specification should not be construed as a limitation of this application.
Claims
1. A redundancy control method for key functions of a controller, characterized in that, The method includes: When the sending controller sends service data, it determines the communication status of the Ethernet link; In the event of a communication failure, the service type of the service data is determined based on the tag of the service data, and the tag of the service data will be set in advance during toolchain deployment; When the service type is target service, the CAN communication transmission function is called to transmit the service data to the receiving controller via the CAN physical link; Based on the received service data, the receiving end controller controls the corresponding actuator to perform the corresponding action.
2. The redundancy control method for key functions of a controller according to claim 1, characterized in that, When the service type is target service, the CAN communication transmission function is invoked to transmit the service data to the receiving controller via the CAN physical link, including: When the service type is the target service, the service data is stored in the corresponding cache area according to the call type of the service data; The CAN communication transmission function is invoked to read the service data from the corresponding buffer and transmit it to the receiving controller via the CAN physical link.
3. The redundancy control method for key functions of a controller according to claim 1, characterized in that, Based on the received service data, the receiving end controller controls the corresponding actuator to perform corresponding actions, including: Based on the received service data, determine the target parsing rule corresponding to the service data; The service data is parsed using the target parsing rules to obtain the corresponding parsing results; Based on the analysis results, the corresponding actuator is controlled by the receiving end controller to perform the corresponding action.
4. The redundancy control method for key functions of a controller according to claim 2, characterized in that, Based on the service data call type, the service data is stored in the corresponding cache area, including: If the service data is called via RPC, the service data is stored in a single-frame buffer. When the service data call type is NTF notification, the service data is stored in a multi-frame buffer.
5. A redundancy control method for key functions of a controller according to claim 4, characterized in that, When the service data call type is NTF notification, storing the service data in a multi-frame buffer includes: When the service data call type is NTF notification, the service data is split into data segments according to a preset transmission strategy to generate corresponding first frame data, flow control frame data and continuous frame data. The first frame data records the total number of data frames, the flow control frame data records the sending speed and frame interval, and the continuous frame data records data segments of the service data. The generated first frame data, flow control frame data, and consecutive frame data are sequentially stored in a multi-frame buffer.
6. The redundancy control method for key functions of a controller according to claim 5, characterized in that, When the buffer where the service data is stored is a multi-frame buffer, the receiving end controller receives the service data, including: The total number of data frames of the service data is determined based on the first frame of the received service data. Based on the received flow control frame data of the service data, determine the transmission speed and frame interval of the continuous frame data for transmitting the service data; Based on the transmission speed and frame interval, determine the corresponding reception strategy; According to the receiving strategy and the total number of data frames, the continuous frame data of the service data are received and spliced to obtain the original service data.
7. The redundancy control method for key functions of a controller according to claim 1, characterized in that, The method further includes: When the service type is target service, the target CANID is embedded in the service data; The step of parsing the service data using the target parsing rules to obtain the corresponding parsing results includes: Based on the target CANID in the service data, determine the target parsing rule corresponding to the target CANID; The service data is parsed using the target parsing rules to obtain the corresponding parsing results.
8. A redundant control system for key controller functions, characterized in that, The system includes: The communication status determination module is used to determine the communication status of the Ethernet link when the sending controller sends service data; The service type determination module is used to determine the service type of the service data based on the tag of the service data in the event of a communication anomaly. The tag of the service data will be set in advance during toolchain deployment. The service data transmission module is used to call the CAN communication transmission function when the service type is the target service, and transmit the service data to the receiving end controller through the CAN physical link; The control module is used to control the corresponding actuator to perform the corresponding action through the receiving end controller based on the received service data.
9. An electronic device, characterized in that, include: A processor, a memory, and a computer program stored in the memory and running on the processor, wherein the computer program, when executed by the processor, implements the steps of a redundant control method for a controller key function as described in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the steps of a redundant control method for a controller's key functions as described in any one of claims 1 to 7.
Citation Information
Cited By
Data communication method and system for a vehicle
CN122437895A
