📄 includes.h.bak
字号:
#include <STC12C.H>
#include <stdio.h>
#include <intrins.h>
#include <DS18B20.h>
#include <Time.h>
#include <ADC.h>
#include <KEY.h>
#include <IAP.h>
#define INT8U unsigned char //无符号8位数
#define INT8S signed char //有符号8位数
#define INT16U unsigned int //无符号16位数
#define INT16S signed int //有符号16位数
#define INT32U unsigned long //无符号32位数
#define INT32S signed long //有符号32位数
#define FP32 float //单精度浮点数
#define FP64 double //双精度浮点数
//************************** 8051中断源定义 ***********************
#define INT_EX0 0 //外部中断0源,P3.2
#define INT_EX1 2 //外部中断1源,P3.3
#define INT_T0 1 //定时器0中断源,Timer0
#define INT_T1 3 //定时器1中断源,Timer1
#define INT_SER 4 //串口中断源,P3.0,P3.1
#define INT_ADC 5 //ADC中断源
//****************************************************************
//***********************定义LED控制与I/O控制端口*******************
#define LED_DATABUS P2
sbit Pin_T0 =P0^0;
sbit Pin_T1 =P0^1;
sbit Pin_LED1 =P3^3;
sbit Pin_LED2 =P3^4;
sbit Pin_Buz =P0^3;
sbit Pin_Alm_OvTemp =P0^2;
sbit Pin_Alm_Tsensor =P3^5;
sbit Pin_Alm_Tled =P3^7;
sbit Pin_Alm_Fan =P1^1;
sbit Pin_Ctrl_Fan1 =P1^2;
sbit Pin_Ctrl_Fan2 =P1^3;
//***************************************************************
#define BZ_ON 0 //蜂鸣器开关定义
#define BZ_OFF 1
#define ALM_ON 0 //告警干接点输出开关定义
#define ALM_OFF 1
#define LED_DIS_ON 0 //LED位选信号开关定义
#define LED_DIS_OFF 1
#define LED_ALM_ON 0 //告警LED开关定义
#define LED_ALM_OFF 1
#define FAN_ON 1 //风扇开关定义
#define FAN_OFF 0
#define KEY_UP 1 //按键开关定义
#define KEY_DOWN 0
#define TEMP_SEG1 1
#define TEMP_SEG2 2
#define TEMP_SEG3 3
#define TEMP_SEG4 4
#define TEMP_SEG5 5
#define TEMP_SEG6 6
//***************************************************************
#ifdef MAIN_GLOBALS
#define MAIN_EXT
#else
#define MAIN_EXT extern
#endif
MAIN_EXT INT8U Led_DisMem[2]; //数码管显存
MAIN_EXT INT8U MenuLevel;
#define MENU_ROOT 0
#define MENU_CONFIG 1
#define MENU_ALM_DIS 2
#define MENU_SET 3
MAIN_EXT INT8U Led_Sta;
#define LED_FLASH 1
#define LED_NORMAL 0
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -