


版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進(jìn)行舉報(bào)或認(rèn)領(lǐng)
文檔簡介
1、可編程實(shí)驗(yàn)報(bào)告實(shí)驗(yàn)報(bào)告要求:1、任務(wù)的簡單描述2、畫出電路圖3、寫出源代碼4、仿真結(jié)果5、分析和討論1、3-8譯碼器源代碼:LIBRARY ieee;USE ieee.std_logic_1164.all;USE ieee.std_logic_arith.all;USE ieee.std_logic_sig ned.all;ENTITY dc38 ISP0RT(sel :in stdogic_vector(2 downto 0);y :out stdogic_vector(7 downto 0);END dc38;ARCHITECTURE behavior OF dc38 ISBEGINy &
2、lt;= "11111110" WHEN sel = "000" else "11111101" WHEN sel = "001" else "11111011" WHEN sel = "010" else "11110111" WHEN sel = "011" else "11101111" WHEN sel = "100" else "11011111" WHEN sel
3、= "101" else "10111111" WHEN sel = "110" else "01111111" WHEN sel = "111" else "ZZZZZZZZ"«««««««« JEND behavior;仿真結(jié)果:一位全加器比 MA-rplu-G 'll 刊* E<Sr V*w Synh>!巳趴辛* l>ifleii Woof Whdew 怖蟲n曲百看
4、 曇 蚪缶蛹竊©總也藥E蛋耳衛(wèi)4吒蠱迫簽勺耳三±>瓦11: I* Tiaw 何晁49D 加&I» ri世I可債i一_ rilMMMi; d d|_托 母 BBB幷n MAK»*Lii I 曲丄Kmudd ftJ諾,史I igqrfk l勒*d口U% ll 刊中 Edr View Had中斗料審 Lnh-rt 葉。皿 W-da-比切nqs嚴(yán)橋心囲用目總占險(xiǎn)國菟ed6吧港雯澧朋四級流水加法器立第(位 全 加 l=LH、一位全加器第鎖存library ieee;use ieee.stdo gic_1164.all;use ieee.std_log
5、ic_ un sig ned.all;use ieee.std_logic_arith.all;en tity adder isport(clk,rst : in std_logic;a,b : in std_logic_vector(3 dow nto 0); sum : out std_logic_vector(3 dow nto 0); c : out std_logic);end en tity adder;architecture depict of adder issignal reg1: std_logic_vector(7 dow nto 0); signal reg2: st
6、d_logic_vector(6 dow nto 0); signal reg3: std_logic_vector(5 dow nto 0); beginbitO:process(clk,rst)beginif(rst='1') the n reg1<="00000000"elsif(ris in g_edge(clk) the n reg1(0)<= a(0) xor b(0);reg1(1)<= a(0) and b(0);reg1(2)<= a(1);reg1(3)<= b(1);reg1(4)<= a(2);re
7、g1(5)<= b(2);reg1(6)<= a(3);reg1(7)<= b(3);end if;end process bit0;bit1:process(clk,rst)beginif(rst='1') the nreg2<="0000000"elsif(ris in g_edge(clk) the nreg2(0)<= reg1(0);reg2(1)<= reg1(1) xor reg1(2) xor reg1(3);reg2(2)<=(reg1(1)andreg1(3)or(reg1(2)a nd reg1
8、(3);reg2(6 dow nto 3)<=reg1(7 dow nto 4);end if;end process bit1;bit2:process(clk,rst)beginif(rst='1') the nreg3<="000000"elsif(ris in g_edge(clk) the nreg3(1 dow nto 0)<=reg2(1 dow nto 0); reg3(2)<=reg2(2)xor reg2(3)xor reg2(4);reg3(3)<=(reg2(2)a ndreg2 (3) )or(reg2
9、(2)a ndreg2(4);reg3(5 dow nto 4)<=reg2( 6 dow nto 5);end if;end process bit2;bit3:process(clk,rst)beginif(rst='1') the nsum<="0000"c<='0'elsif(ris in g_edge(clk) the nsum(2 dow nto 0)<=reg3(2 dow nto 0);sum(3) <=reg3(3)xor reg3(4)xor reg3(5);c<=(reg3 (3) a
10、 ndreg3(4)or(reg3(3)a ndreg1(2)or(reg1(1)a ndreg2 (4) )or(reg2(3)a ndreg3(5)or(reg3(4)a ndreg3(5);end if;end process bit3;end depict;二 Tamo 陽nggytsn: MAXI 譏*id彈比F ,adiih<M 鼻砂a mw4 fngnu4Jnn*H»i ,7gi.呂呼M4J 9Wmt1dta1i r ii i i i i1 rf 1 f£«LD7-nrXV AF;??;B IDT、r12" 1K j« K L
11、1 J(_j JL1 J. J Jt(3 訓(xùn)D T'K 2K¥rx t* T w乍-X飛 1 U J « :詁丫I1】右】.苯;qD-00I *Xi1尬一:t ;a MAM-rphri II 貝tr Edr 5e Nodt-Q¥4on« HMow Hr|pn啟肴雖魄鎖園出皿匪匹鬲序也甘覺蠱怕澄冊ci ,s 3 ? *(. 匚 rm 昨 1library ieee;use ieee.std_logic_1164.all;use ieee.std_logic_ un sig ned.all;use ieee.std_logic_arith.all;e
12、n tity n oadd isport(clk,rst : in std_logic;a,b : in std_logic_vector(3 dow nto 0); sum : out std_logic_vector(3 dow nto 0); c : out std_logic);end en tity no add;architecture depict of no add issig nal reg : std_logic_vector(4 dow nto 0);sig nal rega: std_logic_vector(4 dow nto 0);sig nal regb: std
13、_logic_vector(4 dow nto 0);beginprocess(clk)beginif(risi ng_edge(clk)the nrega<='0' & a;regb<='0' & b;end if;end process;process(clk)beginif(rst='1')the nreg<="00000"elsif(ris in g_edge(clk)the nreg<=rega+regb;end if;end process;sum<=reg(3 dow
14、 nto 0);c<=reg(4);end depict;4位十進(jìn)制數(shù)計(jì)數(shù)器library ieee;use ieee.std_logic_1164.all;use ieee.std_logic_ un sig ned.all;use ieee.std_logic_arith.all;en tity dec_disp is port( clk_c nt : in std_logic;sel1 : out std_logic_vector(3 dow nto 0); sel2 : out std_logic_vector(3 dow nto 0);sel3 : out std_logic_
15、vector(3 dow nto 0);sel4 : out std_logic_vector(3 dow nto 0);end dec_disp;architecture behav of dec_disp issig naldata1:std_logic_vector(3 dow nto 0);sig naldata2:std_logic_vector(3 dow nto 0);sig naldata3:std_logic_vector(3 dow nto 0);sig naldata4:std_logic_vector(3 dow nto 0);begincoun t:process(c
16、lk_c nt)beginif(risi ng_edge(clk_cnt)the n if(data 1="1001")the n data1<="0000"else if(data2="1001")the n data2<="0000" data1<=data1+1;else if(data3="1001")the n data3<="0000" data2<=data2+1;else if(data4="1001")the
17、 n data4<="0000" data3<=data3+1;else data4<=data4+1;end if;end if;end if;end if;end if;end process count;sel1<=data1;sel2<=data2;sel3<=data3;sel4<=data4;end behav;vQV»iu n Hi口蘭加“2 £ T 士32*Jh. n I?血_9»OHbZd叵fhil«ll*i| I He 12 hi 工應(yīng) 1h 3te 14U- J 5rit
18、 4-K» 5«ufl BVk EX t.h# T£uc I Qua Bg 9 瞰 l.bi Pnjuu JL L JJLTL JUUL LUL'LLUtfLULIT lJinJE LJ JLrLl'J'Jt'LT_TLIL JJll L'LltTLLfLTL'MD3*正弦波發(fā)生器sin .mif 文件depth=256;width=8;address_radix=dec;data_radix=dec; contentbegin43:241;87:234;0: 131;44:242;88:233;1: 134;45:
19、244;89:231;2: 137;46:245;90:229;3: 141;47:246;91:227;4: 144;48:247;92:225;5: 147;49:249;93:223;6: 150;50:250;94:221;7: 153;51:250;95:219;8: 156;52:251;96:216;9: 159;53:252;97:214;10: 162;54:253;98:212;11: 165;55:254;99:209;12: 168;56:254;100:207;13: 171;57:255;101:204;14: 174;58:255;102:202;15: 177;
20、59:255;103:199;16: 180;60:255;104:196;17: 183;61:255;105:194;18: 186;62:255;106:191;19: 188;63:255;107:188;20: 191;64:255;108:186;21: 194;65:255;109:183;22: 196;66:255;110:180;23: 199;67:255;111:177;24: 202;68:255;112:174;25: 204;69:255;113:171;26: 207;70:254;114:168;27: 209;71:254;115:165;28: 212;7
21、2:253;116:162;29: 214;73:252;117:159;30: 216;74:251;118:156;31!219;75:250;119:153;32:221;76:250;120:150;33:223;77:249;121:147;34:225;78:247;122:144;35:227;79:246;123:141;36:229;80:245;124:137;37:231;81:244;125:134;38:233;82:242;126:131;39:234;83:241;127:128;40:236;84:239;128:125;41:238;85:238;129:122;42:239;86:236;130:119;131:115;175:10;219:29;132:112;176:9;220:31;133:109;177:7;221:33;134:106;178:6;222:35;135:103;179:6;223:37;136:10;180:5;224:40;137:97;181:4;225:42;1
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時(shí)也不承擔(dān)用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- ××超市監(jiān)控系統(tǒng)細(xì)則
- 2025年系統(tǒng)集成項(xiàng)目管理工程師考試網(wǎng)絡(luò)技術(shù)與應(yīng)用試卷
- 假期旅游計(jì)劃知情及同意證明(7篇)
- 工業(yè)互聯(lián)網(wǎng)平臺2025年生物識別技術(shù)在智能工廠人員管理中的應(yīng)用方案
- 2025年病煤生物工作試題
- 電子商務(wù)營銷中的消費(fèi)者行為分析閱讀題
- 2025年城市自來水廠升級改造項(xiàng)目施工進(jìn)度與質(zhì)量控制報(bào)告
- 城市污水處理廠智能化升級改造中的智能水質(zhì)監(jiān)測與預(yù)警系統(tǒng)應(yīng)用報(bào)告
- 網(wǎng)絡(luò)直播平臺內(nèi)容監(jiān)管與行業(yè)自律發(fā)展的技術(shù)創(chuàng)新分析報(bào)告
- 2025年金融CRM數(shù)字化升級金融行業(yè)客戶關(guān)系管理智能化解決方案報(bào)告
- 《食管胃底靜脈曲張》課件
- 周圍性面癱的分期治療技術(shù)課件
- AutoCAD 2020中文版從入門到精通(標(biāo)準(zhǔn)版)
- 初中英語2023年中考專題訓(xùn)練任務(wù)型閱讀-判斷正誤篇
- 2022年江西南昌高新技術(shù)產(chǎn)業(yè)開發(fā)區(qū)人民檢察院聘用制檢察輔助人員招聘考試真題
- 小學(xué)安全隱患排查表
- 學(xué)校財(cái)務(wù)人員述職報(bào)告范文
- 履帶式微耕機(jī)的結(jié)構(gòu)設(shè)計(jì)說明書
- 一種鰭狀結(jié)型場效應(yīng)晶體管及其制備方法、芯片與流程
- 套管開窗側(cè)鉆技術(shù)
- 【2023有效教學(xué)設(shè)計(jì)原理、策略與評價(jià)讀書報(bào)告3600字】
評論
0/150
提交評論