A vehicle adaptation method and system
By identifying vehicle models using the vehicle's VIN code and converting CAN protocol configuration files using a preset template, the problem of inconsistent software versions for vehicle connectivity devices is solved, enabling unified adaptation and dynamic updates of vehicle connectivity devices under different vehicle manufacturer protocols.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-04-27
- Publication Date
- 2026-06-23
AI Technical Summary
In existing technologies, vehicle connectivity devices suffer from difficulties in version management, function management, and repair due to inconsistent software versions from different car manufacturers.
The vehicle model is identified by its VIN code, and the version information of the CAN protocol configuration file bound to the model is fed back to the vehicle connectivity device to determine its compatibility and completeness. If they do not match, the latest configuration file is obtained from the cloud and the different vehicle manufacturer protocols are converted using a preset template to achieve unified management.
It achieves unified adaptation of vehicle connectivity devices under different vehicle manufacturer protocols, ensures software version management and normal function operation, and supports dynamic updates for vehicle model recognition and changes.
Smart Images

Figure CN122268703A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of vehicle technology, and more particularly to a vehicle adaptation method and system. Background Technology
[0002] Vehicle connectivity devices, also known as Internet of Vehicles (IoV) devices, are hardware and terminal systems installed on or working in conjunction with vehicles to enable multi-dimensional communication and data interaction, such as vehicle-to-vehicle (V2V), vehicle-to-infrastructure (V2I), vehicle-to-person (V2P), and vehicle-to-cloud (V2N). They are the core physical carriers that constitute the Internet of Vehicles (IoV).
[0003] Vehicle connectivity devices often need to be compatible with protocols from multiple vehicle manufacturers. However, compatibility with these protocols requires different software versions, resulting in the problem of inconsistent software versions for the same hardware in practical applications. The lack of a unified software version leads to issues such as version management, feature management, logic problem generation and fixing, and disorganized development. Summary of the Invention
[0004] The purpose of this invention is to provide a vehicle adaptation method and system that can solve the problem of the lack of a unified software version for vehicle connectivity devices in the prior art.
[0005] To solve the above-mentioned technical problems, the present invention provides the following technical solution: This invention provides a vehicle adaptation method, applied to a vehicle adaptation system including vehicle connectivity devices and the cloud, the method comprising: The vehicle connectivity device sends the vehicle VIN code to the cloud, so that the cloud can determine the first vehicle model of the vehicle to which the vehicle connectivity device is located based on the vehicle VIN code, and feed back the first version information of the CAN (Controller Area Network) protocol configuration file bound to the first vehicle model to the vehicle connectivity device; The vehicle connectivity device determines whether the first version information matches the version information of the first CAN protocol configuration file stored in the vehicle connectivity device; If a match is found, verify the integrity and validity of the first CAN protocol configuration file; If the verification is successful, the parsing module is initialized and the first CAN protocol configuration file is parsed through the parsing module, and the parsing result is stored in memory.
[0006] Optionally, after the step of the vehicle connectivity device determining whether the first version information matches the version information of the first CAN protocol configuration file stored in the vehicle connectivity device, the method further includes: If they do not match, the vehicle-to-everything (V2X) device sends a protocol configuration file retrieval request to the cloud, wherein the protocol configuration file retrieval request carries the first version information; The cloud responds to the protocol configuration file retrieval request by searching for the second CAN protocol configuration file corresponding to the first version information in the vehicle model database and sending it to the vehicle connectivity device.
[0007] Optionally, the first CAN protocol configuration file is pre-generated in the following manner: The scaling factor and offset in the original CAN protocol configuration file of the vehicle are converted according to the preset template to generate the first CAN protocol configuration file.
[0008] Optionally, the step of converting the scaling factor and offset in the original CAN protocol configuration file of the vehicle according to a preset template to generate the first CAN protocol configuration file includes: Extract the first data parsing rule from the original CAN protocol configuration file; Adjust the values of the scaling factor and offset fields in the first data parsing rule to generate a first CAN protocol configuration file containing the second data parsing rule.
[0009] Optionally, the second data parsing rule includes: Extract the CANID, ID name, ID data length, ID sender, and corresponding period information; Extract the name of the data segment carried by the ID, the position of the data segment in the data carried by the ID, the data length, the data type, the scaling factor, the offset, and the physical extreme value range; The magnification factor is determined based on the physical values corresponding to the parameters; Based on the scaling factor, the offset, and the magnification factor, the physical values corresponding to the parameters in the preset template are determined.
[0010] Optionally, after verifying the integrity and validity of the first CAN protocol configuration file, the method further includes: If the verification fails, a protocol configuration file retrieval request is sent to the cloud, wherein the protocol configuration file retrieval request carries the first version information; The cloud responds to the protocol configuration file retrieval request, searches for the second CAN protocol configuration file corresponding to the first version information in the vehicle model database, and sends it to the vehicle connectivity device. The vehicle connectivity device replaces the first CAN protocol configuration file with the second CAN protocol configuration file.
[0011] Optionally, when the vehicle connected to the vehicle network switches from a first vehicle model to a second vehicle model, the vehicle network connection receives a vehicle model change command sent from the cloud, wherein the vehicle model change command carries a third CAN protocol configuration file bound to the second vehicle model; or, When the vehicle connected to the vehicle is switched from the first vehicle model to the second vehicle model, the vehicle connected to the vehicle determines the first vehicle VIN code and compares the first vehicle VIN code with the vehicle VIN code of the first vehicle model stored in the system. If the two are different, the first vehicle VIN code is sent to the cloud so that the cloud can return a third CAN protocol configuration file that matches the first vehicle VIN code to replace the first CAN protocol configuration file.
[0012] This invention also provides a vehicle adaptation system, which includes vehicle connectivity devices and a cloud platform. The vehicle connectivity devices include: The communication module is used to send the vehicle VIN code to the cloud, so that the cloud can determine the first vehicle model of the vehicle connected to the vehicle based on the vehicle VIN code, and feed back the first version information of the CAN protocol configuration file bound to the first vehicle model to the vehicle connected device. The judgment module is used to determine whether the first version information matches the version information of the first CAN protocol configuration file stored in the vehicle connectivity device; The verification module is used to verify the integrity and legality of the first CAN protocol configuration file if a match is found. The initialization module is used to initialize the parsing module if the verification passes. The parsing module is used to parse the first CAN protocol configuration file and store the parsing results in memory.
[0013] Optionally, the communication module is also used for: After the judgment module determines whether the first version information matches the version information of the first CAN protocol configuration file stored in the vehicle connectivity device, if they do not match, a protocol configuration file retrieval request is sent to the cloud, wherein the protocol configuration file retrieval request carries the first version information. The cloud is used to respond to the protocol configuration file acquisition request, and search for the second CAN protocol configuration file corresponding to the first version information from the vehicle model database and send it to the vehicle connectivity device.
[0014] Optionally, the first CAN protocol configuration file is pre-generated in the following manner: The scaling factor and offset in the original CAN protocol configuration file of the vehicle are converted according to the preset template to generate the first CAN protocol configuration file.
[0015] Optionally, the first CAN protocol configuration file is pre-generated in the following manner: Extract the first data parsing rule from the original CAN protocol configuration file; Adjust the values of the scaling factor and offset fields in the first data parsing rule to generate a first CAN protocol configuration file containing the second data parsing rule.
[0016] Optionally, the second data parsing rule includes: Extract the CANID, ID name, ID data length, ID sender, and corresponding period information; Extract the name of the data segment carried by the ID, the position of the data segment in the data carried by the ID, the data length, the data type, the scaling factor, the offset, and the physical extreme value range; The magnification factor is determined based on the physical values corresponding to the parameters; Based on the scaling factor, the offset, and the magnification factor, the physical values corresponding to the parameters in the preset template are determined.
[0017] Optionally, the communication module is further configured to: After the verification module verifies the integrity and legality of the first CAN protocol configuration file, if the verification fails, a protocol configuration file retrieval request is sent to the cloud, wherein the protocol configuration file retrieval request carries the first version information; The cloud is also used to respond to the protocol configuration file acquisition request, search for the second CAN protocol configuration file corresponding to the first version information from the vehicle model database and send it to the vehicle connectivity device, and the vehicle connectivity device replaces the first CAN protocol configuration file with the second CAN protocol configuration file.
[0018] This invention provides an electronic device, which includes a processor, a memory, and a program or instructions stored in the memory and executable on the processor. When the program or instructions are executed by the processor, they implement the steps of the vehicle adaptation method executed by any of the above-described vehicle connectivity devices.
[0019] This invention provides a readable storage medium storing a program or instructions, which, when executed by a processor, implement the steps of the vehicle adaptation method executed by any of the above-described vehicle connectivity devices.
[0020] The vehicle adaptation scheme provided in this embodiment of the invention involves the vehicle connectivity device sending the vehicle VIN code to the cloud, so that the cloud can determine the first vehicle model of the vehicle connectivity device based on the vehicle VIN code, and feed back the first version information of the CAN protocol configuration file bound to the first vehicle model to the vehicle connectivity device; the vehicle connectivity device determines whether the first version information matches the version information of the first CAN protocol configuration file stored in the vehicle connectivity device; If a match is found, the integrity and validity of the first CAN protocol configuration file are verified. If the verification passes, the parsing module is initialized and the first CAN protocol configuration file is parsed using the parsing module. The parsing result is then stored in memory. The vehicle adaptation scheme provided in this application converts different vehicle manufacturer protocols into CAN protocol configuration files with different scaling factors and offsets within the same template word template. Based on preset, vehicle VIN code parsing, and cloud management configuration, it achieves dynamic updates for vehicle model recognition and vehicle model changes, enabling vehicle connectivity devices to adapt to different vehicle manufacturer protocols. Attached Figure Description
[0021] Figure 1 This is a flowchart illustrating the steps of a vehicle adaptation method according to an embodiment of this application; Figure 2 This is a flowchart illustrating the steps of another vehicle adaptation method according to an embodiment of this application; Figure 3 This is a schematic diagram illustrating the structure of a vehicle adaptation system according to an embodiment of this application; Figure 4 This is a structural block diagram illustrating another vehicle adaptation system according to an embodiment of this application. Detailed Implementation
[0022] To make the technical problems, technical solutions and advantages of the present invention clearer, a detailed description will be given below in conjunction with the accompanying drawings and specific embodiments.
[0023] The vehicle adaptation solution provided in this application will be described in detail below with reference to the accompanying drawings, through specific embodiments and application scenarios.
[0024] As attached Figure 1 As shown, the vehicle adaptation method of this application embodiment includes the following steps: Step 101: The vehicle connectivity device sends the vehicle VIN code to the cloud so that the cloud can determine the first vehicle model of the vehicle connectivity device based on the vehicle VIN code, and feed back the first version information of the CAN protocol configuration file bound to the first vehicle model to the vehicle connectivity device.
[0025] The vehicle adaptation method provided in this application is used in a vehicle adaptation system that includes vehicle connectivity devices and the cloud. For each automaker that needs to adapt to vehicle connectivity devices, when adapting to the CAN protocol of model A, the automaker will provide a CAN protocol configuration file, which is pre-converted into a preset template CAN protocol configuration file. Only the field values in the protocol configuration file are converted according to preset rules. The converted CAN protocol configuration file can be adapted to vehicle connectivity devices.
[0026] For example, if a car manufacturer has two models, A and B, that need to be adapted to vehicle connectivity devices, it can provide CAN protocol configuration files for model A and model B. The two CAN protocol configuration files are converted according to preset templates to obtain two converted CAN protocol configuration files. The converted CAN protocol configuration files can be managed in the cloud, and the CAN protocol configuration files can be stored in the cloud according to the corresponding car models.
[0027] The VIN code is a unique vehicle identification code consisting of 17 characters. After the vehicle connectivity device is installed on the vehicle, it obtains the vehicle VIN code and sends it to the cloud so that the cloud can determine the vehicle model based on the vehicle VIN code. After determining the vehicle model, it further determines the first version information of the CAN protocol configuration file bound to the vehicle model.
[0028] Step 102: The vehicle-to-everything (V2X) device determines whether the first version information matches the version information of the first CAN protocol configuration file stored in the V2X device.
[0029] The first CAN protocol configuration file can be pre-generated as follows: the scaling factor and offset in the original CAN protocol configuration file of the vehicle are converted according to a preset template to generate the first CAN protocol configuration file.
[0030] In one optional embodiment, the method of generating a first CAN protocol configuration file by converting the scaling factor and offset in the original CAN protocol configuration file of the vehicle according to a preset template may include the following sub-steps: Sub-step 1: Extract the first data parsing rule from the original CAN protocol configuration file; The original CAN protocol configuration file contains data parsing rules, which are distributed in different parts of the document. To standardize these rules, the first parsing rule in the original CAN protocol configuration file needs to be extracted and processed into the second data parsing rule.
[0031] Sub-step 2: Adjust the field values of the scaling factor and offset in the first data parsing rule to generate the first CAN protocol configuration file containing the second data parsing rule.
[0032] In one feasible implementation, the second data parsing rule may include, but is not limited to: Extract CANID, ID name, ID data length, ID sender, and corresponding periodic information; extract ID data segment name, data segment position in ID data, data length, data type, scaling factor, offset, and physical extreme value range; determine the scaling factor based on the physical values corresponding to the parameters; determine the physical values corresponding to the parameters in the preset template based on the scaling factor, offset, and scaling factor.
[0033] Scale factor describes the multiplier between two quantities; offset is the displacement or difference between a reference point and a target position; CANID (Controller Area Network Identifier) is an identifier located at the beginning of a data frame; physical value refers to a human-readable numerical value with practical engineering significance; and raw value refers to the actual numerical format of the data transmitted on the bus.
[0034] When determining the physical values corresponding to parameters in a preset template based on scaling factors, offsets, and magnification factors, adjacent physical values smaller than the current physical value can be magnified by a factor of 100 / 1000. Alternatively, for parameters that do not meet the preconditions, a magnification of 100 / 1000 can be used. Taking battery SOC (State of Charge, remaining charge) and total vehicle mileage as examples: Battery SOC: The physical value is usually a percentage. You can choose to multiply this percentage by 100. The conversion formula for this parameter is: (Original value for model A) (proportion factor) 100) + Offset 100 = Template SOC data Total vehicle mileage: The physical value is generally expressed in km. The conversion formula for this parameter can be: (Original value for vehicle model A) (proportion factor) 1000) + Offset 1000 = Template total mileage data It should be noted that the above is only an example of magnification factor of 100 or 1000. In actual implementation, the specific value of magnification factor can be flexibly configured by those skilled in the art, and no specific restrictions are imposed on this in the embodiments of this application.
[0035] Step 103: If a match is found, verify the integrity and validity of the first CAN protocol configuration file.
[0036] If a match is found, it means that the CAN protocol configuration file managed in the vehicle connectivity device is compatible with the current vehicle. However, to ensure communication, it is necessary to further verify the integrity and validity of the CAN protocol configuration file.
[0037] In an optional embodiment, after the vehicle connectivity device determines whether the first version information matches the version information of the first CAN protocol configuration file stored in the vehicle connectivity device, the following steps may also be performed: If they do not match, the vehicle-to-everything (V2X) device sends a protocol configuration file retrieval request to the cloud. The cloud responds to the protocol configuration file retrieval request by searching for the second CAN protocol configuration file corresponding to the first version information in the vehicle model database and sending it to the V2X device.
[0038] The request to obtain the protocol configuration file contains information about the first version.
[0039] In this alternative embodiment, since the vehicle-to-everything (V2X) device does not have a CAN protocol configuration file adapted to the current vehicle, it requests the cloud, which manages CAN protocol configuration files adapted to each vehicle model, to obtain it. The cloud then provides a second CAN protocol configuration file adapted to the current vehicle. After obtaining the second CAN protocol configuration file from the cloud, the V2X device verifies the integrity and legality of the second CAN protocol configuration file.
[0040] Step 104: If the verification is successful, initialize the parsing module and parse the first CAN protocol configuration file through the parsing module, and store the parsing result in memory.
[0041] The parsing results stored in memory can then be used for CAN protocol network communication based on vehicle connectivity devices.
[0042] In an optional embodiment, after verifying the integrity and legality of the first CAN protocol configuration file, the method further includes: if the verification fails, sending a protocol configuration file retrieval request to the cloud, wherein the protocol configuration file retrieval request carries first version information; the cloud responds to the protocol configuration file retrieval request, searches for the second CAN protocol configuration file corresponding to the first version information in the vehicle model database, sends it to the vehicle connectivity device, and the vehicle connectivity device replaces the first CAN protocol configuration file with the second CAN protocol configuration file.
[0043] If the CAN protocol configuration file changes but is not synchronized in time on the vehicle connectivity device, the integrity and legality verification will fail. In this case, it is necessary to obtain the latest version of the CAN protocol configuration file adapted to the vehicle from the cloud.
[0044] In one optional embodiment, when the vehicle connected to the vehicle network switches from a first vehicle model to a second vehicle model, the vehicle network device receives a vehicle model change command sent from the cloud, wherein the vehicle model change command carries a third CAN protocol configuration file bound to the second vehicle model; or, when the vehicle connected to the vehicle network device switches from a first vehicle model to a second vehicle model, the vehicle network device determines the first vehicle VIN code and compares the first vehicle VIN code with the vehicle VIN code of the first vehicle model stored in the system; if the two are different, the first vehicle VIN code is sent to the cloud so that the cloud returns a third CAN protocol configuration file that matches the first vehicle VIN code to replace the first CAN protocol configuration file.
[0045] The vehicle adaptation method provided in this application embodiment involves the vehicle connectivity device sending the vehicle VIN code to the cloud, so that the cloud can determine the first vehicle model of the vehicle connectivity device based on the vehicle VIN code, and feed back the first version information of the CAN protocol configuration file bound to the first vehicle model to the vehicle connectivity device; the vehicle connectivity device determines whether the first version information matches the version information of the first CAN protocol configuration file stored in the vehicle connectivity device; If a match is found, the integrity and validity of the first CAN protocol configuration file are verified. If the verification passes, the parsing module is initialized and the first CAN protocol configuration file is parsed using the parsing module, and the parsing result is stored in memory. The vehicle adaptation method provided in this application converts different vehicle manufacturer protocols into CAN protocol configuration files with different scaling factors and offsets within the same template word template. Based on preset, vehicle VIN code parsing, and cloud management configuration, it realizes dynamic updates for vehicle model recognition and vehicle model changes, so that vehicle connectivity devices can adapt to different vehicle manufacturer protocols.
[0046] The following reference Figure 2 The vehicle adaptation method provided in the embodiments of this application will be illustrated with a specific example.
[0047] The vehicle adaptation method provided in this specific example converts CAN protocol configuration files from different car manufacturers into CAN protocol configuration files with the same template but different scaling factors and offsets within the template. Based on preset configurations, vehicle VIN code parsing, and cloud management configurations, it enables dynamic updates for vehicle model recognition and vehicle model changes.
[0048] The vehicle adaptation method provided in this specific example includes two parts: template file preprocessing and vehicle adaptation based on the preprocessed template file. The preprocessing part mainly includes the following: This section describes the template file (i.e., the CAN protocol configuration file of the preset template) creation process. When it is necessary to adapt the CAN protocol configuration file of vehicle model A, the vehicle manufacturer of model A provides a CAN protocol configuration file. This CAN protocol configuration file contains the corresponding parsing rules for the data, which are distributed in different parts of the document. Therefore, it is necessary to regularize it. The parsing rules contained in this CAN protocol configuration file are extracted and processed into rules that are compatible with vehicle connectivity devices. The specific adaptation rules can be as follows: Extract the CANID, ID name, data length carried by the ID, sender and period information of the ID.
[0049] Extract the data segment name, position of the data segment within the ID's data, data length, data type, scaling factor, offset, and physical extreme value range from the ID. After extracting this information, process the scaling factor and offset of the data segment. The processing method involves increasing the scaling factor and offset by a multiple smaller than the current physical value, or, if the preconditions are not met, increasing it by a factor of 100 / 1000. For example, consider the battery's SOC and the vehicle's total mileage: SOC: Physical values are generally percentage data. You can choose to scale this percentage data by 100 times. The response parameter conversion formula can be: (Original value of vehicle type A) (proportion factor) 100) + Offset 100 = Template SOC data.
[0050] Total vehicle mileage: The physical value is generally expressed in km. The corresponding parameter conversion formula can be: (Original value for vehicle model A) (proportion factor) 1000) + Offset 1000 = Total mileage data for the template.
[0051] Using the above preprocessing operations, CAN protocol configuration files of various vehicle models can be converted into CAN protocol configuration files with the same template but different field values within the template, based on a preset template. The cloud can manage the CAN protocol configuration files corresponding to different vehicle models.
[0052] like Figure 2 As shown, the vehicle adaptation process based on the preprocessed template file can be as follows: S1: Determine if the configuration file matches the stored vehicle model A; if yes, execute S2; if no, execute S6 and S7.
[0053] The program starts running and first checks whether the configuration of vehicle model A matches the vehicle model currently being used by the device. If yes, it proceeds to the next check; otherwise, it proceeds to step S6 to process and obtains the matching vehicle model's configuration file, i.e., the CAN protocol configuration file, via step S7.
[0054] S2: Determine if the configuration file for vehicle model A is complete and valid; if yes, proceed to S3; otherwise, proceed to S7.
[0055] After the integrity verification of the vehicle model A configuration file is completed, if the verification result is successful, proceed to step S3; if the verification result is unsuccessful, proceed to step S7 to update the configuration file. Then proceed to step S2 to perform the integrity and legality verification process.
[0056] S3: Initialize the parsing module.
[0057] S4: Parse the vehicle model A configuration file into memory.
[0058] After ensuring that the configuration file is intact and matches vehicle model A, S4 will be executed to bind the ID in the configuration file and all data segments under that ID in memory.
[0059] S5: Analyze the CAN data of vehicle model A.
[0060] After receiving the corresponding ID, S5 fills in the data content of the data segment for that ID.
[0061] When using the vehicle adaptation method provided in this application embodiment, the following processing will be performed when the device switches from vehicle model A to vehicle model B: Method 1: Cloud configuration change to vehicle model B: After receiving the cloud instruction, the device will perform the relevant checks and verification operations on vehicle model B after S7.
[0062] Method 2: The device actively reports vehicle model A upon startup. The cloud verifies that vehicle model A has been changed to vehicle model B. After receiving the change, the device performs relevant checks and verifications on the configuration of vehicle model B.
[0063] Method 3: The device parses the vehicle's VIN code via CAN to obtain vehicle model B. If a match is found between the VIN code and the locally stored vehicle model information, a VIN code model change is reported. The device receives the vehicle model B configuration file from the cloud and performs relevant checks and verification operations on the configuration file.
[0064] like Figure 3 As shown in the figure, this application embodiment also provides a structural block diagram of a vehicle adaptation system. The vehicle adaptation system includes: a vehicle and a cloud. A preprocessing module can be installed in the vehicle or connected externally. The fish hammer module is used to process the original CAN protocol file (i.e., the original CAN protocol configuration file) from the vehicle manufacturer into a configuration file with the same template but different field values.
[0065] like Figure 3 As shown, the vehicle includes a 4G vehicle connectivity device with CAN communication function that communicates with the vehicle's CAN in real time, and a vehicle information management system configured in the cloud that can verify the vehicle model and manage vehicle information.
[0066] Vehicle-to-everything (V2X) devices: V2X devices can communicate with the vehicle information management system via 4G communication to enable functions such as issuing control commands based on vehicle model, reporting and verifying vehicle model information, and updating vehicle model configuration. Upon startup, the V2X devices join the vehicle's CAN network via the CAN communication unit, enabling data transmission with the entire vehicle. The main control unit's parsing module parses the data received from the CAN communication unit and uploads the data via the 4G communication module.
[0067] The cloud-based vehicle information management system includes: a communication unit and a vehicle information module; The communication unit is used to communicate with the 4G communication module of the vehicle-to-everything (V2X) device to upload or receive information.
[0068] The vehicle information module manages a vehicle model database: the vehicle model database can save the binding relationship between vehicle models and vehicle-to-everything (V2X) devices imported from orders, as well as the exact vehicle models and V2X device binding relationships imported from external sources.
[0069] The vehicle model verification and configuration functions performed by the vehicle information module are as follows: Vehicle model verification function: After the vehicle-to-everything (V2X) device starts up and connects to the network, it actively sends a vehicle model command to the vehicle information management system. Upon receiving the reported vehicle model, the vehicle information module queries the vehicle model database based on the unique identifier of the V2X device to check if the corresponding vehicle model matches. The verification result is then returned.
[0070] Vehicle model configuration function: When the vehicle model is changed by the vehicle connectivity device, the cloud actively issues a vehicle model change command and synchronously modifies the vehicle model database.
[0071] Figure 4 The structural block diagram of the vehicle adaptation system in this application embodiment is shown.
[0072] The vehicle adaptation system provided in this application embodiment includes a vehicle connectivity device 401 and a cloud 402. The vehicle connectivity device 401 includes the following functional modules: The communication module 4011 is used to send the vehicle VIN code to the cloud 402, so that the cloud can determine the first vehicle model of the vehicle connected to the vehicle based on the vehicle VIN code, and feed back the first version information of the CAN protocol configuration file bound to the first vehicle model to the vehicle connected to the vehicle. The judgment module 4012 is used to determine whether the first version information matches the version information of the first CAN protocol configuration file stored in the vehicle connectivity device; The verification module 4013 is used to verify the integrity and legality of the first CAN protocol configuration file if a match is found. Initialization module 4014 is used to initialize the parsing module if the verification passes. The parsing module 4015 is used to parse the first CAN protocol configuration file and store the parsing result in memory.
[0073] Optionally, the communication module is further configured to: After the judgment module determines whether the first version information matches the version information of the first CAN protocol configuration file stored in the vehicle connectivity device, if they do not match, a protocol configuration file retrieval request is sent to the cloud, wherein the protocol configuration file retrieval request carries the first version information. The cloud is used to respond to the protocol configuration file acquisition request, and search for the second CAN protocol configuration file corresponding to the first version information from the vehicle model database and send it to the vehicle connectivity device.
[0074] Optionally, the first CAN protocol configuration file is pre-generated in the following manner: The scaling factor and offset in the original CAN protocol configuration file of the vehicle are converted according to the preset template to generate the first CAN protocol configuration file.
[0075] Optionally, the first CAN protocol configuration file is pre-generated in the following manner: Extract the first data parsing rule from the original CAN protocol configuration file; Adjust the values of the scaling factor and offset fields in the first data parsing rule to generate a first CAN protocol configuration file containing the second data parsing rule.
[0076] Optionally, the second data parsing rule includes: Extract the CANID, ID name, ID data length, ID sender, and corresponding period information; Extract the name of the data segment carried by the ID, the position of the data segment in the data carried by the ID, the data length, the data type, the scaling factor, the offset, and the physical extreme value range; The magnification factor is determined based on the physical values corresponding to the parameters; Based on the scaling factor, the offset, and the magnification factor, the physical values corresponding to the parameters in the preset template are determined.
[0077] Optionally, the communication module is further configured to: After the verification module verifies the integrity and legality of the first CAN protocol configuration file, if the verification fails, a protocol configuration file retrieval request is sent to the cloud, wherein the protocol configuration file retrieval request carries the first version information; The cloud is also used to respond to the protocol configuration file acquisition request, search for the second CAN protocol configuration file corresponding to the first version information from the vehicle model database and send it to the vehicle connectivity device, and the vehicle connectivity device replaces the first CAN protocol configuration file with the second CAN protocol configuration file.
[0078] The vehicle adaptation system provided in this application converts different vehicle manufacturer protocols into CAN protocol configuration files with different scaling factors and offsets within the same template word template. Based on preset, vehicle VIN code parsing, and cloud management configuration, it realizes dynamic updates for vehicle model recognition and vehicle model changes, so that vehicle connectivity devices can adapt to different vehicle manufacturer protocols.
[0079] In the embodiments of this application Figure 4 The vehicle connectivity device in the vehicle adaptation system shown can be a device with an operating system. This operating system can be Android, iOS, or other possible operating systems; this application does not specifically limit the specific operating system used.
[0080] The embodiments provided in this application Figure 4 The vehicle adaptation system shown can achieve Figure 1 The various processes implemented in the method implementation examples will not be described again here to avoid repetition.
[0081] Optionally, embodiments of this application also provide an electronic device, including a processor, a memory, and a program or instructions stored in the memory and executable on the processor. When the program or instructions are executed by the processor, they implement the various processes performed by the above-mentioned vehicle connectivity device in the vehicle adaptation method and can achieve the same technical effect. To avoid repetition, they will not be described again here.
[0082] The processor is the processor in the electronic device described in the above embodiments. The readable storage medium includes computer-readable storage media, such as computer read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk.
[0083] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus 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 apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.
[0084] The above description represents the preferred embodiments of the present invention. It should be noted that those skilled in the art can make various improvements and modifications without departing from the principles of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.
Claims
1. A vehicle adaptation method, characterized in that, The method, applied to a vehicle adaptation system that includes vehicle connectivity devices and the cloud, comprises: The vehicle connectivity device sends the vehicle VIN code to the cloud, so that the cloud can determine the first vehicle model of the vehicle connectivity device based on the vehicle VIN code, and feed back the first version information of the CAN protocol configuration file bound to the first vehicle model to the vehicle connectivity device; The vehicle connectivity device determines whether the first version information matches the version information of the first CAN protocol configuration file stored in the vehicle connectivity device; If a match is found, verify the integrity and validity of the first CAN protocol configuration file; If the verification is successful, the parsing module is initialized and the first CAN protocol configuration file is parsed through the parsing module, and the parsing result is stored in memory.
2. The method according to claim 1, characterized in that, After the step of determining whether the first version information matches the version information of the first CAN protocol configuration file stored in the vehicle connectivity device, the method further includes: If they do not match, the vehicle-to-everything (V2X) device sends a protocol configuration file retrieval request to the cloud, wherein the protocol configuration file retrieval request carries the first version information; The cloud responds to the protocol configuration file retrieval request by searching for the second CAN protocol configuration file corresponding to the first version information in the vehicle model database and sending it to the vehicle connectivity device.
3. The method according to claim 1, characterized in that, The first CAN protocol configuration file is pre-generated in the following manner: The scaling factor and offset in the original CAN protocol configuration file of the vehicle are converted according to the preset template to generate the first CAN protocol configuration file.
4. The method according to claim 3, characterized in that, The step of converting the scaling factor and offset in the original CAN protocol configuration file of the vehicle according to a preset template to generate the first CAN protocol configuration file includes: Extract the first data parsing rule from the original CAN protocol configuration file; Adjust the values of the scaling factor and offset fields in the first data parsing rule to generate a first CAN protocol configuration file containing the second data parsing rule.
5. The method according to claim 4, characterized in that, The second data parsing rule includes: Extract the CANID, ID name, ID data length, ID sender, and corresponding period information; Extract the name of the data segment carried by the ID, the position of the data segment in the data carried by the ID, the data length, the data type, the scaling factor, the offset, and the physical extreme value range; The magnification factor is determined based on the physical values corresponding to the parameters; Based on the scaling factor, the offset, and the magnification factor, the physical values corresponding to the parameters in the preset template are determined.
6. The method according to claim 1, characterized in that, After verifying the integrity and validity of the first CAN protocol configuration file, the method further includes: If the verification fails, a protocol configuration file retrieval request is sent to the cloud, wherein the protocol configuration file retrieval request carries the first version information; The cloud responds to the protocol configuration file retrieval request, searches for the second CAN protocol configuration file corresponding to the first version information in the vehicle model database, and sends it to the vehicle connectivity device. The vehicle connectivity device replaces the first CAN protocol configuration file with the second CAN protocol configuration file.
7. The method according to claim 1, characterized in that, When the vehicle connected to the vehicle network switches from a first vehicle model to a second vehicle model, the vehicle network device receives a vehicle model change command sent from the cloud. This vehicle model change command carries a third CAN protocol configuration file bound to the second vehicle model; or... When the vehicle connected to the vehicle is switched from the first vehicle model to the second vehicle model, the vehicle connected to the vehicle determines the first vehicle VIN code and compares the first vehicle VIN code with the vehicle VIN code of the first vehicle model stored in the system. If the two are different, the first vehicle VIN code is sent to the cloud so that the cloud can return a third CAN protocol configuration file that matches the first vehicle VIN code to replace the first CAN protocol configuration file.
8. A vehicle adaptation system, the vehicle connectivity adaptation system comprising vehicle connectivity devices and a cloud, the vehicle connectivity devices comprising: The communication module is used to send the vehicle VIN code to the cloud, so that the cloud can determine the first vehicle model of the vehicle connected to the vehicle based on the vehicle VIN code, and feed back the first version information of the CAN protocol configuration file bound to the first vehicle model to the vehicle connected device. The judgment module is used to determine whether the first version information matches the version information of the first CAN protocol configuration file stored in the vehicle connectivity device; The verification module is used to verify the integrity and legality of the first CAN protocol configuration file if a match is found. The initialization module is used to initialize the parsing module if the verification passes. The parsing module is used to parse the first CAN protocol configuration file and store the parsing results in memory.
9. The vehicle adaptation system according to claim 8, characterized in that, The communication module is also used for: After the judgment module determines whether the first version information matches the version information of the first CAN protocol configuration file stored in the vehicle connectivity device, if they do not match, a protocol configuration file retrieval request is sent to the cloud, wherein the protocol configuration file retrieval request carries the first version information. The cloud is used to respond to the protocol configuration file acquisition request, and search for the second CAN protocol configuration file corresponding to the first version information from the vehicle model database and send it to the vehicle connectivity device.
10. The vehicle adaptation system according to claim 8, characterized in that, The first CAN protocol configuration file is pre-generated in the following manner: The scaling factor and offset in the original CAN protocol configuration file of the vehicle are converted according to the preset template to generate the first CAN protocol configuration file.
11. The vehicle adaptation system according to claim 10, characterized in that, The first CAN protocol configuration file is pre-generated in the following manner: Extract the first data parsing rule from the original CAN protocol configuration file; Adjust the values of the scaling factor and offset fields in the first data parsing rule to generate a first CAN protocol configuration file containing the second data parsing rule.
12. The vehicle adaptation system according to claim 11, characterized in that, The second data parsing rule includes: Extract the CANID, ID name, ID data length, ID sender, and corresponding period information; Extract the name of the data segment carried by the ID, the position of the data segment in the data carried by the ID, the data length, the data type, the scaling factor, the offset, and the physical extreme value range; The magnification factor is determined based on the physical values corresponding to the parameters; Based on the scaling factor, the offset, and the magnification factor, the physical values corresponding to the parameters in the preset template are determined.
13. The vehicle adaptation system according to claim 8, characterized in that, The communication module is also used for: After the verification module verifies the integrity and legality of the first CAN protocol configuration file, if the verification fails, a protocol configuration file retrieval request is sent to the cloud, wherein the protocol configuration file retrieval request carries the first version information; The cloud is also used to respond to the protocol configuration file acquisition request, search for the second CAN protocol configuration file corresponding to the first version information from the vehicle model database and send it to the vehicle connectivity device, and the vehicle connectivity device replaces the first CAN protocol configuration file with the second CAN protocol configuration file.