Data calibration method, device, equipment, storage medium and vehicle
Through the mapping relationship between the Flash pointer area and the RAM pointer area, the problem of Overlay resource limitation in traditional XCP double-page calibration is solved, data calibration of large amounts of data is realized, and calibration efficiency is improved.
Patent Information
- Application Number
- CN202410893536.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-04
- Publication Date
- 2024-10-29
- Estimated Expiration
- 2044-07-04
AI Technical Summary
Due to the limitation of Overlay resources, the traditional XCP double-page calibration method is difficult to achieve calibration work with large amounts of data, resulting in low data calibration efficiency.
Establish an indirect mapping relationship between the Flash pointer area and the RAM pointer area, and use the address overlap method between the Flash pointer area and the RAM pointer area to store the address values of multiple data blocks, optimize the storage capacity of RAM, and achieve data calibration of large amounts of data.
It effectively improves the efficiency of data calibration, solves the problem of insufficient RAM storage due to Overlay resource limitations, and realizes multi-data block calibration based on the Flash pointer area and RAM pointer area.
Smart Images

Figure CN118426708B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of vehicle data processing technology, and in particular to a data calibration method, device, equipment, storage medium and vehicle. Background Art
[0002] During the development and debugging of vehicle-related software, it is usually necessary to calibrate the vehicle-mounted equipment based on actual vehicle test data in order to continuously optimize vehicle performance parameters such as drivability, power, and economy.
[0003] Traditional XCP (Universal Calibration Protocol) calibration methods can only achieve single-page calibration. If you want to achieve double-page calibration, the vehicle-mounted equipment needs to have an overlay function. The overlay function can establish a corresponding relationship between the read-only memory Flash and the read-write memory RAM of the vehicle-mounted equipment. When performing data calibration, the calibration data is mapped from the read-only memory Flash to the read-write memory RAM, and the data is continuously optimized to complete the calibration process. However, the overlay resources of the vehicle-mounted equipment are limited (generally 8k), and the storage capacity allocated to RAM is usually small, making it difficult to implement calibration work for large amounts of data, resulting in low data calibration efficiency. Summary of the invention
[0004] The present invention provides a data calibration method, device, equipment, storage medium and vehicle to solve the problem that in traditional XCP double-page calibration, it is difficult to implement calibration work of large data volume due to Overlay resource limitation, resulting in low data calibration efficiency.
[0005] A data calibration method is provided, comprising:
[0006] When receiving a calibration command for a target vehicle-mounted device, parsing the calibration command to obtain a target address of the data to be calibrated;
[0007] Locating and obtaining a first data block corresponding to a target address in a Flash data area through a Flash pointer area of a target vehicle-mounted device;
[0008] Locating and obtaining a second data block stored in a RAM data area of a target vehicle-mounted device through a RAM pointer area having a mapping relationship with the Flash pointer area;
[0009] Based on the data to be calibrated and the second data block in the RAM data area, the first data block in the Flash data area is calibrated.
[0010] Optionally, locating and determining a first data block corresponding to a target address in a Flash data area through a Flash pointer area of a target vehicle-mounted device includes:
[0011] Determine the first address of the first data block in the Flash data area to obtain the Flash first address;
[0012] The Flash first address is input into the Flash pointer area, so that the Flash pointer area locates the first data block in the Flash data area based on the Flash first address.
[0013] Optionally, determining the first address of the first data block in the Flash data area to obtain the Flash first address includes:
[0014] The first address and data size of all data blocks in the Flash data area are read from the pre-stored Flash data block information;
[0015] Based on the target address, the first address of each data block and the data size, each data block is matched to obtain the first data block, and the Flash first address is the first address of the first data block in the Flash data area.
[0016] Optionally, determining the second data block stored in the RAM data area of the target vehicle-mounted device by using the RAM pointer area having a mapping relationship with the Flash pointer area includes:
[0017] Determine the first address of the second data block in the RAM data area to obtain the RAM first address;
[0018] The RAM first address is input into the RAM pointer area so that the RAM pointer area locates the second data block in the RAM data area based on the RAM first address.
[0019] Optionally, after determining that the second data block is before the first address of the RAM data area of the target vehicle-mounted device, the method further includes:
[0020] Read the first data block in the Flash data area;
[0021] After storing the first data block in the RAM data area, a second data block is obtained, and the first address of the second data block in the RAM data area is recorded.
[0022] Optionally, calibrating the first data block in the Flash data area based on the data to be calibrated and the second data block in the RAM data area includes:
[0023] Based on the target address, determining a writing position of the data to be calibrated in the second data block;
[0024] Writing the data to be calibrated at the writing position in the second data block to obtain a target data block;
[0025] The target data block that meets the calibration requirements replaces the first data block in the Flash data area.
[0026] Optionally, based on the target address, determining a writing position of the data to be calibrated in the second data block includes:
[0027] Determine the address offset between the Flash first address and the target address;
[0028] Based on the RAM first address and the address offset, the writing position of the data to be calibrated in the second data block is determined.
[0029] Optionally, before parsing the calibration command to obtain the target address of the data to be calibrated, the method further includes:
[0030] When the target vehicle-mounted device is powered on, the data in the Flash data area is read through the Flash pointer area to obtain the first addresses of all data blocks in the Flash data area;
[0031] Sort the first addresses of each data block in ascending order, and determine the data size of each data block based on two adjacent first addresses;
[0032] The first address and data size of each data block are summarized to obtain the Flash data block information and store it.
[0033] Optionally, before parsing the calibration command to obtain the target address of the data to be calibrated, the method further includes:
[0034] The data of each data block is stored in the Flash data area in the form of a structure, and the first address of each data block in the Flash data area is stored in the Flash pointer area;
[0035] A mapping relationship between the Flash pointer area and the RAM pointer area is established by using an address overlap method; wherein the Flash storage space of the target vehicle-mounted device includes a Flash data area and a Flash pointer area, and the RAM storage space of the target vehicle-mounted device includes a RAM data area and a RAM pointer area.
[0036] A data calibration device is provided, comprising:
[0037] A parsing module, for parsing the calibration command to obtain the target address of the data to be calibrated when receiving the calibration command for the target vehicle-mounted device;
[0038] A first positioning module, used for locating a first data block corresponding to a target address in a Flash data area through a Flash pointer area of a target vehicle-mounted device;
[0039] A second positioning module, used for locating a second data block stored in a RAM data area of a target vehicle-mounted device through a RAM pointer area having a mapping relationship with the Flash pointer area;
[0040] The calibration module is used to calibrate the first data block in the Flash data area based on the data to be calibrated and the second data block in the RAM data area.
[0041] A computer device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the steps of the above-mentioned data calibration method are implemented when the processor executes the computer program.
[0042] A readable storage medium is provided, which stores a computer program. When the computer program is executed by a processor, the steps of the above-mentioned data calibration method are implemented.
[0043] A vehicle comprises the above-mentioned computer device or the above-mentioned readable storage medium.
[0044] In a scheme provided by the above-mentioned data calibration method, device, equipment, storage medium and vehicle, when a calibration command for a target vehicle-mounted device is received, the calibration command is parsed to obtain the target address of the data to be calibrated; the first data block corresponding to the target address in the Flash data area is located through the Flash pointer area of the target vehicle-mounted device; the second data block stored in the RAM data area of the target vehicle-mounted device is located through the RAM pointer area having a mapping relationship with the Flash pointer area; based on the data to be calibrated and the second data block in the RAM data area, the first data block in the Flash data area is calibrated. In an embodiment of the present invention, an indirect mapping relationship is established for the Flash data area and the RAM data area through the mapping relationship between the Flash pointer area and the RAM pointer area. Different from the way in which the overlay function area stores the calibration data block in the traditional XCP calibration process, the overlay function area of this embodiment, i.e., the Flash pointer area and the RAM pointer area, can store the address values of multiple data blocks, effectively reducing the situation where the RAM storage capacity is not high due to the limitation of overlay resources, so that the data calibration work of large data volume can be performed based on the Flash pointer area and the RAM pointer area, and the efficiency of data calibration is effectively improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0045] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments of the present invention will be briefly introduced below. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative labor.
[0046] Figure 1 is a structural schematic diagram of a data calibration system in one embodiment of the present invention;
[0047] Figure 2 is a data access schematic diagram in a target vehicle-mounted device in one embodiment of the present invention;
[0048] Figure 3 is a flow chart of a data calibration method in one embodiment of the present invention;
[0049] Figure 4 yes Figure 3 A schematic diagram of an implementation process of step S20;
[0050] Figure 5 yes Figure 3 A schematic diagram of an implementation process of step S30;
[0051] Figure 6 yes Figure 3 A schematic diagram of an implementation process of step S40;
[0052] Figure 7 is a structural schematic diagram of a data calibration device in one embodiment of the present invention;
[0053] Figure 8 It is a structural diagram of a computer device in one embodiment of the present invention. DETAILED DESCRIPTION
[0054] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0055] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of the described features, integrals, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components and / or their collections. It should also be understood that the term "and / or" used in the present specification and the appended claims refers to any combination of one or more of the associated listed items and all possible combinations, and includes these combinations.
[0056] In addition, in the description of the present specification and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the descriptions and cannot be understood as indicating or implying relative importance.
[0057] References to "one embodiment" or "some embodiments" etc. described in the present specification mean that one or more embodiments of the present invention include specific features, structures or characteristics described in conjunction with the embodiment. Therefore, the statements "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. that appear in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways. The terms "including", "comprising", "having" and their variations all mean "including but not limited to", unless otherwise specifically emphasized in other ways.
[0058] It should be understood that the order of execution of the steps in the following embodiments does not imply a precedence of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.
[0059] In order to illustrate the technical solution of the present invention, specific embodiments are provided below for illustration.
[0060] The data calibration method provided by the embodiment of the present invention can be applied in Figure 1 In the data calibration system, the data calibration system includes a data calibration device and a plurality of vehicle-mounted devices (vehicle-mounted device 1, vehicle-mounted device n, where n is an integer greater than 1) on the vehicle. Each vehicle-mounted device can communicate with the data calibration device through a network or a bus.
[0061] Among them, the storage space of each vehicle-mounted device includes a readable but not writable flash memory FLASH storage space and a readable and writable random access memory RAM storage space. The Flash storage space of each vehicle-mounted device includes a Flash data area and a Flash pointer area; the Flash data area stores data blocks for realizing various types of vehicle performance, and the Flash pointer area is a pointer area of the Flash data area. The Flash pointer area stores the storage address of each data block in the Flash data area, and is used to locate the corresponding data block in the Flash data area based on the storage address of each data block in the Flash data area. The RAM storage space of the vehicle-mounted device includes a RAM data area and a RAM pointer area. The RAM data area stores the data blocks to be calibrated in the Flash data area. The RAM pointer area is a pointer area of the RAM data area. The RAM pointer area stores the storage address of each data block in the RAM data area, and is used to locate the corresponding data block in the RAM data area based on the storage address of each data block in the RAM data area, that is, locate each data block to be calibrated in the RAM data area. The Flash pointer area and the RAM pointer area establish a mapping relationship by overlapping addresses; that is, the Flash pointer area and the RAM pointer area form an overlay functional area.
[0062] When receiving a calibration command for a target vehicle-mounted device (i.e., a vehicle-mounted device that currently needs to be calibrated), the calibration command is parsed to obtain the target address of the data to be calibrated, and the first data block corresponding to the target address in the Flash data area is located through the Flash pointer area of the target vehicle-mounted device. The Flash pointer area stores the storage addresses of all data blocks in the Flash data area. Then, the second data block stored in the RAM data area of the target vehicle-mounted device is located through the RAM pointer area that has a mapping relationship with the Flash pointer area; wherein the second data block is a data block obtained after the first database is stored in the RAM data area, that is, the information of the first data block and the second data block is the same. Finally, based on the data to be calibrated and the second data block in the RAM data area, the first data block in the Flash data area is calibrated.
[0063] like Figure 2 As shown, when accessing the data in the Flash data area and RAM data area of the target vehicle-mounted device, the access is performed through the pointer in the pointer area, rather than by querying the data block to be calibrated itself. This pointer variable method provides convenience for double-page calibration. When there is no calibration requirement for the target vehicle-mounted device, the pointer in the Flash pointer area points to (locates to) the data block to be accessed in the Flash data area. When there is a calibration requirement, that is, when the data of the target vehicle-mounted device needs to be calibrated, the reference page and the calibration page are switched by assigning a value to the pointer, that is, switching from the Flash pointer area to the RAM pointer area mapped thereto, and then pointing to (locating to) the data block to be calibrated in the RAM data area through the RAM pointer area pointer (the data block is taken out of the Flash data area), so that the data block to be calibrated can be modified and adjusted in the RAM data area until the calibration work is completed. This method can only perform overlay processing on the address pointer of the calibrated data block, greatly optimizing the use of overlay RAM, allowing the RAM pointer area to store a large number of data address values, increasing the data storage capacity of the RAM pointer area, and solving the problem of low RAM storage capacity due to overlay resource limitations.
[0064] In this embodiment, an indirect mapping relationship is established between the Flash data area and the RAM data area through the mapping relationship between the Flash pointer area and the RAM pointer area. Different from the way in which the overlay functional area stores calibration data blocks in the traditional XCP calibration process, the overlay functional area of this embodiment, namely the Flash pointer area and the RAM pointer area, can store address values of multiple data blocks, effectively reducing the situation where the RAM storage capacity is not high due to overlay resource limitations, so that data calibration work with large amounts of data can be performed based on the Flash pointer area and the RAM pointer area, effectively improving the efficiency of data calibration.
[0065] The vehicle-mounted device may be a microcontroller unit (MCU) on the vehicle, or an electronic control unit (ECU) on the vehicle. The data calibration device may be other devices on the vehicle except the target vehicle-mounted device. In other embodiments, the data calibration device may also be a device in the vehicle-mounted device, that is, the execution subject of the data calibration method may be the target vehicle-mounted device.
[0066] The data calibration system including the data calibration device and multiple vehicle-mounted devices is only an exemplary description. In other embodiments, the data calibration system may also include other devices, such as a host computer, which is used to send calibration commands to the target terminal device.
[0067] In one embodiment, if Figure 3 As shown, a data calibration method is provided, which is applied in Figure 1 The data calibration device is taken as an example to illustrate, including the following steps:
[0068] S10: When a calibration command for a target vehicle-mounted device is received, the calibration command is parsed to obtain a target address of the data to be calibrated.
[0069] When it is necessary to calibrate the data of the target vehicle-mounted device, that is, when it is necessary to adjust and optimize the operation and parameter algorithms of the target vehicle-mounted device on the vehicle to optimize the performance of the vehicle, a calibration command for the target vehicle-mounted device is sent through the host computer. The calibration command usually contains the calibration content of the corresponding data block in the target vehicle-mounted device, and the calibration content includes information such as the data to be calibrated and the target address of the data to be calibrated. The data to be calibrated is the relevant parameter data in the data block to be calibrated in the Flash data area of the target vehicle-mounted device. The data to be calibrated is usually the performance parameters of the vehicle, such as parameters related to the vehicle's drivability, power, economy and other performance. The target address of the data to be calibrated is the specific address of the data to be calibrated in the Flash data area.
[0070] When receiving a calibration command sent by the host computer, the calibration command is usually an encrypted command, so the data calibration device needs to parse the calibration command to obtain the data to be calibrated in the calibration command and the target address of the data to be calibrated.
[0071] S20: Locate and obtain a first data block corresponding to a target address in a Flash data area by marking a Flash pointer area of the vehicle-mounted device.
[0072] It should be understood that the Flash storage space of the target vehicle-mounted device includes a Flash data area and a Flash pointer area; the Flash pointer area stores the storage address of each data block in the Flash data area, and the corresponding data block in the Flash data area can be quickly located through the pointer in the Flash pointer area. The RAM storage space of the vehicle-mounted device includes a RAM data area and a RAM pointer area; the RAM data area is used to store the data blocks that need to be calibrated in the Flash data area, and the RAM pointer area stores the storage address of each data block in the RAM data area, and the second data block in the RAM data area can be quickly located through the pointer in the RAM pointer area. The Flash pointer area and the RAM pointer area establish a mapping relationship by address overlay.
[0073] After determining the target address of the data to be calibrated in the calibration command, the data calibration device will locate the first data block corresponding to the target address in the Flash data area of the target vehicle-mounted device through the Flash pointer area of the target vehicle-mounted device, that is, locate the data block where the target address is located in the Flash data area as the first data block, and the first data block is the data block that needs to be calibrated. For example, the target address can be directly input into the Flash pointer area, so that the pointer of the Flash pointer area directly points to (locates) the data block where the target address is located in the Flash data area, and the first data block can be obtained.
[0074] S30: Determine a second data block stored in the RAM data area of the target vehicle-mounted device through the RAM pointer area having a mapping relationship with the Flash pointer area.
[0075] After determining the first data block corresponding to the target address in the Flash data area, the data calibration device needs to determine the second data block stored in the RAM data area of the target vehicle-mounted device through the RAM pointer area in the target vehicle-mounted device that has a mapping relationship with the Flash pointer area. The second data block is a data block obtained after the first database is stored in the RAM data area, that is, the information of the first data block and the second data block is the same.
[0076] S40: Calibrate the first data block in the Flash data area based on the data to be calibrated and the second data block in the RAM data area.
[0077] After determining the second data block stored in the RAM data area, the data calibration device calibrates the first data block in the Flash data area of the target vehicle-mounted device based on the data to be calibrated and the second data block in the RAM data area. For example, based on the data to be calibrated, the corresponding data of the target second data block in the RAM data area is modified and adjusted until the second data block meets the calibration requirements, and the second data block (i.e., the target data block) that meets the requirements is written into the Flash data area to replace the original first data block in the Flash data area, and the calibration work is completed.
[0078] In this embodiment, when it is necessary to calibrate the data of the target vehicle-mounted device, the calibration command is parsed to obtain the target address of the data to be calibrated, and the first data block corresponding to the target address in the Flash data area is located through the Flash pointer area of the target vehicle-mounted device, and then the data block (i.e., the second data block) to be calibrated in the RAM data area is located through the RAM pointer area, so that the second data block is modified and adjusted in the RAM data area based on the data to be calibrated until the calibration work is completed. Through the mapping relationship between the Flash pointer area and the RAM pointer area, an indirect mapping relationship is established between the Flash data area and the RAM data area. Different from the way in which the overlay function area stores the calibration data block in the traditional XCP calibration process, the overlay function area of this embodiment, i.e., the Flash pointer area and the RAM pointer area, can store the address values of multiple data blocks, effectively reducing the situation where the RAM storage capacity is not high due to the limitation of overlay resources, so that the data calibration work of large amounts of data can be performed based on the Flash pointer area and the RAM pointer area, effectively improving the efficiency of data calibration.
[0079] In one embodiment, before step S10, that is, before parsing the calibration command to obtain the target address of the data to be calibrated, the method further specifically includes the following steps:
[0080] S101: storing the data of each data block in a Flash data area in a structured manner, and storing the first address of each data block in the Flash data area in a Flash pointer area.
[0081] In this embodiment, the storage space of the vehicle-mounted device includes a readable but non-writable flash memory Flash storage space and a readable and writable random access memory RAM storage space. Before parsing the calibration command to obtain the target address of the data to be calibrated, that is, before receiving the calibration command for the target vehicle-mounted device, the relevant personnel (developers) need to divide the Flash storage space and RAM storage space of each vehicle-mounted device. The data calibration device will mark the Flash storage space of each vehicle-mounted device with different types according to the division instruction (division result), and obtain the Flash data area and the Flash pointer area by marking, and mark the RAM storage space of each vehicle-mounted device with different types to obtain the RAM data area and the RAM pointer area.
[0082] Specifically, it is necessary to divide the Flash and RAM storage space of the target vehicle-mounted device according to the requirements of each project to obtain the Flash data area and RAM data area used for data calibration. Then, according to the Overlay resources (usually 8k) of the target vehicle-mounted device, divide an area from the Flash storage space and RAM storage space respectively for address overlap to obtain the Flash pointer area and RAM pointer area.
[0083] Based on the above marking results, the Flash storage space of each on-board device on the vehicle (including the target on-board device) includes a Flash data area and a Flash pointer area, and the RAM storage space of each on-board device on the vehicle includes a RAM data area and a RAM pointer area.
[0084] Then, the data of each data block related to each vehicle-mounted device (including the target vehicle-mounted device) on the vehicle is stored in the Flash data area in the form of a structure, and the first address of each data block in the Flash data area is stored in the Flash pointer area. Storing each data block in the form of a structure can greatly increase the number of address pointers stored in the pointer area.
[0085] After storing the first address of each data block in the Flash data area of each on-board device (including the target on-board device) on the vehicle into the Flash pointer area, determine the unused area in the Flash data area and the Flash pointer area of each on-board device (such as the target on-board device), and then fill the unused area in the Flash data area and the Flash pointer area with preset bytes, such as filling the hexadecimal byte C3, that is, filling the unused area in the Flash data area and the Flash pointer area with 0xC3, until all areas in the Flash data area and the Flash pointer area are filled respectively, so as to facilitate the subsequent reading of the data block and the first address of the data block.
[0086] S102: Establishing a mapping relationship between the Flash pointer area and the RAM pointer area by using an address overlap method.
[0087] After the first address of each data block in the Flash data area is stored in the Flash pointer area, an address overlay method is adopted, that is, the Overlay function is used to establish a mapping relationship between the Flash pointer area and the RAM pointer area.
[0088] In this embodiment, before determining the target address of the data to be calibrated in the calibration command, the data of each data block is stored in the Flash data area in the form of a structure, and the first address of each data block in the Flash data area is stored in the Flash pointer area, and finally the mapping relationship between the Flash pointer area and the RAM pointer area is established by overlapping the addresses. Through the mapping relationship between the Flash pointer area and the RAM pointer area, an indirect mapping relationship is established for the Flash data area and the RAM data area, so that the Flash data area and the RAM data area are responsible for the storage of the calibration data block, and the Flash pointer area and the RAM pointer area are responsible for the address storage of the data block, which effectively reduces the situation where the RAM storage capacity is not high due to the limitation of overlay resources, thereby providing a basis for the subsequent data calibration work of large amounts of data.
[0089] In one embodiment, the storage addresses stored in the Flash pointer area and the RAM pointer area may be the first addresses of each data block. That is, the Flash pointer area may store the first addresses of each data block in the Flash data area; the RAM pointer area stores the first addresses of each data block in the RAM data area. The pointer area only stores the first addresses of the data blocks in the corresponding data area, which can effectively reduce the length of the address value and further increase the data storage capacity of the Flash pointer area and the RAM pointer area, thereby further reducing the dependence on overlay resources, thereby performing data calibration work with a larger amount of data and improving the efficiency of data calibration.
[0090] In one embodiment, the Flash pointer area may store the first address of each data block in the Flash data area. Figure 4 As shown, in step S20, namely, determining the first data block corresponding to the target address in the Flash data area through the Flash pointer area of the target vehicle-mounted device, specifically includes the following steps:
[0091] S21: Determine the first address of the first data block in the Flash data area to obtain the Flash first address;
[0092] S22: inputting the Flash first address into the Flash pointer area, so that the Flash pointer area locates the first data block in the Flash data area based on the Flash first address.
[0093] In this embodiment, the Flash pointer area can store the first address of each data block in the Flash data area. After determining the first data block corresponding to the target address in the Flash data area, the data calibration device needs to determine the first address of the first data block in the Flash data area to obtain the Flash first address. Among them, the first address of each data block in the Flash data area can be pre-stored in the target vehicle-mounted device; after determining the first data block corresponding to the target address in the Flash data area, the first address of the first data block in the Flash data area can be directly read from the target vehicle-mounted device to obtain the Flash first address of the first data block. Then, the Flash first address is input into the Flash pointer area so that the pointer of the Flash pointer area points to the first data block corresponding to the Flash first address in the Flash data area, and the first data block can be quickly read, that is, the Flash pointer area can quickly locate the first data block in the Flash data area based on the Flash first address.
[0094] Afterwards, the data calibration device copies the first data block in the Flash data area and stores it in the RAM data area of the target vehicle-mounted device to obtain the second data block, and then records the first address of the second data block in the RAM data area to obtain the RAM first address of the second data block, so that the RAM first address of the second data block can be subsequently input into the RAM pointer area, thereby locating the second data block in the RAM data area through the RAM pointer area, thereby executing the calibration action of the second data block to realize the calibration of the first data block.
[0095] In this embodiment, the first address of the first data block in the Flash data area is determined to obtain the Flash first address, and then the Flash first address is input into the Flash pointer area, so that the Flash pointer area locates the second data block in the Flash data area based on the Flash first address, and the step of locating the first data block is refined. The first address of each data block in the Flash data area is stored in the Flash pointer area, and then the first address can be directly input later to locate the first data block in the Flash data area, which is simple and fast, and the pointer area only stores the first address of the data block in the corresponding data area, which can effectively reduce the length of the address value and further increase the data storage capacity of the Flash pointer area and the RAM pointer area.
[0096] In one embodiment, step S21, that is, determining the first address of the first data block in the Flash data area, recorded as the Flash first address, specifically includes the following steps:
[0097] S211: Read the first addresses and data sizes of all data blocks in the Flash data area from the pre-stored Flash data block information.
[0098] After determining the target address of the data to be calibrated in the calibration command, the data calibration device needs to obtain the Flash data block information pre-stored in the target vehicle-mounted device, and the Flash data block information records the first address and data size of all data blocks in the Flash data area. The data calibration device needs to read the first address and data size of all data blocks in the Flash data area from the pre-stored Flash data block information.
[0099] In this embodiment, after each data block is stored in the Flash data area of the target vehicle-mounted device, the first address and data size of each data block in the Flash data area need to be updated to the Flash data block information, and the Flash data block information is stored in the target vehicle-mounted device for subsequent direct use.
[0100] S212: Matching each data block based on the target address, the first address of each data block and the data size, and obtaining a first data block by matching.
[0101] Then, the data calibration device needs to match each data block based on the target address, the first address and data size of each data block, so as to match and obtain the first data block. According to the first address and data size of each data block, the storage address range of each data block, that is, the first address and the last address of each data block, can be known. At this time, the target address can be matched with the storage address range of each data block. If the target address falls within the storage address range of the data block, the data block is the data block where the target address is located, that is, the data block is the first data block to be calibrated.
[0102] Finally, the first address of the first data block obtained by matching in the Flash data block information in the Flash data area can be directly recorded as the Flash first address, that is, the Flash first address is the first address of the first data block in the Flash data area.
[0103] In other embodiments, the Flash data block information may also record the starting address and the ending address of all data blocks in the Flash data area, and then match each data block based on the target address, the starting address and the ending address of each data block to obtain the first data block, thereby obtaining the starting address of the first data block in the Flash data area, that is, the Flash starting address.
[0104] In this embodiment, by reading the first address and data size of all data blocks in the Flash data area from the pre-stored Flash data block information, and then matching each data block based on the target address, the first address and data size of each data block, the first data block is matched, and the first address of the first data block in the Flash data area is obtained, that is, the Flash first address is obtained, and the specific steps for obtaining the Flash first address are clarified. This process is convenient for subsequent direct use of the target address for matching by pre-storing the first address and data size of all data blocks in the Flash data area, which is simple and convenient, and is convenient for subsequent data reading based on the first address, and can also reduce the amount of data occupied by the Flash data block information.
[0105] In one embodiment, before step S10, that is, before parsing the calibration command to obtain the target address of the data to be calibrated, the method further specifically includes the following steps:
[0106] S01: When the target vehicle-mounted device is powered on, the data in the Flash data area is read through the Flash pointer area to obtain the first addresses of all data blocks in the Flash data area.
[0107] Each time the target vehicle-mounted device is powered on, the data standard device needs to read the data in the Flash data area through the Flash pointer area to obtain the first address of all data blocks in the Flash data area. Among them, first read a fixed number of bytes (such as 4 bytes) of data from the first address of the Flash pointer area (the Flash pointer area stores the first addresses of all data blocks in the Flash, and each first address is a fixed number of bytes) until the preset bytes (such as 0xC3C3C3C3) are read. By reading the first address data of the Flash pointer area, it is possible to determine how many data blocks there are in the Flash data area and the first address of each data block.
[0108] S02: sorting the first addresses of each data block in ascending order, and determining the data size of each data block according to two adjacent first addresses.
[0109] After obtaining the first addresses of all data blocks in the Flash data area, the first addresses of the data blocks are sorted in ascending order, and the data size of each data block is determined based on two adjacent first addresses.
[0110] Among them, the data size of the last data block needs to be calculated. Since the unused area of the Flash data area will be filled with the preset byte C3, the filled preset byte C3 can be used to determine the data size of the last data block. Specifically, it is necessary to read the data of the last data block in the Flash data area according to the first address of the last data block, and read from the first address of the last data block to the preset byte, indicating that the reading of the last data block is completed, and the data size of the last data block is obtained.
[0111] S03: Summarize the first address and data size of each data block to obtain Flash data block information and store it.
[0112] After obtaining the first addresses and data sizes of all data blocks, the first addresses and data sizes of each data block are summarized to obtain the Flash data block information and store it in the target vehicle-mounted device for subsequent calling.
[0113] In other embodiments, the data size may not be determined through the Flash pointer area, but the starting address of each data block may be determined through the Flash pointer area, and then data is read based on the starting address of each data block to obtain the data size of each data block, thereby summarizing the starting address and data size of each data block to obtain and store the Flash data block information.
[0114] In this embodiment, when the target vehicle-mounted device is powered on, the data in the Flash data area is read through the Flash pointer area to obtain the first addresses of all data blocks in the Flash data area, and then the first addresses of each data block are sorted in ascending order, and the data size of each data block is determined based on two adjacent first addresses, and the first address and data size of each data block are summarized to obtain and store the Flash data block information. The determination process of the Flash data block information is clarified, and the first address and data size of each data block in the Flash data area are determined through the Flash pointer area, which is simple and convenient, reducing the frequent reading operations on the Flash data area, thereby reducing the load of the Flash data area.
[0115] In one embodiment, the RAM pointer area may store the first address of each data block in the RAM data area. Figure 5 As shown, in step S30, namely, determining the second data block stored in the RAM data area of the target vehicle-mounted device through the RAM pointer area having a mapping relationship with the Flash pointer area, specifically includes the following steps:
[0116] S31: Determine the first address of the second data block in the RAM data area, recorded as the RAM first address;
[0117] S32: Inputting the RAM first address into the RAM pointer area, so that the RAM pointer area locates the second data block in the RAM data area based on the RAM first address.
[0118] In this embodiment, when the first data block is stored in the RAM data area to obtain the second data block, the first address of the second data block in the RAM data area will be recorded and stored. After determining the first data block corresponding to the target address in the Flash data area, the first address of the corresponding second data block in the RAM data area will be determined to obtain the RAM first address, and then a page switching operation is performed to switch from the Flash pointer area to the RAM pointer area mapped thereto, and the RAM first address is input into the RAM pointer area. The pointer in the RAM pointer area directly points to the second data block of the RAM first address in the RAM data area, and the second data block can be quickly read, that is, the RAM pointer area is based on the RAM first address to quickly locate the second data block in the RAM data area.
[0119] In this embodiment, the first address of the second data block in the RAM data area is determined and recorded as the RAM first address, and then the RAM first address is input into the RAM pointer area, so that the RAM pointer area locates the second data block in the RAM data area based on the RAM first address. The specific acquisition process of the second data block in the RAM data area is clarified, and the first address of the second data block to be calibrated is directly input into the RAM pointer area, so that the second data block in the RAM data area can be quickly located, which is convenient for subsequent modification and adjustment operations on the second data block in the RAM data area, so as to efficiently complete the calibration work.
[0120] In one embodiment, before step S31, that is, before determining the first address of the second data block in the RAM data area, the method further specifically includes the following steps:
[0121] S33: Read the first data block in the Flash data area;
[0122] S34: After storing the first data block in the RAM data area, a second data block is obtained, and a first address of the second data block in the RAM data area is recorded.
[0123] After determining the second data block corresponding to the target address in the Flash data area of the target vehicle-mounted device, it is necessary to determine whether the RAM data area of the target vehicle-mounted device stores the second data block corresponding to the first data block, that is, to determine whether the RAM data area of the target vehicle-mounted device stores a second data block that is exactly the same as the first data block. If the RAM data area stores the second data block (such as the first data block was previously stored in the RAM data area and the target vehicle-mounted device is not powered off), determine the first address of the second data block in the RAM data area, record it as the RAM first address, and then perform a page switching operation, switch from the Flash pointer area to the RAM pointer area mapped thereto, and input the RAM first address into the RAM pointer area, so that the RAM pointer area locates the second data block in the RAM data area based on the RAM first address.
[0124] If the second data block is not stored in the RAM data area, the first data block is read and copied from the Flash data area, and the first data block is stored in the RAM data area to obtain the second data block. Then, the first address of the second data block in the RAM data area is recorded and stored, so as to perform a page switching operation later, and the RAM first address is directly input into the RAM pointer area, so that the RAM pointer area locates the second data block in the RAM data area based on the RAM first address.
[0125] In this embodiment, the first data block in the Flash data area is read, and the second data block is obtained after the first data block is stored in the RAM data area, and the first address of the second data block in the RAM data area is recorded, so that the first address of the second data block in the RAM data area can be directly input into the RAM pointer area, so as to quickly locate and obtain the second data block in the RAM data area through the pointer, and then modify and adjust the second data, thereby completing the calibration operation.
[0126] In one embodiment, if Figure 6 As shown, step S40, i.e., calibrating the first data block in the Flash data area based on the data to be calibrated and the second data block in the RAM data area, specifically includes the following steps:
[0127] S41: Based on the target address, determine the writing position of the data to be calibrated in the second data block.
[0128] After determining the second data block stored in the RAM data area, the write position of the data to be calibrated in the second data block in the RAM data area is determined based on the target address of the data to be calibrated and the first address of the second data block in the Flash data area.
[0129] Specifically, it is necessary to first determine the address offset between the Flash starting address and the target address, that is, determine the address offset between the starting address and the target address of the second data block in the Flash data area; then, based on the RAM starting address and the address offset, determine the write position of the data to be calibrated in the second data block in the RAM data area, that is, offset the address offset after the starting address of the second data block in the RAM data area, and you can get the write position of the data to be calibrated in the second data block in the RAM data area.
[0130] S42: Write the data to be calibrated at the writing position in the second data block to obtain a target data block.
[0131] S43: Replace the first data block in the Flash data area with the target data block that meets the calibration requirements.
[0132] Then, the data to be calibrated is written to the write position in the second data block of the RAM data area to obtain a new second data block, i.e., the target data block, and finally, the target data block that meets the calibration requirements replaces the first data block in the Flash data area. That is, the target data block that meets the calibration requirements in the RAM data area is copied and written to the Flash data area, and then the original target data block in the Flash data area is deleted, and the calibration work is completed at this time.
[0133] In this embodiment, based on the target address, the writing position of the data to be calibrated in the second data block is determined, and then the data to be calibrated is written in the writing position in the second data block to obtain the target data block. Then, the target data block that meets the calibration requirements replaces the first data block in the Flash data area. This process clarifies the specific process of calibrating the first data block in the Flash data area. The writing position of the data to be calibrated in the second data block can be quickly determined through the target address, and then the writing of the data to be calibrated is completed. It is simple and convenient, and the data calibration work can be completed quickly, improving the calibration efficiency.
[0134] In a specific embodiment, a data calibration method is provided, and the complete steps of the data calibration method are as follows:
[0135] S1: storing the data of each data block in the Flash data area of the target vehicle-mounted device in the form of a structure, and storing the first address of each data block in the Flash data area to the Flash pointer area of the target vehicle-mounted device, and establishing a mapping relationship between the Flash pointer area of the target vehicle-mounted device and the RAM pointer area of the target vehicle-mounted device by using an address overlap method;
[0136] S3: When receiving a calibration command for the target vehicle-mounted device, parsing the calibration command to obtain a target address of the data to be calibrated;
[0137] S4: Determine the first address of the first data block corresponding to the target address in the Flash data area through the pre-stored Flash data block information, and record it as the Flash first address;
[0138] S5: inputting the Flash first address into the Flash pointer area, so that the Flash pointer area locates the first data block in the Flash data area based on the Flash first address;
[0139] S6: copying and storing the first data block in the Flash data area to the RAM data area to obtain the second data block in the RAM data area, and recording the first address of the second data block in the RAM data area as the RAM first address;
[0140] S7: Execute a page switching operation, switch from the Flash pointer area to the RAM pointer area having a mapping relationship therewith, input the RAM first address into the RAM pointer area, so that the RAM pointer area locates the second data block in the RAM data area based on the RAM first address;
[0141] S8: determining the address offset between the Flash first address and the target address, and determining the write position of the data to be calibrated in the second data block based on the RAM first address and the address offset;
[0142] S9: writing the data to be calibrated in the write position of the second data block to obtain a target data block, and replacing the first data block in the Flash data area with the target data block that meets the calibration requirements.
[0143] In this embodiment, when it is necessary to calibrate the data of the target vehicle-mounted device, the calibration command is parsed to obtain the target address of the data to be calibrated, and the first data block corresponding to the target address in the Flash data area of the target vehicle-mounted device is determined through the Flash pointer area of the target vehicle-mounted device, and then the Flash pointer area is switched to the RAM pointer area mapped thereto, and the second data block to be calibrated in the RAM data area of the target vehicle-mounted device is located through the RAM pointer area, so that the second data block is modified and adjusted in the RAM data area based on the data to be calibrated until the calibration work is completed. Through the mapping relationship between the Flash pointer area and the RAM pointer area, an indirect mapping relationship is established between the Flash data area and the RAM data area. Different from the way in which the overlay function area stores the calibration data block in the traditional XCP calibration process, the overlay function area of this embodiment, i.e., the Flash pointer area and the RAM pointer area, can store the address values of multiple data blocks, effectively reducing the situation where the RAM storage capacity is not high due to the limitation of overlay resources, so that the data calibration work of large amounts of data can be performed based on the Flash pointer area and the RAM pointer area, and the efficiency of data calibration is effectively improved.
[0144] It should be understood that the order of execution of the steps in the above embodiment does not necessarily mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present invention.
[0145] In one embodiment, a data calibration device is provided, which corresponds one-to-one to the data calibration method in the above embodiment. Figure 7 As shown, the data calibration device includes a parsing module 701, a first positioning module 702, a second positioning module 703 and a calibration module 704. Each functional module is described in detail as follows:
[0146] The parsing module 701 is used to parse the calibration command to obtain the target address of the data to be calibrated when receiving the calibration command for the target vehicle-mounted device;
[0147] A first positioning module 702 is used to determine a first data block corresponding to a target address in a Flash data area through a Flash pointer area of a target vehicle-mounted device;
[0148] The second positioning module 703 is used to determine the second data block stored in the RAM data area of the target vehicle-mounted device through the RAM pointer area having a mapping relationship with the Flash pointer area;
[0149] The calibration module 704 is used to calibrate the first data block in the Flash data area based on the data to be calibrated and the second data block in the RAM data area.
[0150] Optionally, the first positioning module 702 is specifically configured to:
[0151] Determine the first address of the first data block in the Flash data area to obtain the Flash first address;
[0152] The Flash first address is input into the Flash pointer area, so that the Flash pointer area locates the first data block in the Flash data area based on the Flash first address.
[0153] Optionally, the first positioning module 702 is further specifically configured to:
[0154] Read the first address and data size of all data blocks in the Flash data area from the pre-stored Flash data block information;
[0155] Based on the target address, the first address of each data block and the data size, each data block is matched to obtain the first data block; the Flash first address is the first address of the first data block in the Flash data area.
[0156] Optionally, the second positioning module 703 is specifically configured to:
[0157] Determine the first address of the second data block in the RAM data area to obtain the RAM first address;
[0158] The RAM first address is input into the RAM pointer area so that the RAM pointer area locates the second data block in the RAM data area based on the RAM first address.
[0159] Optionally, the data calibration device further includes a storage module 705, which determines that the second data block is before the first address of the RAM data area, and the storage module 705 is used to:
[0160] Read the first data block in the Flash data area;
[0161] The first data block is stored in the RAM data area to obtain the second data block, and the first address of the second data block in the RAM data area is recorded.
[0162] Optionally, the calibration module 704 is specifically used for:
[0163] Based on the target address, determining a writing position of the data to be calibrated in the second data block;
[0164] Writing the data to be calibrated into the writing position of the second data block to obtain a target data block;
[0165] The target data block that meets the calibration requirements replaces the first data block in the Flash data area.
[0166] Optionally, the calibration module 704 is further configured to:
[0167] Determine the address offset between the Flash first address and the target address;
[0168] Based on the RAM first address and the address offset, the writing position of the data to be calibrated in the second data block is determined.
[0169] Optionally, before parsing the calibration command to obtain the target address of the data to be calibrated, the storage module 705 is further used to:
[0170] When the target vehicle-mounted device is powered on, the data in the Flash data area is read through the Flash pointer area to obtain the first addresses of all data blocks in the Flash data area;
[0171] Sort the first addresses of each data block in ascending order, and determine the data size of each data block based on two adjacent first addresses;
[0172] The first address and data size of each data block are summarized to obtain the Flash data block information and store it.
[0173] Optionally, before parsing the calibration command to obtain the target address of the data to be calibrated, the storage module 705 is further used to:
[0174] The data of each data block is stored in the Flash data area in the form of a structure, and the first address of each data block in the Flash data area is stored in the Flash pointer area;
[0175] The mapping relationship between the Flash pointer area and the RAM pointer area is established by using the address overlap method;
[0176] The Flash storage space of the target vehicle-mounted device includes a Flash data area and a Flash pointer area, and the RAM storage space of the target vehicle-mounted device includes a RAM data area and a RAM pointer area.
[0177] For the specific definition of the data calibration device, please refer to the definition of the data calibration method above, which will not be repeated here. Each module in the above data calibration device can be implemented in whole or in part by software, hardware and a combination thereof. The above modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.
[0178] In one embodiment, Figure 8 As shown, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the above-mentioned data calibration method are implemented.
[0179] In one embodiment, a readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the steps of the above-mentioned data calibration method are implemented.
[0180] In one embodiment, a vehicle is provided, the vehicle comprising the above-mentioned computer device and / or readable storage medium.
[0181] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be implemented by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory.
[0182] Those skilled in the art can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example. In actual applications, the above-mentioned functions can be distributed and completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above.
[0183] The embodiments described above are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be included in the protection scope of the present invention.
Claims
1. A data calibration method, characterized in that: include: When receiving a calibration command for a target vehicle-mounted device, parsing the calibration command to obtain a target address of the data to be calibrated; Locating and obtaining a first data block corresponding to the target address in the Flash data area through the Flash pointer area of the target vehicle-mounted device; Locating and obtaining a second data block stored in a RAM data area of the target vehicle-mounted device through a RAM pointer area having a mapping relationship with the Flash pointer area; Calibrate the first data block in the Flash data area based on the data to be calibrated and the second data block in the RAM data area; When receiving a calibration command for the target vehicle device: Based on the data to be calibrated in the calibration command and the target data block in the RAM data area corresponding to the target address of the data to be calibrated, calibrate the target data block in the Flash data area corresponding to the target address of the data to be calibrated; Before parsing the calibration command to obtain the target address of the data to be calibrated, the method further includes: Storing the data of each data block in a structure in the Flash data area of the target vehicle-mounted device, and storing the first address of each data block in the Flash data area in the Flash pointer area; A mapping relationship between the Flash pointer area and the RAM pointer area is established by using an address overlap method; The Flash storage space of the target vehicle-mounted device includes the Flash data area and the Flash pointer area, and the RAM storage space of the target vehicle-mounted device includes the RAM data area and the RAM pointer area.
2. The data calibration method according to claim 1, characterized in that: The method of locating a first data block corresponding to the target address in a Flash data area through a Flash pointer area of the target vehicle-mounted device includes: Determine the first address of the first data block in the Flash data area to obtain the Flash first address; The Flash first address is input into the Flash pointer area of the target vehicle-mounted device, so that the Flash pointer area locates the first data block in the Flash data area based on the Flash first address.
3. The data calibration method according to claim 2, characterized in that: The determining the first address of the first data block in the Flash data area to obtain the Flash first address includes: Reading the first address and data size of all data blocks in the Flash data area from the pre-stored Flash data block information; Based on the target address, the first address and the data size of each data block, each data block is matched to obtain the first data block, and the Flash first address is the first address of the first data block in the Flash data area.
4. The data calibration method according to claim 1, characterized in that: The method of locating a second data block stored in a RAM data area of the target vehicle-mounted device through a RAM pointer area having a mapping relationship with the Flash pointer area includes: Determine the first address of the second data block in the RAM data area of the target vehicle-mounted device to obtain the RAM first address; The RAM first address is input into the RAM pointer area of the target vehicle-mounted device, so that the RAM pointer area locates the second data block in the RAM data area based on the RAM first address.
5. The data calibration method according to claim 4, characterized in that: The determining that the second data block is before the first address of the RAM data area of the target vehicle-mounted device, the method further comprises: Reading the first data block in the Flash data area; After storing the first data block in the RAM data area, the second data block is obtained, and the first address of the second data block in the RAM data area is recorded.
6. The data calibration method according to claim 1, characterized in that: The step of calibrating the first data block in the Flash data area based on the data to be calibrated and the second data block in the RAM data area includes: Based on the target address, determining a writing position of the data to be calibrated in the second data block; Writing the data to be calibrated at a writing position in the second data block to obtain a target data block; The target data block that meets the calibration requirements replaces the first data block in the Flash data area.
7. The data calibration method according to claim 6, characterized in that: The step of determining a writing position of the data to be calibrated in the second data block based on the target address includes: Determine the address offset between the Flash first address and the target address; Based on the RAM first address and the address offset, the writing position of the data to be calibrated in the second data block is determined.
8. The data calibration method according to claim 1, characterized in that: Before parsing the calibration command to obtain the target address of the data to be calibrated, the method further includes: When the target vehicle-mounted device is powered on, the data in the Flash data area is read through the Flash pointer area to obtain the first addresses of all data blocks in the Flash data area; Sorting the first addresses of the data blocks in ascending order, and determining the data size of each data block according to two adjacent first addresses; The first address and data size of each data block are summarized to obtain Flash data block information and store it.
9. A data calibration device, characterized in that: include: A parsing module, configured to parse a calibration command for a target vehicle-mounted device to obtain a target address of the data to be calibrated when receiving the calibration command; A first positioning module, used for locating a first data block corresponding to the target address in the Flash data area through a Flash pointer area of the target vehicle-mounted device, wherein the Flash pointer area stores storage addresses of all data blocks in the Flash data area; A second positioning module, used for positioning a second data block stored in a RAM data area of a target vehicle-mounted device through a RAM pointer area having a mapping relationship with the Flash pointer area; A calibration module, used for calibrating the first data block in the Flash data area based on the data to be calibrated and the second data block in the RAM data area; Before parsing the calibration command to obtain the target address of the data to be calibrated, the device further includes: Storing the data of each data block in a structure in the Flash data area of the target vehicle-mounted device, and storing the first address of each data block in the Flash data area in the Flash pointer area; A mapping relationship between the Flash pointer area and the RAM pointer area is established by using an address overlap method; The Flash storage space of the target vehicle-mounted device includes the Flash data area and the Flash pointer area, and the RAM storage space of the target vehicle-mounted device includes the RAM data area and the RAM pointer area.
10. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the data calibration method according to any one of claims 1 to 8 are implemented.
11. A readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of the data calibration method according to any one of claims 1 to 8 are implemented.
12. A vehicle, characterized in that: Includes the computer device as claimed in claim 10, or the readable storage medium as claimed in claim 11.
Citation Information
Patent Citations
Full-address calibration method and system supporting oversized calibration data volume
CN109656607A
