【正文】
用清零的方法把模 16的計數(shù)器轉(zhuǎn)換為模三的計數(shù)器,輸出即為三分頻后的脈沖。模式狀態(tài)切換的連個按鍵的輸入同時輸送到兩個 LED 燈,通過觀察燈的狀態(tài)我們就可以判斷當(dāng)前的P I N _ 1 5 6V C CC M OD 1 I N P U TP I N _ 1 5 8V C CC M OD 2 I N P U TP I N _ 1 2 4V C CC LE AR I N P U TP I N _ 1 2 1V C C1 I N P U TP I N _ 1 2 2V C C2 I N P U TP I N _ 1 2 3V C C3 I N P U TP I N _ 2 8V C CC 48 M I N P U TV C CEN I N P U TP I N _ 1 7 5BEEPO U T P U TP I N _ 1 6 9AO U T P U TP I N _ 1 7 0BO U T P U TP I N _ 1 6 7CO U T P U TP I N _ 1 6 8DO U T P U TP I N _ 1 6 5EO U T P U TP I N _ 1 6 6FO U T P U TP I N _ 1 6 3GO U T P U TP I N _ 1 6 2SLO U T P U TP I N _ 1 6 1SHO U T P U TP I N _ 1 3 6MLO U T P U TP I N _ 1 3 7MHO U T P U TP I N _ 1 3 8HLO U T P U TP I N _ 1 3 9HHO U T P U TC L E A R 1XMXHD M KC M O D 1DHKC L E A R 248mC M O D 2X I A O D A YX I A O M O NX I A O Y E A RB E E PABCDEFGSLSHMLMHHLHHH A V E A L Bins tKM O DM O D 1M O D 22 2ins t 5KM O DM O D 1M O D 22 2ins t 6KM O DM O D 1M O D 22 2ins t 10KM O DM O D 1M O D 22 2ins t 11KM O DM O D 1M O D 22 2ins t 12N O Tins t 13N O Tins t 14A N D 2ins t 1C M OD 1C M OD 2M1M2M1M248M48MY EA RY EA REDA(II) 多功能數(shù)字鐘 8 模式。 最后由于有三組輸出信號要顯示,我們通過顯示模式控制開關(guān)選擇要顯示的狀態(tài)信號。清零開關(guān)的輸入信號輸送到各個 計數(shù)器的清零端即可。鬧表各位的動態(tài)顯示原理與上面相同。至于整點報時電路我們把要蜂鳴器響的時間通過卡諾圖化 簡,得到最簡的邏輯函數(shù)式,再把邏輯函數(shù)式通過電路實現(xiàn),滿足要求才把脈沖信號輸送給蜂鳴器。數(shù)據(jù)選擇器輸入信號由一個模八的計數(shù)器提供,這個模八的計數(shù)器的輸出同時送給一 74138 譯碼器。 1hz 的脈沖送到時鐘計時電路秒位的 clk 輸入口;秒位的進位信號和 2hz脈沖通過開關(guān)的選擇輸送到分位電路的時鐘輸入口,前者用 于正常計時,后者由于校分時;分位的進位信號和 2hz 脈沖通過開關(guān)的選擇輸送到 時 位電路的時鐘輸入口 ,前者用于正常計時,后者由于校時。同樣萬年歷電路需要一個時間調(diào)整電路、顯示電路、顯示模式切換電路。因為我們只含有一個數(shù)碼顯示 器,一般狀態(tài)下顯示的是時鐘,所以我們需要一個顯示模式切換電路。這EDA(II) 多功能數(shù)字鐘 6 是只含基本功能的時鐘電路所包含的子電路。 校分、校時、清零電路只需要輸入一些控制信號給時鐘計時電路即可,當(dāng)然這些控制信號是由開關(guān)提供的。時鐘的計時范圍是 00: 00: 0023: 59: 59,所以我們需要設(shè)計模六十和模二十四的 計數(shù)器組成時鐘計時電路。 這樣我們總共使用三個開關(guān)就可以控制整個電路 鎖死鍵、模式鍵、控制鍵。 d、 鎖死狀態(tài)( K5=0) :此狀態(tài)下所有電路都保持原狀態(tài)(不給電路送脈沖)。 b、 鬧表狀態(tài)( K7= K8=0): 此狀態(tài)下數(shù)碼管顯示當(dāng)前 鬧定的時間, K1 為 設(shè)定分鐘的開關(guān),K2為 設(shè)定小 時開關(guān) ,清零開關(guān)無用 K4。 II.功能簡介 本電路具有三種不同的工作狀態(tài)(同步工作),可通過模式鍵進行切換 (可通過 LED LED2觀察當(dāng)前的模式) 。 關(guān)鍵字: 層次設(shè)計 多功能數(shù)字時鐘 同步 整點報時 鬧鐘 萬年歷 VHDL語言 EDA(II) 多功能數(shù)字鐘 2 Summary: This text is according to Altera pany’s QuartusII software and homologous experiment terrace pleted multifunction number timer experiment, make us clearly understand the function of number form how carry out. While designing we adopted the layer designs thought, the function pursues class gradually increase, and stay a lot of outer circles to connect while sealing to pack to fully increase other new functions. The experiment mainly includes three corpusesThe clock basic function electric circuit, alarm clock electric circuit, ten thousand calendar electric circuits. Corpus one: Mainly involve a mold 60 with mold 24 count machine, dynamic state to show a control electric circuit, cent repeatedly machine , a little bit whole tell the time electric circuit, These electric circuits are all packed with mold piece okay, for the purpose of other electric circuits adjust to use. With count machine posing to account parts, pass a cent repeatedly the machine divides of when the 1 HZ pulse accounts adjust to show that the electric circuit suggests and passes a little bit whole buzzer that tell the time an electric circuit control with the dynamic state. BE counting the way that the machine class adopted synchronously external different step in the inner part while uniting, but came to a synchronous effect through a simple change and than synchronously returned credibility. While showing a control for economizing a resources adoption dynamic state principle, from wove VHDL language of 24 choose 4 data selectors. Corpus two: Mainly involve a mold 60 with mold 24 count machine, show control electric circuit, 147 together or door. With mold 60 with mold 24 count machine posing in fixed time with saving electric circuit, adjust to show control electric circuit to suggest with the dynamic state, pass 147 together or door and followup and door control buzzer. Corpus three: Mainly involve a mold 100, mold 12 with mold 30 count a machine, dynamic state to show electric circuit. With count the machine posing accounts parts, adjust to show that the electric circuit shows with the dynamic state. Finally because of too many switch involving in the function, we adopted 2 kinds to reply to use principle and gave 2 kinds reply to use thought. Key word: The layer designs、 multifunction digital clock、 Synchronous、 A little bit whole tell the time, alarm clock、 ten thousand calendars,、 The language of VHDL EDA(II) 多功能數(shù)字鐘 3 目 錄 一. 設(shè)計說明 ………………………………………………………… 4 I.功能說明 ……………………………………………… ……………………………… … 4 II.功能簡介 ……………………………………………… ……………………………… … 4 (兩種方案) ………… ……………………………… ……………… … 4 二. 方案論證 ……………………………………………… …… 5 ………… ……………………………… ………………… …………… 5 II. 電路的工作原理 ………… ……………………………… ………………… ……… 6 三. 各子模塊設(shè)計原理 …………………………… ……………… 8 I. 脈沖分頻模塊 …………………………………………………………… …………… 8 (包含校定和清零功能 ) …………………………………………… …1 0 III.顯示控制電路 ………… ……………………………… ………………… …………… 14 ………… ……………………………… ………………… 18 ………… ……………………………… ………………… …………… 18 ………… …………… ………………… ………………… ………………… 20 ………… ……………………………… ………………… ……………… 24 四. 調(diào)試與仿真 …………………………………… ……………… 27 ………… ……………………………… ………………… …………… 27 II. 計時電路 ………… ……………………………… ………………… ……………… 28 ………… ……………………………… ………………… ……………………… 29 五.結(jié)論 ………………………………………………………………… 29 六.實驗感想 ………………………………………………………… 30 EDA(II) 多功能數(shù)字鐘 4 一. 設(shè)計 說明 I. 功能說明 : 利用 QuartusII軟件設(shè)計一個數(shù)字鐘,對設(shè)計電路進行功能仿真,并下載到 SmartSOPC實驗系統(tǒng)中,可以完成 00:00:00 到 23:59:59的計時功能,并在控制電路的作用下具有保持、清零、快速校時、快速校分、整點報時等功能。以計數(shù)器構(gòu)成計時部件,調(diào)用動態(tài)顯示電路顯示。以模 60 與模 24 計數(shù)器構(gòu)成定時與存儲電路,調(diào)用 動態(tài)顯示控制電路顯示,通過 147 同或門和后 續(xù)與門控制蜂鳴器。顯示控制時為了節(jié)約資源采用動態(tài)原理,自