|
DS1302命令字定义的头文件 天涯过客 发表于 2005-10-31 9:36:14
//作者评论:续上篇,DS1302命令字定义的头文件,作为函数参数,使用驱动程序,就可实现对DS1302的读写。 #ifndef DS1302_H #define DS1302_H
/*---------ds1302 define ----------*/ #define CmdRdSec 0x81 #define CmdRdMin 0x83 #define CmdRdHour 0x85 #define CmdRdDate 0x87 #define CmdRdMonth 0x89 #define CmdRdDay 0x8b #define CmdRdYear 0x8d #define CmdRdControl 0x8f #define CmdRdTrickleCharge 0x91 #define CmdRdClockBurst 0xbf #define CmdWrSec 0x80 #define CmdWrMin 0x82 #define CmdWrHour 0x84 #define CmdWrDate 0x86 #define CmdWrMonth 0x88 #define CmdWrDay 0x8a #define CmdWrYear 0x8c #define CmdWrControl 0x8e #define CmdWrTrickleCharge 0x90 #define CmdWrClockBurst 0xbe
#endif
|