CN111857777B - System updating method and device based on double-core intelligent ammeter and computer equipment - Google Patents

System updating method and device based on double-core intelligent ammeter and computer equipment Download PDF

Info

Publication number
CN111857777B
CN111857777B CN202010686625.3A CN202010686625A CN111857777B CN 111857777 B CN111857777 B CN 111857777B CN 202010686625 A CN202010686625 A CN 202010686625A CN 111857777 B CN111857777 B CN 111857777B
Authority
CN
China
Prior art keywords
application
upgraded
upgrade
system application
parameter file
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
CN202010686625.3A
Other languages
Chinese (zh)
Other versions
CN111857777A (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.)
China Southern Power Grid Digital Grid Technology Guangdong Co ltd
Original Assignee
China Southern Power Grid Digital Grid Technology Guangdong 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 China Southern Power Grid Digital Grid Technology Guangdong Co ltd filed Critical China Southern Power Grid Digital Grid Technology Guangdong Co ltd
Priority to CN202010686625.3A priority Critical patent/CN111857777B/en
Publication of CN111857777A publication Critical patent/CN111857777A/en
Application granted granted Critical
Publication of CN111857777B publication Critical patent/CN111857777B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01RMEASURING ELECTRIC VARIABLES; MEASURING MAGNETIC VARIABLES
    • G01R11/00Electromechanical arrangements for measuring time integral of electric power or current, e.g. of consumption
    • G01R11/02Constructional details
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/61Installation
    • G06F8/63Image based installation; Cloning; Build to order
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Stored Programmes (AREA)

Abstract

The application relates to a system updating method, a device, computer equipment and a storage medium based on a dual-core intelligent ammeter. Acquiring an upgrade request file comprising an upgrade parameter file for a system application to be upgraded in the dual-core intelligent ammeter, acquiring a storage position of the mirror image system application corresponding to the system application to be upgraded in the upgrade parameter file according to application information in the upgrade parameter file, acquiring the mirror image system application corresponding to the system application to be upgraded according to the storage position, installing the mirror image system application in a flash memory of the dual-core intelligent ammeter, configuring operation parameters and authority of the mirror image system application after the installation according to configuration information in the upgrade parameter file, and updating the system application to be upgraded. Compared with the traditional electric energy meter which does not support system application upgrading and updating, the method and the device realize stable and reliable system application updating of the double-core intelligent electric meter by using the upgrading parameter file, the mirror image application and other methods.

Description

System updating method and device based on double-core intelligent ammeter and computer equipment
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a system updating method and apparatus based on a dual-core smart meter, a computer device, and a storage medium.
Background
The electric power is an important energy source for guaranteeing normal operation of daily life and national economy of people, the electric power is conducted to terminal power users through power transmission, transformation, distribution and power consumption links of a power grid, and the electric energy meter is arranged on the power consumption links of the power grid and serves as a vital electric energy consumption trade settlement tool. In the comprehensive energy market with increasingly abundant market bodies and complex and changeable market bodies, the electric energy meter needs to support flexible expansion of diversified advanced applications and online upgrading of system software, however, at present, the electric energy meter software in China is designed integrally, namely, a metering part and a non-metering part do not do independent work requirements, the software system of the electric energy meter is solidified, is strongly coupled with a hardware platform, and cannot realize online upgrading of the software system, so that the electric energy meter cannot adapt to diversified application requirements. According to the requirement of the IR46 standard, the management core and the metering core of the dual-core intelligent ammeter are mutually separated, management core software can be updated and iterated to meet the requirement of online upgrade of a software system, in addition, the ammeter has limited software and hardware resources, and the occupation and consumption of the resources inside a communication network and the software system by upgrade are required to be compressed as much as possible when the system is upgraded.
Therefore, how to realize stable and reliable system upgrade and update of the dual-core intelligent ammeter under the condition of limited software and hardware resources becomes a problem to be solved urgently.
Disclosure of Invention
Based on the foregoing, it is necessary to provide a system updating method, device, computer equipment and storage medium based on a dual-core smart meter, which can realize stable and reliable system updating of the dual-core smart meter.
A system updating method based on a dual-core smart meter, which is applied to a system updating component in the dual-core smart meter, the method comprising:
acquiring an upgrade request file; the upgrade request file comprises an upgrade parameter file applied to a system to be upgraded in the dual-core intelligent ammeter; the upgrade parameter file comprises application information and configuration information of the system application to be upgraded;
acquiring a storage position of a mirror image system application corresponding to the system application to be upgraded from the upgrading parameter file according to the application information;
acquiring mirror image system applications corresponding to the system applications to be upgraded according to the storage positions, and installing the mirror image system applications in a flash memory of the dual-core intelligent ammeter;
and configuring the running parameters and the authority of the mirror image system application after the installation is completed according to the configuration information in the upgrading parameter file so as to update the system application to be upgraded.
In one embodiment, after the obtaining the upgrade request file, the method includes:
restarting the system, and judging whether the upgrade request file still exists;
if yes, acquiring the application information of the system application to be upgraded from the upgrade parameter file, and returning to the step of acquiring the storage position of the mirror image system application corresponding to the system application to be upgraded from the upgrade parameter file according to the application information.
In one embodiment, the upgrade parameter file includes application information of a plurality of system applications to be upgraded;
and after the running parameters and the authorities of the mirror image system application are configured and installed according to the configuration information in the upgrading parameter file so as to update the system application to be upgraded, the method further comprises the steps of:
detecting whether the plurality of system applications to be upgraded are all upgraded;
if not, acquiring a new application to be upgraded from the upgrade parameter file as a current system application to be upgraded, acquiring application information of the current system application to be upgraded from the upgrade parameter file, and returning to the step of acquiring a storage position of a mirror image system application corresponding to the system application to be upgraded from the upgrade parameter file according to the application information.
In one embodiment, after the operating parameters and the permissions of the mirror image system application after the installation are configured according to the configuration information in the upgrade parameter file to update the system application to be upgraded, the method further includes:
and deleting the upgrade request file when the plurality of system applications to be upgraded are all upgraded.
In one embodiment, when the plurality of system applications to be upgraded are all upgraded, the updated running parameters of the mirror image system application are stored in the flash memory of the dual-core smart electric meter.
In one embodiment, the obtaining the upgrade request file includes:
acquiring an upgrade request file sent by an application management unit; the application management unit is used for acquiring a system application to be upgraded from the memory of the dual-core intelligent ammeter, creating the upgrade parameter file, generating the upgrade request file according to the upgrade parameter file, and sending the upgrade request file to the system updating component.
In one embodiment, the method further comprises:
the updated operation parameters of the system application to be upgraded are sent to an application starting unit in the dual-core intelligent ammeter; the application starting unit is used for running the updated system application according to the running parameters.
A system update device based on a dual-core smart meter, applied to a system update component in the dual-core smart meter, the device comprising:
the first acquisition module is used for acquiring an upgrade request file; the upgrade request file comprises an upgrade parameter file applied to a system to be upgraded in the dual-core intelligent ammeter; the upgrade parameter file comprises application information and configuration information of the system application to be upgraded;
the second acquisition module is used for acquiring the storage position of the mirror image system application corresponding to the system application to be upgraded from the upgrading parameter file according to the application information;
the installation module is used for acquiring mirror image system applications corresponding to the system applications to be upgraded according to the storage positions and installing the mirror image system applications in the flash memory of the dual-core intelligent ammeter;
and the updating module is used for configuring the running parameters and the authority of the mirror image system application after the installation is completed according to the configuration information in the upgrading parameter file so as to update the system application to be upgraded.
A computer device comprising a memory storing a computer program and a processor implementing the steps of the method described above when the processor executes the computer program.
A computer readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the method described above.
According to the system updating method, the device, the computer equipment and the storage medium based on the dual-core intelligent electric meter, the upgrade request file comprising the upgrade parameter file for the system application to be upgraded in the dual-core intelligent electric meter is obtained, the storage position of the mirror image system application corresponding to the system application to be upgraded is obtained in the upgrade parameter file according to the application information in the upgrade parameter file, the mirror image system application corresponding to the system application to be upgraded is obtained according to the storage position and is installed in the flash memory of the dual-core intelligent electric meter, and the running parameters and the authority of the mirror image system application after the installation are configured according to the configuration information in the upgrade parameter file, so that the system application to be upgraded is updated. Compared with the traditional electric energy meter which does not support system application upgrading and updating, the method and the device realize stable and reliable system application updating of the double-core intelligent electric meter by using the upgrading parameter file, the mirror image application and other methods.
Drawings
FIG. 1 is an application environment diagram of a system update method based on a dual-core smart meter in one embodiment;
FIG. 2 is a flow chart of a system update method based on a dual-core smart meter in one embodiment;
FIG. 3 is a flow chart of an update step in one embodiment;
FIG. 4 is a flow chart of a system update method based on a dual-core smart meter according to another embodiment;
FIG. 5 is a block diagram of a system update device based on a dual-core smart meter in one embodiment;
fig. 6 is an internal structural diagram of a computer device in one embodiment.
Description of the embodiments
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application will be further described in detail with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the present application.
The system updating method based on the dual-core intelligent ammeter can be applied to an application environment shown in fig. 1. Wherein the application management unit 102 may communicate with the system update component 104 via a network, and the system update component 104 may communicate with the application initiation unit 106. The system updating component 104 can acquire an upgrade request file sent by the application management unit 102, obtain a storage position of an image system application of the system application to be upgraded according to application information in the upgrade request file, and also can acquire the image system application summarized by the storage position, install the image system application into a flash memory of the dual-core intelligent ammeter, and then configure operation parameters and authority of the installed image system application according to configuration information in the upgrade parameter file in the upgrade request file, so as to update the system application to be upgraded, and the system updating component 104 can also send the operation parameters to the application starting unit 106, and the application starting unit 106 can operate the upgraded system application according to the operation parameters. In one embodiment, the system updating component 104 may further include an MCU file system and an upgrade parameter analysis sub-module, where the MCU file system may be used to display the upgraded system application, and the upgrade parameter analysis sub-module may be used to analyze the upgrade parameter file. .
In one embodiment, as shown in fig. 2, a system updating method based on a dual-core smart meter is provided, and the system updating component in fig. 1 is taken as an example to illustrate the application of the method, and the method includes the following steps:
step S202, obtaining an upgrade request file; the upgrade request file comprises an upgrade parameter file applied to a system to be upgraded in the dual-core intelligent ammeter; the upgrade parameter file includes application information and configuration information of the system application to be upgraded.
The upgrade request file may be a request file sent by the application management unit 102, the upgrade request file may be used to instruct the system update component 104 to perform online update of the system application, the upgrade request file may include an upgrade parameter file of the system application to be upgraded, the upgrade parameter file may include application information and configuration information of the system application to be upgraded, the system update component 104 may obtain the upgrade request file sent by the application management unit 102, and the upgrade parameter file may be parsed by an upgrade parameter parsing sub-module in the system update component 104, so that application information and configuration information therein may be obtained. The system application to be upgraded can be a system application to be upgraded in the dual-core intelligent ammeter, the application information can comprise information such as an application name, an application storage position and the like, and the configuration information can be information such as operation parameters and authority information of the system application.
Step S204, according to the application information, the storage position of the mirror image system application corresponding to the system application to be upgraded is obtained from the upgrade parameter file.
The application information may be application information of the system application in step S202, for example, may be information such as an application name, an application storage location, etc., and the upgrade parameter file may be a file included in the system upgrade request, where information such as application information and configuration information of the system application to be upgraded may be included, and the upgrade parameter file may include the application information. The system updating component 104 may analyze the upgrade parameter file by using an internal upgrade parameter analysis sub-module, and obtain a storage location of an image system application corresponding to the system application to be upgraded, where the image is a file storage form and is a redundant type, and a duplicate of data on one disk exists on another disk to be an image, so that many files may be made into an image file, where the image system application may be an application for upgrading, and the image system application may implement processes of installation and configuration information.
Step S206, obtaining mirror image system application corresponding to the system application to be upgraded according to the storage position, and installing the mirror image system application in the flash memory of the dual-core intelligent ammeter.
The storage location may be a storage location corresponding to the mirror system application in step S204, where the storage location may be a storage location located in the dual-core smart meter, and after the storage location of the mirror system application is obtained, the system update component 104 may obtain, in the storage location, the mirror system application corresponding to the system application to be upgraded, and may also install the obtained mirror system application in a corresponding location, for example, a flash memory of the dual-core smart meter, where the flash memory may be a nonvolatile memory, or an electronic form of a removable programmed rom, where the flash memory is allowed to be erased or written multiple times in operation, and this technology is mainly used for general data storage and exchange transmission data between a computer and other digital products. The system update component 104 installs the mirrored system applications into flash memory, and can implement configuration of relevant parameters of the mirrored system applications.
And step S208, configuring the running parameters and the authority of the mirror image system application after the installation is completed according to the configuration information in the upgrade parameter file so as to update the system application to be upgraded.
The upgrade parameter file may be a file included in the system upgrade request, the upgrade parameter file may include application information and configuration information of a system application to be upgraded, where the application information may include information such as an application name, a storage location of an image application, and the configuration information may include information such as an operation parameter and authority information, and the system update component 104 may analyze the upgrade parameter file through an upgrade parameter analysis sub-module to obtain the application information and the configuration information therein, and may perform configuration of operation parameters and authority on the installed image system application according to the configuration information in the upgrade parameter file, so as to implement updating and upgrading of the system application. Wherein the relevant information in the upgrade parameter file conforms to the FDT format standard, FDT (Field Device Tool ) is a development standard for integrating intelligent field devices into process and plant automation systems, which standardizes the standard software interface between DTM (Device Type Manager ) and framework applications, and which is independent of the various device manufacturers and various fieldbus protocols, using upgrade parameters in FDT format, greatly reduces code redundancy. Specifically, as shown in fig. 3, fig. 3 is a flow chart illustrating the updating step in one embodiment. The upgrade parameter file may be specifically an update. Dtb file, the system update component 104 may analyze the upgrade parameter file by using the FDT standard, and find a node corresponding to the application information of the upgrade system application, for example, an "ms-app" node, in the analyzed upgrade parameter file, after the first node is queried, may read the application information of the system application to be upgraded, for example, read an img_file attribute in the upgrade parameter file, specifically, may be a storage location of the mirror image system application, and install the mirror image system file in the location into the flash memory, and modify the attributes, such as "img-base", "img-size" and "img-crc32", in the mirror image system application by using the operation parameter and the authority information in the upgrade parameter file, so as to complete configuration of the operation parameter and the authority information of the new application.
In the system updating method based on the dual-core smart meter, an upgrade request file comprising an upgrade parameter file for a system application to be upgraded in the dual-core smart meter is obtained, a storage position of an image system application corresponding to the system application to be upgraded is obtained in the upgrade parameter file according to application information in the upgrade parameter file, then the image system application corresponding to the system application to be upgraded is obtained according to the storage position and is installed in a flash memory of the dual-core smart meter, and then the running parameters and the authority of the installed image system application are configured according to configuration information in the upgrade parameter file, so that the system application to be upgraded is updated. Compared with the traditional electric energy meter which does not support system application upgrading and updating, the method and the device realize stable and reliable system application updating of the double-core intelligent electric meter by using the upgrading parameter file, the mirror image application and other methods.
In one embodiment, after obtaining the upgrade request file, it includes: restarting the system, and judging whether the upgrade request file still exists; if yes, acquiring application information of the system application to be upgraded from the upgrade parameter file, and returning to the step of acquiring a storage position of the mirror image system application corresponding to the system application to be upgraded from the upgrade parameter file according to the application information.
In this embodiment, the upgrade request file may be a request file sent by the application management unit 102, where the upgrade request file may include an upgrade parameter file, the upgrade parameter file may include application information and configuration information of a system application to be upgraded, after receiving the upgrade request file sent by the application management unit 102, the system update component 104 may restart the system and determine whether the upgrade request file still exists in the restarted system, if yes, may obtain the application information of the system application to be upgraded from the upgrade parameter file in the upgrade request file, and return a step of obtaining, according to the application information, a storage location of an image system application corresponding to the system application to be upgraded, that is, when the upgrade request file still exists in the restarted system, the system update component 104 may continue the step of updating the system application to be upgraded. Specifically, the system update component 104 may restart the system after receiving the upgrade request file, for example, the update_req file, sent by the application management unit 102, call the interface ms_rtos_update () to determine whether the restarted upgrade request file still exists, and when the upgrade request file exists, may sequentially obtain application information of the application with the upgrade system, for example, an application name and a storage location of the application with the mirror system by using the upgrade action file update_actions in the upgrade parameter file, and update the obtained application with the mirror system.
With this embodiment, the system update component 104 can determine whether the upgrade request file exists by restarting the system, so that reliability and stability of system update can be improved.
In one embodiment, according to the configuration information in the upgrade parameter file, the running parameters and the permissions of the mirror image system application after the installation are configured, so as to update the system application to be upgraded, and the method further comprises: detecting whether a plurality of system applications to be upgraded are all upgraded; if not, acquiring a new application to be upgraded from the upgrade parameter file as the current system application to be upgraded, acquiring application information of the current system application to be upgraded from the upgrade parameter file, and returning to the step of acquiring a storage position of the mirror image system application corresponding to the system application to be upgraded from the upgrade parameter file according to the application information.
In this embodiment, the upgrade parameter file may be a file included in the upgrade request file, where the upgrade parameter file may include information such as application information and configuration information of a system application to be upgraded, and the upgrade parameter file may further include application information of a plurality of system applications to be upgraded; when the system updating component 104 completes updating a system application, that is, the configuration of the running parameters and the configuration information of the system application is completed, the system updating component 104 may detect whether the plurality of system applications to be updated in the upgrade parameter file are all updated, specifically, the system updating component 104 may sequentially detect whether the application in each application node in the upgrade parameter file is updated, if there is a system application that is not updated, the system updating component 104 may acquire a new application to be updated from the upgrade parameter file as a current system application to be updated, and acquire application information of the current system application to be updated in the upgrade parameter file, specifically, may be application information of the current system application to be updated obtained by analyzing the upgrade parameter file by using the upgrade parameter sub-module, and after acquiring the application information of the current system application to be updated, may return to the step of acquiring a storage location of the mirror image system application corresponding to the system application to be updated in the upgrade parameter file according to the application information, that is, if there is a system application to be updated, the system updating component 104 may update the newly acquired current system application to be updated, until the update of the newly acquired current system application to be updated is stopped, that the system application to be updated is updated, and the system updating component 104 is updated.
In one embodiment, according to the configuration information in the upgrade parameter file, the running parameters and the permissions of the mirror image system application after the installation are configured, so as to update the system application to be upgraded, and the method further comprises: and deleting the upgrade request file when the upgrade of the plurality of system applications to be upgraded is completed. In this embodiment, when the system applications to be upgraded in the upgrade parameter file are all upgraded, the system updating component 104 may delete the upgrade request file to end the upgrade and the upgrade, and in particular, the upgrade request file may be update_req.
Through the above embodiment, the system upgrade component 104 may perform relevant detection on the system applications to be upgraded in the upgrade parameter file, so as to complete the upgrade of all the system applications to be upgraded, thereby implementing reliable online upgrade on the system applications in the dual-core smart meter.
In one embodiment, when a plurality of system applications to be upgraded are all upgraded, the operation parameters of the updated mirror image system applications are stored in the flash memory of the dual-core smart meter.
In this embodiment, the upgrade parameter file may include a plurality of system applications to be upgraded, the system update component 104 may upgrade each system application to be upgraded in the upgrade parameter file, and when the system update component 104 upgrades all the plurality of system applications to be upgraded in the upgrade parameter file, the system update component 104 may store the operation parameters of the updated image system application in the flash memory of the dual-core smart electric meter, and specifically, the system update component 104 may copy the operation parameter file updated in the memory into the internal flash memory after all the system applications to be upgraded are installed.
Through the embodiment, the system updating component 104 can store the operation parameters into the flash memory after the upgrade of the system application to be upgraded is completed, so that the normal operation of the upgraded and updated system application can be ensured.
In one embodiment, obtaining an upgrade request file includes: acquiring an upgrade request file sent by the application management unit 102; the application management unit 102 is configured to obtain a system application to be upgraded from a memory of the dual-core smart meter, create an upgrade parameter file, generate an upgrade request file according to the upgrade parameter file, and send the upgrade request file to the system update component 104.
In this embodiment, the upgrade request file may be a file for upgrading and updating a system application in the dual-core smart meter. The upgrade request file may be sent by the application management unit 102, the application management unit 102 may be a service for managing the dual-core smart meter, for example, system update and upgrade are performed on the dual-core smart meter, the application management unit 102 may obtain a system application to be upgraded from a memory of the dual-core smart meter, create an upgrade parameter file according to related application information of the system application to be upgraded, the upgrade parameter file may also be referred to as an upgrade action file, the application management unit 102 may also generate the upgrade request file according to the upgrade parameter file, and send the upgrade request file to the system update component 104, specifically, the upgrade parameter file may be update_actions, the upgrade request file may be update_req, and the application management unit 102 may transfer the upgrade request file update_req to the system update component 104 by calling a system update call interface ms_rtos_update ().
Through the embodiment, the system updating component 104 can update and upgrade the system application in the dual-core smart meter by receiving the upgrade request file sent by the application management unit 102, thereby realizing reliable and stable upgrade and update of the system in the dual-core smart meter.
In one embodiment, further comprising: the updated operation parameters of the system application to be upgraded are sent to an application starting unit 106 in the dual-core intelligent ammeter; the application starting unit 106 is configured to run the updated system application according to the operation parameter.
In this embodiment, the application starting unit 106 may be a device for starting the system application, for example, may start an updated system application, and the system updating component 104 may send an operation parameter used in updating to the application starting unit 106 after updating the system application to be updated is completed, where the application starting unit 106 may read the operation parameter, and may operate the updated system application according to the operation parameter. Specifically, after the system updating component 104 sends the operation parameters to the application starting unit 106, the application starting unit 106 may analyze the starting parameters written by the system updating component 104 when the operating system of the intelligent dual-core ammeter is started, call the process creation function of process management according to the installed application information, and automatically load and start the corresponding process.
Through the embodiment, the system updating component 104 can send the operation parameters to the application starting unit 106, so that the application starting unit 106 can automatically start the updated system application in the dual-core intelligent ammeter, thereby meeting the requirements of automatic production, operation and maintenance of the ammeter and improving the reliability of the upgrading of the ammeter system.
In one embodiment, as shown in fig. 4, fig. 4 is a flow chart of a system updating method based on a dual-core smart meter in another embodiment. The application management unit 102 may obtain the system application to be upgraded in the dual-core smart meter, create related upgrade parameter files update_actions, form an upgrade request file update_req according to the upgrade parameter files, call a system update call interface ms_rtos_update () to send the upgrade request file update_req to the system update component 104, after receiving the upgrade request file, the system update component 104 may call the interface ms_rtos_update () to restart the system, determine whether the upgrade request file still exists, if so, open the upgrade parameter file in the upgrade request file, sequentially read the application name of the system application to be upgraded in the upgrade parameter file, obtain the storage location of the mirror image file of the system application to be upgraded, install the mirror image file in the storage location into the flash memory, configure the operation parameters and permissions of the application, after all the system applications to be upgraded in the upgrade request file are updated, the system update component 104 may copy the operation parameter file updated in the flash memory to the internal memory, and may further end the upgrade request file. The application starting unit 106 may read the above operation parameters, so as to start the updated system application according to the operation parameters. The upgrade parameter file may be upgrade parameters conforming to the FDT format, which describe parameters such as upgrade file path, service or application main thread parameters, service or application rights, and the like.
In addition, the updated system application may also be displayed in the system update component 104 through an MCU file system, which may be a read-only file system, supporting the user to view the installed services and applications, and the installed file size. Specifically, the MCU file system supports a user to view installed services and applications through a file list under the read/mcufs/directory of a system command ls or a system API interface ms_io_readdir (), and the system update component 104 further includes a power-down upgrade security mechanism, so as to protect the upgraded and updated system applications and related information thereof when abnormal conditions such as power failure are encountered during the upgrade process.
Through the embodiment, the dual-core smart meter can perform online update on the system application to be upgraded by using the application management unit 102, the system update component 104 and the application starting unit 106, so that stable and reliable system application update of the dual-core smart meter is realized.
It should be understood that, although the steps in the flowcharts of fig. 2-4 are shown in order as indicated by the arrows, these steps are not necessarily performed in order as 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-4 may include multiple 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 at least a portion of the steps or stages in other steps or other steps.
In one embodiment, as shown in fig. 5, there is provided a system updating apparatus based on a dual-core smart meter, including: a first acquisition module 500, a second acquisition module 502, an installation module 504, and an update module 506, wherein:
the first acquisition module is used for acquiring an upgrade request file; the upgrade request file comprises an upgrade parameter file applied to a system to be upgraded in the dual-core intelligent ammeter; the upgrade parameter file includes application information and configuration information of the system application to be upgraded.
And the second acquisition module is used for acquiring the storage position of the mirror image system application corresponding to the system application to be upgraded from the upgrade parameter file according to the application information.
And the installation module is used for acquiring mirror image system applications corresponding to the system applications to be upgraded according to the storage positions and installing the mirror image system applications in the flash memory of the dual-core intelligent ammeter.
And the updating module 506 is configured to configure the running parameters and the authority of the mirror image system application after the installation is completed according to the configuration information in the upgrade parameter file, so as to update the system application to be upgraded.
In one embodiment, the apparatus further comprises: the first judging module is used for restarting the system and judging whether the upgrade request file still exists or not; if yes, acquiring application information of the system application to be upgraded from the upgrade parameter file, and returning to the step of acquiring a storage position of the mirror image system application corresponding to the system application to be upgraded from the upgrade parameter file according to the application information.
In one embodiment, the apparatus further comprises: the second judging module is used for detecting whether the plurality of system applications to be upgraded are all upgraded or not; if not, acquiring a new application to be upgraded from the upgrade parameter file as the current system application to be upgraded, acquiring application information of the current system application to be upgraded from the upgrade parameter file, and returning to the step of acquiring a storage position of the mirror image system application corresponding to the system application to be upgraded from the upgrade parameter file according to the application information.
In one embodiment, the apparatus further comprises: and the deleting module is used for deleting the upgrade request file when the plurality of system applications to be upgraded are all upgraded.
In one embodiment, the apparatus further comprises: and the storage module is used for storing the operation parameters of the updated mirror image system application into the flash memory of the dual-core intelligent ammeter when the plurality of system applications to be upgraded are upgraded.
In one embodiment, the first obtaining module 500 is specifically configured to obtain an upgrade request file sent by the application management unit; the application management unit is used for acquiring the system application to be upgraded from the memory of the dual-core intelligent ammeter, creating an upgrade parameter file, generating an upgrade request file according to the upgrade parameter file, and sending the upgrade request file to the system updating component.
In one embodiment, the apparatus further comprises: the sending module is used for sending the updated operation parameters of the system application to be upgraded to an application starting unit in the dual-core intelligent ammeter; the application starting unit is used for running the updated system application according to the running parameters.
For specific limitations regarding the system updating device based on the dual-core smart meter, reference may be made to the above limitations regarding the system updating method based on the dual-core smart meter, and thus, the description thereof will not be repeated. The above-mentioned system updating device based on the dual-core smart meter may be implemented in whole or in part by software, hardware, and a combination thereof. The above modules may be embedded in hardware or may be independent of a processor in the computer device, or may be stored in software in a memory in the computer device, so that the processor may call and execute operations corresponding to the above modules.
In one embodiment, a computer device is provided, which may be a dual-core smart meter, the internal structure of which may be as shown in fig. 6. The computer device includes a processor, a memory, and a network interface connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The database of the computer device is for storing system application related data. The network interface of the computer device is used for communicating with an external terminal through a network connection. The computer program, when executed by a processor, implements a system update method based on a dual-core smart meter.
It will be appreciated by those skilled in the art that the structure shown in fig. 6 is merely a block diagram of some of the structures associated with the present application and is not limiting of the computer device to which the present application may be applied, and that a particular computer device may include more or fewer components than shown, or may combine certain components, or have a different arrangement of components.
In one embodiment, a computer device is provided, including a memory and a processor, the memory storing a computer program, the processor implementing a system update method based on a dual-core smart meter as described above when executing the computer program.
In one embodiment, a computer readable storage medium is provided, on which a computer program is stored, which when executed by a processor implements a system update method based on a dual-core smart meter as described above.
Those skilled in the art will appreciate that implementing all or part of the above described methods may be accomplished by way of a computer program stored on a non-transitory computer readable storage medium, which when executed, may comprise the steps of the embodiments of the methods described above. Any reference to memory, storage, database, or other medium used in embodiments provided herein may include at least one of non-volatile and volatile memory. The nonvolatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical Memory, or the like. Volatile memory can include random access memory (Random Access Memory, RAM) or external cache memory. By way of illustration, and not limitation, RAM can be in the form of a variety of forms, such as static random access memory (Static Random Access Memory, SRAM) or dynamic random access memory (Dynamic Random Access Memory, DRAM), and the like.
The technical features of the above embodiments may be arbitrarily combined, and all possible combinations of the technical features in the above 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 are described in more detail and 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. Accordingly, the scope of protection of the present application is to be determined by the claims appended hereto.

Claims (10)

1. A system updating method based on a dual-core smart meter, characterized by being applied to a system updating component in the dual-core smart meter, the method comprising:
acquiring an upgrade request file; the upgrade request file comprises an upgrade parameter file applied to a system to be upgraded in the dual-core intelligent ammeter; the upgrade parameter file comprises application information and configuration information of the system application to be upgraded;
according to the application information, acquiring the storage position of the mirror image system application corresponding to the system application to be upgraded from the upgrade parameter file comprises the following steps: analyzing the upgrade parameter file according to the FDT standard, searching a node corresponding to the application information of the system application to be upgraded in the analyzed upgrade parameter file, and reading a storage position of the mirror image system application corresponding to the system application to be upgraded in the node corresponding to the application information; the storage position is a position in the dual-core intelligent ammeter;
acquiring mirror image system applications corresponding to the system applications to be upgraded according to the storage positions, and installing the mirror image system applications in a flash memory of the dual-core intelligent ammeter;
and configuring the running parameters and the authority of the mirror image system application after the installation is completed according to the configuration information in the upgrading parameter file so as to update the system application to be upgraded.
2. The method of claim 1, wherein after the obtaining the upgrade request file, comprising:
restarting the system, and judging whether the upgrade request file still exists;
if yes, acquiring the application information of the system application to be upgraded from the upgrade parameter file, and returning to the step of acquiring the storage position of the mirror image system application corresponding to the system application to be upgraded from the upgrade parameter file according to the application information.
3. The method of claim 1, wherein the upgrade parameter file includes application information of a plurality of system applications to be upgraded;
and after the running parameters and the authorities of the mirror image system application are configured and installed according to the configuration information in the upgrading parameter file so as to update the system application to be upgraded, the method further comprises the steps of:
detecting whether the plurality of system applications to be upgraded are all upgraded;
if not, acquiring a new application to be upgraded from the upgrade parameter file as a current system application to be upgraded, acquiring application information of the current system application to be upgraded from the upgrade parameter file, and returning to the step of acquiring a storage position of a mirror image system application corresponding to the system application to be upgraded from the upgrade parameter file according to the application information.
4. The method of claim 3, wherein configuring the operating parameters and permissions of the mirror system application after the installation is completed according to the configuration information in the upgrade parameter file, so as to update the system application to be upgraded, further comprises:
and deleting the upgrade request file when the plurality of system applications to be upgraded are all upgraded.
5. The method of claim 4, wherein when the plurality of system applications to be upgraded are all upgraded, storing the updated operating parameters of the mirror system application into the flash memory of the dual-core smart meter.
6. The method of claim 1, wherein the obtaining the upgrade request file comprises:
acquiring an upgrade request file sent by an application management unit; the application management unit is used for acquiring a system application to be upgraded from the memory of the dual-core intelligent ammeter, creating the upgrade parameter file, generating the upgrade request file according to the upgrade parameter file, and sending the upgrade request file to the system updating component.
7. The method as recited in claim 1, further comprising:
the updated operation parameters of the system application to be upgraded are sent to an application starting unit in the dual-core intelligent ammeter; the application starting unit is used for running the updated system application according to the running parameters.
8. A system updating device based on a dual-core smart meter, characterized by a system updating component applied in the dual-core smart meter, the device comprising:
the first acquisition module is used for acquiring an upgrade request file; the upgrade request file comprises an upgrade parameter file applied to a system to be upgraded in the dual-core intelligent ammeter; the upgrade parameter file comprises application information and configuration information of the system application to be upgraded;
the second obtaining module is used for obtaining the storage position of the mirror image system application corresponding to the system application to be upgraded in the upgrade parameter file according to the application information, and is specifically used for analyzing the upgrade parameter file according to the FDT standard, searching the node corresponding to the application information of the system application to be upgraded in the analyzed upgrade parameter file, and reading the storage position of the mirror image system application corresponding to the system application to be upgraded in the node corresponding to the application information; the storage position is a position in the dual-core intelligent ammeter;
the installation module is used for acquiring mirror image system applications corresponding to the system applications to be upgraded according to the storage positions and installing the mirror image system applications in the flash memory of the dual-core intelligent ammeter;
and the updating module is used for configuring the running parameters and the authority of the mirror image system application after the installation is completed according to the configuration information in the upgrading parameter file so as to update the system application to be upgraded.
9. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the steps of the method of any of claims 1 to 7 when the computer program is executed.
10. 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 steps of the method of any of claims 1 to 7.
CN202010686625.3A 2020-07-16 2020-07-16 System updating method and device based on double-core intelligent ammeter and computer equipment Active CN111857777B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010686625.3A CN111857777B (en) 2020-07-16 2020-07-16 System updating method and device based on double-core intelligent ammeter and computer equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010686625.3A CN111857777B (en) 2020-07-16 2020-07-16 System updating method and device based on double-core intelligent ammeter and computer equipment

Publications (2)

Publication Number Publication Date
CN111857777A CN111857777A (en) 2020-10-30
CN111857777B true CN111857777B (en) 2024-02-27

Family

ID=72984729

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010686625.3A Active CN111857777B (en) 2020-07-16 2020-07-16 System updating method and device based on double-core intelligent ammeter and computer equipment

Country Status (1)

Country Link
CN (1) CN111857777B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112395012B (en) * 2020-11-03 2024-02-27 南方电网数字电网科技(广东)有限公司 Data emptying method and device based on double-core intelligent ammeter and computer equipment
CN112559252B (en) * 2020-12-23 2021-09-03 广州技象科技有限公司 Configuration data management method and device based on attribute classification
CN112559250B (en) * 2020-12-23 2023-08-04 广州技象科技有限公司 Configuration data backup method and device for electric power Internet of things
CN112631633B (en) * 2021-01-07 2024-07-19 南方电网数字电网研究院有限公司 Function module upgrading method and device based on double-core intelligent ammeter
CN112667643B (en) * 2021-01-07 2023-09-15 南方电网数字电网研究院有限公司 Power failure data storage method and device based on double-core intelligent ammeter

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102317906A (en) * 2008-12-31 2012-01-11 施耐德电气美国股份有限公司 Automatic firmware updates for intelligent electronic devices
WO2016145679A1 (en) * 2015-03-16 2016-09-22 宇龙计算机通信科技(深圳)有限公司 Terminal upgrade method and device
CN107770279A (en) * 2017-10-31 2018-03-06 深圳市银河风云网络系统股份有限公司 Remote upgrade method and system
WO2018041061A1 (en) * 2016-08-29 2018-03-08 深圳市中兴微电子技术有限公司 Onboard device upgrade method, device, system and computer storage medium
CN109144547A (en) * 2018-08-20 2019-01-04 贵州电网有限责任公司 A kind of electric energy meter legality measurement program and non-legal system function program separation method
CN109634645A (en) * 2018-12-28 2019-04-16 深圳市有方科技股份有限公司 Firmware upgrade method and terminal
CN110764809A (en) * 2019-10-31 2020-02-07 福州汇思博信息技术有限公司 OTA APN upgrading method, device, equipment and medium
CN111258608A (en) * 2020-01-16 2020-06-09 宁波三星医疗电气股份有限公司 Software upgrading method and device for terminal equipment and electronic system
CN111314133A (en) * 2020-02-14 2020-06-19 宁波三星智能电气有限公司 Ammeter communication module upgrading method, ammeter control module and ammeter communication module

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102317906A (en) * 2008-12-31 2012-01-11 施耐德电气美国股份有限公司 Automatic firmware updates for intelligent electronic devices
WO2016145679A1 (en) * 2015-03-16 2016-09-22 宇龙计算机通信科技(深圳)有限公司 Terminal upgrade method and device
WO2018041061A1 (en) * 2016-08-29 2018-03-08 深圳市中兴微电子技术有限公司 Onboard device upgrade method, device, system and computer storage medium
CN107770279A (en) * 2017-10-31 2018-03-06 深圳市银河风云网络系统股份有限公司 Remote upgrade method and system
CN109144547A (en) * 2018-08-20 2019-01-04 贵州电网有限责任公司 A kind of electric energy meter legality measurement program and non-legal system function program separation method
CN109634645A (en) * 2018-12-28 2019-04-16 深圳市有方科技股份有限公司 Firmware upgrade method and terminal
CN110764809A (en) * 2019-10-31 2020-02-07 福州汇思博信息技术有限公司 OTA APN upgrading method, device, equipment and medium
CN111258608A (en) * 2020-01-16 2020-06-09 宁波三星医疗电气股份有限公司 Software upgrading method and device for terminal equipment and electronic system
CN111314133A (en) * 2020-02-14 2020-06-19 宁波三星智能电气有限公司 Ammeter communication module upgrading method, ammeter control module and ammeter communication module

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
Blockchain applications for legal metrology;Daniel Peters等;《2018 IEEE International Instrumentation and Measurement Technology Conference (I2MTC)》;1-6 *
基于Android的智能配电终端应用软件平台的研究与开发;张捷;《中国优秀硕士学位论文全文数据库 工程科技Ⅱ辑》;C042-1132 *

Also Published As

Publication number Publication date
CN111857777A (en) 2020-10-30

Similar Documents

Publication Publication Date Title
CN111857777B (en) System updating method and device based on double-core intelligent ammeter and computer equipment
CN103425468B (en) Plug-in type software integrating method and device
CN113434158B (en) Custom management method, device, equipment and medium for big data component
CN109389299B (en) Workflow process deployment method, workflow process deployment device, computer equipment and storage medium
CN111414391A (en) Method and system for accessing multiple data sources
CN111651304B (en) Software recovery method and device based on double-core intelligent ammeter and computer equipment
CN113407208A (en) Edge device function online configuration method based on remote deployment
CN104679500B (en) Method and device for realizing automatic generation of entity class
CN111737227A (en) Data modification method and system
CN112416957B (en) Data increment updating method and device based on data model layer and computer equipment
US20230259358A1 (en) Documentation enforcement during compilation
CN114443294B (en) Big data service component deployment method, system, terminal and storage medium
CN112631633A (en) Function module upgrading method and device based on double-core intelligent electric meter
CN106951593B (en) Method and device for generating configuration file of protection measurement and control device
CN113468143A (en) Data migration method, system, computing device and storage medium
CN105677427A (en) Module upgrading method and device
CN110908644A (en) Configuration method and device of state node, computer equipment and storage medium
CN116048609A (en) Configuration file updating method, device, computer equipment and storage medium
CN113608831B (en) Plug-in instance management method, system, storage medium and equipment
CN110795113A (en) Redis cluster service installation method, server and medium
CN113449035B (en) Data synchronization method, device, computer equipment and readable storage medium
CN115599868B (en) Data real-time synchronous processing method, system, equipment and medium
CN116302206B (en) Presto data source hot loading method based on MQ
CN113129049B (en) File configuration method and system for model training and application
CN118245532A (en) Service operation processing method, device, computer equipment and storage medium

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
CB02 Change of applicant information

Address after: Room 86, room 406, No.1, Yichuang street, Zhongxin Guangzhou Knowledge City, Huangpu District, Guangzhou City, Guangdong Province

Applicant after: Southern Power Grid Digital Grid Research Institute Co.,Ltd.

Address before: 511458 Room 1301, Chengtou Building, 106 Fengze East Road, Nansha District, Guangzhou City, Guangdong Province (self-compiled 1301-12159)

Applicant before: Southern Power Grid Digital Grid Research Institute Co.,Ltd.

CB02 Change of applicant information
TA01 Transfer of patent application right

Effective date of registration: 20230407

Address after: Full Floor 14, Unit 3, Building 2, No. 11, Middle Spectra Road, Huangpu District, Guangzhou, Guangdong 510700

Applicant after: China Southern Power Grid Digital Grid Technology (Guangdong) Co.,Ltd.

Address before: Room 86, room 406, No.1, Yichuang street, Zhongxin Guangzhou Knowledge City, Huangpu District, Guangzhou City, Guangdong Province

Applicant before: Southern Power Grid Digital Grid Research Institute Co.,Ltd.

TA01 Transfer of patent application right
GR01 Patent grant
GR01 Patent grant