Control method, system, device, processor and storage medium for real-time switching of CAN communication protocol based on vehicle body controller

By switching CAN communication protocol in real time in the body controller, using the logical processing of calibration values ​​and hard-wire switch status, the problem of insufficient spare parts during vehicle assembly is solved, and the simplicity, convenience and high reliability of multi-model adaptation is achieved, ensuring that The normal operation of the vehicle.

CN115145244BActive Publication Date: 2024-11-01DONGFENG ELECTRONICS TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210716804.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-06-23
Publication Date
2024-11-01
Estimated Expiration
2042-06-23

AI Technical Summary

Technical Problem

During the car assembly and testing process, due to insufficient spare parts of the body controller or not arriving in time, the vehicle cannot be used normally. The existing solutions need to wait for professional and technical personnel to re-bury the software to adapt to the CAN communication protocol, and the timeliness is not high.

Method used

By realizing the function of switching CAN communication protocols in the body controller, the logic processing is performed using calibration values, adaptive setting values ​​and hard-wire switch status, allowing the direct replacement and installation of body controllers of different models, and data verification through encryption algorithms By writing calibration values, the protocol switching is achieved without the need to update the software program.

Benefits of technology

It realizes multi-model adaptation with simple and convenient operation, good compatibility and high stability. It has been used in 6 mass-produced models, with 20,444 units without faults, proving the reliability and stability of switching.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115145244B_ABST
    Figure CN115145244B_ABST
Patent Text Reader

Abstract

The present invention relates to a control method for implementing a real-time switching function of a CAN communication protocol based on a vehicle body controller, comprising the following steps: if an internal calibration value has been calibrated, the calibration value is used to initialize the corresponding CAN communication protocol; if an adaptive setting exists, the hard-line switch state is read, and if the adaptive setting value matches the hard-line switch state, the adaptive setting value is used to initialize the CAN communication protocol. The present invention also relates to a system, device, processor and storage medium for implementing a real-time switching function of a CAN communication protocol based on a vehicle body controller. The control method, system, device, processor and storage medium for implementing a real-time switching function of a CAN communication protocol based on a vehicle body controller of the present invention have good compatibility and can be adapted to a variety of vehicle models. The stability is good and the reliability is high. The switching operation is simple and convenient, and there is no need to update the software program. The CAN communication protocol can be switched in real time to adapt to the corresponding vehicle model, and the compatibility is good, and the switching operation is simple and convenient.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the automotive field, in particular to the automotive electronic control technology field, and specifically refers to a control method, system, device, processor and storage medium thereof for realizing real-time switching of CAN communication protocol functions based on a vehicle body controller. Background Art

[0002] At present, most models in the vehicle market are equipped with body controller modules. One model corresponds to one body controller module. Therefore, the body controllers of different models are not universal. However, through the comparison of body controller requirements and functions, it is found that the function definitions of different models of the same company are basically the same. Sometimes only the CAN communication protocol is different, including baud rate, ID, specific signal distribution, etc. In the test field or automobile assembly position, when the body controller of a car needs to be installed or replaced, the body controller of the corresponding model must be found. However, due to insufficient spare parts or delayed arrival, the car can only be left in place, affecting the progress of road tests, vehicle display delivery, etc., and the timeliness of solving the problem is not high. In view of this situation, the current existing solution is to wait for professional technicians to re-burn the software program corresponding to the model based on the body controller hardware of other models, so as to adapt all the functions of this car, including the CAN communication protocol. After using this technical solution, since the CAN communication protocol can control the switch, the spare parts of other models or the body controller of other models can be directly removed and installed on the vehicle to be replaced, and the CAN communication protocol of the corresponding model can be switched to solve this problem. Summary of the invention

[0003] The purpose of the present invention is to overcome the shortcomings of the above-mentioned prior art and provide a control method, system, device, processor and storage medium based on a vehicle body controller that can realize real-time switching of CAN communication protocol functions, which are simple to operate, fast and convenient, and have a wide range of applications.

[0004] In order to achieve the above-mentioned purpose, the control method, system, device, processor and storage medium thereof for realizing real-time switching of CAN communication protocol function based on vehicle body controller of the present invention are as follows:

[0005] The control method for implementing real-time switching of CAN communication protocol function based on vehicle body controller is mainly characterized in that the method comprises the following steps:

[0006] (1) Read the internal calibration value and determine whether it has been calibrated. If so, use the calibration value to initialize the corresponding CAN communication protocol and exit the step; otherwise, continue to step (2);

[0007] (2) Read the adaptive setting value and determine whether the adaptive setting exists. If yes, proceed to step (3); otherwise, exit the step;

[0008] (3) Read the hard-wire switch state and determine whether the adaptive setting value matches the hard-wire switch state. If so, proceed to step (4); otherwise, exit the step;

[0009] (4) Initialize the CAN communication protocol using the adaptive setting value, clear the adaptive setting value, and exit the step.

[0010] Preferably, the method further comprises a step of periodic task execution, specifically comprising the following processing:

[0011] (5) Determine whether the CAN communication protocol has been initialized. If so, exit the step; otherwise, proceed to step (6);

[0012] (6) Read the internal calibration value to determine whether it has been calibrated. If so, use the calibration value to initialize the corresponding CAN communication protocol and exit the step; otherwise, continue to step (7);

[0013] (7) Read the hard-wire switch status;

[0014] (8) Monitor whether the ignition lock signal is switched from OFF to ON. If so, proceed to step (9); otherwise, proceed to step (7);

[0015] (9) Initialize the CAN communication protocol using the hard-wire switch status and exit the step.

[0016] Preferably, the method further comprises the step of writing the adaptive setting, which specifically comprises the following steps:

[0017] (1-1) The body controller is powered off during sleep mode;

[0018] (1-2) Register the adaptive settings.

[0019] Preferably, the method further comprises the step of writing a calibration value, specifically:

[0020] The data of the body controller is verified by an encryption algorithm. If successful, the calibration value is written; otherwise, the calibration value is not written.

[0021] The main feature of the system for implementing the real-time switching of the CAN communication protocol function is that the system comprises:

[0022] The calibration value module is used to read the internal calibration value and use the calibration value to initialize the corresponding CAN communication protocol;

[0023] An adaptive setting module, connected to the calibration value module, for reading the adaptive setting value;

[0024] The hard-wire switch status module is connected to the adaptive setting module and the calibration value module, and is used to read the hard-wire switch status, monitor the ignition lock signal, and use the hard-wire switch status to initialize the CAN communication protocol.

[0025] Preferably, the calibration value module comprises:

[0026] A calibration value judgment unit, used for reading an internal calibration value and judging whether the internal calibration value has been calibrated;

[0027] The calibration value initialization unit is connected to the calibration value judgment unit and is used to initialize the corresponding CAN communication protocol using the calibration value when the internal calibration value has been calibrated.

[0028] Preferably, the adaptive setting module includes:

[0029] An adaptive setting judgment unit, connected to the calibration value module, for reading the adaptive setting value and judging whether the adaptive setting value exists;

[0030] A matching judgment unit, connected to the adaptive setting judgment unit and the hard-line switch state module, for judging whether the adaptive setting value matches the hard-line switch state;

[0031] The adaptive setting initialization unit is connected to the matching judgment unit and is used to initialize the CAN communication protocol using the adaptive setting when the adaptive setting value matches the hard-line switch state.

[0032] Preferably, the hard-line switch status module comprises:

[0033] A hard-wire switch state reading unit, connected to the adaptive setting module and the calibration value module, for reading the hard-wire switch state;

[0034] An ignition lock signal monitoring unit, connected to the hard-wire switch state reading unit, for monitoring whether the ignition lock signal is switched from the OFF position to the ON position;

[0035] The hard-wire switch state initialization unit is connected to the ignition lock signal monitoring unit and is used to initialize the CAN communication protocol using the hard-wire switch state when the ignition lock signal is switched to the ON position.

[0036] Preferably, the adaptive setting module further comprises an adaptive setting writing unit connected to the adaptive setting judging unit, and used for powering down the vehicle body controller to sleep and registering the adaptive setting.

[0037] The main feature of the device for realizing the real-time switching of the CAN communication protocol function is that the device comprises:

[0038] a processor configured to execute computer-executable instructions;

[0039] The memory stores one or more computer executable instructions. When the computer executable instructions are executed by the processor, the various steps of the method for implementing the real-time switching of the CAN communication protocol function are implemented.

[0040] The main feature of the processor for realizing the real-time switching of the CAN communication protocol function is that the processor is configured to execute computer executable instructions, and when the computer executable instructions are executed by the processor, the various steps of the above-mentioned method for realizing the real-time switching of the CAN communication protocol function are implemented.

[0041] The main feature of the computer-readable storage medium is that a computer program is stored thereon, and the computer program can be executed by a processor to implement the various steps of the above-mentioned method for realizing the real-time switching of the CAN communication protocol function.

[0042] The control method, system, device, processor and storage medium thereof for realizing the real-time switching function of the CAN communication protocol based on the body controller of the present invention have good compatibility and can be adapted to a variety of vehicle models. Good stability and high reliability. The current CAN communication protocol switching function has been applied to 6 mass-produced vehicle models. As of March 2022, 20,444 units have been supplied, and no faulty parts involving the switching disorder of the CAN communication protocol have been received. This proves that the CAN communication protocol will not change arbitrarily and is stable and reliable. The switching operation is simple and convenient. Due to the use of the real-time switching function of the CAN communication protocol, there is no need to wait for professional technicians to arrive. Someone only needs to install the body controller directly on the vehicle, turn the hard-wire switch to the corresponding CAN communication protocol, and then turn the ignition lock. This technical solution is a solution for using the same body controller that needs to be adapted and installed on different vehicles or models. There is no need to update the software program. The CAN communication protocol can be switched in real time to adapt to the corresponding vehicle model. It has good compatibility and the switching operation is simple and convenient. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] Figure 1 The present invention is a schematic diagram of the judgment process of the vehicle body controller power-on initialization execution of the control method for implementing the real-time switching of the CAN communication protocol function based on the vehicle body controller.

[0044] Figure 2 The present invention is a schematic diagram of a judgment flow chart executed by a vehicle body controller in a periodic task in a control method for implementing a real-time switching CAN communication protocol function based on a vehicle body controller.

[0045] Figure 3 The present invention is a flow chart of a control method for implementing a real-time switching CAN communication protocol function based on a vehicle body controller, which is executed when the vehicle body controller is in sleep mode and powered off. DETAILED DESCRIPTION

[0046] In order to more clearly describe the technical content of the present invention, further description is given below in conjunction with specific embodiments.

[0047] The control method of the present invention for implementing real-time switching of CAN communication protocol function based on the vehicle body controller comprises the following steps:

[0048] (1) Read the internal calibration value and determine whether it has been calibrated. If so, use the calibration value to initialize the corresponding CAN communication protocol and exit the step; otherwise, continue to step (2);

[0049] (2) Read the adaptive setting value and determine whether the adaptive setting exists. If yes, proceed to step (3); otherwise, exit the step;

[0050] (3) Read the hard-wire switch state and determine whether the adaptive setting value matches the hard-wire switch state. If so, proceed to step (4); otherwise, exit the step;

[0051] (4) Initialize the CAN communication protocol using the adaptive setting value, clear the adaptive setting value, and exit the step;

[0052] As a preferred embodiment of the present invention, the method further includes a step of periodic task execution, specifically including the following processing:

[0053] (5) Determine whether the CAN communication protocol has been initialized. If so, exit the step; otherwise, proceed to step (6);

[0054] (6) Read the internal calibration value to determine whether it has been calibrated. If so, use the calibration value to initialize the corresponding CAN communication protocol and exit the step; otherwise, continue to step (7);

[0055] (7) Read the hard-wire switch status;

[0056] (8) Monitor whether the ignition lock signal is switched from OFF to ON. If so, proceed to step (9); otherwise, proceed to step (7);

[0057] (9) Initialize the CAN communication protocol using the hard-wire switch status and exit the step.

[0058] As a preferred embodiment of the present invention, the method further comprises the step of writing the adaptive settings, which specifically comprises the following steps:

[0059] (1-1) The body controller is powered off during sleep mode;

[0060] (1-2) Register the adaptive settings.

[0061] As a preferred embodiment of the present invention, the method further comprises the step of writing a calibration value, specifically:

[0062] The data of the body controller is verified by an encryption algorithm. If successful, the calibration value is written; otherwise, the calibration value is not written.

[0063] The main feature of the system for implementing the real-time switching of the CAN communication protocol function of the present invention is that the system comprises:

[0064] The calibration value module is used to read the internal calibration value and use the calibration value to initialize the corresponding CAN communication protocol;

[0065] An adaptive setting module, connected to the calibration value module, for reading the adaptive setting value;

[0066] The hard-wire switch status module is connected to the adaptive setting module and the calibration value module, and is used to read the hard-wire switch status, monitor the ignition lock signal, and use the hard-wire switch status to initialize the CAN communication protocol.

[0067] As a preferred embodiment of the present invention, the calibration value module includes:

[0068] A calibration value judgment unit, used for reading an internal calibration value and judging whether the internal calibration value has been calibrated;

[0069] The calibration value initialization unit is connected to the calibration value judgment unit and is used to initialize the corresponding CAN communication protocol using the calibration value when the internal calibration value has been calibrated.

[0070] As a preferred embodiment of the present invention, the adaptive setting module includes:

[0071] An adaptive setting judgment unit, connected to the calibration value module, for reading the adaptive setting value and judging whether the adaptive setting value exists;

[0072] A matching judgment unit, connected to the adaptive setting judgment unit and the hard-line switch state module, for judging whether the adaptive setting value matches the hard-line switch state;

[0073] The adaptive setting initialization unit is connected to the matching judgment unit and is used to initialize the CAN communication protocol using the adaptive setting when the adaptive setting value matches the hard-line switch state.

[0074] As a preferred embodiment of the present invention, the hard-line switch state module comprises:

[0075] A hard-wire switch state reading unit, connected to the adaptive setting module and the calibration value module, for reading the hard-wire switch state;

[0076] An ignition lock signal monitoring unit, connected to the hard-wire switch state reading unit, for monitoring whether the ignition lock signal is switched from the OFF position to the ON position;

[0077] The hard-wire switch state initialization unit is connected to the ignition lock signal monitoring unit and is used to initialize the CAN communication protocol using the hard-wire switch state when the ignition lock signal is switched to the ON position.

[0078] As a preferred embodiment of the present invention, the adaptive setting module further comprises an adaptive setting writing unit connected to the adaptive setting judging unit, for powering off the vehicle body controller and registering the adaptive setting.

[0079] The main feature of the device for implementing the real-time switching of the CAN communication protocol function of the present invention is that the device comprises:

[0080] a processor configured to execute computer-executable instructions;

[0081] The memory stores one or more computer executable instructions. When the computer executable instructions are executed by the processor, the various steps of the method for implementing the real-time switching of the CAN communication protocol function are implemented.

[0082] The processor for realizing the real-time switching of the CAN communication protocol function of the present invention has the main feature that the processor is configured to execute computer executable instructions, and when the computer executable instructions are executed by the processor, the various steps of the above-mentioned method for realizing the real-time switching of the CAN communication protocol function are implemented.

[0083] The computer-readable storage medium of the present invention has the main feature that a computer program is stored thereon, and the computer program can be executed by a processor to implement the various steps of the above-mentioned method for realizing the real-time switching of the CAN communication protocol function.

[0084] In the specific implementation of the present invention, since the CAN communication protocol can be flexibly configured while taking into account the stability of the normal operation of the body controller function, it cannot be easily switched and changed, and a series of strict logical processing and judgment are required, otherwise it will cause errors in the received and sent CAN data, thereby affecting the normal operation of the body controller function, or even loss of function. For example, a mismatch in the CAN communication protocol will lead to incorrect data on vehicle speed and rotation speed, thereby affecting all functional logic related to vehicle speed and rotation speed of the body controller; it will also cause the switch or load status signal sent by the body controller to be incorrect, resulting in incorrect reception of other electronic control modules of the vehicle, thereby affecting the display errors of the instrument and other interfaces.

[0085] The purpose of the present invention is to adapt and install the same body controller on different vehicle models without updating the software program. The function definitions of different vehicle models of the same company are basically the same, and sometimes only the CAN communication protocol is different. In view of this situation, a solution is provided that can switch the CAN communication protocol in real time.

[0086] The technical solution of the present invention is: the body controller reads the internal calibration value, the adaptive setting value, and the hard-line switch state, and switches to the corresponding value after logical processing and priority judgment.

[0087] To switch the CAN communication protocol, you only need to plug in the body controller connector, turn the hard-wire switch to the corresponding CAN communication protocol, and turn the ignition lock from OFF to ON. No program update is required, and the CAN communication protocol can be switched in real time.

[0088] The control method for implementing real-time switching of CAN communication protocol function based on vehicle body controller of the present invention comprises the following steps:

[0089] 1. After the body controller is powered on, the internal calibration value is read first. If it has been calibrated, the corresponding CAN communication protocol is initialized according to the calibration value. If it has not been calibrated, the adaptive setting value is read. If not, the power-on judgment process ends; if there is an adaptive setting value, the hard-wire switch state is read next. When the hard-wire switch state and the adaptive setting value correspond to the same set of CAN communication protocols, the corresponding CAN communication protocol is initialized. Otherwise, the power-on judgment process ends (see Figure 1 ).

[0090] 2. If the CAN communication protocol is not initialized in step 1 because the adaptive setting does not exist or the adaptive setting does not match the hard-wire switch state, then in order to ensure the normal operation of other functions of the body controller, the program cannot be stuck in one link. A periodic task is required to determine which CAN communication protocol to execute. The periodic task includes first reading the calibration value. If it has been calibrated, the corresponding CAN communication protocol is initialized according to the calibration value. If it has not been calibrated, the hard-wire switch state is read and the ignition lock signal is monitored to switch from OFF to ON. If it is detected, the CAN communication protocol corresponding to the hard-wire switch is executed (see Figure 2 ).

[0091] The adaptive setting value needs to be written when the body controller is powered off (see Figure 3 ).

[0092] The calibration value can be written at any time when the program is running, but in order to increase security, it can only be written after the encryption algorithm is successfully verified. The host computer communicates with the body control module, and the host computer sends instructions to the body control module. The body control module encrypts the instructions with the locally stored key and returns the encrypted result to the host computer. The host computer uses its own key to process the sent instructions, calculates the encryption result, and compares the encryption result sent by the body control module with the encryption result calculated by itself. If they are consistent, the encryption algorithm verification is successful and the calibration value is written.

[0093] The operating method of real-time switching of CAN communication protocol of the present invention comprises the following steps:

[0094] 1. Plug in the connector of the body controller and turn the hard-wire switch to the corresponding CAN communication protocol.

[0095] 2. Turn the ignition lock from OFF to ON.

[0096] After the corresponding CAN communication protocol is successfully executed, if you want to calibrate, you can write the calibration value through the calibration process. If you do not want to calibrate, the safe and reliable operation of the CAN communication protocol can be ensured through adaptive setting values ​​and hard-wire switches.

[0097] The present invention is further described in detail with reference to the following examples.

[0098] Example 1:

[0099] In many scenarios such as test tracks and 4S stores, the body controller of a vehicle needs to be replaced or assembled. In the case of emergency and no spare parts for the same model, if the body controller has the function of switching the CAN communication protocol in real time, this problem can be solved. You only need to switch the CAN communication protocol:

[0100] 1. Plug in the connector of the body controller and turn the hard-wire switch to the corresponding CAN communication protocol.

[0101] 2. Turn the ignition lock from OFF to ON.

[0102] If the body controllers are equipped with the function of switching CAN communication protocols in real time, the types of body controller spare parts in test tracks and 4S stores can be reduced, thus preventing the risk of service personnel taking the wrong body controller.

[0103] Example 2:

[0104] On the factory production line, the product will undergo a program burning process. After adding the control method in this article, there is no need to switch to different burning programs on the production line. The same program can be burned in, reducing the risk of selecting the wrong program, speeding up the production line, and shortening the process time. In the future, only the corresponding vehicle model needs to switch to the corresponding CAN communication protocol to complete the product delivery.

[0105] The specific implementation scheme of this embodiment can refer to the relevant description in the above embodiment, which will not be repeated here.

[0106] It can be understood that the same or similar parts of the above embodiments can be referenced to each other, and the contents not described in detail in some embodiments can refer to the same or similar contents in other embodiments.

[0107] It should be noted that, in the description of the present invention, the terms "first", "second", etc. are only used for descriptive purposes and cannot be understood as indicating or implying relative importance. In addition, in the description of the present invention, unless otherwise specified, the meaning of "plurality" refers to at least two.

[0108] Any process or method description in a flowchart or otherwise described herein may be understood to represent a module, segment or portion of code that includes one or more executable instructions for implementing the steps of a specific logical function or process, and the scope of the preferred embodiments of the present invention includes alternative implementations in which functions may not be performed in the order shown or discussed, including performing functions in a substantially simultaneous manner or in the reverse order depending on the functions involved, which should be understood by those skilled in the art to which the embodiments of the present invention belong.

[0109] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, a plurality of steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution device. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.

[0110] A person skilled in the art may understand that all or part of the steps in the method for implementing the above-mentioned embodiment may be completed by instructing related hardware through a program, and the corresponding program may be stored in a computer-readable storage medium, which, when executed, includes one of the steps of the method embodiment or a combination thereof.

[0111] In addition, each functional unit in each embodiment of the present invention may be integrated into a processing module, or each unit may exist physically separately, or two or more units may be integrated into one module. The above-mentioned integrated module may be implemented in the form of hardware or in the form of a software functional module. If the integrated module is implemented in the form of a software functional module and sold or used as an independent product, it may also be stored in a computer-readable storage medium.

[0112] The storage medium mentioned above can be a read-only memory, a magnetic disk or an optical disk, etc.

[0113] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.

[0114] The control method, system, device, processor and storage medium thereof for realizing the real-time switching function of the CAN communication protocol based on the body controller of the present invention have good compatibility and can be adapted to a variety of vehicle models. Good stability and high reliability. The current CAN communication protocol switching function has been applied to 6 mass-produced vehicle models. As of March 2022, 20,444 units have been supplied, and no faulty parts involving the switching disorder of the CAN communication protocol have been received. This proves that the CAN communication protocol will not change arbitrarily and is stable and reliable. The switching operation is simple and convenient. Due to the use of the real-time switching function of the CAN communication protocol, there is no need to wait for professional technicians to arrive. Someone only needs to install the body controller directly on the vehicle, turn the hard-wire switch to the corresponding CAN communication protocol, and then turn the ignition lock. This technical solution is a solution for using the same body controller that needs to be adapted and installed on different vehicles or models. There is no need to update the software program. The CAN communication protocol can be switched in real time to adapt to the corresponding vehicle model. It has good compatibility and the switching operation is simple and convenient.

[0115] In this specification, the present invention has been described with reference to specific embodiments thereof. However, it is apparent that various modifications and variations may be made without departing from the spirit and scope of the present invention. Therefore, the specification and drawings should be regarded as illustrative rather than restrictive.

Claims

1. A control method for implementing real-time switching of CAN communication protocol function based on a vehicle body controller, characterized in that: The method comprises the following steps: (1) Read the internal calibration value and determine whether it has been calibrated. If so, use the calibration value to initialize the corresponding CAN communication protocol and exit the step; otherwise, continue to step (2); (2) Read the adaptive setting value and determine whether the adaptive setting exists. If yes, proceed to step (3); otherwise, exit the step; (3) Read the hard-wire switch state and determine whether the adaptive setting value matches the hard-wire switch state. If so, proceed to step (4); otherwise, exit the step; (4) Initialize the CAN communication protocol using the adaptive setting value, clear the adaptive setting value, and exit the step; The method further comprises the step of executing a periodic task, which specifically comprises the following processing: (5) Determine whether the CAN communication protocol has been initialized. If so, exit the step; otherwise, proceed to step (6); (6) Read the internal calibration value to determine whether it has been calibrated. If so, use the calibration value to initialize the corresponding CAN communication protocol and exit the step; otherwise, continue to step (7); (7) Read the hard-wire switch status; (8) Monitor whether the ignition lock signal switches from OFF to ON. If so, proceed to step (9); otherwise, proceed to step (7); (9) Initialize the CAN communication protocol using the hard-wire switch status and exit the step.

2. The control method for realizing real-time switching of CAN communication protocol function based on vehicle body controller according to claim 1 is characterized in that: The method further comprises the step of writing the adaptive settings, specifically comprising the following steps: (1-1) The body controller is powered off during sleep mode; (1-2) Register the adaptive settings.

3. The control method for realizing real-time switching of CAN communication protocol function based on vehicle body controller according to claim 1, characterized in that: The method further comprises the step of writing the calibration value, specifically: The data of the body controller is verified by an encryption algorithm. If successful, the calibration value is written; otherwise, the calibration value is not written.

4. A system for implementing the method of claim 1 and realizing the real-time switching of CAN communication protocol function, characterized in that: The system comprises: The calibration value module is used to read the internal calibration value and use the calibration value to initialize the corresponding CAN communication protocol; An adaptive setting module, connected to the calibration value module, for reading the adaptive setting value; The hard-wire switch status module is connected to the adaptive setting module and the calibration value module, and is used to read the hard-wire switch status, monitor the ignition lock signal, and use the hard-wire switch status to initialize the CAN communication protocol.

5. The system for realizing real-time switching of CAN communication protocol function according to claim 4, characterized in that: The calibration value module comprises: A calibration value judgment unit, used for reading an internal calibration value and judging whether the internal calibration value has been calibrated; The calibration value initialization unit is connected to the calibration value judgment unit and is used to initialize the corresponding CAN communication protocol using the calibration value when the internal calibration value has been calibrated.

6. The system for implementing real-time switching of CAN communication protocol function according to claim 4, characterized in that: The adaptive setting module includes: An adaptive setting judgment unit, connected to the calibration value module, is used to read the adaptive setting value and judge whether the adaptive setting value exists; A matching judgment unit, connected to the adaptive setting judgment unit and the hard-line switch state module, for judging whether the adaptive setting value matches the hard-line switch state; The adaptive setting initialization unit is connected to the matching judgment unit and is used to initialize the CAN communication protocol using the adaptive setting when the adaptive setting value matches the hard-line switch state.

7. The system for implementing real-time switching of CAN communication protocol function according to claim 4, characterized in that: The hard-line switch status module comprises: A hard-wire switch state reading unit, connected to the adaptive setting module and the calibration value module, for reading the hard-wire switch state; An ignition lock signal monitoring unit, connected to the hard-wire switch state reading unit, for monitoring whether the ignition lock signal is switched from the OFF position to the ON position; The hard-wire switch state initialization unit is connected to the ignition lock signal monitoring unit and is used to initialize the CAN communication protocol using the hard-wire switch state when the ignition lock signal is switched to the ON position.

8. The system for implementing real-time switching of CAN communication protocol function according to claim 4, characterized in that: The adaptive setting module further comprises an adaptive setting writing unit connected to the adaptive setting judging unit and used for powering down the vehicle body controller to sleep and registering the adaptive setting.

9. A device for implementing real-time switching of CAN communication protocol function, characterized in that: The device comprises: a processor configured to execute computer executable instructions; A memory stores one or more computer executable instructions, and when the computer executable instructions are executed by the processor, the steps of the method for realizing real-time switching of CAN communication protocol function described in any one of claims 1 to 3 are implemented.

10. A processor for implementing real-time switching of CAN communication protocol function, characterized in that: The processor is configured to execute computer executable instructions. When the computer executable instructions are executed by the processor, the steps of the method for realizing real-time switching of CAN communication protocol function described in any one of claims 1 to 3 are implemented.

11. A computer-readable storage medium, characterized in that: A computer program is stored thereon, and the computer program can be executed by a processor to implement the various steps of the method for implementing the real-time switching of the CAN communication protocol function as described in any one of claims 1 to 3.