CN110609770A - Flash off-line parameter adjusting system and method based on single chip microcomputer - Google Patents
Flash off-line parameter adjusting system and method based on single chip microcomputer Download PDFInfo
- Publication number
- CN110609770A CN110609770A CN201910760511.6A CN201910760511A CN110609770A CN 110609770 A CN110609770 A CN 110609770A CN 201910760511 A CN201910760511 A CN 201910760511A CN 110609770 A CN110609770 A CN 110609770A
- Authority
- CN
- China
- Prior art keywords
- parameter
- chip microcomputer
- single chip
- flash memory
- flash
- 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/263—Generation of test inputs, e.g. test vectors, patterns or sequences ; with adaptation of the tested hardware for testability with external testers
- G06F11/2635—Generation of test inputs, e.g. test vectors, patterns or sequences ; with adaptation of the tested hardware for testability with external testers using a storage for the test inputs, e.g. test ROM, script files
Landscapes
- Engineering & Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Hardware Design (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Stored Programmes (AREA)
Abstract
The invention provides a Flash off-line parameter adjusting system based on a single chip microcomputer, which comprises the single chip microcomputer, a display screen and a plurality of keys, wherein the single chip microcomputer comprises a FLASH memory and an RAM memory, the FLASH memory is respectively connected with the display screen and all the keys, the single chip microcomputer is used for acquiring a program from the outside, the FLASH memory is used for storing a parameter section in the program, the keys are used for adjusting all parameters of the parameter section, the display is used for displaying all parameters of the parameter section, and the RAM memory is used for reading the parameter section in the FLASH memory after being electrified every time. The invention has the beneficial effects that: the method can avoid the complicated parameter adjustment of a PC (personal computer) end downloading program, prolong the service life of the single chip microcomputer, save the internal parameter data of the RAM (random access memory) by the FLASH memory, and avoid the condition of losing the internal parameter data of the RAM during power failure.
Description
Technical Field
The invention relates to the technical field of program parameter adjustment, in particular to a Flash off-line parameter adjusting system and method based on a single chip microcomputer.
Background
With the development of chip manufacturing process and other technologies, the single chip has the characteristics of low power consumption, low voltage, large capacity, high performance, low price and the like. Therefore, more and more control devices select a single chip microcomputer as a control unit.
In general, when the environment changes or other abnormal conditions occur, many parameters are often involved to be changed. Parameters are modified in the single chip microcomputer at ordinary times, namely parameters of the RAM memory are modified, and due to the characteristics of the RAM memory, data in the RAM memory are lost when power is lost, so that parameter adjustment is inconvenient.
At present, the mainstream parameter adjustment method is to modify parameters in a PC program, and download the program into a single chip microcomputer again after compiling. The method has many defects, except for long operation time and complicated operation steps, the method has higher requirement on the external environment and stronger dependence, and if no computer is provided or the software environment is not matched, the modification task cannot be completed. In addition, parameters are called through a PC (personal computer) side downloading program, although the parameters can be stored in the single chip microcomputer, the downloading program is very complicated once and again, and the single chip microcomputer chip is irreversibly damaged by multiple times of downloading programs.
Disclosure of Invention
In view of this, the embodiment of the invention provides a Flash offline parameter adjusting system based on a single chip microcomputer.
The embodiment of the invention provides a Flash off-line parameter adjusting system based on a single chip microcomputer, which comprises the single chip microcomputer, a display screen and a plurality of keys, wherein the single chip microcomputer comprises a Flash memory and an RAM (random access memory), the Flash memory is respectively connected with the display screen and all the keys, the single chip microcomputer is used for acquiring a program from the outside, the Flash memory is used for storing a parameter section in the program, the keys are used for adjusting all parameters of the parameter section, the display is used for displaying all parameters of the parameter section, and the RAM memory is used for reading the parameter section in the Flash memory after being electrified every time.
Furthermore, the number of the keys is five, two of the keys are used for selecting parameter types, two of the keys are used for adjusting the parameter size, and the other key is used for controlling the adjusted parameters to be written into the FLASH memory.
Further, the display screen is an OLED display screen, and the types and the sizes of the parameters are displayed in real time.
The embodiment of the invention also provides a Flash off-line parameter adjusting method based on the single chip microcomputer, which comprises the following steps,
the S1 single chip microcomputer obtains programs from the outside, and comprises a FLASH memory and an RAM memory;
s2, storing the parameter section of the program in the FLASH memory;
s3, adjusting each parameter of parameter segment in the FLASH memory;
s4, the RAM memory reads each parameter of parameter segment in the FLASH memory.
Further, the method further includes S5, where the FLASH memory stores parameters stored when the RAM memory was powered off last time, and the RAM memory reads the parameters stored in the FLASH memory when the RAM memory was powered on last time.
The technical scheme provided by the embodiment of the invention has the following beneficial effects: the Flash off-line parameter adjusting system based on the single chip microcomputer stores the variable section of the program in the FLASH memory of the single chip microcomputer, directly adjusts the variable section stored in the FLASH memory through the key, reads the variable section from the FLASH memory when the RAM memory is powered on, and acquires the variable parameter required by the program, so that the complex downloading of the program parameter by the PC end can be avoided, the service life of the single chip microcomputer is prolonged, the parameter data in the RAM memory is stored in the FLASH memory, and the condition that the parameter data in the RAM memory is lost when the power is off can also be avoided.
Drawings
FIG. 1 is a schematic diagram of a display screen interface of a Flash off-line parameter adjusting system based on a single chip microcomputer;
FIG. 2 is a circuit diagram of the connection between the key and the pins of the K66 chip in this embodiment;
fig. 3 is a circuit diagram of the pin connection between the display panel and the K66 chip in this embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, embodiments of the present invention will be further described with reference to the accompanying drawings.
The embodiment of the invention provides a Flash off-line parameter adjusting system based on a single chip microcomputer, which comprises the single chip microcomputer, a display screen 2 and a plurality of keys 1.
The single chip microcomputer is used as a control unit of the control equipment, and the single chip microcomputer can obtain programs from the outside, such as downloading from a PC (personal computer) end or a mobile end. The single chip microcomputer stores the variable segment of the obtained program in the FLASH memory, and the variable segment is stored in the FLASH memory to be modified.
The FLASH memory is respectively connected with the display screen 2 and all the keys 1, and the keys 1 are used for adjusting the parameter section parameters. In this embodiment, the number of the keys 1 is five, two of the keys 1 are used to select a parameter type, that is, to switch the type of the parameter being adjusted up or down, two of the keys 1 are used to adjust the size of the parameter, that is, to increase or decrease the size of the parameter being adjusted, and the other key 1 is used to control the parameter that has been adjusted to be written into the FLASH memory, which indicates that the parameter is matched with the program running environment after the adjustment is completed. Referring to fig. 2 and 3, in this embodiment, the single chip microcomputer selects a K66 chip of nxp company, the key 1 is connected to a pin of the K66 chip to realize connection with a FLASH memory inside the single chip microcomputer, and the display screen 2 is connected to a pin of the K66 chip to realize a display function.
Referring to fig. 1, the display screen 2 is an OLED display screen, which displays types and sizes of parameters in real time, determines which specific parameter type and value of the parameter are being adjusted, and assists all the keys 1 to adjust the variable parameters stored in the FLASH memory.
After the RAM memory is powered on every time, variable parameters in the program are assigned one by one through a parameter section in the FLASH memory, so that the running environment of the program is met. Therefore, even if the RAM memory is powered off, the variable parameter data stored in the RAM memory is lost, the parameter section in the FLASH memory can be directly read when the RAM memory is powered on next time, and the loss of the parameter data in the RAM memory caused by power failure is avoided. The singlechip only downloads the program once from the outside, and the change of the program running environment is adapted by adjusting the variable parameters stored in the FLASH memory, so that the complicated debugging of downloading the program by a PC (personal computer) terminal can be avoided, and the service life of the singlechip is prolonged.
The embodiment of the invention also provides a parameter adjusting method of the Flash off-line parameter adjusting system based on the single chip microcomputer, which comprises the following steps,
the S1 single chip microcomputer obtains programs from the outside, and can be directly obtained by downloading from a PC terminal;
s2, storing the parameter section of the program in the FLASH memory;
s3, adjusting each parameter of parameter segment in the FLASH memory through the key 1 until each parameter matches the running environment of the program;
s4, the RAM memory reads each parameter of parameter segment in the FLASH memory, and assigns value to each variable parameter of the program one by one, namely, the running environment of the program is met.
S5 is that the variable parameters stored in the RAM memory are lost due to power failure, the FLASH memory stores the parameters stored in the RAM memory when the RAM memory was powered off last time, and when the RAM memory is powered on again, the program is not changed in operation, and the RAM memory directly reads the parameters stored in the FLASH memory when the RAM memory was powered off last time. When the running environment of the program is changed from the last running environment, the values of the parameters of the parameter section stored in the FLASH memory are adjusted through the key 1, and then the RAM memory directly reads the adjusted values of the parameters stored in the FLASH memory.
The above method can be mainly applied to the following cases
(1) Equipment is frequently switched on and off, so that complicated PC (personal computer) end downloading program parameter adjustment is avoided, and the service life of a single chip microcomputer is prolonged;
(2) on occasions where movable equipment such as a computer is forbidden, for example, on some match occasions, the computer is not allowed to enter the scene to modify the program, but the match environment is unknown in advance, and the method can adjust the program parameters on the scene to meet the match requirements;
(3) the method is suitable for occasions with strong environment dependence and frequent change of environmental parameters. For equipment for acquiring visual information, when sunlight, light and the like in the surrounding environment change or equipment which works outdoors but is greatly influenced by temperature changes, when environmental parameters including illumination intensity, temperature and the like change, in order to not influence the normal operation of the equipment, some parameters in a program are probably required to be changed to adapt to the changed environment, but if a computer is frequently used, the parameters can be adjusted on site to adapt to the change of the environment by using the method;
(4) and (4) on the occasion that the equipment is not stopped. The system controlled by the single chip microcomputer can be reset many times by downloading programs through the PC terminal, a period of non-working time exists, but many industrial devices cannot directly stop working in working, and once the industrial devices directly stop working, great loss is caused. This risk can now be effectively circumvented using the above method.
In this document, the terms front, back, upper and lower are used to define the components in the drawings and the positions of the components relative to each other, and are used for clarity and convenience of the technical solution. It is to be understood that the use of the directional terms should not be taken to limit the scope of the claims.
The features of the embodiments and embodiments described herein above may be combined with each other without conflict.
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and is not to be construed as limiting the invention, and any modifications, equivalents, improvements and the like that fall within the spirit and principle of the present invention are intended to be included therein.
Claims (5)
1. A Flash off-line parameter adjusting system based on a single chip microcomputer is characterized in that: the single chip microcomputer comprises a FLASH memory and an RAM (random access memory), the FLASH memory is connected with the display screen and all keys respectively, the single chip microcomputer is used for acquiring programs from the outside, the FLASH memory is used for storing parameter sections in the programs, the keys are used for adjusting all parameters of the parameter sections, the display is used for displaying all parameters of the parameter sections, and the RAM is used for reading the parameter sections in the FLASH memory after being powered on every time.
2. The Flash off-line parameter adjusting system based on the single chip microcomputer as claimed in claim 1, characterized in that: the number of the keys is five, wherein two keys are used for selecting parameter types, two keys are used for adjusting the parameter size, and the other key is used for controlling the adjusted parameters to be written into the FLASH memory.
3. The Flash off-line parameter adjusting system based on the single chip microcomputer as claimed in claim 1, characterized in that: the display screen is an OLED display screen, and the types and the sizes of all the parameters are displayed in real time.
4. A Flash off-line parameter adjusting method based on a single chip microcomputer is characterized by comprising the following steps: comprises the following steps of (a) carrying out,
the S1 single chip microcomputer obtains programs from the outside, and comprises a FLASH memory and an RAM memory;
s2, storing the parameter section of the program in the FLASH memory;
s3, adjusting each parameter of parameter segment in the FLASH memory;
s4, the RAM memory reads each parameter of parameter segment in the FLASH memory.
5. The Flash off-line parameter adjusting method based on the single chip microcomputer as claimed in claim 1, characterized in that: the method also comprises S5, wherein the FLASH memory stores parameters stored when the RAM memory is powered off last time, and the parameters stored when the RAM memory is powered on last time are read from the FLASH memory.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910760511.6A CN110609770A (en) | 2019-08-16 | 2019-08-16 | Flash off-line parameter adjusting system and method based on single chip microcomputer |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910760511.6A CN110609770A (en) | 2019-08-16 | 2019-08-16 | Flash off-line parameter adjusting system and method based on single chip microcomputer |
Publications (1)
Publication Number | Publication Date |
---|---|
CN110609770A true CN110609770A (en) | 2019-12-24 |
Family
ID=68890530
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910760511.6A Pending CN110609770A (en) | 2019-08-16 | 2019-08-16 | Flash off-line parameter adjusting system and method based on single chip microcomputer |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110609770A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111814211A (en) * | 2020-07-17 | 2020-10-23 | 深圳市易驱电气有限公司 | Frequency converter processing method and device |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103926922A (en) * | 2014-03-06 | 2014-07-16 | 杭州银江智慧城市技术集团有限公司 | Control and monitor system of smart vehicle |
CN203838556U (en) * | 2014-03-28 | 2014-09-17 | 芜湖蓝宙电子科技有限公司 | Control system for intelligent teaching vehicle |
CN104882044A (en) * | 2015-06-01 | 2015-09-02 | 德州学院 | Freescale intelligent vehicle experiment apparatus |
CN105867112A (en) * | 2016-04-15 | 2016-08-17 | 浙江大学 | Intelligent vehicle based on control algorithm with automatically optimized parameter and control method thereof |
US20160364978A1 (en) * | 2015-05-20 | 2016-12-15 | Google Inc. | Systems and methods for coordinating and administering self tests of smart home devices having audible outputs |
-
2019
- 2019-08-16 CN CN201910760511.6A patent/CN110609770A/en active Pending
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103926922A (en) * | 2014-03-06 | 2014-07-16 | 杭州银江智慧城市技术集团有限公司 | Control and monitor system of smart vehicle |
CN203838556U (en) * | 2014-03-28 | 2014-09-17 | 芜湖蓝宙电子科技有限公司 | Control system for intelligent teaching vehicle |
US20160364978A1 (en) * | 2015-05-20 | 2016-12-15 | Google Inc. | Systems and methods for coordinating and administering self tests of smart home devices having audible outputs |
CN104882044A (en) * | 2015-06-01 | 2015-09-02 | 德州学院 | Freescale intelligent vehicle experiment apparatus |
CN105867112A (en) * | 2016-04-15 | 2016-08-17 | 浙江大学 | Intelligent vehicle based on control algorithm with automatically optimized parameter and control method thereof |
Non-Patent Citations (2)
Title |
---|
冯冲等: "《飞思卡尔MC9S12(X)开发必修课[M]》", 30 June 2014, 北京航空航天大学出版社 * |
郑亚利等: "基于CMOS摄像头循迹的智能车控制系统设计", 《贵阳学院学报(自然科学版)》 * |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111814211A (en) * | 2020-07-17 | 2020-10-23 | 深圳市易驱电气有限公司 | Frequency converter processing method and device |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
KR102371906B1 (en) | Display device, mobile device having the same, and method of operating display device | |
CN104361871A (en) | Display screen debugging method, device and system | |
CN106157932B (en) | The control method and device of screen intensity | |
CN104428829A (en) | Color control method and communication apparatus | |
CN109979411B (en) | Display panel, burning method and electrifying method of display panel | |
CN103577223B (en) | Micro control unit (MCU) startup mode selecting circuit and MCU code updating method based on circuit | |
CN101378614A (en) | LED lighting kenel control system and method | |
CN103310763A (en) | Method for switching display state of mobile equipment, device and equipment | |
US20140104298A1 (en) | Method and electronic device for reducing power consumption of display | |
CN101326563A (en) | Luminous display and method for controlling the same | |
CN203838544U (en) | Multimedia exhibition hall display system | |
CN104457974B (en) | The test device and method of testing of light sensor | |
CN110609770A (en) | Flash off-line parameter adjusting system and method based on single chip microcomputer | |
US7646621B2 (en) | Programmable power supply | |
CN104780328A (en) | Driving method, device, mainboard and television | |
CN103730099A (en) | Backlight intensity adjusting method and electronic device | |
CN113805051B (en) | Switch performance testing method and device, electronic equipment and storage medium | |
CN105022647B (en) | A kind of control method and terminal of application installation | |
CN112924875B (en) | Battery detection method and device and electronic equipment | |
CN109151198A (en) | A kind of control method, mobile terminal and storage medium close to light sensor | |
CN205029439U (en) | Electric current intelligent monitoring system | |
TWI533323B (en) | Electronic device and operating method thereof | |
US20200319508A1 (en) | Liquid crystal display lighting modes | |
JP2017054379A (en) | Programmable display, communication terminal, communication terminal control program, and image creation system | |
CN205080416U (en) | Expander circuit of PLC's input point |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20191224 |
|
RJ01 | Rejection of invention patent application after publication |