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

正文內(nèi)容

基于單片機(jī)的多功能萬(wàn)年歷畢業(yè)論文-資料下載頁(yè)

2025-06-20 12:35本頁(yè)面
  

【正文】 )。 mdelay(4000)。 mdelay(4)。 count=0。 hide_sec=0,hide_min=0,hide_hour=0,hide_day=0,hide_week=0,hide_month=0,hide_year=0。 Second=Read1302(DS1302_SECOND)。 Write1302(0x8e,0x00)。 //寫入允許 Write1302(0x80,Secondamp。0x7f)。 Write1302(0x8E,0x80)。 //禁止寫入 done=0。 while(out==0)。 P3=0X00。 LCD_clear()。 mdelay(40)。 }} /*************************菜單選擇**************************/ void Menu_move(void) // 主程序{ unsigned int n。 if(!Up) { di(100)。 //發(fā)出按鍵音 mdelay(4)。 while(!Up)。 //等鍵松開(kāi) count=count+1。 //scankey按一次,count就加1 if (count==4) //因?yàn)橹挥袃杉?jí)菜單,所以當(dāng)count==3時(shí)歸0 count=1。 for(n=0。n2000。n++)。 //鍵去抖 }} /******************確認(rèn)要進(jìn)入的主菜單項(xiàng)**********************/ void menu_OK(void) // 主程序{ unsigned int n。 if(!Set) { di(100)。 LCD_clear()。 di(100)。 //發(fā)出按鍵音 mdelay(4)。 while(!Set)。 //等鍵松開(kāi) set_menu=1。 //進(jìn)入調(diào)整模式 for(n=0。n2000。n++)。 //鍵去抖 }} /*******************檢測(cè)按鍵有無(wú)按下*************************/void scankey(void) // 主程序{ unsigned int n。 if(!Set) { di(100)。 //發(fā)出按鍵音 mdelay(4)。 while(!Set)。 //等鍵松開(kāi) count=count+1。 //scankey按一次,count就加1 done=1。 //進(jìn)入調(diào)整模式 for(n=0。n2000。n++)。 //鍵去抖 }}/////////////////////////////////////////////////////////////////////void Upkey()//升序按鍵{ Up=1。 if(Up==0) { mdelay(4)。 di(100)。 switch(count) {case 1: temp=Read1302(DS1302_SECOND)。 //讀取秒數(shù) temp=temp+1。 //秒數(shù)加1 up_flag=1。 //數(shù)據(jù)調(diào)整后更新標(biāo)志 if((tempamp。0x7f)0x59) //超過(guò)59秒,清零 temp=0。 break。 case 2: temp=Read1302(DS1302_MINUTE)。 //讀取分?jǐn)?shù) temp=temp+1。 //分?jǐn)?shù)加1 up_flag=1。 if(temp0x59) //超過(guò)59分,清零 temp=0。 break。 case 3: temp=Read1302(DS1302_HOUR)。 //讀取小時(shí)數(shù) temp=temp+1。 //小時(shí)數(shù)加1 up_flag=1。 if(temp0x23) //超過(guò)23小時(shí),清零 temp=0。 break。 case 4: temp=Read1302(DS1302_WEEK)。 //讀取星期數(shù) temp=temp+1。 //星期數(shù)加1 up_flag=1。 if(temp0x7) temp=1。 break。 case 5: temp=Read1302(DS1302_DAY)。 //讀取日數(shù) temp=temp+1。 //日數(shù)加1 up_flag=1。 if(temp0x31) temp=1。 break。 case 6: temp=Read1302(DS1302_MONTH)。 //讀取月數(shù) temp=temp+1。 //月數(shù)加1 up_flag=1。 if(temp0x12) temp=1。 break。 case 7: temp=Read1302(DS1302_YEAR)。 //讀取年數(shù) temp=temp+1。 //年數(shù)加1 up_flag=1。 if(temp0x85) temp=0。 break。 default:break。 } while(Up==0)。 }}/////////////////////////////////////////////////////////////////////void Downkey()//降序按鍵{ Down=1。 if(Down==0) { mdelay(4)。 di(100)。 switch(count) {case 1: temp=Read1302(DS1302_SECOND)。 //讀取秒數(shù) temp=temp1。 //秒數(shù)減1 down_flag=1。 //數(shù)據(jù)調(diào)整后更新標(biāo)志 if(temp==0x7f) //小于0秒,返回59秒 temp=0x59。 break。 case 2: temp=Read1302(DS1302_MINUTE)。 //讀取分?jǐn)?shù) temp=temp1。 //分?jǐn)?shù)減1 down_flag=1。 if(temp==1) temp=0x59。 //小于0秒,返回59秒 break。 case 3: temp=Read1302(DS1302_HOUR)。 //讀取小時(shí)數(shù) temp=temp1。 //小時(shí)數(shù)減1 down_flag=1。 if(temp==1) temp=0x23。 break。 case 4: temp=Read1302(DS1302_WEEK)。 //讀取星期數(shù) temp=temp1。 //星期數(shù)減1 down_flag=1。 if(temp==0) temp=0x7。 break。 case 5: temp=Read1302(DS1302_DAY)。 //讀取日數(shù) temp=temp1。 //日數(shù)減1 down_flag=1。 if(temp==0) temp=31。 break。 case 6: temp=Read1302(DS1302_MONTH)。 //讀取月數(shù) temp=temp1。 //月數(shù)減1 down_flag=1。 if(temp==0) temp=12。 break。 case 7: temp=Read1302(DS1302_YEAR)。 //讀取年數(shù) temp=temp1。 //年數(shù)減1 down_flag=1。 if(temp==1) temp=0x85。 break。 default:break。 } while(Down==0)。 }} /************************按鍵選擇**************************/void timedone()//按鍵功能執(zhí)行{ uchar Second。while(done==1){ if(flag==0) //關(guān)閉時(shí)鐘,停止計(jì)時(shí) { Write1302(0x8e,0x00)。 //寫入允許 temp=Read1302(0x80)。 Write1302(0x80,temp|0x80)。 Write1302(0x8e,0x80)。 //禁止寫入 flag=1。 } scankey()。 //掃描模式切換按鍵 switch(count) {case 1:do //count=1,調(diào)整秒 { outkey()。 //掃描跳出按鈕 Upkey()。 //掃描加按鈕 Downkey()。 //掃描減按鈕 if(up_flag==1||down_flag==1) //數(shù)據(jù)更新,重新寫入新的數(shù)據(jù) { Write1302(0x8e,0x00)。 //寫入允許 Write1302(0x80,temp|0x80)。 //寫入新的秒數(shù) Write1302(0x8e,0x80)。 //禁止寫入 u
點(diǎn)擊復(fù)制文檔內(nèi)容
環(huán)評(píng)公示相關(guān)推薦
文庫(kù)吧 www.dybbs8.com
備案圖鄂ICP備17016276號(hào)-1