CN102043634A - Embedded system and embedded software upgrading method - Google Patents

Embedded system and embedded software upgrading method Download PDF

Info

Publication number
CN102043634A
CN102043634A CN2009101105809A CN200910110580A CN102043634A CN 102043634 A CN102043634 A CN 102043634A CN 2009101105809 A CN2009101105809 A CN 2009101105809A CN 200910110580 A CN200910110580 A CN 200910110580A CN 102043634 A CN102043634 A CN 102043634A
Authority
CN
China
Prior art keywords
program
upgrading
compressed package
upgrade
decompress
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.)
Granted
Application number
CN2009101105809A
Other languages
Chinese (zh)
Other versions
CN102043634B (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.)
Konka Group Co Ltd
Original Assignee
Konka Group 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 Konka Group Co Ltd filed Critical Konka Group Co Ltd
Priority to CN200910110580.9A priority Critical patent/CN102043634B/en
Publication of CN102043634A publication Critical patent/CN102043634A/en
Application granted granted Critical
Publication of CN102043634B publication Critical patent/CN102043634B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The invention relates to an embedded system and an embedded software upgrading method. The system comprises an upgraded compressed packet loading module, an upgraded compressed packet decompressing module, a copying module and a detecting module, wherein the upgraded compressed packet loading module is used for loading an upgraded compressed packet from outside storage equipment and reading check code of the upgraded compressed packet; the upgraded compressed packet decompressing module is used for comparing the preset check code with the read check code and starting to decompressing the upgraded compressed packet if the preset code is the same as the check code, and a program exists and the upgrade failure is prompted if the preset check code is not same as the check code; the copying module is used for respectively copying a program obtained by decompressing the upgraded compressed packet to corresponding catalogs; and the detecting module is used for detecting whether the program coped to the corresponding catalogs is correct, and the upgrade is carried out if the program is correct. The invention provides guarantee for the software upgrading reliability of embedded system equipment to ensure successful upgrade, and is suitable for frequently upgrading equipment requiring frequent upgrade on the basis of flash memory partition.

Description

A kind of embedded system and embedded software upgrade method
Technical field
The present invention relates to electronic technology field, more particularly, relate to a kind of embedded system and embedded software upgrade method.
Background technology
Embedded system is meant the dedicated computer system that is used to carry out standalone feature.It is by comprising a series of microelectronic chips and devices such as microprocessor, timer, microcontroller, storer, sensor, form with the micro operation system, the control application software that are embedded in the storer, realize such as various robotization Processing tasks such as real-time control, supervision, management, mobile computing, data processing jointly.Embedded system is application-centered, based on microelectric technique, control technology, computer technology and mechanics of communication, emphasize the concertedness and the conformability of hardware-software, software and hardware can be cut out, to satisfy system to requirements such as function, cost, volume and power consumptions.Embedded software just is based on the software of Embedded System Design, and it also is a kind of of computer software, is made up of program and document thereof equally, can be subdivided into system software, support programs, application software three classes, is the important component part of embedded system.May there be some reason in embedded system device in escalation process, as sudden power, maloperation etc., cause the upgrading failure, and this requires the reliability of software upgrading is provided safeguard, and guarantees to upgrade successfully.
In the prior art, common way is to adopt the readable flash memory of writing (flash memory) as the upgrading private memory, internal storage upgrade image file is burnt to image file in the flash memory or enters upgrade mode by socket burnt-in seat and carries out corresponding order and come ROMPaq.Though the implementation procedure of this mode upgrading is fairly simple, but there is following shortcoming: if embedded software has the frequent upgrade software of renewal needs then inconvenience, run into outage in the escalation process, maloperations etc. then need to wipe again the existing burned new image file of image file, increase the complicacy of technical support personnel's operation, thereby increased cost.
Summary of the invention
The technical problem to be solved in the present invention is that the defective at existing upgrading generation maloperation easily, complexity, inconvenience provides a kind of embedded system and embedded software upgrade method.
The technical solution adopted for the present invention to solve the technical problems is:
A kind of embedded system, it comprises:
The upgrading compressed package loads module, is used for loading the upgrading compressed package from extraneous memory device, reads the check code of described upgrading compressed package;
Upgrading compressed package decompression module, the check code and the described check code that reads that are used for presetting compare, if identical, then begin the described upgrading compressed package of decompress(ion), if difference then program withdraw from, the prompting upgrading is failed;
The copy module is used for copying to corresponding catalogue respectively with obtaining program behind the described upgrading compressed package of decompress(ion);
Detection module, whether correct, if correctly then upgrade if being used to detect the described program that copies to corresponding catalogue.
Wherein, preferred, this system also comprises: the upgrade status display module is used for showing upgrade status on display terminal.
Wherein, further, described upgrade status comprises upgrading success status or upgrading status of fail.
Wherein, further; described copy module; be used for: copy to the kernel program catalogue obtaining kernel program behind the described upgrading compressed package of decompress(ion); to the defence program catalogue, application catalog is arrived in program copy with being applied behind the described upgrading compressed package of decompress(ion) with the program copy that is protected behind the described upgrading compressed package of decompress(ion).
The present invention also provides a kind of embedded software upgrade method, and it comprises step:
Load the upgrading compressed package from extraneous memory device, obtain the check code of described upgrading compressed package;
The check code and the described check code that obtains that preset are compared,, then begin the described upgrading compressed package of decompress(ion) if identical, if difference then program withdraw from, prompting upgrading failure;
Copy to corresponding catalogue respectively with obtaining program behind the described upgrading compressed package of decompress(ion);
Whether correct, if correctly then upgrade if detecting the described program that copies to corresponding catalogue.
Whether wherein, it is correct to detect the described program that copies to corresponding catalogue, if correctly then upgrade; Perhaps prompting upgrading failure further comprises step afterwards:
On display terminal, show upgrade status.
Wherein, further, describedly copy to corresponding catalogue respectively with obtaining program behind the described upgrading compressed package of decompress(ion); Specifically comprise:
Copy to the kernel program catalogue with obtaining kernel program behind the described upgrading compressed package of decompress(ion); to the defence program catalogue, application catalog is arrived in program copy with being applied behind the described upgrading compressed package of decompress(ion) with the program copy that is protected behind the described upgrading compressed package of decompress(ion).
Implement technical scheme of the present invention, has following beneficial effect: make embedded system device in escalation process, prevent some reason that may exist, as sudden power, maloperation etc., the upgrading failure that causes, for the reliability of the software upgrading of embedded system device provides safeguard, guarantee to upgrade successfully.Be applicable on existing flash partition basis, the equipment of the frequent upgrading of needs is frequently upgraded.
Description of drawings
The invention will be further described below in conjunction with drawings and Examples, in the accompanying drawing:
Fig. 1 is the process flow diagram of the embedded software upgrade method that provides of the embodiment of the invention;
Fig. 2 is the Application Example process flow diagram of the embedded software upgrade method that provides of the embodiment of the invention;
Fig. 3 is the structural drawing of the embedded system that provides of the embodiment of the invention.
Embodiment
In order to make purpose of the present invention, technical scheme and advantage clearer,, the present invention is further elaborated below in conjunction with drawings and Examples.Should be appreciated that specific embodiment described herein only in order to explanation the present invention, and be not used in qualification the present invention.
The embodiment of the invention provides a kind of embedded software upgrade method, as shown in Figure 1, comprises step:
11, load the upgrading compressed package from extraneous memory device, obtain the check code of described upgrading compressed package;
Described external device comprises USB flash disk, portable hard drive etc., and described upgrading compressed package is the compressed package that embedded system will be upgraded.
12, check code and the described check code that obtains that presets compared,, then begin the described upgrading compressed package of decompress(ion) if identical, if difference then program withdraw from, prompting upgrading failure;
This check code that presets is the check code of having deposited in the embedded system, and the check code of this check code of having deposited and this compressed package is compared.
13, copy to corresponding catalogue respectively with obtaining program behind the described upgrading compressed package of decompress(ion);
Copy to the kernel program catalogue with obtaining kernel program behind the described upgrading compressed package of decompress(ion); to the defence program catalogue, application catalog is arrived in program copy with being applied behind the described upgrading compressed package of decompress(ion) with the program copy that is protected behind the described upgrading compressed package of decompress(ion).Be specially: kernel (kernel) program (vmlinux.bin) is copied under flash memory (flash) subregion/boot/ catalogue; the defence program (vmlinux_rescue.bin) of kernel (kernel) include file system is copied under flash memory (flash) subregion/boot/ catalogue; when this defence program is used for the upgrading failure; upgrade as kernel (kernel) programmed protection program, application program (home.img) is copied under flash memory (flash) subregion/dev/mmc6 catalogue.
Whether correct, if correctly then upgrade if 14, detecting the described program that copies to corresponding catalogue.
Whether be specially: it is correct to detect the kernel program (vmlinux.bin) that copies to flash memory; whether detection copies the defence program (vmlinux_rescue.bin) of flash memory kernel include file system to correct, and whether detect the application program (home.img) that copies to flash memory correct.If correctly then upgrade.If incorrect, then upgrading failure shows the upgrading status of fail to the user.
An Application Example of the foregoing description is described below in conjunction with Fig. 2.As shown in Figure 2, this embedded software upgrade method Application Example comprises step:
101, load the upgrading compressed package;
102, judge whether this loading fails,, withdraw from the upgrading of compressed package, if not failure then carry out step 103 if failure then carry out step 117;
103, whether checking AKU check code is correct;
104, judge whether the checking check code fails; If failure then carry out step 117; If failure then carry out step 105;
105, withdraw from master routine;
106, carry out ROMPaq;
107, judge whether carry out ROMPaq fails, if failure then carry out step 117, if not failure then carry out step 108;
108, decompression upgrading compressed package;
109, judge whether the upgrading compressed package that decompresses fails, if failure then carry out step 117, if not failure then carry out step 110;
110, kernel (kernel) program (vmlinux.bin) is copied under flash memory (flash) subregion/boot/ catalogue;
Whether correct, if correct, then carry out step 112 if 111, detecting described kernel program (vmlinux.bin), if incorrect, then carry out step 117;
112, the defence program (vmlinux rescue.bin) with kernel (kernel) include file system copies under flash memory (flash) subregion/boot/ catalogue;
Whether correct, if incorrect, then carry out step 117 if 113, detecting the defence program (vmlinux_rescue.bin) copy flash memory kernel include file system to, if correct, then carry out step 114;
114, application program (home.img) is copied under flash memory (flash) subregion/dev/mmc6 catalogue;
Whether correct, if incorrect, then carry out step 118 if 115, detecting the application program (home.img) copy to flash memory, if correct, then carry out step 116;
116, software upgrade success, restart facility carry out step 118.
117, software upgrading failure, upgrade next time again, carry out step 118;
118, withdraw from this escalation process.
The embodiment of the invention also provides a kind of embedded system, and as shown in Figure 3, this system comprises:
The upgrading compressed package loads module 201, is used for loading the upgrading compressed package from extraneous memory device, reads the check code of described upgrading compressed package;
Upgrading compressed package decompression module 202, the check code and the described check code that reads that are used for presetting compare, if identical, then begin the described upgrading compressed package of decompress(ion), if difference then program withdraw from, the prompting upgrading is failed;
Copy module 203 is used for copying to corresponding catalogue respectively with obtaining program behind the described upgrading compressed package of decompress(ion); Concrete: copy to the kernel program catalogue with obtaining kernel program behind the described upgrading compressed package of decompress(ion); to the defence program catalogue, application catalog is arrived in program copy with being applied behind the described upgrading compressed package of decompress(ion) with the program copy that is protected behind the described upgrading compressed package of decompress(ion).
Detection module 204, whether correct, if correctly then upgrade if being used to detect the described program that copies to corresponding catalogue.
Further among the embodiment, this system also comprises: upgrade status display module 205 is used for showing upgrade status on display terminal.Wherein, described upgrade status comprises upgrading success status or upgrading status of fail.
The above only is preferred embodiment of the present invention, not in order to restriction the present invention, all any modifications of being done within the spirit and principles in the present invention, is equal to and replaces and improvement etc., all should be included within protection scope of the present invention.

Claims (7)

1. an embedded system is characterized in that, comprising:
The upgrading compressed package loads module, is used for loading the upgrading compressed package from extraneous memory device, reads the check code of described upgrading compressed package;
Upgrading compressed package decompression module, the check code and the described check code that reads that are used for presetting compare, if identical, then begin the described upgrading compressed package of decompress(ion), if difference then program withdraw from, the prompting upgrading is failed;
The copy module is used for copying to corresponding catalogue respectively with obtaining program behind the described upgrading compressed package of decompress(ion);
Detection module, whether correct, if correctly then upgrade if being used to detect the described program that copies to corresponding catalogue.
2. embedded system according to claim 1 is characterized in that also comprise: the upgrade status display module is used for showing upgrade status on display terminal.
3. as embedded system as described in the claim 2, it is characterized in that described upgrade status comprises upgrading success status or upgrading status of fail.
4. embedded system according to claim 1; it is characterized in that; the copy module; be used for: copy to the kernel program catalogue obtaining kernel program behind the described upgrading compressed package of decompress(ion); to the defence program catalogue, application catalog is arrived in program copy with being applied behind the described upgrading compressed package of decompress(ion) with the program copy that is protected behind the described upgrading compressed package of decompress(ion).
5. an embedded software upgrade method is characterized in that, comprises step:
Load the upgrading compressed package from extraneous memory device, obtain the check code of described upgrading compressed package;
The check code and the described check code that obtains that preset are compared,, then begin the described upgrading compressed package of decompress(ion) if identical, if difference then program withdraw from, prompting upgrading failure;
Copy to corresponding catalogue respectively with obtaining program behind the described upgrading compressed package of decompress(ion);
Whether correct, if correctly then upgrade if detecting the described program that copies to corresponding catalogue.
6. as embedded software upgrade method as described in the claim 5, it is characterized in that whether detect the described program that copies to corresponding catalogue correct, if correctly then upgrade; Perhaps prompting upgrading failure further comprises step afterwards:
On display terminal, show upgrade status.
7. as embedded software upgrade method as described in the claim 5, it is characterized in that, describedly copy to corresponding catalogue respectively obtaining program behind the described upgrading compressed package of decompress(ion); Specifically comprise:
Copy to the kernel program catalogue with obtaining kernel program behind the described upgrading compressed package of decompress(ion); to the defence program catalogue, application catalog is arrived in program copy with being applied behind the described upgrading compressed package of decompress(ion) with the program copy that is protected behind the described upgrading compressed package of decompress(ion).
CN200910110580.9A 2009-10-23 2009-10-23 Embedded system and embedded software upgrading method Active CN102043634B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN200910110580.9A CN102043634B (en) 2009-10-23 2009-10-23 Embedded system and embedded software upgrading method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN200910110580.9A CN102043634B (en) 2009-10-23 2009-10-23 Embedded system and embedded software upgrading method

Publications (2)

Publication Number Publication Date
CN102043634A true CN102043634A (en) 2011-05-04
CN102043634B CN102043634B (en) 2015-01-21

Family

ID=43909793

Family Applications (1)

Application Number Title Priority Date Filing Date
CN200910110580.9A Active CN102043634B (en) 2009-10-23 2009-10-23 Embedded system and embedded software upgrading method

Country Status (1)

Country Link
CN (1) CN102043634B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102436388A (en) * 2011-12-22 2012-05-02 华为技术有限公司 Method and device for upgrading software of embedded system
CN102999397A (en) * 2012-12-17 2013-03-27 四川九洲电器集团有限责任公司 Embedded software upgrading and checking method
CN104298532A (en) * 2014-11-04 2015-01-21 上海斐讯数据通信技术有限公司 Upgrading method and upgrading system for software
CN104375863A (en) * 2014-11-17 2015-02-25 张毓 Program online upgrading method in embedded system
CN109614116A (en) * 2018-11-20 2019-04-12 锐捷网络股份有限公司 The installation method and device of embedded system

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000207193A (en) * 1999-01-13 2000-07-28 Nec Ibaraki Ltd Magnetic tape unit and firmware updating method for the same
CN101316330A (en) * 2007-06-01 2008-12-03 深圳Tcl工业研究院有限公司 Method for upgrading television program
CN101510161A (en) * 2009-03-30 2009-08-19 北京中星微电子有限公司 Bootstrap implementing method, apparatus and portable electronic apparatus

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000207193A (en) * 1999-01-13 2000-07-28 Nec Ibaraki Ltd Magnetic tape unit and firmware updating method for the same
CN101316330A (en) * 2007-06-01 2008-12-03 深圳Tcl工业研究院有限公司 Method for upgrading television program
CN101510161A (en) * 2009-03-30 2009-08-19 北京中星微电子有限公司 Bootstrap implementing method, apparatus and portable electronic apparatus

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102436388A (en) * 2011-12-22 2012-05-02 华为技术有限公司 Method and device for upgrading software of embedded system
CN102999397A (en) * 2012-12-17 2013-03-27 四川九洲电器集团有限责任公司 Embedded software upgrading and checking method
CN104298532A (en) * 2014-11-04 2015-01-21 上海斐讯数据通信技术有限公司 Upgrading method and upgrading system for software
CN104298532B (en) * 2014-11-04 2018-05-01 上海斐讯数据通信技术有限公司 A kind of method for upgrading software and system
CN104375863A (en) * 2014-11-17 2015-02-25 张毓 Program online upgrading method in embedded system
CN109614116A (en) * 2018-11-20 2019-04-12 锐捷网络股份有限公司 The installation method and device of embedded system

Also Published As

Publication number Publication date
CN102043634B (en) 2015-01-21

Similar Documents

Publication Publication Date Title
US8468389B2 (en) Firmware recovery system and method of baseboard management controller of computing device
US10353779B2 (en) Systems and methods for detection of firmware image corruption and initiation of recovery
CN102736978B (en) A kind of method and device detecting the installment state of application program
US20110283274A1 (en) Firmware image update and management
US20150261546A1 (en) Baseboard management controller and method of loading firmware
CN102043634A (en) Embedded system and embedded software upgrading method
CN104185836A (en) Method and system for verifying proper operation of computing device after system change
CN101373433A (en) Method for updating BIOS and computer and system using the same
EP2798428B1 (en) Apparatus and method for managing operation of a mobile device
CN101930384A (en) Fault tolerance method and device for file system
CN103514065A (en) Electronic device with automatic detection and recovery function and method
US20190227811A1 (en) Method for updating a boot loader of a multiprocessor device
CN106909382B (en) Method and device for outputting different types of system starting information
CN103645918A (en) Software upgrading method and device for industrial endoscope
KR100605031B1 (en) A method for upgrading and restoring embeded systems by using usb memory device
CN104765631A (en) Restoration method and device for application program of mobile terminal
TWI310157B (en) Method for changing booting source of a computer system and related backuping/restoring method thereof
CN104778081A (en) Method for switching operating systems and electronic apparatus
CN103984585A (en) Method for upgrading Linux kernel in running process of kernel module capable of being plugged in thermal mode
CN100394392C (en) Computer programe reduction-mode automatic starting control method and system
CN103309691A (en) Information processing equipment and quick startup method thereof
TW202131170A (en) Firmware corruption recovery
KR101461650B1 (en) Apparatus and method for managing file system of a computing device
KR101225841B1 (en) Apparatus and method of updating restoration for firmware
CN104615387A (en) Vehicle-mounted equipment based on XPE system and design method of vehicle-mounted equipment

Legal Events

Date Code Title Description
PB01 Publication
C06 Publication
SE01 Entry into force of request for substantive examination
C10 Entry into substantive examination
GR01 Patent grant
C14 Grant of patent or utility model