A single chip microcomputer online upgrading method and system

A single-chip microcomputer and software upgrade technology, which is applied to instruments, electrical digital data processing, calculation, etc., can solve the problems of time-consuming, time-wasting, and upgrade guide area occupying a lot of FLASH, etc., and achieve the effect of saving moving time

Active Publication Date: 2019-01-18
GUANGXUN SCI & TECH WUHAN
View PDF3 Cites 13 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] At present, there are two main ways to upgrade the single-chip microcomputer: one is to divide the FLASH of the single-chip microcomputer into the application program area and the upgrade guide area, refer to figure 1 In the middle left picture, the application area is upgraded through the upgrade guide area; the biggest problem with this upgrade method is that it cannot support uninterrupted business, that is, the upgrade must be performed in the upgrade guide area.
Another way to upgrade is to divide the FLASH of the single-chip microcomputer into application program area, upgrade backup area and upgrade boot area, refer to figure 1 The picture on the right in the middle; although this upgrade method can support online upgrade without interrupting the business, the upgrade guide area occupies more FLASH, and all the backup programs need to be moved from the upgrade backup area to the application program area, and there are many copies. Will take more time, resulting in time wastage

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • A single chip microcomputer online upgrading method and system
  • A single chip microcomputer online upgrading method and system
  • A single chip microcomputer online upgrading method and system

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0046] An embodiment of the present invention provides a method for online upgrading of a single-chip microcomputer. Before using the method to upgrade, first refer to figure 2 , the FLASH of the single-chip microcomputer is divided into an interrupt vector area, an application program A area and an application program B area; wherein, the interrupt vector area is the common area of ​​the application program A area and the application program B area. The useful part of the interrupt vector area has a maximum of 300 bytes, usually more than 100 bytes, so the bytes occupied by the interrupt vector area are usually within 512 bytes, which is much smaller than the traditional upgrade boot area. The code space for application A and application B will be greatly increased.

[0047] In the embodiment of the present invention, taking the 51 single-chip microcomputer as an example, the interrupt vector area occupies the first 512 bytes (codes 0×0000-0×01FF). Wherein, the application ...

Embodiment 2

[0068] On the basis of the above-mentioned Embodiment 1, an embodiment of the present invention further provides an online upgrade system for a single-chip microcomputer, which is used to execute the online upgrade method for a single-chip microcomputer in the embodiment 1, such as Figure 12 As shown, the upgrade system includes a single-chip microcomputer 1 , a host computer upgrade software 2 and a communication interface 3 . refer to figure 2 , the FLASH of the single-chip microcomputer 1 is divided into an interrupt vector area, an application program area A, and an application program area B; wherein, the interrupt vector area is a common area of ​​the application program area A and the application program area B. The interrupt vector area described here occupies the first 512 bytes (code 0×0000-0×01FF), which is much smaller than the traditional upgrade boot area, so the code space allocated to the application program A area and the application program area B will be g...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention relates to the technical field of single chip microcomputer, especially relates to a single chip microcomputer online upgrading method and system, wherein the method comprises the following steps: the single chip microcomputer initializes the upgrading variable after receiving the upgrading start command, and replies the current running area to the upgrading software of the upper computer, so that the upgrading software of the upper computer decides to generate the upgrading Bin file to be transmitted according to the current running area; The single chip microcomputer receives the upgraded Bin file and stores the upgraded Bin file in the unrunning area of the single chip microcomputer. After receiving the upgrade jump command, MCU shuts down the interrupt, copies the interrupt vector area of upgrade program to the interrupt vector area of MCU, runs the new program after the soft restart, and completes the upgrade. The invention divides the FLASH of the single chip microcomputer into an interrupt vector area, an application program A area and an application program B area. The interrupt vector area occupies small bytes, and only the interrupt vector area needs to be copied when upgrading, thereby saving the FLASH space and the program moving time. At that same time, the upgrade Bin file can be converted into region, and the online upgrade can be realized without interrupting the service.

Description

【Technical field】 [0001] The invention relates to the technical field of single-chip microcomputers, in particular to a method and system for online upgrading of single-chip microcomputers. 【Background technique】 [0002] At present, electronic products on the market are more and more widely used single-chip microcomputer. The application program runs on the microcontroller to complete various functions of the product. Usually, after the electronic product is sold to the customer, the manufacturer needs to maintain and upgrade the electronic product, which requires the software in the CPU to be installed on the customer's site. Can download and upgrade, and try not to affect the normal work of the product. [0003] At present, there are two main ways to upgrade the single-chip microcomputer: one is to divide the FLASH of the single-chip microcomputer into the application program area and the upgrade boot area. figure 1 In the left picture, the application area is upgraded ...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): G06F8/654
CPCG06F8/654
Inventor 陈建宇胡毅张博
Owner GUANGXUN SCI & TECH WUHAN
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products