reset.bak

来自「LED渐明变灭,遥控控制,总体变化,方便使用」· BAK 代码 · 共 63 行

BAK
63
字号
#include <reg51.h>			//包涵头文件
#include <string.h>
#include <intrins.h>

#include "types.h"
//#include "key.h"
#include "managment.h"


uint counter=0;

//unsigned char b_power;		//定义全局变量
//void main(void) {
//	b_power++;
//	if (b_power&1) PCON=2;	//进入低功耗状态
//	while (1) {}		//执行其他操作
//}
//程序需要和NOSTART.OBJ一起连接,才保证在复位时不清零b_pow\   er。
// -----------------------------------------------
//------------------------------------------------
uchar key,key_h,kpush;
uint key_l,constant;

//按键连接到p2.4\p2.5\p2.6\p2.7
//uint temp;

void main(void)
 {
        Timer0Init();
       // Initeeprom();
//NormalStart:
//	IT0=1;
//	IT1=1;
//	EX0=1;
//	EX1=1;
        EA=1;
//------------------
    //-------------------
            plus=0X200;
   MainLoop:
            constant=0;
         //if(!onoff)
          managment();

	goto MainLoop;
	}

//按键扫描驱动程序

void int_t0(void) interrupt 1
    {
       if(!ts)
       {
	TL0=-(2000%256);
	TH0=-(2000/256);	//3ms
        }
        plus = plus + 30;

      }
     //-----------------------------


⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?