洗衣機(jī)控制器課程設(shè)計(jì)_第1頁(yè)
洗衣機(jī)控制器課程設(shè)計(jì)_第2頁(yè)
洗衣機(jī)控制器課程設(shè)計(jì)_第3頁(yè)
洗衣機(jī)控制器課程設(shè)計(jì)_第4頁(yè)
洗衣機(jī)控制器課程設(shè)計(jì)_第5頁(yè)
已閱讀5頁(yè),還剩11頁(yè)未讀, 繼續(xù)免費(fèi)閱讀

下載本文檔

版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請(qǐng)進(jìn)行舉報(bào)或認(rèn)領(lǐng)

文檔簡(jiǎn)介

1、東 北 石 油 大 學(xué)課 程 設(shè) 計(jì) 2012年 3 月2日東北石油大學(xué)課程設(shè)計(jì)任務(wù)書課程 EDA 技術(shù)課程設(shè)計(jì) 題目 洗衣機(jī)控制器 專業(yè) 電子信息工程姓名 姜長(zhǎng)劍 學(xué)號(hào)080901140922主要內(nèi)容、基本要求、主要參考資料等 主要內(nèi)容:設(shè)計(jì)一個(gè)洗衣機(jī)控制器,要求洗衣機(jī)有正轉(zhuǎn)、反轉(zhuǎn)、暫停三種狀態(tài)。設(shè)定洗衣機(jī)的工作時(shí)間,要洗衣機(jī)在工作時(shí)間內(nèi)完成:定時(shí)啟動(dòng) 正轉(zhuǎn)20秒 暫停10秒 反轉(zhuǎn)20秒 暫停10秒 定時(shí)未到回到“正轉(zhuǎn)20秒 暫停10秒 ”,定時(shí)到則停止,同時(shí)發(fā)出提示音?;疽螅?、設(shè)計(jì)一個(gè)電子定時(shí)器,控制洗衣機(jī)作如下運(yùn)轉(zhuǎn):定時(shí)啟動(dòng) 正轉(zhuǎn)20秒 暫停10秒 反轉(zhuǎn)20秒 暫停10秒 定時(shí)未到

2、回到“正轉(zhuǎn)20秒 暫停10秒 ”,定時(shí)到則停止;2、若定時(shí)到,則停機(jī)發(fā)出音響信號(hào);3、用兩個(gè)數(shù)碼管顯示洗滌的預(yù)置時(shí)間(分鐘數(shù)),按倒計(jì)時(shí)方式對(duì)洗滌過程作計(jì)時(shí)顯示,直到時(shí)間到停機(jī);洗滌過程由“開始”信號(hào)開始;4、三只LED 燈表示“正轉(zhuǎn)”、“反轉(zhuǎn)”、“暫?!比齻€(gè)狀態(tài)。 1 潘松著.EDA 技術(shù)實(shí)用教程(第二版. 北京:科學(xué)出版社,2005. 2 康華光主編. 電子技術(shù)基礎(chǔ) 模擬部分. 北京:高教出版社,2006. 3 閻石主編. 數(shù)字電子技術(shù)基礎(chǔ). 北京:高教出版社,2003.完成期限 2012.3.12 指導(dǎo)教師 專業(yè)負(fù)責(zé)人2012年 2月27日一、總體設(shè)計(jì)思想1. 基本原理首先用電路控制三只

3、LED 顯示洗衣機(jī)正轉(zhuǎn)、反轉(zhuǎn)、暫停三種狀態(tài)。然后用電子定時(shí)器控制洗衣機(jī)設(shè)定的工作時(shí)間,以及正傳和反轉(zhuǎn)運(yùn)行時(shí)間的控制。同時(shí)用兩個(gè)數(shù)碼管顯示洗滌的預(yù)置時(shí)間(按分鐘計(jì)數(shù)),按倒計(jì)時(shí)方式對(duì)洗滌過程作計(jì)時(shí)顯示,直到時(shí)間到停機(jī);洗滌過程由“開始”信號(hào)開始;最后定時(shí)到則停止,同時(shí)用蜂鳴器發(fā)出提示音。通過各種開關(guān)組成控制電路,使洗衣機(jī)實(shí)現(xiàn)程序運(yùn)轉(zhuǎn)。 直至結(jié)束為止。 2. 設(shè)計(jì)框圖洗衣機(jī)控制電路由定時(shí)輸入模塊,電機(jī)輸出模塊,電機(jī)時(shí)間控制模塊,數(shù)字顯示電路,倒計(jì)時(shí)模塊以及報(bào)警器模塊組成。 圖一二、設(shè)計(jì)步驟和調(diào)試過程1、總體設(shè)計(jì)電路電路圖如下所示: 圖二 2、模塊設(shè)計(jì)和相應(yīng)模塊程序 (1)定時(shí)輸入模塊:shurui

4、nstshu hshu din dout3.0dout13.0此模塊是為了實(shí)現(xiàn)洗衣機(jī)能夠定時(shí)輸入的功能,保證洗衣機(jī)能夠正常運(yùn)行。 library IEEE;use IEEE.STD_LOGIC_1164.ALL; use IEEE.STD_LOGIC_ARITH.ALL;use IEEE.STD_LOGIC_UNSIGNED.ALL; entity shuru isPort ( shu : in std_logic; hshu: in std_logic; din : in std_logic;dout:out std_logic_vector(3 downto 0;dout1:out std

5、_logic_vector(3 downto 0; end shuru;architecture Behavioral of shuru issignal count: std_logic_vector(3 downto 0; signal count1: std_logic_vector(3 downto 0; signal count2: std_logic_vector(3 downto 0; signal count3: std_logic_vector(3 downto 0; beginprocess(shu,hshu,din begindout<=count; dout1&l

6、t;=count1; if din='1' thendout<="1111"dout1<="1111" elsif rising_edge(shu then if count="1001" then count<="0000" elsecount<=count+1; end if; end if;if rising_edge(hshu then if count1="0110" then count1<="0000" elseco

7、unt1<=count1+1; end if; end if; end process; end Behavioral;(2)電機(jī)時(shí)間控制模塊:washmachineinstclkc d此模塊由一個(gè)累加器和一個(gè)命令控制器組成,用來實(shí)現(xiàn)預(yù)置洗滌時(shí)間的功能,洗滌時(shí)間以分鐘數(shù)為單位,用戶可根據(jù)自己的需求來設(shè)定洗滌時(shí)間的長(zhǎng)短。library IEEE;use IEEE.STD_LOGIC_1164.ALL; use IEEE.STD_LOGIC_ARITH.ALL;use IEEE.STD_LOGIC_UNSIGNED.ALL; entity washmachine isPort ( clk :

8、 in std_logic; c :out std_logic; d :out std_logic; end washmachine;architecture miao20 of washmachine issignal count: std_logic_vector(2 downto 0; signal shi: integer range 0 to 60; beginprocess(clk beginif rising_edge(clk then if shi=60 then shi<=0;c<='1'else shi<=shi+1;c<='

9、0'end if;if count="101" then count<="000" d<='1' elsecount<=count+1; d<='0' end if; end if; end process;end miao20; (3)電機(jī)輸出模塊dianjiinstccdd1.0deng2.0此模塊是為了實(shí)現(xiàn)能夠控制洗衣機(jī)電機(jī)時(shí)間達(dá)到正轉(zhuǎn)、反轉(zhuǎn)、暫停的功能。 library IEEE;use IEEE.STD_LOGIC_1164.ALL; use IEEE.STD_LOGIC_ARIT

10、H.ALL;use IEEE.STD_LOGIC_UNSIGNED.ALL; entity dianji is Port (cc :in std_logic;dd :out std_logic_vector(1 downto 0; deng : out std_logic_vector(2 downto 0; end dianji;architecture di of dianji issignal count : std_logic_vector(2 downto 0; signal dian : std_logic_vector(1 downto 0; signal deng1 : std

11、_logic_vector(2 downto 0; begindd <= dian; deng<=deng1; process(cc beginif rising_edge(cc then if count = "101" then count <= "000" elsecount <= count+1; end if;if count="000" thendian<="01"deng1<="100" elsif count="010" t

12、hendian<="00"deng1<="010" elsif count="011" thendian<="11" ;deng1<="001"end if; end if; end process; end di ;(4)數(shù)碼管顯示模塊: 根據(jù)課程設(shè)計(jì)要求,必須將洗衣機(jī)的工作狀態(tài)及工作時(shí)間在數(shù)碼管和指示燈上顯示出來,此模塊是用來控制洗衣機(jī)的工作狀態(tài)及工作的頻率,并把工作狀態(tài)及工作時(shí)間顯示出來。library IEEE;use IEEE.STD_LOGIC_1164.AL

13、L; use IEEE.STD_LOGIC_ARITH.ALL;use IEEE.STD_LOGIC_UNSIGNED.ALL; entity shuma isPort (din:in std_logic_vector(3 downto 0 ; dout:out std_logic_vector(6 downto 0 ; end shuma;architecture Behavioral of shuma is beginprocess(din begin case din iswhen "0000" => dout<="0000001"-0

14、 when "0001" => dout<="1001111"-1 when "0010" => dout<="0010010"-2 when "0011" => dout<="0000110"-3 when "0100" => dout<="1001100" -4 when "0101" => dout<="0100100"-5 whe

15、n "0110" => dout<="0100000"-6 when "0111" => dout<="0001111"-7 when "1000" => dout<="0000000"-8 when "1001" => dout<="0000100"-9when others => dout<="1111111" end case; end process

16、; end Behavioral; (5)倒計(jì)時(shí)模塊: 由于洗衣機(jī)有工作時(shí)間,必須要一模塊來控制它的工作時(shí)間范圍,當(dāng)洗衣機(jī)開始工作后,減法計(jì)數(shù)器即會(huì)實(shí)現(xiàn)減數(shù)功能,直到時(shí)間減到零,洗衣機(jī)便停止工作。library IEEE;use IEEE.STD_LOGIC_1164.ALL; use IEEE.STD_LOGIC_ARITH.ALL;use IEEE.STD_LOGIC_UNSIGNED.ALL; entity hui isPort ( jian : in std_logic; reset : in std_logic;din : in std_logic_vector(3 downto 0

17、; dout : out std_logic_vector(3 downto 0; c:out std_logic; end hui;architecture Behavioral of hui issignal count : std_logic_vector(3 downto 0; begindout <= count; process(jian,reset,din beginif reset='1'then count <= din ; c<='0'elsif rising_edge(jian then if count = "

18、0000" then count <= "1001" c<='1'elsecount <= count-1; c<='0' end if; end if; end process; end Behavioral; library IEEE;use IEEE.STD_LOGIC_1164.ALL; use IEEE.STD_LOGIC_ARITH.ALL;use IEEE.STD_LOGIC_UNSIGNED.ALL; entity hui1 isPort ( jian : in std_logic; rese

19、t : in std_logic;din : in std_logic_vector(3 downto 0; dout : out std_logic_vector(3 downto 0; c:out std_logic; end hui1;architecture Behavioral of hui1 issignal count : std_logic_vector(3 downto 0; begindout <= count; process(jian,reset,din beginif reset='1'then count <= din ; c<=&

20、#39;0'elsif rising_edge(jian then if count = "0000" then c<='1' elsecount <= count-1; c<='0' end if; end if; end process; end Behavioral;(6)報(bào)警器模塊:當(dāng)洗滌時(shí)間結(jié)束時(shí),洗衣機(jī)就會(huì)自動(dòng)發(fā)出警報(bào)聲,以此提醒用戶洗滌工作完成,此模塊就是實(shí)現(xiàn)此功能。 library ieee;use ieee.std_logic_1164.all; use ieee.std_logic_undigne

21、d.all; entity warming is port(clk:in std_logic;finishc: in std_logic; warn:out std_logic; end warming;Architecture six of warming is begin process(clk BeginIf finishc=1then warn<=clk; Else warn<=0; end if;end process; end;3、仿真及仿真結(jié)果分析EDA工具在EDA 技術(shù)應(yīng)用中占據(jù)極其重要的位置,EDA 的核心是利用計(jì)算機(jī)完成電子設(shè)計(jì)全程自動(dòng)化,因此基于計(jì)算機(jī)環(huán)境的E

22、DA 軟件的支持是必不可少的。此次設(shè)計(jì)所用EDA 工具是由著名的Alter 公司生產(chǎn)的MAX plus工具軟件,它是一種集成的開發(fā)環(huán)境,支持原理圖、VHDL 和Verilog 語言文本文件,以及波形文件作為設(shè)計(jì)輸入,并支持這些文件的人以混合設(shè)計(jì)。 (1)定時(shí)輸入仿真: (2)電機(jī)時(shí)間控制模塊: (4)數(shù)碼顯示仿真: 4、實(shí)驗(yàn)調(diào)試結(jié)果通過幾天的調(diào)試,調(diào)試結(jié)果達(dá)到了設(shè)計(jì)要求。實(shí)現(xiàn)功能如下:定時(shí)啟動(dòng)正轉(zhuǎn)20秒暫停10秒反轉(zhuǎn)20秒暫停10秒定時(shí)未到回到“正轉(zhuǎn)20秒暫停10秒”,時(shí)間控制正常。三只LED 管也能顯示“正轉(zhuǎn)”、“反轉(zhuǎn)”、“暫?!比齻€(gè)狀態(tài)。運(yùn)轉(zhuǎn)時(shí),數(shù)碼管也能顯示倒計(jì)時(shí)間。最后當(dāng)定時(shí)達(dá)到時(shí),蜂鳴器發(fā)出響聲報(bào)警。三、結(jié)論及心得體會(huì) 通過這次課程設(shè)計(jì)使我懂得了理論與實(shí)際相結(jié)合是很重要的,只有理論知 識(shí)是遠(yuǎn)遠(yuǎn)不夠的,只有把所學(xué)的理論知識(shí)與實(shí)踐相結(jié)合起來,從理論中得出結(jié) 論,才能真正地更好去理解知識(shí),從而提高自己的實(shí)際動(dòng)手能力和獨(dú)立思考的 能力。從查閱相關(guān)的資料到自己設(shè)計(jì)總體方案,每一個(gè)環(huán)節(jié)都是在對(duì)

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請(qǐng)下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請(qǐng)聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁(yè)內(nèi)容里面會(huì)有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 人人文庫(kù)網(wǎng)僅提供信息存儲(chǔ)空間,僅對(duì)用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對(duì)用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對(duì)任何下載內(nèi)容負(fù)責(zé)。
  • 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請(qǐng)與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時(shí)也不承擔(dān)用戶因使用這些下載資源對(duì)自己和他人造成任何形式的傷害或損失。

評(píng)論

0/150

提交評(píng)論