文件名称:C51ofthepreaationofhot-startcode
- 所属分类:
- 单片机(51,AVR,MSP430等)
- 资源属性:
- [Text]
- 上传时间:
- 2012-11-26
- 文件大小:
- 2kb
- 下载次数:
- 0次
- 提 供 者:
- 马*
- 相关连接:
- 无
- 下载说明:
- 别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容均来自于网络,请自行研究使用
C51热启动代码的编制
对于工业控制计算机,往往设有有看门狗电路,当看门狗动作,使计算机复位,这就是热启动。热启动时,一般不允许从头开始,这将导致现有的已测量到或计算到的值复位,导致系统工作异常。因而在程序必须判断是热启动还是冷启动,常用的方法是:确定某内存单位为标志位(如0x7f位和0x7e位),启动时首先读该内存单元的内容,如果它等于一个特定的值(例如两个内存单元的都是0xaa),就认为是热启动,否则就是冷启动,程序执行初始化部份,并将0xaa赋与这两个内存单元。-C51 of the preparation of hot-start codeFor industrial control computer, often there are watchdog circuit, when the watchdog action, reset the computer, which is heat activated. Hot start, they generally are not allowed to start from scratch, which will lead to existing measured or calculated values to reset, resulting in abnormal system. And therefore must determine whether the procedure is a hot start or cold start, commonly used method is: to determine if a memory unit for the flag (for example, 0x7e and 0x7f-bit), and starts the first time the contents of the memory unit, if it is equal to the value of a particular (for example, two memory modules are 0xaa), is a hot start on that, otherwise, it is cold start, the program part of the implementation of initialization, and will give the two 0xaa memory modules.
对于工业控制计算机,往往设有有看门狗电路,当看门狗动作,使计算机复位,这就是热启动。热启动时,一般不允许从头开始,这将导致现有的已测量到或计算到的值复位,导致系统工作异常。因而在程序必须判断是热启动还是冷启动,常用的方法是:确定某内存单位为标志位(如0x7f位和0x7e位),启动时首先读该内存单元的内容,如果它等于一个特定的值(例如两个内存单元的都是0xaa),就认为是热启动,否则就是冷启动,程序执行初始化部份,并将0xaa赋与这两个内存单元。-C51 of the preparation of hot-start codeFor industrial control computer, often there are watchdog circuit, when the watchdog action, reset the computer, which is heat activated. Hot start, they generally are not allowed to start from scratch, which will lead to existing measured or calculated values to reset, resulting in abnormal system. And therefore must determine whether the procedure is a hot start or cold start, commonly used method is: to determine if a memory unit for the flag (for example, 0x7e and 0x7f-bit), and starts the first time the contents of the memory unit, if it is equal to the value of a particular (for example, two memory modules are 0xaa), is a hot start on that, otherwise, it is cold start, the program part of the implementation of initialization, and will give the two 0xaa memory modules.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
新建 文本文档 (3).txt