CN103309278B - A kind of method improving fixed cycle digital control system sampling antijamming capability - Google Patents
A kind of method improving fixed cycle digital control system sampling antijamming capability Download PDFInfo
- Publication number
- CN103309278B CN103309278B CN201310196092.0A CN201310196092A CN103309278B CN 103309278 B CN103309278 B CN 103309278B CN 201310196092 A CN201310196092 A CN 201310196092A CN 103309278 B CN103309278 B CN 103309278B
- Authority
- CN
- China
- Prior art keywords
- subroutine
- sampling
- time
- random number
- cycle
- 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
Links
Abstract
The invention discloses a kind of method improving fixed cycle digital control system sampling antijamming capability.For a digital control system, its control subroutine is the subroutine that the fixed cycle T of timer A generation constantly reruns, and in control program porch, first runs random number generation subfunction, produces one and represent time T
irandom number, i.e. time delay one section of T
istart data sampling subroutine after time, carry out the data sampling of digital quantity or analog quantity.The whole control cycle T of such system remains unchanged, and all can run subroutine of once sampling, can not affect the control algolithm of original fixed cycle in each cycle T.Simultaneously due to random time T
iintroducing, make the time interval of every double sampling be not fixing, the interference of some fixed frequencies can be avoided like this, improve the anti-interference of system.
Description
Technical field
The present invention relates to a kind of method of sampling of digital control system, belong to digital control system field.
Background technology
For any control system, the characteristic of system all shows the change of its input and output, obtain desirable control effects, the input and output of necessary correct sampling system, the operation conditions of understanding system, then by suitable control device, make system control effects under some target function reach optimum or realize the control effects of expection.Therefore can the inputoutput data of digital control system collection reflect system truly, is the key of its control performance quality.
Modern digital control theory is all adopt the fixing sampling period to realize based on certain criterion mostly.But in the system of reality, environment and interference are inevitable on the impact of system, and some interference may show large especially in a certain frequency range, when this frequency is just in time consistent with the frequency of the fixed sample period that control system is selected, this interference will have a strong impact on the accuracy that digital control system controls.Such as a driving control system for electric machine, the interrupt cycle of its electric current loop is 100us, sample frequency is 10kHz, with in the fast-pulse group immunity to interference EMC process of the test of same 10kHz frequency, just serious interference is produced to system, even cause the abnormal occurrencies such as motor driving, superpotential, excess current to occur.Trace it to its cause and be that the frequency disturbed is consistent with sample frequency, and this interference has directivity, is not random disturbance, cannot be solved by the mode of the software algorithms such as digital filtering.
A kind of method uses the control strategy of variable period to control digital display circuit, that is controlled by the controlled variable of sampling period as control system.But conventional numerical control theory such as the mathematical tool such as difference equation, transform is difficult to use this kind of method, and the method is because using the sampling period as a variable, add the complicacy of system.
Summary of the invention
The technical problem to be solved in the present invention is on the basis not changing digital control system fixed cycle algorithm, provides a kind of method of sampling with more high noise immunity.
The present invention for solving the problems of the technologies described above by the following technical solutions, a kind of improve fixed cycle digital control system sampling antijamming capability method, its concrete steps are as follows:
(1) in a digital control system, the control subroutine cycle of system is fixed as T;
(2) Operation system setting random number generation subroutine, the working time of random number generation subroutine is T
r, produce the random number T of the time that represents
i, wherein i=1,2,3 ... N, i represent the number of times of interruption, and the value of N is natural number; Through time delay T
iafter, system enters data sampling subroutine; The follow-up reforwarding row of system cloud gray model random number generation subroutine controls steering logic or the control algolithm of subroutine;
(3) in data sampling subroutine, system carries out the process of digital input sample or analog quantity A/D sampling, and the working time of data sampling subroutine is T
c;
Wherein, the random number T of time is represented
i, random number generation subroutine running time T
r, data sampling subroutine working time be T
c, the total ascent time of three should be less than fixed cycle T.
The present invention adopts above technical scheme compared with prior art, can not affect the control algolithm of control system original fixed cycle, simultaneously due to random time T
iintroducing, make the time interval of every double sampling be not fixing, the interference of some fixed frequencies can be avoided, improve the anti-interference of system.
Accompanying drawing explanation
Fig. 1 is program flow diagram of the present invention.
Fig. 2 is sampling system sequential chart of the present invention.
Embodiment
As shown in Figure 1, a digital control system, its control subroutine is the subroutine that the fixed cycle T of timer A generation constantly reruns, when the Interruption time T of timer A arrives, enter interrupt handling routine, first program runs random number generation subfunction, and produce a random number, this random number represents time T
i(T
icomprise T
1, T
2, T
3... a series of random time), then start a timer B, its timing is the time T that above-mentioned random number produces
i, control subroutine subsequently and continue to run its steering logic or control algolithm, return master routine after completing and continue waiting timer A interruption; Simultaneously after control subroutine starts timer B, once the Interruption time T of timer B
iduring arrival, the interrupt priority level arranging sampling subroutine, higher than the interrupt priority level controlling subroutine, can enter data sampling subroutine immediately, and this subroutine can carry out the sampling of numeral input, also can carry out the process of analog quantity A/D sampling, return original program interruptions after having sampled and continue to run.
Fig. 2 is the sampling system sequential chart of one embodiment of the invention, and as can be seen from sequential chart, sampling subroutine is by timer B implement of interruption function, and the time of timer B is a random number time T
i, subroutine of therefore sampling can be inserted in the steering logic controlling subroutine or control algolithm process, also may insert in it waits for the process that next time interrupts.For ensureing to control in subprogram activation cycle T, the operation of subroutine of all once sampling, therefore random time T at every turn
iadd the running time T of up-sampling subroutine
cthe working time of adding random number generation subroutine should be less than the cycle of operation T controlling subroutine, namely should meet following formula:
T > T
r+ T
i+ T
c
The whole control cycle T of such system remains unchanged, and all can run subroutine of once sampling, can not affect the control algolithm of original fixed cycle in each cycle T.Simultaneously due to random time T
iintroducing, make the time interval of every double sampling be not fixing, T in figure
1' be not equal to T
2', the interference of some fixed frequencies can be avoided like this, improve the anti-interference of system.
Above by embodiment to invention has been detailed description, but these are not construed as limiting the invention.Those skilled in the art also can make distortion and the improvement of some equivalent technical elements replacement without departing from the principles of the present invention, and these also should be considered as belonging to protection scope of the present invention.
Claims (1)
1. improve a method for fixed cycle digital control system sampling antijamming capability, its concrete steps are as follows:
Step 1. is in a digital control system, and the control subroutine cycle of initialization system is fixed as T;
Step 2. Operation system setting random number generation subroutine, the working time of random number generation subroutine is T
r, produce the random number T of the time that represents
i, wherein i=1,2,3 ... N, i represent the order of interruption, and the value of N is positive integer; The follow-up reforwarding row of system cloud gray model random number generation subroutine controls steering logic or the control algolithm of subroutine; Elapsed time T
r+ T
i, system data inserting sampling subroutine;
Step 3. is in data sampling subroutine, and system carries out the process of digital input sample or analog quantity A/D sampling, and the working time of data sampling subroutine is T
c;
Wherein, the random number T of time is represented
i, random number generation subroutine running time T
r, data sampling subroutine working time be T
c, the total ascent time of three should be less than fixed cycle T.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310196092.0A CN103309278B (en) | 2013-07-05 | 2013-07-05 | A kind of method improving fixed cycle digital control system sampling antijamming capability |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310196092.0A CN103309278B (en) | 2013-07-05 | 2013-07-05 | A kind of method improving fixed cycle digital control system sampling antijamming capability |
Publications (2)
Publication Number | Publication Date |
---|---|
CN103309278A CN103309278A (en) | 2013-09-18 |
CN103309278B true CN103309278B (en) | 2015-08-19 |
Family
ID=49134607
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201310196092.0A Active CN103309278B (en) | 2013-07-05 | 2013-07-05 | A kind of method improving fixed cycle digital control system sampling antijamming capability |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN103309278B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105786598B (en) * | 2014-12-19 | 2020-02-14 | 北京宝沃汽车有限公司 | Task scheduling method and device |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1175835A (en) * | 1996-07-23 | 1998-03-11 | 罗克马诺尔研究有限公司 | Randomised code acquisition |
CN101682331A (en) * | 2007-04-09 | 2010-03-24 | 罗伯特·博世有限公司 | Hardware-efficient reconstruction for periodic non-uniformly sampled signals |
CN101902320A (en) * | 2010-07-27 | 2010-12-01 | 凯迈(洛阳)测控有限公司 | Timing sampling method |
-
2013
- 2013-07-05 CN CN201310196092.0A patent/CN103309278B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1175835A (en) * | 1996-07-23 | 1998-03-11 | 罗克马诺尔研究有限公司 | Randomised code acquisition |
US6069915A (en) * | 1996-07-23 | 2000-05-30 | Roke Manor Research Limited | Randomized code acquisition |
CN101682331A (en) * | 2007-04-09 | 2010-03-24 | 罗伯特·博世有限公司 | Hardware-efficient reconstruction for periodic non-uniformly sampled signals |
CN101902320A (en) * | 2010-07-27 | 2010-12-01 | 凯迈(洛阳)测控有限公司 | Timing sampling method |
Non-Patent Citations (2)
Title |
---|
基于随机等效采样的高速数据采集系统的设计;张国礼等;《现代电子技术》;20041231;第2004年卷(第24期);3-5 * |
抗干扰电流采样电路的设计;屈凡等;《电子测试》;20121231;第2012年卷(第12期);82-86 * |
Also Published As
Publication number | Publication date |
---|---|
CN103309278A (en) | 2013-09-18 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN102130640B (en) | Multishaft synchronous servo driving system and synchronous control method thereof | |
CN103227623B (en) | The LMS adaptive filter algorithm of variable step size and filter | |
CN103699013A (en) | Method for effectively improving speed and precision of in-loop real-time simulation of motor hardware | |
CN103309278B (en) | A kind of method improving fixed cycle digital control system sampling antijamming capability | |
CN102707083A (en) | Motor speed calculating method | |
CN103838183B (en) | A kind of digital control system and output control method thereof | |
CN105160187A (en) | Iterative method for solving nonlinear mathematical model of aero-engine | |
CN105573854A (en) | Terminal application processing method and device | |
CN106340263A (en) | Gate driver and method for adjusting output channels thereof | |
CN104698286A (en) | Timer-based PWM (Pulse Width Modulation) wave acquisition method | |
CN101719765A (en) | Method and device for generating low-jitter clock | |
Sandoval et al. | Runtime hardware/software task transition scheduling for data-adaptable embedded systems | |
CN204836104U (en) | Anti -jamming circuit based on logic time delay locking | |
CN108075697B (en) | Switched reluctance motor phase current iteration control method for position signal frequency multiplication | |
CN105185297B (en) | A kind of the pulse width modulation conduction method and system of LED displays driving | |
US8775852B2 (en) | Method for sensing input signal changes | |
JP2015099146A5 (en) | ||
CN108549329B (en) | Method and device for realizing uniform pulse output based on FPGA | |
CN103532515B (en) | A kind of method that single-side belt flow-through Doppler filter complexity reduces | |
CN104702251B (en) | Timer-based PWM (Pulse Width Modulation) wave generation method | |
CN103490747B (en) | The configurable pulse generating method of a kind of multichannel | |
CN107966906B (en) | Fractional order delay implementation method based on sampling control separation principle | |
CN108279591B (en) | Simulation platform digital quantity universal output method | |
CN103647528B (en) | Non-overlapping clock generation circuit | |
CN104917497A (en) | Logic delay locking based anti-interference circuit 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 |