CN116450059B - Data management method, apparatus, electronic device, storage medium, and program product - Google Patents

Data management method, apparatus, electronic device, storage medium, and program product Download PDF

Info

Publication number
CN116450059B
CN116450059B CN202310729979.5A CN202310729979A CN116450059B CN 116450059 B CN116450059 B CN 116450059B CN 202310729979 A CN202310729979 A CN 202310729979A CN 116450059 B CN116450059 B CN 116450059B
Authority
CN
China
Prior art keywords
data
target
writing
area
fixed address
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202310729979.5A
Other languages
Chinese (zh)
Other versions
CN116450059A (en
Inventor
冯伟龙
吴顺利
席明
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Contemporary Amperex Technology Co Ltd
Original Assignee
Contemporary Amperex Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Contemporary Amperex Technology Co Ltd filed Critical Contemporary Amperex Technology Co Ltd
Priority to CN202310729979.5A priority Critical patent/CN116450059B/en
Publication of CN116450059A publication Critical patent/CN116450059A/en
Application granted granted Critical
Publication of CN116450059B publication Critical patent/CN116450059B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0614Improving the reliability of storage systems
    • G06F3/0619Improving the reliability of storage systems in relation to data integrity, e.g. data losses, bit errors
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0638Organizing or formatting or addressing of data
    • G06F3/0644Management of space entities, e.g. partitions, extents, pools
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/0671In-line storage system
    • G06F3/0673Single storage device
    • G06F3/0679Non-volatile semiconductor memory device, e.g. flash memory, one time programmable memory [OTP]
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)

Abstract

The application relates to a data management method, apparatus, electronic device, storage medium and program product. The method comprises the following steps: determining a data category of target write data; writing the target writing data into a target storage space according to the data type of the target writing data; the target storage space comprises a fixed address area or a common data area, wherein the fixed address area is an area for storing data according to a physical address and is used for storing offline data, and the common data area is an area for storing data according to a storage block configured according to an automobile open system architecture and is used for storing common data. By adopting the method, the data loss risk can be reduced, and the data storage reliability can be improved.

Description

Data management method, apparatus, electronic device, storage medium, and program product
Technical Field
The present invention relates to the field of data management technologies, and in particular, to a data management method, apparatus, electronic device, storage medium, and program product.
Background
AUTOSAR (AUTomotive Open System Architecture, automobile open System architecture) is a consortium that is dedicated to the development of automobile electronics software standards. In the software architecture of the AUTOSAR, the NvM (Non volatile Manager, management module of nonvolatile data) can manage and maintain nonvolatile RAM data (NVRAM).
In some scenarios, there is a risk of losing important data maintained by NvM.
Disclosure of Invention
Based on the above problems, the present application provides a data management method, apparatus, electronic device, storage medium, and program product, capable of reducing the risk of losing important data.
In a first aspect, the present application provides a data management method, applied to an open system architecture of an automobile, where the method includes: determining a data category of target write data; writing the target writing data into the target storage space according to the data type of the target writing data; the target storage space comprises a fixed address area or a common data area, wherein the fixed address area is an area for storing data according to a physical address and is used for storing offline data, and the common data area is an area for storing data according to a storage block configured according to an automobile open system architecture and is used for storing common data.
In the technical scheme of the embodiment of the application, the fixed address cannot be changed due to software iteration, so that the data written into the fixed address area cannot be lost due to the software iteration, the risk of data loss is reduced, and the reliability of data storage is improved.
In some embodiments of the present application, writing the target write data into the target storage space according to the data type of the target write data includes: and writing the target writing data into the fixed address area under the condition that the data type represents that the target writing data is the offline data. In the technical scheme of the embodiment of the application, since the physical address of the fixed address area is fixed, the storage position of the target write-in data cannot be changed due to different software iteration and configuration of an automobile open system architecture, so that the reliability of data storage is higher and the risk of data loss is lower.
In some embodiments of the present application, the writing the target write data into the fixed address area includes: determining a target physical address corresponding to target write data according to the first configuration information; the first configuration information comprises a corresponding relation between the type of the written data and a physical address in the fixed address area; and writing the target writing data into the area corresponding to the target physical address in the fixed address area. In the technical scheme of the embodiment of the application, the first configuration information is preset, and when the offline data is written, the data writing operation can be rapidly and accurately performed according to the first configuration information, so that the writing efficiency of the offline data is improved.
In some embodiments of the present application, the writing the target write data into the area corresponding to the target physical address in the fixed address area includes: and calling a driving interface of the fixed address area, and writing the target writing data into an area corresponding to the target physical address in the fixed address area. In the technical scheme of the embodiment of the application, the driving interface of the fixed address area is adopted for writing, so that the accuracy of data writing can be improved.
In some embodiments of the present application, writing the target write data into the target storage space according to the data type of the target write data includes: and writing the target writing data into the common data area under the condition that the data category characterizes the target writing data as the common data. According to the technical scheme, the common data is written into the common data area, and the storage mode of the automobile open system architecture is adopted, so that development difficulty can be reduced, and development workload is reduced.
In some embodiments of the present application, the writing the target write data into the normal data area includes: determining a target storage block corresponding to the target writing data according to the second configuration information; the second configuration information comprises a corresponding relation between the type of the written data and the storage block in the common data area; and writing the target writing data into the target storage block. In the technical scheme of the embodiment of the application, the second configuration information is preset, and when the common data is written, the data writing operation can be rapidly and accurately performed according to the second configuration information, so that the writing efficiency of the common data is improved.
In some embodiments of the present application, the writing the target write data into the target storage block includes: and writing the target writing data into the target storage block through a driving interface configured by the automobile open system architecture. According to the technical scheme, the data writing is performed by adopting the driving interface configured by the automobile open system architecture, so that the accuracy of the data writing can be improved.
In some embodiments of the present application, the method further comprises: under the condition that a real-time write demand instruction is acquired, detecting the state of a bus; in the case where the bus is in an idle state, the step of determining the data type of the target write data is performed. In the technical scheme of the embodiment of the application, the bus state is detected, the writing operation can be reduced, and the bus blockage is avoided.
In a second aspect, the present application further provides a data management device, applied to an open system architecture of an automobile, where the device includes:
the type determining module is used for determining the data type of the target writing data;
the data writing module is used for writing the target writing data into the target storage space according to the data type of the target writing data; the target storage space comprises a fixed address area or a common data area, wherein the fixed address area is an area for storing data according to a physical address and is used for storing offline data, and the common data area is an area for storing data according to a storage block configured according to an automobile open system architecture and is used for storing common data.
In a third aspect, the present application further provides an electronic device comprising a memory storing a computer program and a processor implementing the method of the first aspect when executing the computer program.
In a fourth aspect, the present application also provides a computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the method of the first aspect.
In a fifth aspect, the present application also provides a computer program product comprising a computer program which, when executed by a processor, implements the method of the first aspect.
Drawings
Various other advantages and benefits will become apparent to those of ordinary skill in the art upon reading the following detailed description of the alternative embodiments. The drawings are only for purposes of illustrating alternative embodiments and are not to be construed as limiting the application. Also, like reference numerals are used to designate like parts throughout the accompanying drawings. In the drawings:
FIG. 1 is a schematic diagram of an application environment for data management according to an embodiment of the present application;
FIG. 2 is a flow chart of a method of data management according to an embodiment of the present application;
FIG. 3 is a flowchart illustrating a step of writing target write data to a fixed address area according to an embodiment of the present application;
FIG. 4 is a schematic diagram of a correspondence relationship in first configuration information according to an embodiment of the present application;
FIG. 5 is a schematic diagram of writing data through a drive interface according to an embodiment of the present application;
FIG. 6 is a flowchart of the step of writing target write data to a normal data area according to one embodiment of the present application;
FIG. 7 is a schematic diagram of a correspondence relationship in second configuration information according to an embodiment of the present application;
FIG. 8 is a flowchart illustrating steps for detecting bus status according to one embodiment of the present application;
FIG. 9 is a flow chart of a data management method according to another embodiment of the present application;
FIG. 10 is a block diagram of a data management device according to an embodiment of the present application;
fig. 11 is an internal structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
Embodiments of the technical solutions of the present application will be described in detail below with reference to the accompanying drawings. The following examples are only for more clearly illustrating the technical solutions of the present application, and thus are only examples, and are not intended to limit the scope of protection of the present application.
Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs; the terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the application; the terms "comprising" and "having" and any variations thereof in the description and claims of the present application and in the description of the figures above are intended to cover non-exclusive inclusions.
In the description of embodiments of the present application, the technical terms "first," "second," and the like are used merely to distinguish between different objects and are not to be construed as indicating or implying a relative importance or implicitly indicating the number, particular order, or primary and secondary relationships of the technical features characterized. In the description of the embodiments of the present application, the meaning of "plurality" is two or more unless explicitly defined otherwise.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment may be included in at least one embodiment of the present application. The appearances of such phrases in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. Those of skill in the art will explicitly and implicitly appreciate that the embodiments described herein may be combined with other embodiments.
In the description of the embodiments of the present application, the term "and/or" is merely an association relationship describing an association object, which means that three relationships may exist, for example, a and/or B may mean: a exists alone, A and B exist together, and B exists alone. In addition, the character "/" herein generally indicates that the front and rear associated objects are an "or" relationship.
AUTOSAR (AUTomotive Open System Architecture, automobile open System architecture) is a consortium that is dedicated to the development of automobile electronics software standards. In the software architecture of the AUTOSAR, the NvM (Non volatile Manager, management module of nonvolatile data) can manage and maintain nonvolatile RAM data (NVRAM). In some scenarios, there is a risk of losing important data maintained by NvM. For example, in the software iteration process, there may be a situation that the configuration identifiers of the nvms of the new version software and the historical version software are not matched, or that the layouts of the nvms are different, and in these situations, an operation of recovering the default setting is often adopted, which may cause important data loss in the maintenance of the nvms. While loss of important data for NvM maintenance may have serious consequences.
The embodiment of the application provides a data management scheme, which comprises the steps of firstly determining the data type of target write-in data; writing the target writing data into the target storage space according to the data type of the target writing data; the target storage space includes a fixed address area or a normal data area. Because the fixed address is not changed due to software iteration, the data written into the fixed address area is not lost due to software iteration, the risk of data loss is reduced, and the reliability of data storage is improved.
The data management method provided by the application can be applied to an application environment shown in fig. 1. The application environment may include an electronic device 101 and a memory 102 disposed in an automobile, and the electronic device 101 and the memory 102 may be in signaling transmission and data transmission. Wherein the electronic device 101 may be an ECU (Electronic Control Unit ), and the Memory 102 may include, but is not limited to, flash (Flash) or EEPROM (ElectricallyErasable Programmable Read-Only Memory). The settings AUTOSAR, AUTOSAR in the electronic device 101 may configure a storage area in Flash or EEPROM that may store data maintained by NvM. In some scenarios, the memory 102 may also be provided in the electronic device 101, which is not limited in this embodiment of the present application.
According to some embodiments of the present application, referring to fig. 2, a data management method is provided, which may include the steps of:
in step 201, the data type of the target write data is determined.
Wherein the data class characterizes a class of target write data. The data category of the target write data may include the offline data and the normal data. The offline data includes important data in the vehicle, which may be data written to the controller when the vehicle is offline, for example, the offline data includes VIN (Vehicle Identification Number, vehicle identification code), vehicle production date, hardware version number, etc. Besides the offline data, the data maintained by the NvM may further include general data such as SOC (State of Charge) data, real_time Clock (RTC) Time, power-down flag bit, DTC (Diagnostic TroubleCode ), and the like.
When the data is required to be written, the data type of the target writing data can be determined according to the data division basis. For example, if the target write data is VIN, determining that the target write data is offline data; and if the target write data is SOC data, determining that the target write data is common data.
Step 202, writing the target writing data into the target storage space according to the data type of the target writing data.
Wherein the target storage space includes a fixed address area or a normal data area. The fixed address area is an area for storing data according to a physical address and is used for storing offline data, and the common data area is an area for storing data according to a storage block configured according to an automobile open system architecture and is used for storing common data. It will be appreciated that the configuration of the open system architecture of a car may be different and the size and location of the general data area may be different.
When writing, the target writing data is written into the fixed address area or the common data area according to the fact that the target writing data is the offline data or the common data.
In the data management method, the data type of the target writing data is determined; writing the target writing data into the target storage space according to the data type of the target writing data; wherein the target storage space includes a fixed address area or a normal data area. In the technical scheme of the embodiment of the application, the fixed address cannot be changed due to software iteration, so that the data written into the fixed address area cannot be lost due to the software iteration, the risk of data loss is reduced, and the reliability of data storage is improved.
According to some embodiments of the present application, the step of writing the target write data into the target storage space according to the data type of the target write data may include: and writing the target writing data into the fixed address area under the condition that the data type represents that the target writing data is the offline data.
When the target write data is the offline data, the target write data is important, and the target write data is written into the fixed address area. For example, in the case where the target write data is VIN, the VIN is written to the fixed address area; alternatively, in the case where the target write data is a hardware version number, the hardware version number is written to the fixed address area.
It can be appreciated that, since the fixed address area stores data according to the physical address, and the physical address is fixed, the storage location of the target write data is not changed due to software iteration and configuration of an automobile open system architecture, so that the reliability of data storage is higher and the risk of data loss is lower.
In some embodiments of the present application, referring to fig. 3, the step of writing the target write data into the fixed address area may include:
step 301, determining a target physical address corresponding to the target write data according to the first configuration information.
The first configuration information includes a correspondence between a type of the write data and a physical address in the fixed address area. For example, the first configuration information includes: the written data is VIN, and corresponds to physical addresses 0x0003F0000-0x0003F0100; the write data is a hardware version number, and corresponds to physical addresses 0x0003F0101-0x0003F1000, where the corresponding relationship can refer to fig. 4.
And acquiring first configuration information in advance, and storing the first configuration information. And under the condition that the target write data is the offline data, determining a target physical address corresponding to the target write data according to the type of the target write data and the first configuration information.
For example, if the target write data is VIN, determining that the target physical address is 0x0003F0000-0x0003F0100 according to the first configuration information; the target write data is a hardware version number, and the target physical address is determined to be 0x0003F0000-0x0003F0100 according to the first configuration information.
Step 302, writing the target writing data into the area corresponding to the target physical address in the fixed address area.
After the target physical address is determined, the target writing data is written into the area corresponding to the target physical address in the fixed address area. For example, after determining that the target physical address is 0x0003F0000-0x0003F0100, writing target write data into an area corresponding to 0x0003F0000-0x0003F0100 in Flash or EEPROM; after the target physical address is determined to be 0x0003F0101-0x0003F1000, writing target writing data into an area corresponding to 0x0003F0101-0x0003F1000 in Flash or EEPROM.
In some embodiments of the present application, a driving interface of a fixed address area is called, and target writing data is written into an area corresponding to a target physical address in the fixed address area.
Referring to fig. 5, a Flash drive interface is called, and ramdata is written into an area corresponding to 0x0003F0000-0x0003F0100 in Flash through the Flash drive interface. Or, calling a drive interface of the EEPROM, and writing ramdata into an area corresponding to 0x0003F0000-0x0003F0100 in the EEPROM through the drive interface of the EEPROM.
In the above embodiment, the target physical address corresponding to the target write data is determined according to the first configuration information, and the target physical address corresponding to the target write data is determined according to the first configuration information. In the technical scheme of the embodiment of the application, the first configuration information is preset, and when the offline data is written, the data writing operation can be rapidly and accurately performed according to the first configuration information, so that the writing efficiency of the offline data is improved.
According to some embodiments of the present application, the step of writing the target write data into the target storage space according to the data type of the target write data may include: and writing the target writing data into the common data area under the condition that the data category characterizes the target writing data as the common data.
In the case that the target write-in data is normal data, the importance of the target write-in data is low, so that a storage mode of an automobile open system architecture can be adopted to write the target write-in data into the normal data area.
For example, in the case where the target write data is SOC data, the SOC data is written to the normal data area; under the condition that the target write-in data is the power-down RTC time, the power-down RTC time is written into the common data area; writing the lower electric mark bit into the common data area under the condition that the target writing data is the lower electric mark bit; in the case where the target write data is a DTC, the DTC is written to the normal data area.
It can be understood that the common data is written into the common data area, and the storage mode of the automobile open system architecture is still adopted, so that the development difficulty can be reduced, and the development workload can be reduced.
According to some embodiments of the present application, referring to fig. 6, the step of writing the target write data into the normal data area may include:
step 401, determining a target storage block corresponding to the target write data according to the second configuration information.
The common data area comprises a plurality of storage blocks, the storage blocks are arranged according to a preset sequence, and the sizes of the storage blocks can be the same or different. For example, the normal data area includes a memory block 1, a memory block 2, a memory block 3, and a memory block 4 … …, and the plurality of memory blocks are arranged in the order of physical addresses, wherein the memory block 3 and the memory block 4 have the same size. The second configuration information includes a correspondence relationship between the type of the write data and the storage blocks in the normal data area. For example, the second configuration information includes: the corresponding relationship of SOC data to memory block 1, power-down RTC time to memory block 2, power-down flag bit to memory block 3, dtc to memory block 4 … … can be referred to in fig. 7.
And acquiring second configuration information in advance, and storing the second configuration information. And under the condition that the target write data is the common data, determining a target storage block corresponding to the target write data according to the type of the target write data and the second configuration information.
For example, the target write data is SOC data, and the target memory block is determined to be memory block 1 according to the second configuration information; the target write-in data is the power-down RTC time, and the target storage block is determined to be the storage block 2 according to the second configuration information; the target writing data is a power-down mark bit, and the target storage block is determined to be the storage block 3 according to the second configuration information; the target write data is DTC, and the target storage block is determined to be the storage block 4 according to the second configuration information.
Step 402, writing target write data to a target memory block.
After the target memory block is determined, the target write data is written into the target memory block. For example, if the target memory block is determined to be memory block 1, the SOC data is written into memory block 1; if the target storage block is determined to be the storage block 2, the power-down RTC time is written into the storage block 2; if the target storage block is determined to be the storage block 3, writing the lower electric mark bit into the storage block 3; and if the target storage block is determined to be the storage block 4, writing the DTC into the storage block 4.
According to some embodiments of the present application, the step of writing the target write data to the target storage block may include: and writing the target writing data into the target storage block through a driving interface configured by the automobile open system architecture.
The automobile open system architecture is pre-configured with a drive interface of the common data area, and when target writing data is written into the common data area, the target writing data is written into a target storage block of the common data area through the drive interface configured by the automobile open system architecture.
In the above embodiment, the target storage block corresponding to the target write data is determined according to the second configuration information, and the target write data is written into the target storage block. In the technical scheme of the embodiment of the application, the second configuration information is preset, and when the common data is written, the data writing operation can be rapidly and accurately performed according to the second configuration information, so that the writing efficiency of the common data is improved.
According to some embodiments of the present application, referring to fig. 8, the present application may further include the steps of:
in step 501, the status of the bus is detected when the real-time write request command is acquired.
The real-time writing demand instruction can be obtained from other parts of the automobile or through detection. For example, a battery and a coulombmeter for detecting the state of charge of the battery are arranged on the automobile, and after the coulombmeter detects the state of charge of the battery each time, an NvM module in an open system architecture of the automobile can acquire a real-time writing demand instruction for writing the state of charge of the battery into the coulombmeter in real time. Or when the automobile breaks down, the NvM module in the automobile open system architecture can acquire a real-time writing demand instruction for writing the diagnosis fault code in real time. It should be noted that, the method for acquiring the real-time write request command includes, but is not limited to, the foregoing description, and in practical application, other methods may be adopted for acquiring the real-time write request command.
And detecting the bus state under the condition that the real-time write demand instruction is acquired. The bus may be a read-write bus of Flash/EEPROM, and the bus state may include a working state, an idle state, and the like. It should be noted that the bus state is not limited to the above description, and may include other states.
Step 502, in a case where the bus is in an idle state, a step of determining a data type of the target write data is performed.
If the bus is in an idle state, indicating that the write operation can be performed, determining whether the target write data is the offline data; if the target writing data is determined to be the offline data, writing the target writing data into the fixed address area; and if the target write data is determined to be the normal data, writing the target write data into the normal data area.
In the above embodiment, the state of the bus is detected under the condition that the real-time write demand instruction is acquired; and detecting the state of the bus under the condition that the real-time write demand instruction is acquired. In the technical scheme of the embodiment of the application, the bus state is detected, the writing operation can be reduced, and the bus blockage is avoided.
According to some embodiments of the present application, referring to fig. 9, a data management method is provided, which may include the steps of:
in step 601, in response to the power-on wake-up signal, the normal data and the power-down data are read.
And after the automobile is powered on, a power-on wake-up signal is output. And the NvM module of the automobile open system architecture receives the power-on wake-up signal and responds to the power-on wake-up signal to read data. In one embodiment, the normal data is read first, and then the offline data is read. In another embodiment, the offline data is read first, and then the normal data is read. In practical application, the sequence of reading the normal data and the offline data is not limited.
In step 602, the status of the bus is detected when the real-time write request command is obtained.
Step 603, determining a data type of the target write data in a case that the bus is in an idle state.
In step 604, in the case that the data type represents that the target write data is offline data, a target physical address corresponding to the target write data is determined according to the first configuration information.
Step 605, call the driving interface corresponding to the fixed address area, and write the target writing data into the area corresponding to the target physical address in the fixed address area.
Step 606, in the case that the data type represents that the target writing data is normal data, determining a target storage block corresponding to the target writing data according to the second configuration information.
In step 607, the target write data is written into the target storage block through the drive interface configured by the open system architecture of the automobile.
In step 608, in response to the power-down signal, the target write data is written into the target storage space according to the data type of the target write data.
When the automobile is powered down, the NvM module of the automobile open system architecture stores data which needs to be stored when the automobile is powered down. The storage process can refer to a real-time writing process, and whether the data to be stored during power-down is the offline data or not is determined; if the data is the offline data, determining a target physical address corresponding to the data according to the first configuration information; and then, calling a driving interface of the fixed address area, and writing the data into the area corresponding to the target physical address in the fixed address area through the driving interface of the fixed address area. If the data is common data, determining a target storage block corresponding to the data according to second configuration information; then, the data is written into a target storage block of the normal data area through a drive interface configured by the automobile open system architecture.
In the above embodiment, the normal data and the offline data are read in response to the power-on wake-up signal; under the condition that a real-time write demand instruction is acquired, detecting the state of a bus; determining a data type of target write data under the condition that the bus is in an idle state; under the condition that the data category represents that the target writing data is the offline data, determining a target physical address corresponding to the target writing data according to the first configuration information; calling a driving interface corresponding to the fixed address area, and writing target writing data into an area corresponding to a target physical address in the fixed address area; under the condition that the data category represents that the target writing data is common data, determining a target storage block corresponding to the target writing data according to second configuration information; writing target writing data into a target storage block through a driving interface configured by an automobile open system architecture; and responding to the power-down signal, and writing the target writing data into the target storage space according to the data type of the target writing data. The embodiment of the application provides a data management scheme, which can be used for reading data after the automobile is electrified, and when a real-time writing demand instruction is acquired, the data writing is performed according to the data type, and the data writing is performed when the automobile is electrified.
It should be understood that, although the steps in the flowcharts of fig. 2 to 9 are sequentially shown as indicated by arrows, these steps are not necessarily sequentially performed in the order indicated by the arrows. The steps are not strictly limited to the order of execution unless explicitly recited herein, and the steps may be executed in other orders. Moreover, at least a portion of the steps of fig. 2-9 may include steps or stages that are not necessarily performed at the same time, but may be performed at different times, nor does the order in which the steps or stages are performed necessarily occur sequentially, but may be performed alternately or alternately with other steps or at least a portion of the steps or stages in other steps.
Based on the same inventive concept, the embodiment of the application also provides a data management device for realizing the above related data management method. The implementation of the solution provided by the device is similar to the implementation described in the above method, so the specific limitation in one or more embodiments of the data management device provided below may refer to the limitation of the data management method hereinabove, and will not be repeated herein.
According to some embodiments of the present application, referring to fig. 10, there is provided a data management device applied to an open system architecture of an automobile, the device including:
a category determination module 701, configured to determine a data category of the target write data;
the data writing module 702 is configured to write target writing data into the target storage space according to a data type of the target writing data; the target storage space comprises a fixed address area or a common data area, wherein the fixed address area is an area for storing data according to a physical address and is used for storing offline data, and the common data area is an area for storing data according to a storage block configured according to an automobile open system architecture and is used for storing common data.
In some embodiments of the present application, the data writing module 702 is specifically configured to write the target write data into the fixed address area if the data class characterizes that the target write data is offline data.
In some embodiments of the present application, the data writing module 702 is specifically configured to determine, according to the first configuration information, a target physical address corresponding to the target writing data; the first configuration information comprises a corresponding relation between the type of the written data and a physical address in the fixed address area; and writing the target writing data into the area corresponding to the target physical address in the fixed address area.
In some embodiments of the present application, the data writing module 702 is specifically configured to call a driving interface of the fixed address area, and write the target writing data into an area corresponding to the target physical address in the fixed address area.
In some embodiments of the present application, the data writing module 702 is specifically configured to write the target write data into the normal data area if the data class characterizes the target write data as normal data.
In some embodiments of the present application, the data writing module 702 is specifically configured to determine, according to the second configuration information, a target storage block corresponding to the target writing data; the second configuration information comprises a corresponding relation between the type of the written data and the storage block in the common data area; and writing the target writing data into the target storage block.
In some embodiments of the present application, the data writing module 702 is specifically configured to write the target writing data into the target storage block through a driving interface configured by an open system architecture of the automobile.
In some embodiments of the present application, the apparatus further comprises:
the bus detection module is used for detecting the state of the bus under the condition that the real-time write demand instruction is acquired;
the above-mentioned class determination module is configured to perform the step of determining a data class of the target write data in a case where the bus is in an idle state.
The respective modules in the above-described data management apparatus may be implemented in whole or in part by software, hardware, and combinations thereof. The above modules may be embedded in hardware or independent of a processor in the electronic device, or may be stored in software in a memory in the electronic device, so that the processor may call and execute operations corresponding to the above modules.
According to some embodiments of the present application, there is provided an electronic device, which may be an ECU in an automobile, and an internal structure diagram thereof may be as shown in fig. 11. The electronic device includes a processor, a memory, an input/output interface, a communication interface, a display unit, and an input device. The processor, the memory and the input/output interface are connected through a system bus, and the communication interface, the display unit and the input device are connected to the system bus through the input/output interface. Wherein the processor of the electronic device is configured to provide computing and control capabilities. The memory of the electronic device includes a non-volatile storage medium and an internal memory. The nonvolatile storage medium stores an operating system and a computer program, wherein the computer program can be used for realizing the functions of inputting data, executing calculation, outputting results and the like. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The input/output interface of the electronic device is used to exchange information between the processor and the external device. The communication interface of the electronic device is used for conducting wired or wireless communication with an external terminal, and the wireless communication can be realized through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. The computer program is executed by a processor to implement a data management method.
It will be appreciated by those skilled in the art that the structure shown in fig. 11 is merely a block diagram of a portion of the structure associated with the present application and is not limiting of the electronic device to which the present application is applied, and that a particular electronic device may include more or fewer components than shown, or may combine certain components, or have a different arrangement of components.
According to some embodiments of the present application, there is also provided a non-transitory computer-readable storage medium, such as a memory, comprising instructions executable by a processor of an electronic device to perform the above-described method. For example, the non-transitory computer readable storage medium may be ROM, random Access Memory (RAM), CD-ROM, magnetic tape, floppy disk, optical data storage device, etc.
According to some embodiments of the present application, there is also provided a computer program product, which, when being executed by a processor, can implement the above-mentioned method. The computer program product includes one or more computer instructions. When loaded and executed on a computer, these computer instructions may implement some or all of the methods described above, in whole or in part, in accordance with the processes or functions described in embodiments of the present application.
The technical features of the above-described embodiments may be arbitrarily combined, and all possible combinations of the technical features in the above-described embodiments are not described for brevity of description, however, as long as there is no contradiction between the combinations of the technical features, they should be considered as the scope of the description.
The above examples merely represent a few embodiments of the present application, which facilitate a specific and detailed understanding of the technical solutions of the present application, but are not to be construed as limiting the scope of the invention. It should be noted that it would be apparent to those skilled in the art that various modifications and improvements could be made without departing from the spirit of the present application, which would be within the scope of the present application. It should be understood that those skilled in the art, based on the technical solutions provided in the present application, can obtain technical solutions through logical analysis, reasoning or limited experiments, all fall within the protection scope of the claims attached to the present application. The scope of the patent application is therefore intended to be limited by the content of the appended claims, the description and drawings being presented to the extent that the claims are defined.

Claims (8)

1. A method for managing data, applied to an open system architecture of an automobile, the method comprising:
determining a data type of target write-in data, wherein the target write-in data is nonvolatile data;
writing the target writing data into a target storage space according to the data type of the target writing data; the target storage space comprises a fixed address area or a common data area, wherein the fixed address area is an area for storing data according to a physical address and is used for storing offline data, the offline data are data written into a controller when an automobile is offline, the fixed address area is a storage area which is not changed due to software iteration of an automobile open system architecture, and the common data area is an area for storing data according to a storage block configured according to the automobile open system architecture and is used for storing common data;
wherein the writing the target writing data into the target storage space includes:
under the condition that the data category represents that the target writing data is the offline data, calling a driving interface of the fixed address area, and determining a target physical address corresponding to the target writing data according to first configuration information; the first configuration information comprises a corresponding relation between the type of the written data and a physical address in the fixed address area;
and writing the target writing data into the area corresponding to the target physical address in the fixed address area.
2. The method of claim 1, wherein the writing the target write data to the target storage space according to the data class of the target write data comprises:
and writing the target writing data into the common data area under the condition that the data category characterizes the target writing data as the common data.
3. The method of claim 2, wherein the writing the target write data to the normal data area comprises:
determining a target storage block corresponding to the target write data according to second configuration information; the second configuration information comprises a corresponding relation between the type of the written data and the storage blocks in the common data area;
and writing the target writing data into the target storage block.
4. The method of claim 3, wherein the writing the target write data to the target memory block comprises:
and writing the target writing data into the target storage block through a driving interface configured by an automobile open system architecture.
5. The method according to any one of claims 1-4, further comprising:
under the condition that a real-time write demand instruction is acquired, detecting the state of a bus;
and executing the step of determining the data type of the target write data under the condition that the bus is in an idle state.
6. A data management device for use in an automotive open system architecture, the device comprising:
the type determining module is used for determining the data type of target writing data, wherein the target writing data is nonvolatile data;
the data writing module is used for writing the target writing data into a target storage space according to the data type of the target writing data; the target storage space comprises a fixed address area or a common data area, wherein the fixed address area is an area for storing data according to a physical address and is used for storing offline data, the offline data are data written into a controller when an automobile is offline, the fixed address area is a storage area which is not changed due to software iteration of an automobile open system architecture, and the common data area is an area for storing data according to a storage block configured according to the automobile open system architecture and is used for storing common data;
the data writing module is specifically configured to invoke a driving interface of the fixed address area when the data category characterizes that the target writing data is the offline data, and determine a target physical address corresponding to the target writing data according to first configuration information; the first configuration information comprises a corresponding relation between the type of the written data and a physical address in the fixed address area; and writing the target writing data into the area corresponding to the target physical address in the fixed address area.
7. An electronic device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the method of any one of claims 1 to 5 when executing the computer program.
8. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the method of any one of claims 1 to 5.
CN202310729979.5A 2023-06-20 2023-06-20 Data management method, apparatus, electronic device, storage medium, and program product Active CN116450059B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310729979.5A CN116450059B (en) 2023-06-20 2023-06-20 Data management method, apparatus, electronic device, storage medium, and program product

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310729979.5A CN116450059B (en) 2023-06-20 2023-06-20 Data management method, apparatus, electronic device, storage medium, and program product

Publications (2)

Publication Number Publication Date
CN116450059A CN116450059A (en) 2023-07-18
CN116450059B true CN116450059B (en) 2024-04-12

Family

ID=87120612

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310729979.5A Active CN116450059B (en) 2023-06-20 2023-06-20 Data management method, apparatus, electronic device, storage medium, and program product

Country Status (1)

Country Link
CN (1) CN116450059B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111475099A (en) * 2019-01-23 2020-07-31 阿里巴巴集团控股有限公司 Data storage method, device and equipment
CN113590501A (en) * 2020-04-30 2021-11-02 华为技术有限公司 Data storage method and related equipment
CN113849510A (en) * 2021-09-23 2021-12-28 Tcl空调器(中山)有限公司 Data storage method, device and equipment of air conditioner and storage medium
CN114639439A (en) * 2022-04-08 2022-06-17 北京得瑞领新科技有限公司 Chip internal SRAM test method and device, storage medium and SSD device

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP6824929B2 (en) * 2018-06-07 2021-02-03 株式会社日立製作所 Memory control system and memory control method
CN110704334B (en) * 2019-09-25 2021-10-15 苏州浪潮智能科技有限公司 Method, system and equipment for important product data management
CN114281242B (en) * 2021-11-15 2024-05-10 北京智芯微电子科技有限公司 Memory load balancing method, device and equipment
CN115639971B (en) * 2022-12-12 2023-04-07 北京集度科技有限公司 Data writing method, data writing device, electronic device, storage medium, and program product

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111475099A (en) * 2019-01-23 2020-07-31 阿里巴巴集团控股有限公司 Data storage method, device and equipment
CN113590501A (en) * 2020-04-30 2021-11-02 华为技术有限公司 Data storage method and related equipment
CN113849510A (en) * 2021-09-23 2021-12-28 Tcl空调器(中山)有限公司 Data storage method, device and equipment of air conditioner and storage medium
CN114639439A (en) * 2022-04-08 2022-06-17 北京得瑞领新科技有限公司 Chip internal SRAM test method and device, storage medium and SSD device

Also Published As

Publication number Publication date
CN116450059A (en) 2023-07-18

Similar Documents

Publication Publication Date Title
US20120110296A1 (en) Electronic apparatus
CN107239411B (en) Memory management method and system for vehicle-mounted controller
CN112732310A (en) Firmware upgrading method, system, equipment and medium based on embedded boot partition
CN113094072A (en) Vehicle upgrading method and device, electronic device and storage medium
CN116450059B (en) Data management method, apparatus, electronic device, storage medium, and program product
CN116719586B (en) Software module calling method, device, equipment, storage medium and program product
CN117215827A (en) MCU software refreshing and loading backup method based on CAN diagnosis
CN111417908A (en) ECU (electronic control Unit) recognizer, and recognition method, system, equipment and medium thereof
CN115269452A (en) Trim command processing method, system, terminal device and storage medium
CN111679649B (en) Vehicle-mounted terminal starting method and device, terminal equipment and storage medium
CN113377421B (en) Method, device, equipment and medium for detecting software and hardware version information
CN112599172B (en) Data writing method and device of electronic control unit and storage medium
CN112199103B (en) Equipment upgrading method and terminal equipment
CN115460028B (en) Vehicle-mounted network dormancy management method and device, vehicle-mounted network system and vehicle
JP3203884B2 (en) Vehicle diagnostic system
US20240184453A1 (en) Information processing system, storage medium, and data write count management method
CN103473066A (en) Method and device for adding VxWorks image files and reading version numbers
CN117940892A (en) Program updating method and program updating device
US20220258753A1 (en) System and method for providing connected service
CN116010138A (en) GPU control method, device, electronic equipment and computer readable storage medium
JP2001125790A (en) Program reloading method for on-vehicle electronics
CN116414310A (en) Data storage method
CN112363925A (en) Method for acquiring vehicle-mounted machine basic information, electronic equipment and computer storage medium
CN114356384A (en) Vehicle-mounted system updating method, vehicle-mounted system detecting method and vehicle-mounted system detecting system
CN114356638A (en) Log saving method and device, storage medium and computer equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant