CN102945173B - User program online upgrade system and upgrade method - Google Patents

User program online upgrade system and upgrade method Download PDF

Info

Publication number
CN102945173B
CN102945173B CN201210428285.XA CN201210428285A CN102945173B CN 102945173 B CN102945173 B CN 102945173B CN 201210428285 A CN201210428285 A CN 201210428285A CN 102945173 B CN102945173 B CN 102945173B
Authority
CN
China
Prior art keywords
burning
chip microcomputer
user program
program
numerical value
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
CN201210428285.XA
Other languages
Chinese (zh)
Other versions
CN102945173A (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.)
Hisense Broadband Multimedia Technology Co Ltd
Original Assignee
Hisense Broadband Multimedia 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 Hisense Broadband Multimedia Technology Co Ltd filed Critical Hisense Broadband Multimedia Technology Co Ltd
Priority to CN201210428285.XA priority Critical patent/CN102945173B/en
Publication of CN102945173A publication Critical patent/CN102945173A/en
Application granted granted Critical
Publication of CN102945173B publication Critical patent/CN102945173B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Stored Programmes (AREA)

Abstract

The invention discloses a kind of user program online upgrade system and upgrade method, described method includes: after single-chip microcomputer powers on or resets, and reads the burning mark in memorizer;If burning is designated numerical value A, then the IAP program in run memory, carries out online upgrading to the user program in memorizer;If burning is designated numerical value B, then the user program in run memory;When running user program, if receiving burning instruction, then, after change burning is designated numerical value A, carry out warm reset.If owing to single-chip microcomputer receives burning instruction when running user program, then after burning mark being revised as numerical value B, reset single-chip microcomputer;Single-chip microcomputer performs IAP program according to burning mark after the reset, it is achieved the online upgrading of user program.In this process, main frame controls the upgrading to single-chip microcomputer user program without going through hardware pins, thus saving pin resource.

Description

User program online upgrade system and upgrade method
Technical field
The present invention relates to singlechip technology, particularly relate to a kind of user program online upgrade system and upgrade method.
Background technology
User program in single-chip microcomputer is carried out burning and upgrading, is adopt parallel programming device traditionally.When in this way single-chip microcomputer being upgraded, it is necessary to repeatedly plug single-chip microcomputer, and when the single-chip microcomputer of iron plate encapsulation is upgraded, then need Rewelding and dismounting, not only troublesome poeration, and be easily damaged single-chip microcomputer.
IAP(In-ApplicationProgram, in the application programming) technology then solves this problem well.As it is shown in figure 1, storage has user program in non-volatile program memory (FLASH program storage);Single-chip microcomputer is by loading FLASH(flash memory) user program operation in program storage realizes various function, such as functions such as collection, calculating, controls.User program is normally stored in the user program area in FLASH program storage.
Additionally, in FLASH program storage, also storage has IAP program, IAP program is that JTAG or ISP such as single-chip microcomputer is burnt in FLASH program storage by special download mouth;IAP program generally has IAP power function, when single-chip microcomputer runs IAP program, by calling IAP power function, it is possible to achieve receive user program from its general purpose communication port (such as iic bus, spi bus or parallel bus), user program is burnt to FLASH program storage;So, when carrying out user program upgrading, it is not necessary to by special equipment or port, but by running IAP program, the online upgrading of user program is realized by general purpose communication port.IAP program is normally stored in the IAP program area in FLASH program storage.
After single-chip microcomputer powers on, perform Boot(and guide) program: first detect the voltage of IAPPin pin;If the level of IAPPin pin is high level, then single-chip microcomputer performs the IAP program in FLASH program storage;If the level of LoadPin pin is also high level, then IAP program starts to receive binary file from main frame (Host) to be burnt to FLASH program storage by communication bus, as the user program of new edition;Main frame is after sending binary file, and the level controlling LoadPin pin transfers low level to, then single-chip microcomputer terminates the execution of IAP program.After host computer control ResetPin pin resets, single-chip microcomputer is restarted;After single-chip microcomputer is restarted, if detecting, the voltage of IAPPin pin is low-voltage, then the user program of the new edition of burning before performing, thus realizing the online upgrading of the user program of single-chip microcomputer.
It was found by the inventors of the present invention that the online upgrading method of the single-chip microcomputer user program of prior art needs to take the hardware resource that single-chip microcomputer is more;In fact, in order to realize the control of online upgrading, occupying 3 pins of single-chip microcomputer (I O port) to be connected with main frame respectively as IAPPin, LoadPin, ResetPin pin, main frame carrys out the online upgrading of the user program of control single chip computer by these three pin.
Therefore, the online upgrading method of the single-chip microcomputer user program of prior art takies the more hardware resource of single-chip microcomputer, when function of the MCU is increasing, increasingly has the demand saving single-chip microcomputer hardware resource.
Summary of the invention
The embodiment provides a kind of user program online upgrade system and upgrade method, in order to reduce taking of the hardware resource to single-chip microcomputer when the online upgrading of user program.
According to an aspect of the invention, it is provided a kind of user program online upgrading method, including:
After described single-chip microcomputer powers on or resets, read the burning mark in non-volatile program memory;
If described burning is designated numerical value A, then runs the IAP program in described non-volatile program memory, the user program in described non-volatile program memory is carried out online upgrading;
If described burning is designated numerical value B, then run the user program in described non-volatile program memory;When running described user program, if receiving burning instruction, then change after described burning is designated numerical value A, carry out warm reset.
Wherein, the IAP program in the described non-volatile program memory of described operation, the user program in described non-volatile program memory is carried out online upgrading and specifically includes:
After described single-chip microcomputer runs described IAP program, data command is write if receiving, then being written in the user program area of described non-volatile program memory according to the data command of writing received by the binary file of reception, the user program in described non-volatile program memory is carried out online upgrading by the user program as upgrade version.
Further, after described single-chip microcomputer runs described IAP program, also include:
If described single-chip microcomputer receives writes burning identification instruction, then write burning identification instruction described in basis by the numerical value B burning being written in non-volatile program memory mark;Afterwards,
Jump to the porch of the user program area of described non-volatile program memory, start to perform the user program of described upgrade version.
Further, described receive write data command after, also include:
Write data instruction is verified by described single-chip microcomputer according to the check bit in write data instruction;If check results mistake, then return the feedback command receiving mistake;And
Described according to receive write data command the binary file of reception is written to described non-volatile program memory user program area particularly as follows:
If check results is correct, then according to the data command of writing received, the binary file of reception is written to the user program area of described non-volatile program memory, and returns the feedback command that reception is correct.
It is preferred that after the user program of the described upgrade version of described execution, also include:
In the user program operation process of described upgrade version, if described single-chip microcomputer receives described burning instruction, then change after described burning is designated numerical value A, carry out warm reset.
According to another aspect of the present invention, additionally provide a kind of user program online upgrade system, including:
Single-chip microcomputer, for reading the burning mark in non-volatile program memory after powering on or resetting;If described burning is designated numerical value B, then run the user program in described non-volatile program memory;
Main frame, for sending burning instruction to described single-chip microcomputer;
Described single-chip microcomputer is when running described user program, if receiving described burning instruction, then changes after described burning is designated numerical value A, carries out warm reset;After reset, the burning according to the numerical value A read identifies, and runs the IAP program in described non-volatile program memory;
Described main frame sends upgrade version user program to described single-chip microcomputer;
The upgrade version user program received is write in the user program area of described non-volatile program memory by described single-chip microcomputer, carries out the online upgrading of user program.
Wherein, described main frame to described single-chip microcomputer send upgrade version user program particularly as follows:
The binary file of described upgrade version user program is write data command by least one and is sent to described single-chip microcomputer by described main frame.
It is preferred that described main frame is additionally operable to, after described single-chip microcomputer transmission upgrade version user program, send to described single-chip microcomputer and write burning identification instruction;And
Described single-chip microcomputer is additionally operable to write burning identification instruction according to what receive, is written to by numerical value B in the burning mark in non-volatile program memory;Afterwards, jump to the porch of the user program area of described non-volatile program memory, start to perform the user program of described upgrade version.
It is preferred that described single-chip microcomputer is additionally operable to according to the check bit writing in data command received, the data command of writing received be verified;If check results mistake, then return the feedback command receiving mistake to described main frame;And
Described main frame, after receiving the feedback command receiving mistake that described single-chip microcomputer returns, resends and writes data command.
It is preferred that described single-chip microcomputer is additionally operable to after the user program performing described upgrade version, in the user program operation process of described upgrade version, if described single-chip microcomputer receives described burning instruction, then change after described burning is designated numerical value A, carry out warm reset.
In the technical scheme that the embodiment of the present invention provides, having burning to identify owing to increasing in non-volatile program memory, in order to after single-chip microcomputer powers on, instruction single-chip microcomputer performs IAP program or user program;And, the user program that single-chip microcomputer runs increases a function received and process the burning instruction that main frame sends: after receiving the burning instruction that main frame sends, after burning mark is revised as the value (numerical value B) that instruction single-chip microcomputer performs IAP program, reset single-chip microcomputer;Single-chip microcomputer performs IAP program according to burning mark after the reset, obtains upgrade version user program from main frame, it is achieved the online upgrading of user program.In the process, main frame controls the upgrading to single-chip microcomputer user program without going through hardware pins, but realizes what upgrading controlled by sending the software mode of burning instruction;Thus saving the pin resource of single-chip microcomputer, namely decrease taking of the hardware resource to single-chip microcomputer.
Further, after user program is carried out online upgrading by main frame, burning mark is revised as instruction single-chip microcomputer and performs the value (numerical value A) of user program by main frame also control single chip computer, make single-chip microcomputer after user program online upgrading, can automatically perform user program after powering on every time or resetting.
Accompanying drawing explanation
Fig. 1 is the schematic diagram of the single-chip microcomputer user program online upgrade system of prior art;
Fig. 2 is the schematic diagram of the single-chip microcomputer user program online upgrade system of the embodiment of the present invention;
Fig. 3 is the single-chip microcomputer bootstrap flow chart of the embodiment of the present invention;
Fig. 4 is the user program online upgrading method flow diagram of the embodiment of the present invention.
Detailed description of the invention
For making the purpose of the present invention, technical scheme and advantage clearly understand, referring to accompanying drawing and enumerate preferred embodiment, the present invention is described in more detail.However, it is necessary to illustrate, the many details listed in description are only used to make reader that one or more aspects of the present invention are had a thorough explanation, can also realize the aspects of the invention even without these specific details.
The term such as " module " used in this application, " system " is intended to include the entity relevant to computer, for instance but it is not limited to hardware, firmware, combination thereof, software or executory software.Such as, module it may be that it is not limited to: the process run on processor, processor, object, executable program, the thread of execution, program and/or computer.For example, application program and this computing equipment of computing equipment running can be modules.One or more modules may be located in an executory process and/or thread, and module can also on a computer and/or be distributed in two or more between multiple stage computer.
In technical scheme, eliminate the main frame three pins for control single chip computer user program online upgrading, but increase in FLASH program storage and have burning to identify, in order to after single-chip microcomputer powers on, instruction single-chip microcomputer performs IAP program or user program;And, the user program that single-chip microcomputer runs increases a function received and process the burning instruction that main frame sends: after receiving the burning instruction that main frame sends, after burning mark is revised as the value that instruction single-chip microcomputer performs IAP program, reset single-chip microcomputer;Single-chip microcomputer performs IAP program according to burning mark after the reset, obtains the user program of new edition from main frame, it is achieved the online upgrading of user program.In the process, main frame controls the upgrading to single-chip microcomputer user program without going through hardware pins, but realizes what upgrading controlled by sending the software mode of burning instruction;Thus saving the pin resource of single-chip microcomputer, namely decrease taking of the hardware resource to single-chip microcomputer.
The technical scheme of the embodiment of the present invention is described in detail below in conjunction with accompanying drawing.The user program online upgrade system of the single-chip microcomputer that the embodiment of the present invention provides, as in figure 2 it is shown, include: main frame 201, single-chip microcomputer 202, non-volatile program memory 203.
Wherein, non-volatile program memory 203 can be specifically FLASH device.
It is connected to common communication bus between main frame 201 and single-chip microcomputer 202, such as universal serial bus: IIC(Inter-IntegratedCircuit, mutual integrated circuit) or SPI(SerialPeripheralInterface, Serial Peripheral Interface (SPI)) bus, or parallel bus etc..Main frame 201 can be specifically computer, CPU(CentralProcessingUnit, central processing unit), microprocessor etc..
After single-chip microcomputer 202 powers on or resets, first carry out Boot(bootstrap), perform, shown in the flow chart 3 of this program, to comprise the steps:
S301: single-chip microcomputer 202 powers on or resets;
S302: single-chip microcomputer 202 performs Boot program, reads the burning mark in non-volatile program memory 203.
Non-volatile program memory 203 is generally divided into multiple pieces (Block), and single-chip microcomputer is when carrying out burning to it, when namely single-chip microcomputer is to non-volatile program memory 203 write data, it is common that monoblock operates.In certain specific piece that burning mark can be written in non-volatile program memory 203, such as, burning mark is stored in last block in non-volatile program memory 203, and this block is exclusively used in storage burning mark, do not store out of Memory, in order to avoid the mistake write to burning mark;For ease of describing, will be specific to the block of storage burning mark herein and be called burning home block.
Single-chip microcomputer 202 performs Boot program, reads burning mark from the burning home block of non-volatile program memory 203.
S303: judge the numerical value that burning identifies;If burning is designated numerical value A(the first numerical value), then perform step S304, jump to the entrance of IAP program;If burning is designated numerical value B(second value), then perform step S305, jump to the entrance of user program.
Numerical value A and numerical value B in this step are set in advance, such as, it is possible to set numerical value A, numerical value B respectively 0xFFFFFFFF, 0x00000000.The burning read when single-chip microcomputer 202 is designated 0xFFFFFFFF, then jump to the entrance of IAP program, start to perform IAP program;If the burning that single-chip microcomputer 202 reads is designated 0x00000000, then jumps to the entrance of user program, start to perform user program.
S304: single-chip microcomputer 202 jumps to the entrance of the IAP program in non-volatile program memory, runs IAP program.
S305: single-chip microcomputer 202 jumps to the entrance of the user program in non-volatile program memory, runs user program.
When single-chip microcomputer 202 runs user program, if main frame 201 needs the user program in non-volatile program memory 203 is upgraded, then concrete upgrade method flow process, as shown in Figure 4, comprise the steps:
S401: single-chip microcomputer 202 runs user program.
S402: main frame 201 sends burning instruction to single-chip microcomputer 202.
In this step, main frame 201 sends burning instruction by communication bus to single-chip microcomputer 202.Main frame 201 and single-chip microcomputer 202 can arrange a set of instruction for user program online upgrading in advance, may include that in these instructions
Burning instruction, indicates single-chip microcomputer 202 to carry out burning operation in order to main frame 201;
Write data command, indicate single-chip microcomputer 202 to write particular data to specific piece in non-volatile program memory 203 in order to main frame 201;
Feedback command, feeds back the result of write data in order to single-chip microcomputer 202 to main frame 201.
S403: after single-chip microcomputer 202 receives burning instruction, amendment burning carries out warm reset after being designated numerical value A.
Specifically, the user program that single-chip microcomputer runs is generally of the function receiving instruction and data from main frame 201, and in the user program that the single-chip microcomputer 202 of the present invention runs except including common applied function module, also includes a burning command reception processing module.
The user program that single-chip microcomputer 202 runs calls this burning command reception processing module after receiving the instruction that main frame 201 sends, if it is burning instruction that burning command reception processing module identifies the instruction of reception, then perform: amendment burning is designated numerical value A, and this single-chip microcomputer is carried out warm reset.
S404: single-chip microcomputer 202 after the reset, is restarted;
S405: single-chip microcomputer 202 identifies according to burning, performs IAP program.
Specifically, single-chip microcomputer 202 after restart, re-executes Boot program;The idiographic flow performing Boot program describes in the step shown in above-mentioned Fig. 3, repeats no more herein;
Owing to burning mark is revised as numerical value A before, therefore, in the process performing Boot program, single-chip microcomputer 202, after judging that burning is designated numerical value A, jumps to the entrance of IAP program, starts to perform IAP program.
S406: single-chip microcomputer 202 performs IAP program, receives the upgrade version user program sent from main frame 201 and is written to non-volatile program memory 203, carry out the upgrading of user program.
Specifically, main frame 201 can wait one period of time period set after sending burning instruction, such as waits 1s, and between at this moment, in section, single-chip microcomputer 202 completes to restart, and has been running for IAP program;Afterwards, main frame 201 is by new user program, and namely the binary file of upgrade version user program is by sending multiple data commands of writing to single-chip microcomputer 202, single-chip microcomputer 202 be burnt in non-volatile program memory 203 by upgrade version user program:
Single-chip microcomputer 202 performs IAP program, and what IAP program Receiving Host 201 sent writes data command, and the binary file of reception is written in the relevant block in the user program area of non-volatile program memory 203 by the data command of writing according to receiving.It is said that in general, upgrade version user program is written in the user program area of non-volatile program memory 203, in order to override original user program.That is, after single-chip microcomputer 202 runs described IAP program, the binary file that main frame 201 sends is written to the user program area in non-volatile program memory 203, and the user program in non-volatile program memory 203 is carried out online upgrading by the user program as upgrade version.
It is preferred that single-chip microcomputer 202 IAP program receive write data command after also according to its check bit, it can be verified;If check results is correct, then according to the data command of writing received, the data of reception are written in the corresponding block in non-volatile program memory 203, and return, to main frame 201, the feedback command that reception is correct;If check results mistake, then return the feedback command receiving mistake to main frame 201.Main frame 201 writes data command by what send before resending after receiving the feedback command receiving mistake.
If main frame 201 sends to single-chip microcomputer 202 when writing data command after sending burning instruction, single-chip microcomputer 202 is not also restarted, or go back off-duty IAP program, then main frame 201 will not receive the feedback command that single-chip microcomputer 202 returns in setting time period (such as 10ms), therefore, main frame 201 can resend send before write data command, until single-chip microcomputer 202 runs to return to it after IAP program receives correct feedback command.
S407: main frame 201 sends to indicate writes data command in the burning that numerical value B is written to burning home block mark, for ease of describing, writes data command by this herein and is called and writes burning identification instruction.
Main frame 201 writes burning identification instruction by transmission, as the mark terminating this user program escalation process;Namely main frame 201 sends upgrade version user program to after single-chip microcomputer 202 completing, send to single-chip microcomputer 202 and write burning identification instruction, single-chip microcomputer 202 is write in the burning mark that numerical value B is written in non-volatile program memory 203 by burning identification instruction according to described: single-chip microcomputer 202 writes burning identification instruction according to what receive, write data into the burning home block in non-volatile program memory 203, in the data being written to burning home block, the data being written to burning home position place are numerical value B.
S408: single-chip microcomputer 202 writes burning identification instruction according to what receive, identifies the burning in burning home block and is revised as numerical value B.
Specifically, the IAP program of single-chip microcomputer 202 writes burning identification instruction according to what receive, writes data into the burning home block in non-volatile program memory 203, the burning in burning home block is identified and is revised as numerical value B.
S409: single-chip microcomputer 202 jumps to the entrance of the user program of non-volatile program memory 203, starts to perform newly written upgrade version user program.
Burning identification instruction is write, as the mark terminating this user program escalation process owing to single-chip microcomputer 202 will receive;Therefore, the IAP program of single-chip microcomputer 202 is according to writing burning identification instruction, burning in burning home block is identified after being revised as numerical value B, no longer receive from main frame 201 and write data command, but jump to the porch of the user program area of non-volatile program memory 203, start to perform newly written upgrade version user program.
From the above, it can be seen that in order to after upgrading at user program single-chip microcomputer can perform new user program, main frame needs sending after upgrade version user program, and burning mark is written as numerical value B by control single chip computer.
In addition, in order to ensure the lasting upgrading of user program, in each escalation process, the upgrade version user program of write also all has burning command reception processing module as above, and call burning command reception processing module when receiving the instruction that main frame sends in order to identify whether as burning instruction, if burning instruction then carries out respective handling;It is to say, after single-chip microcomputer performs the user program of upgrade version, in the user program operation process of upgrade version, if single-chip microcomputer receives the burning instruction that main frame sends, then change after described burning is designated numerical value A, carry out warm reset.After reset, single-chip microcomputer identifies, according to the burning for numerical value A, the online upgrading carrying out user program, described in detailed process step as shown in Figure 3 above, repeats no more herein;It is achieved thereby that the lasting upgrading of user program.
Therefore, in the present invention except needs are provided with burning mark in non-volatile program memory 203, main frame is also required to carry out the amendment of corresponding burning flow process: namely main frame 201 needs to send burning instruction before carrying out user program upgrading, after upgrade version user program transmits, burning mark is written as numerical value B;And, the user program run in single-chip microcomputer is also required to have the function identifying and processing burning instruction: after receiving burning instruction, burning mark is written as numerical value A, carries out warm reset.
In the technical scheme that the embodiment of the present invention provides, having burning to identify owing to increasing in non-volatile program memory, in order to after single-chip microcomputer powers on, instruction single-chip microcomputer performs IAP program or user program;And, the user program that single-chip microcomputer runs increases a function received and process the burning instruction that main frame sends: after receiving the burning instruction that main frame sends, after burning mark is revised as the value (numerical value B) that instruction single-chip microcomputer performs IAP program, reset single-chip microcomputer;Single-chip microcomputer performs IAP program according to burning mark after the reset, obtains upgrade version user program from main frame, it is achieved the online upgrading of user program.In the process, main frame controls the upgrading to single-chip microcomputer user program without going through hardware pins, but realizes what upgrading controlled by sending the software mode of burning instruction;Thus saving the pin resource of single-chip microcomputer, namely decrease taking of the hardware resource to single-chip microcomputer.
Further, after user program is carried out online upgrading by main frame, burning mark is revised as instruction single-chip microcomputer and performs the value (numerical value A) of user program by main frame also control single chip computer, make single-chip microcomputer after user program online upgrading, can automatically perform user program after powering on every time or resetting.
One of ordinary skill in the art will appreciate that all or part of step realizing in above-described embodiment method can be by the hardware that program carrys out instruction relevant and completes, this program can be stored in a computer read/write memory medium, as: ROM/RAM, magnetic disc, CD etc..
The above is only the preferred embodiment of the present invention; it should be pointed out that, for those skilled in the art, under the premise without departing from the principles of the invention; can also making some improvements and modifications, these improvements and modifications also should be regarded as protection scope of the present invention.

Claims (7)

1. a user program online upgrading method, it is characterised in that including:
After single-chip microcomputer powers on or resets, read the burning mark in non-volatile program memory;
If described burning is designated numerical value A, then runs the IAP program in described non-volatile program memory, the user program in described non-volatile program memory is carried out online upgrading;
If described burning is designated numerical value B, then run the user program in described non-volatile program memory;When running described user program, if receiving burning instruction, then change after described burning is designated numerical value A, carry out warm reset;
Wherein, the IAP program in the described non-volatile program memory of described operation, the user program in described non-volatile program memory is carried out online upgrading and specifically includes:
After described single-chip microcomputer runs described IAP program, data command is write if receiving, then being written in the user program area of described non-volatile program memory according to the data command of writing received by the binary file of reception, the user program in described non-volatile program memory is carried out online upgrading by the user program as upgrade version;
After described single-chip microcomputer runs described IAP program, also include:
If described single-chip microcomputer receives writes burning identification instruction, then write burning identification instruction described in basis by the numerical value B burning being written in non-volatile program memory mark;Afterwards,
Jump to the porch of the user program area of described non-volatile program memory, start to perform the user program of described upgrade version.
2. the method for claim 1, it is characterised in that described receive write data command after, also include:
Write data instruction is verified by described single-chip microcomputer according to the check bit in write data instruction;If check results mistake, then return the feedback command receiving mistake;And
Described according to receive write data command the binary file of reception is written to described non-volatile program memory user program area particularly as follows:
If check results is correct, then according to the data command of writing received, the binary file of reception is written to the user program area of described non-volatile program memory, and returns the feedback command that reception is correct.
3. method as claimed in claim 2, it is characterised in that after the user program performing described upgrade version, also include:
In the user program operation process of described upgrade version, if described single-chip microcomputer receives described burning instruction, then change after described burning is designated numerical value A, carry out warm reset.
4. a user program online upgrade system, it is characterised in that including:
Single-chip microcomputer, for reading the burning mark in non-volatile program memory after powering on or resetting;If described burning is designated numerical value B, then run the user program in described non-volatile program memory;
Main frame, for sending burning instruction to described single-chip microcomputer;
Described single-chip microcomputer is when running described user program, if receiving described burning instruction, then changes after described burning is designated numerical value A, carries out warm reset;After reset, the burning according to the numerical value A read identifies, and runs the IAP program in described non-volatile program memory;
Described main frame sends upgrade version user program to described single-chip microcomputer;
The upgrade version user program received is write in the user program area of described non-volatile program memory by described single-chip microcomputer, carries out the online upgrading of user program;
Described main frame is additionally operable to, after described single-chip microcomputer transmission upgrade version user program, send to described single-chip microcomputer and write burning identification instruction;And
Described single-chip microcomputer is additionally operable to write burning identification instruction according to what receive, is written to by numerical value B in the burning mark in non-volatile program memory;Afterwards, jump to the porch of the user program area of described non-volatile program memory, start to perform the user program of described upgrade version.
5. system as claimed in claim 4, it is characterised in that described main frame send upgrade version user program to described single-chip microcomputer particularly as follows:
The binary file of described upgrade version user program is write data command by least one and is sent to described single-chip microcomputer by described main frame.
6. the system as described in claim 4 or 5, it is characterised in that
Described single-chip microcomputer is additionally operable to according to the check bit writing in data command received, the data command of writing received be verified;If check results mistake, then return the feedback command receiving mistake to described main frame;And
Described main frame, after receiving the feedback command receiving mistake that described single-chip microcomputer returns, resends and writes data command.
7. system as claimed in claim 6, it is characterised in that
Described single-chip microcomputer is additionally operable to after the user program performing described upgrade version, in the user program operation process of described upgrade version, if described single-chip microcomputer receives described burning instruction, then changes after described burning is designated numerical value A, carries out warm reset.
CN201210428285.XA 2012-10-31 2012-10-31 User program online upgrade system and upgrade method Active CN102945173B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210428285.XA CN102945173B (en) 2012-10-31 2012-10-31 User program online upgrade system and upgrade method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210428285.XA CN102945173B (en) 2012-10-31 2012-10-31 User program online upgrade system and upgrade method

Publications (2)

Publication Number Publication Date
CN102945173A CN102945173A (en) 2013-02-27
CN102945173B true CN102945173B (en) 2016-06-29

Family

ID=47728122

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210428285.XA Active CN102945173B (en) 2012-10-31 2012-10-31 User program online upgrade system and upgrade method

Country Status (1)

Country Link
CN (1) CN102945173B (en)

Families Citing this family (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103246536B (en) * 2013-04-28 2016-01-06 常州南京大学高新技术研究院 The wireless firmware upgrade method of thing connection positioning system
CN103294513A (en) * 2013-06-25 2013-09-11 龙迅半导体科技(合肥)有限公司 Software upgrading method and device
CN104423984A (en) * 2013-08-29 2015-03-18 比亚迪股份有限公司 Online upgrading method and online upgrading system
CN104156237B (en) * 2014-07-23 2018-03-09 武汉精测电子集团股份有限公司 The online upgrading method of single-chip microcomputer
CN104461668A (en) * 2015-01-04 2015-03-25 上海雷尼威尔技术有限公司 User program upgrading method and system based on LWIP protocol stack
CN104679559B (en) * 2015-02-11 2019-06-18 北京配天技术有限公司 The method of single-chip microcontroller online programming
CN105183501A (en) * 2015-08-10 2015-12-23 珠海格力电器股份有限公司 Method for preventing on-line program programming error
CN107729040A (en) * 2017-09-28 2018-02-23 郑州云海信息技术有限公司 A kind of IAP method and system of single-chip microcomputer
CN107861745A (en) * 2017-11-30 2018-03-30 厦门科华恒盛股份有限公司 A kind of application program online upgrading method, apparatus, equipment and storage medium
CN108920165A (en) * 2018-07-12 2018-11-30 北京行易道科技有限公司 Update method, device and the embedded device of software program
CN110262349A (en) * 2019-06-28 2019-09-20 中国航空工业集团公司雷华电子技术研究所 A kind of the remote online programmed method and system of C8051F series monolithic
CN110955439A (en) * 2019-12-16 2020-04-03 深圳市思天极创教育科技有限公司 Method and device for burning chip by Bluetooth based on mobile terminal
CN112527087B (en) * 2020-12-24 2022-05-06 上海宗镕电器有限公司 Hardware circuit structure of USB upgrading product firmware program
CN113553087A (en) * 2021-07-16 2021-10-26 湖北三江航天红峰控制有限公司 Singlechip program online upgrading method and device

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101271396A (en) * 2008-04-15 2008-09-24 威盛电子股份有限公司 Electronic device and method for on-line updating firmware
CN101557583A (en) * 2009-03-19 2009-10-14 珠海银邮光电技术发展股份有限公司 Remote-updating and version-switching method of repeater equipment embedded software
CN101770384A (en) * 2010-01-18 2010-07-07 深圳市航盛电子股份有限公司 Car audio system and software upgrading method thereof
CN101950253A (en) * 2010-08-12 2011-01-19 深圳市共进电子有限公司 Method for upgrading optical module firmware in optical network unit by utilizing WEB webpage interface

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100470476C (en) * 2006-05-25 2009-03-18 杭州晟元芯片技术有限公司 Program bootstrap method after chip power-on
CN100578451C (en) * 2007-01-22 2010-01-06 华为技术有限公司 System self-lifting method and apparatus
CN101667133B (en) * 2009-09-30 2012-09-05 威盛电子股份有限公司 Method for updating firmware and chip updating firmware by using same
CN102622253B (en) * 2012-03-09 2015-11-18 瑞斯康达科技发展股份有限公司 A kind of method of single-chip microcomputer and online upgrading thereof

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101271396A (en) * 2008-04-15 2008-09-24 威盛电子股份有限公司 Electronic device and method for on-line updating firmware
CN101557583A (en) * 2009-03-19 2009-10-14 珠海银邮光电技术发展股份有限公司 Remote-updating and version-switching method of repeater equipment embedded software
CN101770384A (en) * 2010-01-18 2010-07-07 深圳市航盛电子股份有限公司 Car audio system and software upgrading method thereof
CN101950253A (en) * 2010-08-12 2011-01-19 深圳市共进电子有限公司 Method for upgrading optical module firmware in optical network unit by utilizing WEB webpage interface

Also Published As

Publication number Publication date
CN102945173A (en) 2013-02-27

Similar Documents

Publication Publication Date Title
CN102945173B (en) User program online upgrade system and upgrade method
US8136108B2 (en) Updating firmware with multiple processors
CN109976767B (en) Software burning method and device
CN103777972A (en) System based on field-programmable gate array, configuration method and upgrading method
CN106569833B (en) DSP program online upgrading method with two-stage BOOT
US20100095044A1 (en) Motherboard system, storage device for booting up thereof and connector
US9836417B2 (en) Bridge configuration in computing devices
WO2021136200A1 (en) Bootloader loading method, storage medium, and embedded terminal
CN104503814A (en) Firmware program automatically downloading method of USB 3.0 data acquisition module
US20100030922A1 (en) Computer peripheral device implemented as optic storage device or/and removable disk by software emulation and implementing method thereof
CN105487890A (en) Firmware downloading method based on C51 series single chip microcomputer kernel
CN108153548A (en) A kind of EMMC firmware upgrade methods and device
CN103064695A (en) Dynamic loading system of field-programmable gate array and loading method thereof
CN111638887A (en) Program curing method for FPGA chip
WO2015196479A1 (en) Program data updating method and device
CN104158709B (en) A kind of optical module knows method for distinguishing and ports-Extending equipment
CN111897560A (en) NB-IoT module-based program upgrading system, method, device and storage medium
CN102169442A (en) Method, equipment, device and system for performing system boot by using USB (universal serial bus) device
CN114138295A (en) Method, device and system for upgrading application program firmware of electronic equipment
CN110908733B (en) Working mode determining method and device, and control method and device
KR20150072963A (en) Multisystem, and method of booting the same
CN105159714B (en) A kind of PMIC initial method and electronic equipment
CN110673988A (en) eMMC debugging method independent of self-contained firmware
CN103345456B (en) Regulate circuit and the method for BootLoader enabling address
CN115934114A (en) Software firmware online programming method and device and computer readable storage medium

Legal Events

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