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

正文內(nèi)容

基于單片機(jī)的電子萬(wàn)年歷設(shè)計(jì)畢業(yè)論文(參考版)

2025-06-30 19:59本頁(yè)面
  

【正文】 } break。 if (temp==0)return(0)。 case 13:{temp=year_code[table_addr+2]amp。else return(1)。0x01。} break。 if (temp==0)return(0)。 case 11:{temp=year_code[table_addr+1]amp。else return(1)。0x04。} break。 if (temp==0)return(0)。 case 9:{temp=year_code[table_addr+1]amp。else return(1)。0x10。} break。 if (temp==0)return(0)。 case 7:{temp=year_code[table_addr+1]amp。else return(1)。0x40。} break。 if (temp==0) return(0)。 case 5:{temp=year_code[table_addr+1]amp。else return(1)。0x01。} break。 if (temp==0)return(0)。 case 3:{temp=year_code[table_addr]amp。else return(1)。0x04。} break。 if (temp==0)return(0)。 switch (month_p) { case 1:{temp=year_code[table_addr]amp。 //data uchar year_moon,month_moon,day_moon,week。 /* 函數(shù)功能:輸入BCD陽(yáng)歷數(shù)據(jù),輸出BCD陰歷數(shù)據(jù)(只允許19012099年) 調(diào)用函數(shù)示例:Conversion(c_sun,year_sun,month_sun,day_sun) 如:計(jì)算2004年10月16日Conversion(0,0x4,0x10,0x16)。 ///月份數(shù)據(jù)表code uchar day_code1[9]={0x0,0x1f,0x3b,0x5a,0x78,0x97,0xb5,0xd4,0xf3}。 //SCK腳置低 Ds1302_Write_Byte(ds1302_sec_add,0x00)。 }}/* DS1302初始化*/void Ds1302_Init(void){ RST_CLR。 time_buf1[i]=time_buf[i]%16。i8。//秒 time_buf[7]=Ds1302_Read_Byte(ds1302_day_add)。 //分 time_buf[6]=(Ds1302_Read_Byte(ds1302_sec_add))amp。 //日 time_buf[4]=Ds1302_Read_Byte(ds1302_hr_add)。 //年 time_buf[2]=Ds1302_Read_Byte(ds1302_month_add)。 //打開寫保護(hù)}/*從DS1302讀出時(shí)鐘數(shù)據(jù)*/void Ds1302_Read_Time(void) { unsigned char data i,tmp。 //秒 Ds1302_Write_Byte(ds1302_day_add,time_buf[7])。 //時(shí) Ds1302_Write_Byte(ds1302_min_add,time_buf[5])。 //日 Ds1302_Write_Byte(ds1302_day_add,time_buf[7])。 //年 Ds1302_Write_Byte(ds1302_month_add,time_buf[2])。 //暫停 //Ds1302_Write_Byte(ds1302_charger_add,0xa9)。 } Ds1302_Write_Byte(ds1302_control_add,0x00)。 time_buf[i]=time_buf1[i]%10。i8。}/*向DS1302寫入時(shí)鐘數(shù)據(jù)*/void Ds1302_Write_Time(void) {unsigned char data i,tmp。 } RST_CLR。 } SCK_SET。 } else { tempamp。 i ++) { temp = temp 1。 } //輸出數(shù)據(jù):temp for (i = 0。 SCK_CLR。 } else { IO_CLR。 i ++) { if (addr amp。//最低位置高 for (i = 0。 RST_SET。 //停止DS1302總線}/*從DS1302讀出一字節(jié)數(shù)據(jù)*/unsigned char Ds1302_Read_Byte(unsigned char addr) //*******{ unsigned char data i。 d = d 1。 } SCK_SET。 0x01) { IO_SET。 i 8。 addr = addr 1。 } SCK_SET。 0x01) { IO_SET。 i 8。 0xFE。 RST_SET。 // 顯示開及光標(biāo)設(shè)置}DS1302子程序include unsigned char idata time_buf[8]。 //顯示清屏12864Writemand(0x06,1)。}void LCDInit(void) //LCM初始化{12864Writemand(0x30,1)。 //檢測(cè)忙信號(hào) LCD_E = 0。 while (LCD_Data amp。 LCD_RW = 1。}*///讀狀態(tài)unsigned char ReadStatusLCD(void){ LCD_Data = 0xFF。 LCD_E = 1。 LCD_E = 0。 }/*讀數(shù)據(jù)unsigned char ReadDataLCD(void){ LCD_RS = 1。 LCD_E = 1。 LCD_E = 1。 LCD_RW = 0。}//寫指令void 12864Writemand(unsigned char WCLCD,Busy) //Busy為0時(shí)忽略忙檢測(cè){ if (Busy) ReadStatusLCD()。 LCD_E = 1。 LCD_E = 1。 LCD_RW = 0。 }}//寫數(shù)據(jù)void12864WriteData(unsigned char WDLCD){ ReadStatusLCD()。i16。12864Writemand(0x98,1)。i++) { 12864WriteData(str3[i])。for(i=0。 }}//dplay3顯示程序void dplay3(void){int i。i16。12864Writemand(0x90,1)。i++) { 12864WriteData(str1[i])。for(i=0。 }}//dplay1顯示函數(shù)void dplay1(void){int i。i16。12864Writemand(0x98,1)。 DelayMs(5)。 // ListLength++。i2。 }12864Writemand(X2, 1)。 case 4:X2|=0X98。 case 3:X2|=0X88。 //根據(jù)行數(shù)來(lái)選擇相應(yīng)地址 case 2:X2|=0X90。 //限制X不能大于16,Y在14之內(nèi)switch(Y){ case 1:X2|=0X80。 X amp。if(Y1) Y=1。 ListLength = 0。}12864子程序include include //按指定位置顯示一個(gè)漢字,也是讀數(shù)組,只不過(guò)讀到的字單獨(dú)顯示出來(lái)void Displayonechar(unsigned char Y, unsigned char X, unsigned char code *DData){int i。 t=a+b。 //低位b=Readonechar()。 //跳過(guò)讀序號(hào)列號(hào)的操作Writeonechar(0xBE)。Init_DS18B20()。 // 跳過(guò)讀序號(hào)列號(hào)的操作Writeonechar(0x44)。Init_DS18B20()。unsigned int b=0。 }DelayUs2x(25)。 DQ = 1。0x01。 i) { DQ = 0。for (i=8。 }return(dat)。 // 給脈沖信號(hào)if(DQ) dat|=0x80。 // 給脈沖信號(hào)dat=1。i0。unsigned char dat = 0。 //稍作延時(shí)返回return dat。 //15~60us 后接收60240us的存在脈沖 dat=DQ。 DQ = 1。 //單片機(jī)將DQ拉低 DelayUs2x(200)。 //DQ復(fù)位 DelayUs2x(5)。}各部分子程序/*名稱:18B20溫度傳感器內(nèi)容:18B20單線溫度檢測(cè)的應(yīng)用樣例程序*/includeinclude/* 18b20初始化*/bit Init_DS18B20(void){bit dat=0。 //以下再次全屏顯示,使屏幕顯示穩(wěn)定 if(alarm==0) display4_0()。beepalarm。alarm) beepalarm=11。(al_min==time_buf1[5])amp。 //判斷set鍵按下,進(jìn)入設(shè)置界面 //以下鬧鐘響,即定時(shí)報(bào)警功能 if(al_sec==time_buf1[6]) {if((al_hour==time_buf1[4])amp。 //以下按鍵循環(huán)大程序 key_count()。 if(alarm==0) display4_0()。 Conver_week(time_buf1[1],time_buf1[2],time_buf1[3])。beeptime1==0) beep=1。} if(beeptime2==0amp。} if(beeptime2!=0) {beep=~beep。beeptime1。 // 以下是正點(diǎn)報(bào)時(shí)功能 if(time_buf1[6]==0) {if(time_buf1[5]==30) beeptime1=4。 //延時(shí)片刻(可不要) while(1){ DelayMs(400)。 //啟動(dòng)等待,等LCD講入工作狀態(tài) LCDInit()。//初值寫入ds1302 Init_DS18B20()。 Ds1302_Init()。void main(void){beep=1。uchar count=0。[11] Meehan Joanne,Muir in Merseyside SMEs:Benefits and barriers[J]. TQM Journal. 2008附 錄源程序清單主程序includeinclude include include include include include include include unsigned char idata time_buf1[8] = {20,14,6,6,12,29,45}。Effect[J]theBasedT
點(diǎn)擊復(fù)制文檔內(nèi)容
數(shù)學(xué)相關(guān)推薦
文庫(kù)吧 www.dybbs8.com
備案圖鄂ICP備17016276號(hào)-1