摘要
在单片机应用系统中 ,为了提高系统的抗干扰能力 ,目前广泛采用了监视定量器来监视程序的运行情况 ,及时发现程序跑飞并将其拉回正轨。然而在很多情况下这种方法并不是很有效的 ,针对这一问题 ,提出了通过软件设计进一步提高系统可靠性的方法 ,并以 MCS- 5 1单片机为例 ,详细地说明主程序、中断服务程序和监视定时器之间如何相互制约、相互监视 ,达到迅速发现程序跑飞的位置并进行相应的错误处理的具体方法。
In the applied system of MCU, watchdog timer is widely used to monitor the running of program in order to improve anti interference of the system. It discovers the program running away in time and pull it back to the normal state. However, this method isn′t always efficient. Aiming at this problem, this article puts forward a way to improve dependence of the system through software design. Taking MCS-51 of MCU for example, this paper describes the method of anti interference of monitoring together on maser program, interrupt service program and watchdog timer so as to rapidly find the position of program running away and take specific measures to deal with mistakes.
出处
《陕西科技大学学报(自然科学版)》
2003年第1期81-83,共3页
Journal of Shaanxi University of Science & Technology