CN101950160B - Anti-jamming method of electrical appliance, control system and corresponding electrical appliance - Google Patents
Anti-jamming method of electrical appliance, control system and corresponding electrical appliance Download PDFInfo
- Publication number
- CN101950160B CN101950160B CN 201010218283 CN201010218283A CN101950160B CN 101950160 B CN101950160 B CN 101950160B CN 201010218283 CN201010218283 CN 201010218283 CN 201010218283 A CN201010218283 A CN 201010218283A CN 101950160 B CN101950160 B CN 101950160B
- Authority
- CN
- China
- Prior art keywords
- setting value
- setup unit
- storer
- electrical equipment
- reset
- 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.)
- Expired - Fee Related
Links
Images
Landscapes
- Techniques For Improving Reliability Of Storages (AREA)
Abstract
The invention is applicable to the field of a controller for a household electric appliance, and provides an anti-jamming method of the electrical appliance, a control system and the corresponding electrical appliance. In the embodiment of the invention, a setting value is written into a memory in case of normal power-on operation; the setting value is removed in case of normal termination of a task program; and the setting value is still stored in the memory in case of abnormal reset so as to smoothly judge whether the controller is reset abnormally; and if yes, the memory is not initialized and can be restored to the state before reset according to operating parameters stored by the memory, thus solving the problem that the controller is out of control in the event that a reset circuit is reset in an abnormal situation, which less causes damage to the whole household electric appliance and more leads to safety accidents.
Description
Technical field
The invention belongs to the domestic electric appliances controller field, relate in particular to a kind of electrical equipment anti-disturbance method, control system and corresponding electric appliance.
Background technology
Usually, in each domestic electric appliances controller, include the circuit that resets, see also Fig. 1,2, generally use the circuit structure of two kinds of periphery circuits that reset for the MCU of Single Chip Microcomputer (SCM) system.Although what have also can use the internal reset circuit that MCU carries; because the restriction of cost; can not add too many protection circuit; under normal environment for use, these the two kinds circuits that reset can both work reliably, and the voltage that resets mouthful when powering on and the voltage pattern of power supply are seen Fig. 3; as long as produce one several milliseconds low level at the resetting pin of MCU; MCU will enter reset mode, and a series of initialization operation is carried out in inside, and the program in the complete rear MCU of initialization will be moved.
Power on or abnormal conditions under, produce a reset signal and offer MCU, order MCU carries out internal initialization and resets.For normal power-on reset signal, these two kinds of circuits that reset are working properly, if but under abnormal conditions, such as electromagnetic interference (EMI), in the situation that low-voltage resets, if do not process, whole controller will be out of control (such as program fleet, the load that should not open is by false triggering), thus gently then cause easily whole household appliances to damage, heavy then lead to easily security incident.
Summary of the invention
The purpose of the embodiment of the invention is to provide a kind of electrical equipment anti-disturbance method, is intended to solve under abnormal conditions, and the circuit that resets produces when resetting, and controller will be out of control, gently then causes easily whole household appliances to damage, and is heavy then lead to easily the problem of security incident.
The embodiment of the invention is achieved in that a kind of electrical equipment anti-disturbance method, said method comprising the steps of:
Behind the appliance starting task program, write setting value X at the setup unit of the storer of electrical equipment;
When the task program normal termination, remove the setting value X of the setup unit of described storer;
Reset when powering on, judge whether the value of the setup unit of described storer is setting value X;
If be setting value X, then be judged to be exceptional reset and power on, skip internal memory initialization, and according to the front parameter that resets of preserving in the internal memory, continue the task program before operation resets, if be not setting value X, then be judged to be normal electrification reset, initialization MCU and internal memory.
Further, described setup unit comprises one or more byte, consists of setting value X.
Further, a plurality of bytes in the described setup unit are stored in respectively in a plurality of discrete position units of storer.
Further, described storer is flash memory or is the internal memory of electrical equipment.
Another purpose of the embodiment of the invention is to provide a kind of control system of electrical equipment, and described control system comprises reset circuit and MCU, and described control system also comprises:
The setup unit writing unit is used for behind the appliance starting task program, writes setting value X at the setup unit of the storer of electrical equipment;
The setup unit clearing cell is used for removing the setting value X of the setup unit of described storer when the task program normal termination;
Judge module is used for resetting when powering on, and judges whether the value of the setup unit of described storer is setting value X; And
The redirect execution module is if for being setting value X, then being judged to be exceptional reset and powering on, skip internal memory initialization, and according to the front parameter that resets of preserving in the internal memory, continue the task program before operation resets, if be not setting value X, then be judged to be normal electrification reset, initialization MCU and internal memory.
Further, described storer is flash memory or is the internal memory of electrical equipment.
Further, described setup unit comprises one or more byte, consists of setting value X.
Further, a plurality of bytes in the described setup unit are stored in respectively in a plurality of discrete position units of storer.
Further, described storer is flash memory or is the internal memory of electrical equipment.
Another purpose of the embodiment of the invention is to provide a kind of electrical equipment, and described electrical equipment comprises shell, and described electrical equipment adopts above-mentioned each described control system.
In an embodiment of the present invention, when normally powering on operation, in storer, write setting value, when the normal termination task program, dispose this setting value, and when exceptional reset, still can preserve this setting value in the storer.Like this, whether just can judge smoothly is exceptional reset, if exceptional reset does not then internally deposit into capable initialization, according to the operational factor of internal memory preservation, can return to the state before resetting, thereby solved under abnormal conditions, the circuit that resets produces when resetting, and controller will be out of control, gently then cause easily whole household appliances to damage, heavy then lead to easily the problem of security incident.
Description of drawings
Fig. 1 is the reset electrical block diagram of circuit of the first that prior art provides;
Fig. 2 is the reset electrical block diagram of circuit of the second that prior art provides;
Fig. 3 is the resetting pin that provides of prior art and the voltage synoptic diagram of supply pin;
Fig. 4 is the electrical equipment anti-disturbance method process flow diagram that the embodiment of the invention provides;
Fig. 5 is the structural representation of the control system of the electrical equipment that provides of the embodiment of the invention.
Embodiment
In order to make purpose of the present invention, technical scheme and advantage clearer, below in conjunction with drawings and Examples, the present invention is further elaborated.Should be appreciated that specific embodiment described herein only in order to explain the present invention, is not intended to limit the present invention.
Fig. 4 shows the electrical equipment anti-disturbance method flow process that the embodiment of the invention provides, and details are as follows:
Usually, the MCU of electrical equipment resets in the situation of not power down, the state of MCU inner only can reset I/O mouth and specified register, and the value of internal memory (RAM) can not be affected and change.According to this specific character of MCU, under MCU normally resets the situation of operation, write the value of a setting at the setup unit of the storer of electrical equipment, such as 0X55AA.And moved in program, in the situation of normal termination, then remove the setting value of setup unit.When resetting, before initial internal memory, judge first the value of setup unit, if be not equal to setting value, that is just judged is to reset normally specifically, just by normal operation operation (initialization internal memory), if equal setting value, be illustrated as exceptional reset, at this moment, just do not carry out the initialization of internal memory, but leap to the then operation of place (according to the operational factor of internal memory reservation) of the original operation of program.Like this, from the angle of using, whole system is not just as having abnormal resets, thereby reaches jamproof purpose.
In step S101, the I/O port of initialization main control chip MCU.
In step S102, judge whether the value of the setup unit of storer is setting value X.If be setting value X, execution in step S105 then, otherwise execution in step S103.
As embodiments of the invention, this storer can or be the internal memory of electrical equipment for flash memory.When selecting internal memory to store setting value X, not power down setting value X just exists, and compares and be stored in the flash memory, and the speed of obtaining data is faster.
In an embodiment of the present invention, described setup unit comprises one or more byte, consists of setting value X.
When only using a byte, because normally reset when powering on, the content of each internal storage location is uncertain, might be just consistent with setting value, and it is disconnected like that just to be easy to erroneous judgement.
For making the present invention more reliable, reduce erroneous judgement, the setup unit that 2 bytes of normal operation are above.
As preferred embodiment of the present invention, a plurality of bytes in the setup unit are stored in respectively in a plurality of discrete position units of storer.
And described setting value also adopts special value as far as possible, does not adopt such value as 00, FF, because single-chip microcomputer is exactly such value when internal storage location is very possible initial when normally powering on.
In step S103, be judged to be for the first time power on (being normal electrification reset), initialization MCU and internal memory.
In step S104, after the initiating task program, write setting value X at the setup unit of storer.
In step S105, be judged to be exceptional reset and power on, skip internal memory initialization, and according to the front parameter that resets of preserving in the internal memory, continue the task program before operation resets.
In step S106, judge whether normal termination of task program.If for normal termination, execution in step S107 then, otherwise finish this flow process.
In step S107, remove the setting value X of the setup unit of storer.
Fig. 5 shows the structure of the control system of the electrical equipment that the embodiment of the invention provides, this control system can be software unit or hardware cell or the unit soft, that scleroma is closed that is built in electrical equipment, this electrical equipment at least also comprises the parts such as shell, motor except control system.
This control system also comprises except comprising the circuit (not shown) that resets, MCU50, storer 52: setup unit writing unit 51, setup unit clearing cell 53, judge module 55, redirect execution module 57.
Under the control of MCU50: setup unit writing unit 51 is behind the appliance starting task program, setup unit at the storer 52 of electrical equipment writes setting value X, setup unit clearing cell 52 is removed the setting value X of the setup unit of described storer 52 when the task program normal termination.
Resetting when powering on, judge module 53 judges whether the value of the setup unit of described storer 52 is setting value X, if redirect execution module 54 is setting value X, then be judged to be exceptional reset and power on, skip internal memory initialization, and according to the front parameter that resets of preserving in the internal memory, continue the task program before operation resets, if be not setting value X, then be judged to be normal electrification reset, initialization MCU and internal memory.
As embodiments of the invention, described storer 52 is flash memory or is the internal memory of electrical equipment.
As embodiments of the invention, described setup unit comprises one or more byte, consists of setting value X.In order to obtain better implementation result, a plurality of bytes in the described setup unit are stored in respectively in a plurality of discrete position units of storer 52.
In sum, when normally powering on operation, in storer, write setting value, when the normal termination task program, dispose this setting value, and when exceptional reset, still can preserve this setting value in the storer.Like this, whether just can judge smoothly is exceptional reset, if exceptional reset does not then internally deposit into capable initialization, according to the operational factor of internal memory preservation, can return to the state before resetting, thereby solved under abnormal conditions, the circuit that resets produces when resetting, and controller will be out of control, gently then cause easily whole household appliances to damage, heavy then lead to easily the problem of security incident.
Adopt internal memory as storer, can save cost, and make its response speed very fast.Adopt a plurality of bytes as setup unit, increased its reliability.A plurality of bytes in this setup unit are stored in respectively in a plurality of discrete position units of storer, thereby have further increased its reliability.
The above only is preferred embodiment of the present invention, not in order to limiting the present invention, all any modifications of doing within the spirit and principles in the present invention, is equal to and replaces and improvement etc., all should be included within protection scope of the present invention.
Claims (5)
1. an electrical equipment anti-disturbance method is characterized in that, said method comprising the steps of:
Behind the appliance starting task program, write setting value X at the setup unit of the storer of electrical equipment;
When the task program normal termination, remove the setting value X of the setup unit of described storer;
Reset when powering on, judge whether the value of the setup unit of described storer is setting value X;
If be setting value X, then be judged to be exceptional reset and power on, skip internal memory initialization, and according to the front parameter that resets of preserving in the internal memory, continue the task program before operation resets, if be not setting value X, then be judged to be normal electrification reset, initialization MCU and internal memory,
Described storer is flash memory or is the internal memory of electrical equipment,
Described setup unit comprises a plurality of bytes, consists of setting value X.
2. method according to claim 1 is characterized in that, a plurality of bytes in the described setup unit are stored in respectively in a plurality of discrete position units of storer.
3. the control system of an electrical equipment, described control system comprises reset circuit and MCU, it is characterized in that, described control system also comprises:
The setup unit writing unit is used for behind the appliance starting task program, writes setting value X at the setup unit of the storer of electrical equipment;
The setup unit clearing cell is used for removing the setting value X of the setup unit of described storer when the task program normal termination;
Judge module is used for resetting when powering on, and judges whether the value of the setup unit of described storer is setting value X; And
The redirect execution module if for being setting value X, then being judged to be exceptional reset and powering on, is skipped internal memory initialization, and according to the front parameter that resets of preserving in the internal memory, continue the task program before operation resets, if be not setting value X, then be judged to be normal electrification reset, initialization MCU and internal memory
Described storer is flash memory or is the internal memory of electrical equipment that described setup unit comprises a plurality of bytes, consists of setting value X.
4. control system according to claim 3 is characterized in that, a plurality of bytes in the described setup unit are stored in respectively in a plurality of discrete position units of storer.
5. electrical equipment, described electrical equipment comprises shell, it is characterized in that, described electrical equipment adopts each described control system among the claim 3-4.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN 201010218283 CN101950160B (en) | 2010-07-02 | 2010-07-02 | Anti-jamming method of electrical appliance, control system and corresponding electrical appliance |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN 201010218283 CN101950160B (en) | 2010-07-02 | 2010-07-02 | Anti-jamming method of electrical appliance, control system and corresponding electrical appliance |
Publications (2)
Publication Number | Publication Date |
---|---|
CN101950160A CN101950160A (en) | 2011-01-19 |
CN101950160B true CN101950160B (en) | 2013-04-10 |
Family
ID=43453678
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN 201010218283 Expired - Fee Related CN101950160B (en) | 2010-07-02 | 2010-07-02 | Anti-jamming method of electrical appliance, control system and corresponding electrical appliance |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN101950160B (en) |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104020833A (en) * | 2014-06-25 | 2014-09-03 | 苏州塔可盛电子科技有限公司 | Anti-interference singlechip reset circuit |
CN110433047A (en) * | 2019-07-25 | 2019-11-12 | 江苏慧明智能科技有限公司 | Intelligence cleaning device for nursing beds and intelligent cleaning method |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
ITMI20020053A1 (en) * | 2002-01-14 | 2003-07-14 | Whirlpool Co | CONTROL DEVICE OF A SIMPLE MANUFACTURING HOUSEHOLD APPLIANCE |
CN101382780A (en) * | 2007-09-05 | 2009-03-11 | 武汉奇致激光技术有限公司 | Apparatus and control method for enhancing anti-jamming capability of main control electric appliance system of monolithic computer |
CN201298160Y (en) * | 2008-08-11 | 2009-08-26 | 比亚迪股份有限公司 | Reset circuit for singlechip |
CN101763058B (en) * | 2009-11-24 | 2012-07-11 | 美的集团有限公司 | Monitoring method for household appliance microcontroller |
-
2010
- 2010-07-02 CN CN 201010218283 patent/CN101950160B/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
CN101950160A (en) | 2011-01-19 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN100419699C (en) | Method and device remotely automatic recovering CMOS date with network | |
CN100428203C (en) | Portable equipment based on non-volatile memory and method of realizing power failure protection | |
CN109885343A (en) | A kind of controller low-power consumption starting method, apparatus, computer equipment and storage medium | |
CN104881375B (en) | Storage system power-down data protection method and apparatus | |
CN103345189A (en) | Controller and power fail safeguard method | |
CN102970432B (en) | A kind of mobile terminal and the method controlling SIM card hot plug thereof | |
CN103150125A (en) | Method for prolonging service life of power-down protection date buffer memory and smart card | |
CN205195387U (en) | Stake of charging and fall electric memory circuit thereof | |
CN105759679B (en) | Power down protection controller and its power-down retaining method | |
CN101286738A (en) | Method, device and system for loading logic files based on equipment information | |
CN102169442B (en) | Method, equipment, device and system for performing system boot by using USB (universal serial bus) device | |
CN103399520B (en) | For power failure data access method and the device of programmable logic controller system | |
CN104881312A (en) | FPGA (Field Programmable Gate Array) logic code iterable upgrading method and circuit | |
CN101996144B (en) | Flash control method and device | |
CN109144778A (en) | A kind of storage server system and its backup method, system and readable storage medium storing program for executing | |
CN101950160B (en) | Anti-jamming method of electrical appliance, control system and corresponding electrical appliance | |
CN104850182A (en) | Circuit structure applied to embedded system and power-fail protection method | |
CN102508536A (en) | One-button startup and shutdown circuit in embedded system and control method thereof | |
CN104166521A (en) | Computer with a memory card | |
CN106503542A (en) | The anti-Improvement of device parameter, equipment and air-conditioner | |
CN112346556A (en) | Method, device, computer equipment and medium for improving low power consumption efficiency of chip | |
CN103890713A (en) | Apparatus and method for managing register information in a processing system | |
CN103309827B (en) | The device parameter reading/writing method of terminal and device | |
CN104570821A (en) | Integrated circuit and operation method thereof | |
CN103810051A (en) | Watchdog abnormity recovery device and method |
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 | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20130410 |
|
CF01 | Termination of patent right due to non-payment of annual fee |