基于單片机的时钟芯片C程序.docVIP

  • 5
  • 0
  • 约4.06万字
  • 约 43页
  • 2016-11-27 发布于重庆
  • 举报
基于單片机的时钟芯片C程序

/*============================================================ 使用1602液晶显示DS1302+c51时钟 [注:AT89C51使用12M晶振] =============================================================*/ #include AT89x51.h #include string.h #include intrins.h #define delayNOP(); {_nop_() ;_nop_() ;_nop_() ;_nop_() ;} ; #define LCM_RW P2_5 //定义引脚 #define LCM_RS P2_4 #define LCM_E P2_6 #define LCM_Data P0 #define Busy 0x80 //用于检测LCM状态字中的Busy标识 #define uchar unsigned char #define uint unsigned int sbit T_CLK=P3^5; sbit T_IO =P3^6; sbit T_RST=P3^7; sbit ACC0=ACC^0; sbit ACC7=ACC^7; sbit LED=P1^6; //背光灯输出 (因本实验板无此功能 所

文档评论(0)

1亿VIP精品文档

相关文档