freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

單片機(jī)的溫度檢測記錄系統(tǒng)原理圖和c程序(doc畢設(shè)論文)-資料下載頁

2025-06-18 07:57本頁面
  

【正文】 if(1 == up_flag || 1 == down_flag) //數(shù)據(jù)更新,重新寫入新的數(shù)據(jù) { Write1302(0x8e,0x00)。 //寫入允許 Write1302(0x80,temp|0x80)。 //寫入新的秒數(shù) Write1302(0x8e,0x80)。 //禁止寫入 up_flag=0。 down_flag=0。 } hide_sec++。 //位閃計(jì)數(shù) if(hide_sec3) hide_sec=0。 show_time()。 //液晶顯示數(shù)據(jù) }while(2 == count)。break。 case 2:do //count=2,調(diào)整分 { hide_sec=0。 Exitkey()。 Upkey()。 Downkey()。 if(temp0x60) temp=0。 if(1 == up_flag || 1 == down_flag) { Write1302(0x8e,0x00)。 //寫入允許 Write1302(0x82,temp)。 //寫入新的分?jǐn)?shù) Write1302(0x8e,0x80)。 //禁止寫入 up_flag=0。 down_flag=0。 } hide_min++。 if(hide_min3) hide_min=0。 show_time()。 }while(3 == count)。break。 case 3:do //count=3,調(diào)整小時(shí) { hide_min=0。 Exitkey()。 Upkey()。 Downkey()。 if(1 == up_flag || 1 == down_flag) { Write1302(0x8e,0x00)。 //寫入允許 Write1302(0x84,temp)。 //寫入新的小時(shí)數(shù) Write1302(0x8e,0x80)。 //禁止寫入 up_flag=0。 down_flag=0。 } hide_hour++。 if(hide_hour3) hide_hour=0。 show_time()。 }while(4 == count)。break。 case 4:do //count=4,調(diào)整星期 { hide_hour=0。 Exitkey()。 Upkey()。 Downkey()。 if(1 == up_flag || 1 == down_flag) { Write1302(0x8e,0x00)。 //寫入允許 Write1302(0x8a,temp)。 //寫入新的星期數(shù) Write1302(0x8e,0x80)。 //禁止寫入 up_flag=0。 down_flag=0。 } hide_week++。 if(hide_week3) hide_week=0。 show_time()。 }while(5 == count)。break。 case 5:do //count=5,調(diào)整日 { hide_week=0。 Exitkey()。 Upkey()。 Downkey()。 if(1 == up_flag || 1 == down_flag) { Write1302(0x8e,0x00)。 //寫入允許 Write1302(0x86,temp)。 //寫入新的日數(shù) Write1302(0x8e,0x80)。 //禁止寫入 up_flag=0。 down_flag=0。 } hide_day++。 if(hide_day3) hide_day=0。 show_time()。 }while(6 == count)。break。 case 6:do //count=6,調(diào)整月 { hide_day=0。 Exitkey()。 Upkey()。 Downkey()。 if(1 == up_flag || 1 == down_flag) { Write1302(0x8e,0x00)。 //寫入允許 Write1302(0x88,temp)。 //寫入新的月數(shù) Write1302(0x8e,0x80)。 //禁止寫入 up_flag=0。 down_flag=0。 } hide_month++。 if(hide_month3) hide_month=0。 show_time()。 }while(7 == count)。break。 case 7:do //count=7,調(diào)整年 { hide_month=0。 Exitkey()。 Upkey()。 Downkey()。 if(1 == up_flag || 1 == down_flag) { Write1302(0x8e,0x00)。 //寫入允許 Write1302(0x8c,temp)。 //寫入新的年數(shù) Write1302(0x8e,0x80)。 //禁止寫入 up_flag=0。 down_flag=0。 } hide_year++。 if(hide_year3) hide_year=0。 show_time()。 }while(8 == count)。break。 case 8: count=0。hide_year=0。 //count8, 跳出調(diào)整模式,返回默認(rèn)顯示狀態(tài) Second=Read1302(DS1302_SECOND)。 Write1302(0x8e,0x00)。 //寫入允許 Write1302(0x80,Secondamp。0x7f)。 Write1302(0x8E,0x80)。 //禁止寫入 done=0。 break。 //count=7,開啟中斷,標(biāo)志位置0并退出 default:break。 }} void show_time() //液晶顯示程序{ DS1302_GetTime(amp。CurrentTime)。 //獲取時(shí)鐘芯片的時(shí)間數(shù)據(jù) TimeToStr(amp。CurrentTime)。 //時(shí)間數(shù)據(jù)轉(zhuǎn)換液晶字符 DateToStr(amp。CurrentTime)。 //日期數(shù)據(jù)轉(zhuǎn)換液晶字符 LCD_Print(0,0,TempBuffer1)。 //顯示時(shí)間 LCD_Print(8,0,)。 //顯示時(shí)間 LCD_Print(1,1,)。 //顯示日期 //getweekstr()。 //Set_X_Y(12,1)。 //Print(week_str)。 LCD_Print(12,1,)。 Delay1ms(100)。 //掃描延時(shí)}void temp_save(uchar addr,uchar tdata) //向AT24C02中的ADDR地址中寫入一個(gè)字節(jié)tdata數(shù)據(jù){ uchar handshake。 // 握手次數(shù)/* 寫0x01地址的數(shù)據(jù) */ for(handshake=0。handshake1。handshake++) { iic_start()。 // 啟動(dòng) iic_writebyte(0xa0)。 // 寫IIC命令 if(iic_ackcheck()!=0) // 應(yīng)答信號(hào) break。 iic_writebyte(addr)。 // 寫地址命令,地址是0x01 if(iic_ackcheck()!=0) // 應(yīng)答信號(hào) break。 iic_writebyte(tdata)。 // 寫數(shù)據(jù) if(iic_ackcheck()!=0) // 應(yīng)答信號(hào) break。 iic_stop()。 // 停止 Delay1ms(20)。 }} uchar temp_read(uchar addr) //讀取AT24C02中addr中的一個(gè)字節(jié)數(shù)據(jù){ uchar handshake,tdata。 // 握手次數(shù) for(handshake=0。handshake1。handshake++) { iic_start()。 // 啟動(dòng) iic_writebyte(0xa0)。 // 寫IIC命令 if(iic_ackcheck()!=0) // 應(yīng)答信號(hào) break。 iic_writebyte(addr)。 // 寫地址命令,地址是0x00 if(iic_ackcheck()!=0) // 應(yīng)答信號(hào) break。 iic_start()。 // 啟動(dòng) iic_writebyte(0xa1)。 // 寫IIC命令 if(iic_ackcheck()!=0) // 應(yīng)答信號(hào) break。 tdata=iic_readbyte()。 // 讀0x00地址的數(shù)據(jù), // 且把這個(gè)數(shù)據(jù)暫存全局變量times_pd iic_nack()。 // 發(fā)送非應(yīng)答信號(hào) iic_stop()。 // 停止 delayms(20)。 // 重新啟動(dòng)與停止之間需要有時(shí)間差 } return tdata。}void save_data() //向AT24C02中保存的溫度和時(shí)間信息{ uchar i。 for(i=0。i6。i++) temp_save(0x00+i,TempBuffer1[i])。 for(i=0。i11。i++) temp_save(0x06+i,[i])。 for(i=0。i9。i++) temp_save(0x11+i,[i])。}void read_data() //讀取AT24C02中保存的溫度和時(shí)間信息{ uchar i。 for(i=0。i6。i++) TempBuffer[i]=temp_read(0x00+i)。 for(i=0。i11。i++) DateString[i]=temp_read(0x06+i)。 for(i=0。i9。i++) TimeString[i]=temp_read(0x11+i)。}vo
點(diǎn)擊復(fù)制文檔內(nèi)容
高考資料相關(guān)推薦
文庫吧 www.dybbs8.com
備案圖鄂ICP備17016276號(hào)-1