[go: up one dir, main page]
More Web Proxy on the site http://driver.im/

CN111309359A - Firmware remote control automatic upgrading method, electronic equipment and storage medium - Google Patents

Firmware remote control automatic upgrading method, electronic equipment and storage medium Download PDF

Info

Publication number
CN111309359A
CN111309359A CN202010180530.4A CN202010180530A CN111309359A CN 111309359 A CN111309359 A CN 111309359A CN 202010180530 A CN202010180530 A CN 202010180530A CN 111309359 A CN111309359 A CN 111309359A
Authority
CN
China
Prior art keywords
firmware
equipment
upgrading
write
data block
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.)
Pending
Application number
CN202010180530.4A
Other languages
Chinese (zh)
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.)
Shenzhen Yibang Internet Of Things Technology Co ltd
Original Assignee
Shenzhen Yibang Internet Of Things 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 Shenzhen Yibang Internet Of Things Technology Co ltd filed Critical Shenzhen Yibang Internet Of Things Technology Co ltd
Priority to CN202010180530.4A priority Critical patent/CN111309359A/en
Publication of CN111309359A publication Critical patent/CN111309359A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/08Error detection or correction by redundancy in data representation, e.g. by using checking codes
    • G06F11/10Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's
    • G06F11/1004Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's to protect a block of data words, e.g. CRC or checksum

Landscapes

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

Abstract

The invention discloses a firmware remote control automatic upgrading method, which comprises the following steps: when detecting that the equipment needs to write in the firmware, judging whether the firmware exists on the equipment or not, if so, upgrading the firmware by the equipment, otherwise, transmitting the firmware to a corresponding storage interval on the equipment; and receiving write-in state information from the equipment, and upgrading the firmware by the equipment when detecting that the firmware is completely written into the equipment. According to the invention, through a corresponding firmware transmission and verification mechanism, whether equipment needs to be upgraded or not is automatically detected, whether firmware needs to be transmitted or not is automatically detected, manual intervention is not required in the whole process, the economic and time cost caused by the fact that field operation and maintenance personnel frequently confirm the connection state of the equipment and manually upgrade the equipment due to unstable equipment connection is avoided, and the purposes of enabling the upgrading process to be accurate and efficient are achieved.

Description

Firmware remote control automatic upgrading method, electronic equipment and storage medium
Technical Field
The present invention relates to device upgrading technologies, and in particular, to a firmware remote control automatic upgrading method, an electronic device, and a storage medium.
Background
The solar photovoltaic industry has become one of the ways in which the energy strategy of China is not negligible, the solar photovoltaic power generation system is mainly formed by connecting a series of solar cell modules at present, but the dependence of the solar photovoltaic system on the environment determines the instability of the performance of the solar photovoltaic system, such as illumination intensity, aging of a cell panel, dirt, artificial improper operation, different specifications of the cell panel and the like, the damage or efficiency reduction of the solar photovoltaic module becomes a normal state, and due to the fact that the possibility of faults is numerous, the positioning is difficult, the shutdown is caused with high possibility, and the great loss of economic benefit can be caused because maintenance personnel cannot successfully upgrade for many times. In the solar photovoltaic industry, photovoltaic equipment is installed at a place relatively far away from a place where the photovoltaic equipment is resident, the cost of going to a site is high, and the site is inconvenient to operate. Therefore, the workload of upgrading is greatly increased, and the operation per se has certain technical threshold and operation difficulty and needs to be completed by professional personnel. A certain technical barrier is created for common users, and the method is humanized.
Disclosure of Invention
In order to overcome the defects of the prior art, the invention aims to provide a firmware remote control automatic upgrading method which can solve the problems of large workload and high difficulty of firmware upgrading in the prior art.
The second objective of the present invention is to provide an electronic device, which can solve the problems of the prior art that the firmware upgrade workload is large and the difficulty is large.
The invention also aims to provide a storage medium which can solve the problems of large workload and difficulty in firmware upgrade in the prior art.
One of the purposes of the invention is realized by adopting the following technical scheme:
the firmware remote control automatic upgrading method comprises the following steps:
when detecting that the equipment needs to write in the firmware, judging whether the firmware exists on the equipment or not, if so, upgrading the firmware by the equipment, otherwise, transmitting the firmware to a corresponding storage interval on the equipment;
and receiving write-in state information from the equipment, and upgrading the firmware by the equipment when detecting that the firmware is completely written into the equipment.
Preferably, when it is determined that the device needs to write the firmware and the firmware does not exist, the firmware is divided into a plurality of data blocks and sequentially transmitted to the corresponding storage intervals on the device.
Preferably, each data block is equal in size, and when the bytes of the last data block are less than the bytes of the other data blocks, the OxFF is filled in the last data block.
Preferably, when the data blocks are sequentially transmitted to the device, the writing status information of each data block from the device is received, so as to judge whether the data block is successfully written according to the writing status of the data block.
Preferably, when the writing of the data block fails, the data block is retransmitted to the device.
Preferably, whether the firmware is completely written is detected through the MD5 algorithm.
Preferably, whether the firmware is completely written is detected, and meanwhile, the actual length of the firmware is acquired, and the actual length and the fixed MD5 value are stored in the storage interval.
Preferably, the firmware is stored in a memory external to the device.
The second purpose of the invention is realized by adopting the following technical scheme:
an electronic device having stored thereon a memory, a processor, and a computer readable program stored in the memory and executable by the processor, the computer readable program when executed by the processor implementing the steps of:
when detecting that the equipment needs to write in the firmware, judging whether the firmware exists on the equipment or not, if so, upgrading the firmware by the equipment, otherwise, transmitting the firmware to a corresponding storage interval on the equipment;
and receiving write-in state information from the equipment, and upgrading the firmware by the equipment when detecting that the firmware is completely written into the equipment.
The third purpose of the invention is realized by adopting the following technical scheme:
a storage medium having a computer readable program stored thereon that is executable by a processor, the computer readable program when executed by the processor implementing the steps of:
when detecting that the equipment needs to write in the firmware, judging whether the firmware exists on the equipment or not, if so, upgrading the firmware by the equipment, otherwise, transmitting the firmware to a corresponding storage interval on the equipment;
and receiving write-in state information from the equipment, and upgrading the firmware by the equipment when detecting that the firmware is completely written into the equipment.
Compared with the prior art, the invention has the beneficial effects that:
according to the invention, through a corresponding firmware transmission and verification mechanism, whether equipment needs to be upgraded or not is automatically detected, whether firmware needs to be transmitted or not is automatically detected, manual intervention is not required in the whole process, the economic and time cost caused by the fact that field operation and maintenance personnel frequently confirm the connection state of the equipment and manually upgrade the equipment due to unstable equipment connection is avoided, and the purposes of enabling the upgrading process to be accurate and efficient are achieved.
Drawings
Fig. 1 is a flowchart of a firmware remote control automatic upgrade method according to the present invention.
Detailed Description
The invention will be further described with reference to the accompanying drawings and the detailed description below:
the invention provides a firmware remote control automatic upgrading method, as shown in figure 1, comprising the following steps:
s1: and detecting whether the equipment needs to write the firmware, if so, executing S2, otherwise, not performing the operation of writing the firmware into the equipment.
In this step, the device to be upgraded is selected, the inverter and the data collector in the device are extracted, whether the device is on-line is judged, and when the device is on-line, whether the device needs to be written in the firmware can be detected.
S2: it is determined whether firmware is present on the device. If so, executing S3 to upgrade the firmware, otherwise, executing S4 to transmit the firmware to the corresponding storage section on the device.
The device needs to write the firmware, which indicates that the device has an upgrade requirement, and the detection of whether the device needs to write the firmware is also to detect whether the device needs to be upgraded. When the device is detected to need to be upgraded, whether the upgrade package is stored in the device is further judged. When the firmware is stored in the device, the server does not transmit the firmware to the device, so as to avoid resource waste. When the firmware is not present on the device, the firmware is transferred to the device.
In this step, the storage area is a memory externally connected to the device. That is, the firmware transmitted by the server is stored in a memory external to the device.
Further, in this step, when it is determined that the device needs to write the firmware and the firmware does not exist, the firmware is divided into a plurality of data blocks and sequentially transmitted to the corresponding storage sections on the device. Each data block is equal in size, and when the bytes of the last data block are less than the bytes of the other data blocks, the OxFF is filled in the last data block. For example, each data block is 1024 bytes, and when the last database is less than 1024 bytes, the data blocks are supplemented by OxFF to set the database, so that data transmission is facilitated. The transmitted firmware has an upgrade baud rate, but the true baud rate should be 100 times the upgrade baud rate, e.g. 1152bps for the upgrade baud rate, 115300bps for the true baud rate.
S5: write status information is received from the device.
In this step, the server uses the function code to receive the data blocks from the data digital collector, that is, the write status information of the data blocks, and whether the data blocks are written successfully or not is characterized by using a "data block write record table", which is a 16-bit byte string with the number of bytes equal to the "number of data blocks" in the request command, where each bit of each byte represents the write status of one data block, and a value of 1 represents write success, and a value of 0 represents no write or write failure. Bit0 through Bit7 of the first byte represent the write status of the data blocks numbered 0 through 7, respectively, Bit0 through Bit7 of the second byte represent the write status of the data blocks numbered 8 through 15, respectively, and so on. If the remaining data block is less than one byte of bits, the redundant bits are directly set to 1.
S6: and judging whether the firmware is completely written into the equipment, if so, executing S3 to upgrade the firmware by the equipment, otherwise, executing S7 to retransmit the missing data blocks.
Specifically, when the data blocks are sequentially transmitted to the device, the writing state information of each data block from the device is received, so as to judge whether the data block is successfully written according to the writing state of the data block. And when the writing of the data block fails, retransmitting the data block to the equipment. This step detects whether the firmware is completely written by the MD5 algorithm.
Further, whether the firmware is completely written is detected, meanwhile, the actual length of the firmware is obtained, and the actual length and the fixed MD5 value are stored in the storage interval.
After the server transmits all the firmware, the functional code is used for triggering the digital collector to carry out integrity verification on the written firmware, so that no error is generated when the firmware is written, and the verification mode adopts an MD5 algorithm commonly adopted in file verification. Meanwhile, the digital collector is informed of the real (not adjusted) firmware size through the field of 'check length', and the digital collector takes the value of the field as the actual length of the firmware to be burned at this time and stores the actual length into the information area of the external memory after burning so as to transmit the actual length when burning the firmware of the equipment. Also stored is the MD5 value for checking before the next upgrade if the firmware to be upgraded has been delivered to the digital collector.
After the firmware is transmitted, the server informs the digital collector of exiting the file transmission state and the exit reason through the function code. And then, the server also queries the firmware upgrading progress of the equipment corresponding to the digital collector by using the function codes.
The present invention also provides an electronic device having stored thereon a memory, a processor, and a computer readable program stored in the memory and executable by the processor, the computer readable program when executed by the processor implementing the steps of: when detecting that the equipment needs to write in the firmware, judging whether the firmware exists on the equipment or not, if so, upgrading the firmware by the equipment, otherwise, transmitting the firmware to a corresponding storage interval on the equipment; and receiving write-in state information from the equipment, and upgrading the firmware by the equipment when detecting that the firmware is completely written into the equipment.
The present invention also provides a storage medium having a computer readable program stored thereon that is executable by a processor, the computer readable program when executed by the processor implementing the steps of: when detecting that the equipment needs to write in the firmware, judging whether the firmware exists on the equipment or not, if so, upgrading the firmware by the equipment, otherwise, transmitting the firmware to a corresponding storage interval on the equipment; and receiving write-in state information from the equipment, and upgrading the firmware by the equipment when detecting that the firmware is completely written into the equipment.
The electronic device and the storage medium provided by the invention have the same principle as the firmware remote control automatic upgrading method provided by the invention, and are not described again.
Various other modifications and changes may be made by those skilled in the art based on the above-described technical solutions and concepts, and all such modifications and changes should fall within the scope of the claims of the present invention.

Claims (10)

1. The firmware remote control automatic upgrading method is characterized by comprising the following steps:
when detecting that the equipment needs to write in the firmware, judging whether the firmware exists on the equipment or not, if so, upgrading the firmware by the equipment, otherwise, transmitting the firmware to a corresponding storage interval on the equipment;
and receiving write-in state information from the equipment, and upgrading the firmware by the equipment when detecting that the firmware is completely written into the equipment.
2. The method for automatically upgrading firmware according to claim 1, wherein when it is determined that the device needs to write the firmware and no firmware exists, the firmware is divided into a plurality of data blocks and sequentially transmitted to corresponding storage sections on the device.
3. The firmware remote control automatic upgrade method according to claim 2, wherein each data block is equal in size, and when bytes of the last data block are less than other data blocks, the OxFF is padded into the last data block.
4. The firmware remote control automatic upgrade method according to claim 3, wherein when the data blocks are sequentially transmitted to the device, write status information for each data block from the device is received to determine whether the data block is successfully written according to the write status of the data block.
5. The method of claim 4, wherein the data block is retransmitted to the device when the writing of the data block fails.
6. The firmware remote control automatic upgrade method according to claim 1, wherein it is detected by MD5 algorithm whether the firmware is written completely.
7. The firmware remote control automatic upgrading method according to claim 6, characterized in that whether the firmware is completely written is detected, meanwhile, the actual length of the firmware is obtained, and the actual length and the fixed MD5 value are stored in the storage interval.
8. The method for remotely controlled automatic upgrade of firmware according to claim 1, wherein the firmware is stored in a memory external to the device.
9. An electronic device having a memory, a processor, and a computer readable program stored in the memory and executable by the processor, wherein the computer readable program when executed by the processor implements the steps of:
when detecting that the equipment needs to write in the firmware, judging whether the firmware exists on the equipment or not, if so, upgrading the firmware by the equipment, otherwise, transmitting the firmware to a corresponding storage interval on the equipment;
and receiving write-in state information from the equipment, and upgrading the firmware by the equipment when detecting that the firmware is completely written into the equipment.
10. A storage medium having a computer readable program stored thereon that is executable by a processor, the computer readable program when executed by the processor implementing the steps of:
when detecting that the equipment needs to write in the firmware, judging whether the firmware exists on the equipment or not, if so, upgrading the firmware by the equipment, otherwise, transmitting the firmware to a corresponding storage interval on the equipment;
and receiving write-in state information from the equipment, and upgrading the firmware by the equipment when detecting that the firmware is completely written into the equipment.
CN202010180530.4A 2020-03-16 2020-03-16 Firmware remote control automatic upgrading method, electronic equipment and storage medium Pending CN111309359A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010180530.4A CN111309359A (en) 2020-03-16 2020-03-16 Firmware remote control automatic upgrading method, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010180530.4A CN111309359A (en) 2020-03-16 2020-03-16 Firmware remote control automatic upgrading method, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN111309359A true CN111309359A (en) 2020-06-19

Family

ID=71158705

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010180530.4A Pending CN111309359A (en) 2020-03-16 2020-03-16 Firmware remote control automatic upgrading method, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN111309359A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113568648A (en) * 2021-07-19 2021-10-29 上海智能网联汽车技术中心有限公司 Program online upgrading method, device and medium for embedded microprocessor

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20040022020A (en) * 2002-09-06 2004-03-11 삼성전자주식회사 Display device and method for upgrading firmware remotely
WO2015051647A1 (en) * 2013-10-10 2015-04-16 中兴通讯股份有限公司 Firmware upgrade method and system, upper computer and optical module
CN107645419A (en) * 2017-10-20 2018-01-30 深圳益邦阳光有限公司 Firmware upgrade method, electronic equipment and storage medium based on Transmission Control Protocol
CN107908417A (en) * 2017-10-24 2018-04-13 北京臻迪科技股份有限公司 Firmware upgrade method and electronic equipment
CN108021410A (en) * 2017-12-06 2018-05-11 九阳股份有限公司 A kind of firmware upgrade method and system of intelligent appliance equipment
CN108804118A (en) * 2018-04-25 2018-11-13 顺丰科技有限公司 Firmware upgrade method, equipment and storage medium
CN110175042A (en) * 2019-06-04 2019-08-27 深圳云里物里科技股份有限公司 A kind of firmware upgrade method, device and its relevant device

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20040022020A (en) * 2002-09-06 2004-03-11 삼성전자주식회사 Display device and method for upgrading firmware remotely
WO2015051647A1 (en) * 2013-10-10 2015-04-16 中兴通讯股份有限公司 Firmware upgrade method and system, upper computer and optical module
CN107645419A (en) * 2017-10-20 2018-01-30 深圳益邦阳光有限公司 Firmware upgrade method, electronic equipment and storage medium based on Transmission Control Protocol
CN107908417A (en) * 2017-10-24 2018-04-13 北京臻迪科技股份有限公司 Firmware upgrade method and electronic equipment
CN108021410A (en) * 2017-12-06 2018-05-11 九阳股份有限公司 A kind of firmware upgrade method and system of intelligent appliance equipment
CN108804118A (en) * 2018-04-25 2018-11-13 顺丰科技有限公司 Firmware upgrade method, equipment and storage medium
CN110175042A (en) * 2019-06-04 2019-08-27 深圳云里物里科技股份有限公司 A kind of firmware upgrade method, device and its relevant device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
方兵兵;闻路红: "基于TFTP与AES的嵌入式设备远程固件升级", 《数据通信》 *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113568648A (en) * 2021-07-19 2021-10-29 上海智能网联汽车技术中心有限公司 Program online upgrading method, device and medium for embedded microprocessor

Similar Documents

Publication Publication Date Title
CN107453925A (en) Remote firmware updating method and cloud platform based on multistage communication platform
CN105183515A (en) Cloud deck firmware updating method and device
CN104750566A (en) Serial link fault detection system and method
CN111309359A (en) Firmware remote control automatic upgrading method, electronic equipment and storage medium
CN105630861A (en) Operation parameter management method and system of distributed data acquisition system
CN111371756B (en) Method for automatically converting communication protocol of inverter
CN101197640A (en) HARQ remained error detection method and system
KR102014202B1 (en) Power generation management system
CN117171083B (en) NAK-based system for adaptively repairing PCIE interface interconnection link
CN111124785B (en) Method, device, equipment and storage medium for hard disk fault detection
US7155636B2 (en) Method for detecting faults between storage devices and storage devices using the same
CN111565236B (en) Automatic coding method and device for sensor of fire protection system
KR102711057B1 (en) Method for updating BMS software of an energy storage system having different internal and external communication methods
CN102984160B (en) Distributed network scan task processing method and system
CN113672246B (en) Optical module upgrading device, system and method
CN111669389A (en) Data transmission method and device of industrial control system and related equipment
CN104038309A (en) Simulation system communication method and simulation system
CN117201222B (en) I2C interface system, data writing method and data reading method
CN116088912B (en) Application system, method and computer readable storage medium for upgrading user terminal equipment
KR20240143232A (en) Photovoltaic power generation system, and apparatus and method for updating firmware of mlpe
CN113934579B (en) Hardware detection method and equipment for short-distance single-signal transmission network
CN116820530A (en) Data transmission system based on IAP technology
CN210324177U (en) Remote measuring terminal machine supporting rapid and reliable remote upgrading
CN112463704B (en) Method, device and equipment for identifying topology of case and storage medium
CN101354665B (en) Control apparatus and control method

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20200619