CN106354598A - One-time programmable microcontroller debugging method based on flash memory - Google Patents
One-time programmable microcontroller debugging method based on flash memory Download PDFInfo
- Publication number
- CN106354598A CN106354598A CN201610899443.8A CN201610899443A CN106354598A CN 106354598 A CN106354598 A CN 106354598A CN 201610899443 A CN201610899443 A CN 201610899443A CN 106354598 A CN106354598 A CN 106354598A
- Authority
- CN
- China
- Prior art keywords
- flash memory
- time programmable
- method based
- programmable microcontroller
- module
- 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
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/22—Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
- G06F11/26—Functional testing
- G06F11/261—Functional testing by simulating additional hardware, e.g. fault simulation
Landscapes
- Engineering & Computer Science (AREA)
- Computer Hardware Design (AREA)
- General Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Debugging And Monitoring (AREA)
- Test And Diagnosis Of Digital Computers (AREA)
Abstract
The invention discloses a one-time programmable microcontroller debugging method based on a flash memory and belongs to the technical field of electronic control devices. A simulation debugging system comprises a software part and a hardware part, wherein the software part comprises PC upper computer software and simulation monitoring chip internal firmware programs; the hardware part comprises a simulation monitoring chip, a target MCU (micro controller unit) module, a memory module and a user target board. A FLASH memory is used as a memory unit of the simulation debugging system, so that the memory module has the features such as electronic erasable programmable features, no data loss when power is off and rapid reading of data and the like; a carrier which only comprises a to-be-detected MCU core is used for replacing a field-programmable gate array and achieving the simulation function, so that the simulation effect is closer to the running condition of a to-be-detected target MCU core module; meanwhile, the field-programmable gate array is eliminated; the cost of a hardware debugging system can be reduced.
Description
Technical field
The present invention relates to electronic-controlled installation technical field, specially a kind of One Time Programmable based on flash memory
Microcontroller adjustment method.
Background technology
The application of single-chip microcomputer (mcu) has penetrated into the every field of our lives, such as instrument and meter, household electrical appliance, boat
Empty space flight, armarium, Industry Control, automotive electronics etc..What the so huge market demand had promoted mcu R & D Level enters one
Step improves.Whether normal the exploitation of and application scheme for checking mcu various functions, need the running status of monitor in real time mcu,
The application of therefore emulation debugging method is just particularly important.
Current microcontroller emulation debugging system is broadly divided into three kinds: a kind of is to replace micro-control by the artificial head of emulator
Device work processed, reads and writes including the data flow when generation of internal signal, the capture of external signal, data transfer and stores, deposits
Read-write of device etc.;Second is Lai the logical structure of complete simulated target mcu kernel with field programmable gate array, in conjunction with corresponding
Peripheral circuit such as interface circuit, level switch module etc., realize the function of target mcu;The third is directly by test program
It is burnt in One Time Programmable microcontroller and debugged.
At present in the emulation debugging system of single-chip microcomputer of main flow, comprise pc host computer, main control module, emulation module, storage
Module and interface module etc..Communicated using usb agreement between pc host computer and main control module.Test program passes through master control mould
Block is loaded in memory module.User sends emulation command to emulation module by PC control main control module, emulates mould
Block responds to it after receiving this order and returns corresponding register data.The emulation module of existing emulation debugging system
The general function to realize mcu kernel using field programmable gate array, memory module typically adopts sram single as its storage
Unit.
In existing one-chip machine simulation debugging system, it is that its emulation module typically adopts scene that shortcoming mainly has two: one
Programmable gate array is deposited with mcu chip actual motion effect realizing the function of mcu kernel, thus obtained analog simulation effect
In some fine distinctions, there is the probability leading to simulated effect undesirable;Two is to adopt static storage emulation debugging system more
, as the memory element of memory module, sram integrated level is low, and power consumption is larger for device (sram), can not preserve legacy data after power down.
Content of the invention
It is an object of the invention to provide a kind of One Time Programmable microcontroller adjustment method based on flash memory,
Some trickle differences are had with mcu chip actual motion effect with the analog simulation effect solving to propose in above-mentioned background technology
Not, adopt static memory (sram) as the memory element of memory module emulation debugging system, sram integrated level is low, power consumption more
Larger problem.
For realizing the problems referred to above, the present invention provides a kind of following technical scheme: disposably can compile based on flash memory
Journey microcontroller adjustment method, including software and hardware two parts, described software section includes pc upper computer software, simulative surveillance
Chip internal firmware program, described hardware components include simulative surveillance chip, target mcu core module, flash memory module and use
Family Target Board.
Preferably, described pc upper computer software includes institute under host computer Debugging interface and source program, host computer running status
The dynamic link library calling.
Preferably, described host computer Debugging interface makes user realize project file and debugging test journey according to the demand of oneself
The related operation of sequence.
Preferably, described debugging test program includes the single step run to test program, full speed running, breakpoint mode, reality
Apply passback display register data.
Preferably, described dynamic link library achieves the communication between host computer and simulative surveillance chip, comprises inside it
The communication protocol of the two.
Preferably, described target mcu core module is not comprise memory element by only comprising mcu internal logic structure to be measured
Carrier forms.
Preferably, described target mcu core module has burning designated lane, by this passage by test program directly by emulating
Monitoring chip is loaded onto flash memory module.
Preferably, described flash memory module is made up of flash memory.
Preferably, the microcontroller that this method is suitable for refers to the One Time Programmable microcontroller of risc structure.
Compared with prior art, the invention has the beneficial effects as follows: the present invention proposes one kind flash memory (flash)
Do not comprise the carrier of memory element as the memory module of emulation debugging system, with only comprising mcu core to be measured as emulation module
The microcontroller emulation debugging method of core component.Using flash memory as the memory element of emulation debugging system so that
This memory module has Electrical Erasable programmable features, power-off data is not lost and quickly reads characteristic of data etc..With
When, the erasability of flash memory determine test program can burning repeatedly, fall compared with directly with otp burning chip
Low debugging cost;Substitute field programmable gate array with the carrier only comprising mcu core to be measured and realize copying so that emulating
Effect is more nearly the ruuning situation of target mcu module to be measured, and saves field programmable gate array and can debug system for hardware
System is cost-effective;This method can be realized for test program being loaded directly into quick flashing by the burning designated lane of target mcu core
In memorizer (flash) module, decrease the hardware interface design between simulative surveillance chip and memory module, lifting is entirely imitated
Also because decreasing part peripheral interface circuit while true debugging system reliability, reduce further hardware cost.
Brief description
Fig. 1 is implementation principle block diagram of the present invention.
In figure: 1pc upper computer software, 2 simulative surveillance chips, 3 target mcu core modules, 4flash memory module, 5 users
Target Board.
Specific embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clear, complete
Site preparation description is it is clear that described embodiment is only a part of embodiment of the present invention, rather than whole embodiments.It is based on
Embodiment in the present invention, it is every other that those of ordinary skill in the art are obtained under the premise of not making creative work
Embodiment, broadly falls into the scope of protection of the invention.
Refer to Fig. 1, the present invention provides a kind of a kind of technical scheme: One Time Programmable micro-control based on flash memory
Device adjustment method processed, including software and hardware two parts, described software section includes pc upper computer software 1, simulative surveillance chip
Internal firmware procedure, described hardware components include simulative surveillance chip 2, target mcu core module 3, flash memory module 4 and use
Family Target Board 5.
Wherein, described pc upper computer software 1 includes host computer Debugging interface and source program, host computer running status are lower is adjusted
Dynamic link library, described host computer Debugging interface makes user realize project file and debugging test journey according to the demand of oneself
The related operation of sequence, described debugging test program includes the single step run to test program, full speed running, breakpoint mode, enforcement
Passback display register data, described dynamic link library achieves the communication between host computer and simulative surveillance chip 2, in it
Portion comprises the communication protocol of the two, and described target mcu core module 3 is not comprise to deposit by only comprising mcu internal logic structure to be measured
The carrier composition of storage unit, described target mcu core module 3 has burning designated lane, by this passage by test program directly by
Simulative surveillance chip 2 is loaded onto flash memory module 4, and described flash memory module 4 is made up of flash memory, this method institute
Applicable microcontroller refers to the One Time Programmable microcontroller of risc structure.
Specifically, during use, select the arm single-chip microcomputer of a embedded usb2.0 module in this method as simulative surveillance core
Piece 2, pc upper computer software 1 is communicated with simulative surveillance chip 2 by usb2.0 agreement, and target mcu core module 3 is using only wrapping
Do not comprise the core component as this module for the carrier of memory element containing mcu internal logic structure to be measured.Except programmable pulse is sent out
Outside the logical structures needed for normal work such as raw device, analog to digital conversion circuit, house dog and operational amplifier, target mcu core module 3 is also
Including a burning designated lane, test program directly can be loaded onto flash memory module 4 by this passage.
Before carrying out artificial debugging, first firmware program is downloaded to simulative surveillance chip 2, after starting host computer, debugging system
Enter init state, wait user to operate further.User, after editor's test program, compiles to it and can generate for adjusting
The target mcu test program of examination.Host computer send download test program order, simulative surveillance chip 2 after receiving this order,
It is parsed and is responded, will test program be sent to target mcu core module 3 by spi bus, and then by target
The burning designated lane of mcu is loaded onto flash memory module 4.Debug when user sends single step, breaking, operation to breakpoint etc.
During order, simulative surveillance chip 2 equally parses to this order, is subsequently done by target mcu core module 3 according to command context
A series of take location, the operating and return the data of corresponding registers to host computer of value.The key technology of the present invention is target
Mcu core module 3 is to be made up of the carrier of the target mcu core to be measured carrying without memory element, rather than by field programmable gate
Array emulation obtains.Therefore, debugging process and objective chip actual moving process to be measured are more pressed close to.Additionally, target mcu core mould
Burning designated lane is comprised, test program can directly download in flash memory module 4 via target mcu module 3 in block 3,
Simulative surveillance chip 2 is not necessarily the download special spare interface of test program, is reducing peripheral circuit, is improving the same of Electro Magnetic Compatibility
When, also improve the reliability of whole debugging system.
Although an embodiment of the present invention has been shown and described, for the ordinary skill in the art, permissible
Understand and can carry out multiple changes, modification, replacement to these embodiments without departing from the principles and spirit of the present invention
And modification, the scope of the present invention be defined by the appended.
Claims (9)
1. a kind of One Time Programmable microcontroller adjustment method based on flash memory, including software and hardware two parts,
It is characterized in that: described software section includes pc upper computer software (1), simulative surveillance chip internal firmware program, described hardware
Part includes simulative surveillance chip (2), target mcu core module (3), flash memory module (4) and ownership goal plate (5).
2. a kind of One Time Programmable microcontroller adjustment method based on flash memory according to claim 1, its
It is characterised by: described pc upper computer software (1) includes host computer Debugging interface and source program, host computer running status are lower is called
Dynamic link library.
3. a kind of One Time Programmable microcontroller adjustment method based on flash memory according to claim 2, its
It is characterised by: described host computer Debugging interface makes user realize project file and debugging test program correlation according to the demand of oneself
Operation.
4. a kind of One Time Programmable microcontroller adjustment method based on flash memory according to claim 3, its
It is characterised by: described debugging test program includes the single step run to test program, full speed running, breakpoint mode, implements passback
And display register data.
5. a kind of One Time Programmable microcontroller adjustment method based on flash memory according to claim 2, its
It is characterised by: described dynamic link library achieves the communication between host computer and simulative surveillance chip (2), comprises the two inside it
Communication protocol.
6. a kind of One Time Programmable microcontroller adjustment method based on flash memory according to claim 1, its
It is characterised by: described target mcu core module (3) is by the load only comprising mcu internal logic structure to be measured and not comprising memory element
Body forms.
7. a kind of One Time Programmable microcontroller adjustment method based on flash memory according to claim 1, its
It is characterised by: described target mcu core module (3) has burning designated lane, is directly supervised test program by emulation by this passage
Control chip (2) is loaded onto flash memory module (4).
8. a kind of One Time Programmable microcontroller adjustment method based on flash memory according to claim 7, its
It is characterised by: described flash memory module (4) is made up of flash memory.
9. a kind of One Time Programmable microcontroller adjustment method based on flash memory according to claim 1, its
It is characterised by: the microcontroller that this method is suitable for refers to the One Time Programmable microcontroller of risc structure.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610899443.8A CN106354598A (en) | 2016-10-14 | 2016-10-14 | One-time programmable microcontroller debugging method based on flash memory |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610899443.8A CN106354598A (en) | 2016-10-14 | 2016-10-14 | One-time programmable microcontroller debugging method based on flash memory |
Publications (1)
Publication Number | Publication Date |
---|---|
CN106354598A true CN106354598A (en) | 2017-01-25 |
Family
ID=57866662
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610899443.8A Pending CN106354598A (en) | 2016-10-14 | 2016-10-14 | One-time programmable microcontroller debugging method based on flash memory |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106354598A (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109459947A (en) * | 2018-10-29 | 2019-03-12 | 无锡中微爱芯电子有限公司 | A kind of microcontroller programming method based on Special Interface Chip |
CN110427338A (en) * | 2019-07-05 | 2019-11-08 | 中国科学院电子学研究所 | Spaceborne field programmable gate array and its reliability reinforcement means |
CN113255287A (en) * | 2021-05-21 | 2021-08-13 | 珠海市一微半导体有限公司 | OTP register verification method based on RAL |
CN114492261A (en) * | 2021-08-10 | 2022-05-13 | 北京芯娴电子科技有限公司 | Chip simulation system |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN202748777U (en) * | 2012-06-26 | 2013-02-20 | 珠海市杰理科技有限公司 | On-line singlechip debugging system |
CN104077204A (en) * | 2014-07-22 | 2014-10-01 | 无锡中微爱芯电子有限公司 | Reconfigurable 8-bit RSIC (reduced instruction set computer) SCM (Single Chip Microcomputer) simulator |
CN105487906A (en) * | 2015-12-07 | 2016-04-13 | 浪潮集团有限公司 | Method and system for realizing MCU core code updating by using plug-in FLASH |
-
2016
- 2016-10-14 CN CN201610899443.8A patent/CN106354598A/en active Pending
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN202748777U (en) * | 2012-06-26 | 2013-02-20 | 珠海市杰理科技有限公司 | On-line singlechip debugging system |
CN104077204A (en) * | 2014-07-22 | 2014-10-01 | 无锡中微爱芯电子有限公司 | Reconfigurable 8-bit RSIC (reduced instruction set computer) SCM (Single Chip Microcomputer) simulator |
CN105487906A (en) * | 2015-12-07 | 2016-04-13 | 浪潮集团有限公司 | Method and system for realizing MCU core code updating by using plug-in FLASH |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109459947A (en) * | 2018-10-29 | 2019-03-12 | 无锡中微爱芯电子有限公司 | A kind of microcontroller programming method based on Special Interface Chip |
CN110427338A (en) * | 2019-07-05 | 2019-11-08 | 中国科学院电子学研究所 | Spaceborne field programmable gate array and its reliability reinforcement means |
CN113255287A (en) * | 2021-05-21 | 2021-08-13 | 珠海市一微半导体有限公司 | OTP register verification method based on RAL |
CN114492261A (en) * | 2021-08-10 | 2022-05-13 | 北京芯娴电子科技有限公司 | Chip simulation system |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106354598A (en) | One-time programmable microcontroller debugging method based on flash memory | |
CN104077204B (en) | Reconfigurable 8 RSIC singlechip emulators | |
CN105741879B (en) | A kind of simulation intelligent electric energy meter memory test plate system and its test method | |
CN109783340B (en) | SoC test code programming method, IP test method and device | |
CN101102566B (en) | A design method and debugging method for mobile phone JTAG debugging interface signals | |
CN102521444A (en) | Cooperative simulation/verification method and device for software and hardware | |
CN102122530B (en) | A kind of system and method for programming flash memory | |
CN110427289A (en) | The method and device that automatic test SSD power down influences data consistency | |
CN107290654A (en) | A kind of fpga logic test structure and method | |
CN216901630U (en) | Interface conversion circuit and chip burning device | |
CN105446859B (en) | The software condition monitoring of power consumption analysis and wave file automatic generation method | |
CN108563452A (en) | A kind of method and system of embedded scm automatic online programming program | |
CN209086915U (en) | C8051F SCM program burning device | |
CN103793263A (en) | DMA transaction-level modeling method based on Power PC processor | |
CN2904109Y (en) | Pocket 51 series single chip machine simulator | |
CN114138360A (en) | Multi-core programming starting method and system of DSP on Flash | |
CN102193860B (en) | Microcontroller online debugging circuit and method as well as microcontroller | |
CN113204456A (en) | Test method, tool, device and equipment for VPP interface of server | |
CN101281507A (en) | USB interface type DSP real-time simulation development system | |
CN104572515B (en) | Tracking module, method, system and on-chip system chip | |
CN102955872B (en) | There is the emulator of parameter propagation function | |
CN216210991U (en) | Wireless transmission multi-path RISC-V chip debugger based on WIFI | |
CN205247119U (en) | Gradual signal real -time supervision device of low frequency | |
CN103336752A (en) | Microcontroller real-time data transmission device and method | |
CN204331709U (en) | Have both the simulator of external memory circuit and built-in memory circuit |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
CB02 | Change of applicant information |
Address after: 214000 D3, Wuxi science and Technology Park, Changjiang Road, No. 21, Changjiang District, Jiangsu, China Applicant after: WUXI I-CORE ELECTRONICS CO., LTD. Address before: 214000 Jiangsu city of Wuxi province DiCui Binhu District Liyuan Development Zone, Road No. 100 building 9 layer 2 Applicant before: WUXI I-CORE ELECTRONICS CO., LTD. |
|
COR | Change of bibliographic data | ||
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 |
Application publication date: 20170125 |
|
RJ01 | Rejection of invention patent application after publication |