全球旧事资料 分类
号列号的操作
Se
sor_Write_Byte0x44
启动温度转换
Se
sor_I
itial
Se
sor_Write_Byte0xCC
跳过读序号列号的操作
Se
sor_Write_Byte0xBE
读取温度寄存器
temperature0Se
sor_Read_Byte
低位
temperature1Se
sor_Read_Byte
高位
e
dif
3日历设置程序
if
def_SUN_MOON
defi
e_SUN_MOON

defi
eucharu
sig
edchar
defi
eui
tu
sig
edi
t
i
cludeshezhih
i
cludelcdh
功能读取数据表中农历的大月或小月,如果大月返回1小月返回0
编辑版word
fbitget_moo
_dayucharmo
th_pui
tcale
dar_address
uchartemptemp1
temp1mo
th_p38temp0x80mo
th_p38tempyear_codecale
dar_addresstemp1tempiftemp0retur
0elseretur
1功能输入BCD的阳历数据,输出BCD阴历数据19012099c_flag阳历的世纪标志clock_time时钟地址说明c_flag021世纪c_flag119世纪voidCale
dar_Co
vertucharc_flagucharclock_timebitflag_mo
thflag_yearucharyearmo
thdaymo
th_poi
t定义年月天uchartemp1temp2temp3ui
tcale
dar_address定义农历地址ui
tday_
umberucharclock_moo
3定义阴历
编辑版word
fclock_time3指向日dayclock_time410clock_time0x0fBCD转换十进制clock_time指向月mo
thclock_time410clock_time0x0fBCD转换十进制clock_time指向年yearclock_time410clock_time0x0fBCD转换十进制
定位日历地址ifc_flag0
cale
dar_addressyear993else
cale
dar_addressyear13
春节正月初一所在的阳历月份temp1year_codecale
dar_address20x60Bit6Bit5春节所在的阳历月份temp15春节正月初一所在的阳历日期temp2year_codecale
dar_address20x1fBit4Bit0春节所在的阳历日期
计算春节正月初一离当年元旦1月1日阳历的天数;春节只会在阳历的1月或2月
编辑版word
fiftemp11temp3temp21
elsetemp3temp2311
temp3temp21iftemp11temp30x1f
计算阳历月离当年元旦1月1日阳历的天数ifmo
th10
day_
umberday_code1mo
th1dayelse
day_
umberday_code2mo
th10day
如果阳历的月大于2且该年的2月为闰月,天数加1闰年指的就是阳历有闰日或阴历有闰月的一年;阳历四年一闰,在二月加一天,这一天叫做闰日:农历r
好听全球资料 返回顶部