可編程序控制器試題及答案_第1頁(yè)
可編程序控制器試題及答案_第2頁(yè)
可編程序控制器試題及答案_第3頁(yè)
可編程序控制器試題及答案_第4頁(yè)
可編程序控制器試題及答案_第5頁(yè)
已閱讀5頁(yè),還剩59頁(yè)未讀, 繼續(xù)免費(fèi)閱讀

下載本文檔

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

文檔簡(jiǎn)介

1、思考題:進(jìn)程的敏感信號(hào)表指的是什么?簡(jiǎn)述敏感信號(hào)表在進(jìn)程中的作用?進(jìn)程的敏感信號(hào)表指的是什么?簡(jiǎn)述敏感信號(hào)表在進(jìn)程中的作用? 進(jìn)程的“敏感信號(hào)表”也稱敏感表,是進(jìn)程的激活條件,可由一個(gè)或多個(gè)信號(hào)組成,各信號(hào)間以“,”號(hào)分隔。當(dāng)敏感信號(hào)表中的任一個(gè)信號(hào)有事件發(fā)生,即發(fā)生任意變化,此時(shí),進(jìn)程被激活,進(jìn)程中的語(yǔ)句將從上到下逐句執(zhí)行一遍,當(dāng)最后一條語(yǔ)句執(zhí)行完畢之后,進(jìn)程即進(jìn)入等待掛起狀態(tài),直到下一次敏感表中的信號(hào)有事件發(fā)生,進(jìn)程再次被激活,如此循環(huán)往復(fù)。vhdl復(fù)習(xí)題1 什么是vhdl?簡(jiǎn)述vhdl的發(fā)展史。答: vhdl是美國(guó)國(guó)防部為電子項(xiàng)目設(shè)計(jì)承包商提供的,簽定合同使用的,電子系統(tǒng)硬件描述語(yǔ)言。1

2、983年成立vhdl語(yǔ)言開(kāi)發(fā)組,1987年推廣實(shí)施,1993年擴(kuò)充改版。vhdl是ieee標(biāo)準(zhǔn)語(yǔ)言,廣泛用于數(shù)字集成電路邏輯設(shè)計(jì)。2 簡(jiǎn)述vhdl設(shè)計(jì)實(shí)體的結(jié)構(gòu)。答:實(shí)體由實(shí)體名、類型表、端口表、實(shí)體說(shuō)明部分和實(shí)體語(yǔ)句部分組成。根據(jù)ieee標(biāo)準(zhǔn),實(shí)體組織的一般格式為:entity 實(shí)體名 is generic(類型表); -可選項(xiàng) port(端口表); -必需項(xiàng) 實(shí)體說(shuō)明部分; -可選項(xiàng) begin 實(shí)體語(yǔ)句部分;end entity 實(shí)體名;3 分別用結(jié)構(gòu)體的3種描述法設(shè)計(jì)一個(gè)4位計(jì)數(shù)器。答: 用行為描述方法設(shè)計(jì)一個(gè)4位計(jì)數(shù)器如下,其它描述方法,讀者可自行設(shè)計(jì)。library ieee;us

3、e ieee.std_logic_1164.all;use ieee.std_logic_unsigned.all;entity counta is port (clk,clr,en:in std_logic; qa,qb,qc,qd:out std_logic);end counta;architecture example of counta issignal count_4:std_logic_vector (3 downto 0);begin qa = count_4(0); qb = count_4(1); qc = count_4(2); qd = count_4(3);proce

4、ss (clk,clr) begin if (clr = 1 ) then count_4 = 0000; elsif (clkevent and clk = 1 ) then if (en = 1 ) then if (count_4 = 1111) then count_4 = 0000; else count_4 = count_4+ 1; end if; end if; end if; end process;end example;1 什么叫對(duì)象?對(duì)象有哪幾個(gè)類型?答:在vhdl語(yǔ)言中,凡是可以賦于一個(gè)值的客體叫對(duì)象(object)。vhdl對(duì)象包含有專門(mén)數(shù)據(jù)類型,主要有4個(gè)基本類型

5、:常量(constant)、信號(hào)(signal)、變量(variable)和文件(files)。2 vhdl語(yǔ)言定義的標(biāo)準(zhǔn)類型有哪些?答 vhdl語(yǔ)言標(biāo)準(zhǔn)所定義的標(biāo)準(zhǔn)數(shù)據(jù)類型(1) 整數(shù)類型(integer type)(2) 實(shí)數(shù)類型或浮點(diǎn)類型(real type floating type)(3) 位類型(bit type)(4) 位矢量類型(bit_vector type)(5) 布爾類型(boolean type)(6) 字符類型(character type)(7) 時(shí)間類型或物理類型(time type physical type)(8) 錯(cuò)誤類型(note,warniing,err

6、or,failure type)(9) 自然數(shù)、整數(shù)類型(natural type)(10) 字符串類型(tring type)3 簡(jiǎn)述vhdl語(yǔ)言操作符的優(yōu)先級(jí)。答: 在表2.1中,取反和取絕對(duì)值優(yōu)先級(jí)較高,與、或邏輯運(yùn)算的優(yōu)先級(jí)低于算術(shù)運(yùn)算的優(yōu)先級(jí)。4 哪3種方法可用來(lái)進(jìn)行類型轉(zhuǎn)換?答:進(jìn)行不同類型的數(shù)據(jù)變換,有3種方法:類型標(biāo)記法、函數(shù)轉(zhuǎn)換法和常數(shù)轉(zhuǎn)換法。1 什么叫進(jìn)程?簡(jiǎn)述進(jìn)程的工作方式。答:進(jìn)程(process)是由外部信號(hào)觸發(fā)執(zhí)行的一段程序。進(jìn)程語(yǔ)句是并行處理語(yǔ)句,即各個(gè)進(jìn)程是同時(shí)處理的,在結(jié)構(gòu)體中多個(gè)process語(yǔ)句是同時(shí)并發(fā)運(yùn)行的。在進(jìn)程內(nèi)部是順序執(zhí)行的。process語(yǔ)句在

7、vhdl程序中,是描述硬件并行工作行為的最常用、最基本的語(yǔ)句。進(jìn)程process語(yǔ)句中一般帶有幾個(gè)信號(hào)量例表,稱為該進(jìn)程的敏感量表。這些信號(hào)無(wú)論哪一個(gè)發(fā)生變化都將啟動(dòng)process進(jìn)程。一旦啟動(dòng),進(jìn)程process中的程序?qū)纳系较马樞驁?zhí)行一遍,由新變化的量引導(dǎo)進(jìn)程產(chǎn)生變化結(jié)果輸出。當(dāng)進(jìn)程的最后一個(gè)語(yǔ)句執(zhí)行完成后,就返回到進(jìn)程開(kāi)始處,等待敏感量的新變化,引發(fā)進(jìn)程的再一次執(zhí)行。周而復(fù)始,循環(huán)往復(fù),以至無(wú)窮。這就是進(jìn)程的執(zhí)行過(guò)程。2 什么叫模塊?區(qū)分模塊與進(jìn)程。答:模塊(block)語(yǔ)句是結(jié)構(gòu)體中積木化設(shè)計(jì)語(yǔ)言,適用于復(fù)雜項(xiàng)目設(shè)計(jì)。block塊是一個(gè)獨(dú)立的子結(jié)構(gòu),可以包含port語(yǔ)句、generi

8、c語(yǔ)句,允許設(shè)計(jì)者通過(guò)這兩個(gè)語(yǔ)句將block塊內(nèi)的信號(hào)變化傳遞給block塊的外部信號(hào)。同樣,也可以將block塊的外部信號(hào)變化傳遞給block塊的內(nèi)部信號(hào)。對(duì)vhdl語(yǔ)言中的block模塊進(jìn)行仿真時(shí),block模塊中所描述的各個(gè)語(yǔ)句是可以并發(fā)執(zhí)行的,和模塊中的語(yǔ)句書(shū)寫(xiě)順序無(wú)關(guān)。進(jìn)程語(yǔ)句是一段程序,這段程序是順序執(zhí)行的。3 用結(jié)構(gòu)描述法和generate語(yǔ)句設(shè)計(jì)一個(gè)8位移位寄存器。答:library ieee;use ieee.std_logic_1164.all;entity shift_register isport(a,clk: in std_logic; b: out std_logi

9、c);end entity shift_regester; architecture eight_bit_shift_register of shift_register iscomponent dff - dff元件調(diào)用 port(a,clk: in std_logic; b: out std_logic); end component; signal x: std_logic_vector(0 to 4);begin x(0) = a; dff1:dff port map (x(0),clk,z(1); dff2:dff port map (x(1),clk,z(2);dff3:dff p

10、ort map (x(2),clk,z(3); dff4:dff port map (x(3),clk,z(4);dff5:dff port map (x(4),clk,z(5);dff6:dff port map (x(5),clk,z(6);dff7:dff port map (x(6),clk,z(7);dff4:dff port map (x(7),clk,z(8); b=x(8);end architecture eight_bit_shift_register;1 設(shè)計(jì)一個(gè)加法器, 答:半加器及全加器vhdl程序設(shè)計(jì)(1)。library ieee;use ieee.std_log

11、ic_1164.all;entity full_adder is port (a,b,cin:in std_logic; sum,co:out std_logic);end full_adder;architecture full1 of full_adder iscomponent half_adder port (a,b:in std_logic; s,co:out std_logic);end component;signal u0_co,u0_s,u1_co:std_logic;begin u0:half_adder port map (a,b,u0_s,u0_co); u1:half

12、_adder port map (u0_s,cin,sum,u1_co); co = u0_co or u1_co;end full1;半加器及全加器vhdl程序設(shè)計(jì)(2)。library ieee;use ieee.std_logic_1164.all;entity half_adder is port (a,b:in std_logic; s,co:out std_logic);end half_adder;architecture half1 of half_adder issignal c,d:std_logic;begin c = a or b; d = a nand b; co =

13、 not d; s = c and d;end half1;2 簡(jiǎn)述層次化設(shè)計(jì)的過(guò)程。答:層次化設(shè)計(jì)是指對(duì)于一個(gè)大型設(shè)計(jì)任務(wù),將目標(biāo)層層分解,在各個(gè)層次上分別設(shè)計(jì)的方法。有些設(shè)計(jì),在一些模塊的基礎(chǔ)上,通過(guò)搭建積木的方法進(jìn)行設(shè)計(jì)。有人稱,在整個(gè)設(shè)計(jì)任務(wù)上進(jìn)行行為描述的設(shè)計(jì)方法,稱為高層次設(shè)計(jì),而從事某一模塊、某一元件行為設(shè)計(jì)稱為底層設(shè)計(jì)方法。3 什么是庫(kù),程序包,子程序,過(guò)程調(diào)用,函數(shù)調(diào)用?答:庫(kù)(libraries)和程序包(package)用來(lái)描述和保存元件、類型說(shuō)明、函數(shù)、模塊等,以便在其他設(shè)計(jì)中可隨時(shí)引用它們。庫(kù)(libraries)是用來(lái)存儲(chǔ)和放置可編譯的設(shè)計(jì)單元的地方,通過(guò)其目錄可查

14、詢、調(diào)用。設(shè)計(jì)庫(kù)中的設(shè)計(jì)單元(實(shí)體說(shuō)明、結(jié)構(gòu)體、配置說(shuō)明、程序包說(shuō)明和程序包體)可以用作其他vhdl描述的資源。函數(shù)和過(guò)程統(tǒng)稱為子程序。子程序由過(guò)程和函數(shù)組成。在子程序調(diào)用過(guò)程中,過(guò)程能返回多個(gè)變量,函數(shù)能返回一個(gè)變量。若子程序調(diào)用是一個(gè)過(guò)程,就稱為過(guò)程調(diào)用;若子程序調(diào)用是一個(gè)函數(shù),則稱為函數(shù)調(diào)用。過(guò)程調(diào)用和函數(shù)調(diào)用都是子程序調(diào)用。函數(shù)的參數(shù)都是輸入?yún)?shù)。過(guò)程的參數(shù)有輸入、輸出和雙向參數(shù)。函數(shù)有順序函數(shù)、并行函數(shù)。過(guò)程有順序過(guò)程、并行過(guò)程。1 clk信號(hào)怎樣用vhdl語(yǔ)言描述?答:時(shí)鐘信號(hào)的上升沿的描述:if clkevent and clk = 1 then ;時(shí)鐘信號(hào)的下降沿的描述: if

15、 clk event and clk = 1 then ;2 異步復(fù)位怎樣用vhdl語(yǔ)言描述?答:當(dāng)復(fù)位信號(hào)低電平有效時(shí),vhdl的描述為:if reset = 0 then ;當(dāng)復(fù)位信號(hào)高電平有效時(shí), vhdl的描述為:if reset =1 then ;3 設(shè)計(jì)一個(gè)8位循環(huán)移位寄存器。答: 8位循環(huán)計(jì)寄存器的vhdl參考程序設(shè)計(jì)如下: library ieee;use ieee.std_logic_1164.all;entity circleshift8 is port (seldata:in std_logic_vector(2 downto 0); clr,clk: in std_lo

16、gic; sel: out std_logic_vector(7 downto 0);end circleshift8;architecture sample of circleshift8 isbeginprocess(clk,clr) beginif (clr=1)then selselselselselselselsel sel=00000000;end case; end if; end process;end sample;4. 設(shè)計(jì)一個(gè)六十進(jìn)制計(jì)數(shù)器。答: 60進(jìn)制計(jì)數(shù)器的vhdl參考程序設(shè)計(jì)如下:library ieee;use ieee.std_logic_1164.all;u

17、se ieee.std_logic_unsigned.all;use ieee.std_logic_arith.all;-* entity counter60 is port( cp:in std_logic; bin:out std_logic_vector(6 downto 0); s:in std_logic; clr:in std_logic; ec:in std_logic; cy60:out std_logic ); end counter60;-*architecture b of counter60 is signal q:std_logic_vector(6 downto 0

18、); signal rst,dly:std_logic;begin process(rst,cp) begin if rst=1 then q=0000000; - cy(60)=0; elsif cpevent and cp=1 then dly=q(5); if ec=1then if q=59 then q=0000000; else q=q+1; end if; else q=q; end if; end if; end process; cy60= not q(5) and dly; rst= clr; bin=q when s=1 else 1111111;end b;5. 設(shè)計(jì)一

19、個(gè)八位編碼器。答: 八位編碼器的vhdl參考程序設(shè)計(jì)如下:library ieee;use ieee.std_logic_1164.all;entity priotyencoder is port (d : in std_logic_vector (7 downto 0); e1: in std_logic; gs,e0: out bit std_logic; q : out std_logic_vector(2 downto 0);end priotyencoder;architecture encoder of prioty encoder isbegin p1: process ( d

20、)begin if ( d(0) = 0 and e1 = 0 ) then y = 111; gs = 0 ; e0 = 1 ; elsif (d(1) = 0 and e1 = 0 ) then q = 110; gs = 0 ; e0 = 1 ; elsif (d(2) = 0 and e1 = 0 ) then q = 101 ; gs = 0 ; e0 = 1 ; elsif (d(3) = 0 and e1= 0 ) then q = 100 ; gs = 0 ; e0 = 1 ; elsif (d(4) = 0 and e1= 0 ) then q = 011 ; gs = 0

21、; e0 = 1 ; elsif (d(5) = 0 and e1= 0 ) then q = 010 ; gs = 0 ; e0 = 1 ; elsif (d(6) = 0 and e1 = 0 ) then q = 001 ; gs= 0 ; e0= 1 ; elsif (d(7) = 0 and e1 = 0 ) then q = 000 ; gs = 0 ;e0 = 1 ; elsif (e1 = 1 ) then q = 111 ; gs = 1 ; e0 = 1 ; elsif (d = 1111 1111 and e1 = 0 ) then q = 111 ; gs = 1 ;

22、e0 = 0 ; end if; end process p1; end encoder;6. 設(shè)計(jì)一個(gè)三八譯碼器。答: 三八譯碼器的vhdl參考程序設(shè)計(jì)如下:library ieee;use ieee.std_logic_1164.all;entity decoder3_8 is port (a,b,c,g1,g2a,g2b:in std_logic; y:out std_logic_vector(7 downto 0);end decoder3_8;architecture rtl of decoder3_8 issignal indata:std_logic_vector (2 down

23、to 0);begin indata y y y y y y y y y = xxxxxxxx ; end case; else y = 11111111 ; end if; end process;end rtl;五、改正以下程序中的錯(cuò)誤,簡(jiǎn)要說(shuō)明原因,并指出可綜合成什么電路。1. library ieee;use ieee.std_logic_1164.all;entity d_flip_flop is port(d, clk: in std_logic;q: out std_logic);end d_flip_flop;architecture rtl of d_flip_flop is

24、begin if clkevent and clk=1 then q=d; end if;end rtl;2. library ieee;use ieee.std_logic_1164.all;entity d_latch is port(d, ena: in std_logic;q: out std_logic);end d_latch;architecture rtl of d_latch isbegin if ena = 1 then q=d; end if;end rtl; 3library ieee;use ieee.std_logic_1164.all;entity test is

25、 port(d, clk: in std_logic;q: out std_logic);end test;architecture rtl of test isbegin process(clk) begin wait until clkevent and clk=1 q q q = d2; end case; end process;end rtl;5.library ieee;use ieee.std_logic_1164.all;entity test is port(d1, d2: in std_logic;sel: in std_logic;q: out std_logic);en

26、d test;architecture rtl of test isbegin process(d1, d2, sel) begin q=d1 when sel = 0 else d2; end process;end rtl;6.library ieee;use ieee.std_logic_1164.all;entity test is port(clk: in std_logic;count: buffer std_logic_vector(3 downto 0);end test;architecture rtl of test isbegin process(clk) begin i

27、f clkevent and clk=1 then count q q = 0 ; end case ; end test ; 【參考答案】: case語(yǔ)句應(yīng)該存在于進(jìn)程process內(nèi)。2 已知start為std_logic類型的信號(hào),sum是integer類型的信號(hào),請(qǐng)判斷下面的程序片斷: process (start) begin for i in 1 to 9 loop sum := sum + i ; end loop ; end process ; 【參考答案】: sum是信號(hào),其賦值符號(hào)應(yīng)該由“:=”改為“=”。3 已知q為std_logic類型的輸出端口,請(qǐng)判斷下面的程序片斷:

28、 architecture test of test is begin signal b :std_logic ; q = b ; end test ; 【參考答案】: 信號(hào)signal的申明語(yǔ)句應(yīng)該放在begin語(yǔ)句之前。4 已知a和b均為std_logic類型的信號(hào),請(qǐng)判斷下面的語(yǔ)句: a = 0 ; b = x ; 【參考答案】: 不定態(tài)符號(hào)應(yīng)該由小寫(xiě)的x改為大寫(xiě)的x。5 已知a為integer類型的信號(hào),b為std_logic類型的信號(hào),請(qǐng)判斷下面的程序片斷: architecture test of test is begin b q q q q = d ; end case ; 【

29、參考答案】: case語(yǔ)句缺“when others”語(yǔ)句。 簡(jiǎn)述top-down設(shè)計(jì)方法及其基本步驟?!緟⒖即鸢浮浚?所謂top-down的設(shè)計(jì)過(guò)程是指從系統(tǒng)硬件的高層次抽象描述向最底層物理描述的一系列轉(zhuǎn)換過(guò)程。具體講這一過(guò)程由功能級(jí)、行為級(jí)描述開(kāi)始;寄存器傳輸(rtl)級(jí)描述為第一個(gè)中間結(jié)果;再將rtl級(jí)描述由邏輯綜合得到網(wǎng)表(net-list)或電路圖;由網(wǎng)表即可自動(dòng)生成現(xiàn)場(chǎng)可編程門(mén)陣列(fpga)/復(fù)雜可編程邏輯器件(cpld)或?qū)S眉呻娐罚╝sic),從而得到電路與系統(tǒng)的物理實(shí)現(xiàn)。3 請(qǐng)從申明格式、賦值符號(hào)、賦值生效時(shí)間、作用范圍等方面對(duì)信號(hào)和變量進(jìn)行比較分析?!緟⒖即鸢浮浚?申明

30、時(shí)關(guān)鍵字不一樣,變量為:variable;信號(hào)為:signal。但申明時(shí)賦初值均用“:”符號(hào)。賦值符號(hào)不同:信號(hào)賦值用“”;變量賦值用“:”。賦值生效時(shí)間:信號(hào)賦值延時(shí)后生效;變量賦值立即生效。聲明引用范圍:信號(hào)在構(gòu)造體內(nèi)(進(jìn)程外)申明,整個(gè)構(gòu)造體內(nèi)有效;變量主要在進(jìn)程內(nèi)申明,只在進(jìn)程內(nèi)有效。2 vhdl程序主要有三種描述方式:行為描述方式、rtl描述方式、結(jié)構(gòu)描述方式。3 vhdl程序中數(shù)值的載體稱為對(duì)象。vhdl中有四種對(duì)象,分別是:常量(constant)、變量(variable)、信號(hào)(signal)、文件(file)。20、在vhdl中,(d )的數(shù)據(jù)傳輸是立即發(fā)生的,不存在任何延時(shí)

31、的行為。 a、信號(hào); b、常量; c、數(shù)據(jù); d、變量21、在vhdl中,(a )的數(shù)據(jù)傳輸是不是立即發(fā)生的,目標(biāo)信號(hào)的賦值需要一定的延時(shí)時(shí)間。 a、信號(hào); b、常量; c、數(shù)據(jù); d、變量22、在vhdl中,為目標(biāo)變量賦值的符號(hào)是(c )。 a、=: ; b、= ; c、:= ; d、=23、在vhdl中,為目標(biāo)信號(hào)賦值的符號(hào)是(d )。 a、=: ; b、= ; c、:= ; d、=24、在vhdl中,定義信號(hào)名時(shí),可以用( c)符號(hào)為信號(hào)賦初值。 a、=: ; b、= ; c、:= ; d、=設(shè)計(jì)一數(shù)據(jù)選擇器mux,其系統(tǒng)模塊圖和功能表如下圖所示。試采用下面三種方式中的兩種來(lái)描述該數(shù)據(jù)選

32、擇器mux的結(jié)構(gòu)體。(a) 用if語(yǔ)句。 (b) 用case 語(yǔ)句。 (c) 用when else 語(yǔ)句。library ieee;use ieee.std_logic_1164.all;entity mymux is port ( sel : in std_logic_vector; - 選擇信號(hào)輸入 ain, bin : in std_logic_vector; - 數(shù)據(jù)輸入 cout : out std_logic_vector(1 downto 0) ); - 數(shù)據(jù)輸出end mymux;eda技術(shù)與項(xiàng)目訓(xùn)練選擇題1. 一個(gè)項(xiàng)目的輸入輸出端口是定義在 a 。 a. 實(shí)體中 b. 結(jié)構(gòu)體

33、中 c. 任何位置 d. 進(jìn)程體 2. 描述項(xiàng)目具有邏輯功能的是 b 。 a. 實(shí)體 b. 結(jié)構(gòu)體 c. 配置 d. 進(jìn)程 3. 關(guān)鍵字architecture定義的是 a 。a. 結(jié)構(gòu)體 b. 進(jìn)程 c. 實(shí)體 d. 配置 4. maxplusii中編譯vhdl源程序時(shí)要求 c 。a.文件名和實(shí)體可不同名 b.文件名和實(shí)體名無(wú)關(guān) c. 文件名和實(shí)體名要相同 d. 不確定 5. 1987標(biāo)準(zhǔn)的vhdl語(yǔ)言對(duì)大小寫(xiě)是 d 。 a. 敏感的 b. 只能用小寫(xiě) c. 只能用大寫(xiě) d. 不敏感 6. 關(guān)于1987標(biāo)準(zhǔn)的vhdl語(yǔ)言中,標(biāo)識(shí)符描述正確的是 a 。 a. 必須以英文字母開(kāi)頭 b.可以使用漢

34、字開(kāi)頭 c.可以使用數(shù)字開(kāi)頭 d.任何字符都可以 7. 關(guān)于1987標(biāo)準(zhǔn)的vhdl語(yǔ)言中,標(biāo)識(shí)符描述正確的是 b 。 a. 下劃線可以連用 b. 下劃線不能連用 c. 不能使用下劃線 d. 可以使用任何字符 8. 符合1987vhdl標(biāo)準(zhǔn)的標(biāo)識(shí)符是 a 。 a. a_2 b. a+2 c. 2a d. 229. 符合1987vhdl標(biāo)準(zhǔn)的標(biāo)識(shí)符是 a 。 a. a_2_3 b. a_2 c. 2_2_a d. 2a 10. 不符合1987vhdl標(biāo)準(zhǔn)的標(biāo)識(shí)符是 c 。 a. a_1_in b. a_in_2 c. 2_a d. asd_1 11. 不符合1987vhdl標(biāo)準(zhǔn)的標(biāo)識(shí)符是 d 。

35、a. a2b2 b. a1b1 c. ad12 d. %50 12. vhdl語(yǔ)言中變量定義的位置是 d 。 a. 實(shí)體中中任何位置 b. 實(shí)體中特定位置 c. 結(jié)構(gòu)體中任何位置 d. 結(jié)構(gòu)體中特定位置 13. vhdl語(yǔ)言中信號(hào)定義的位置是 d 。 a. 實(shí)體中任何位置 b. 實(shí)體中特定位置 c. 結(jié)構(gòu)體中任何位置d. 結(jié)構(gòu)體中特定位置14. 變量是局部量可以寫(xiě)在 b 。 a. 實(shí)體中 b. 進(jìn)程中 c. 線粒體 d. 種子體中 15. 變量和信號(hào)的描述正確的是 a 。 a. 變量賦值號(hào)是:= b. 信號(hào)賦值號(hào)是:= c. 變量賦值號(hào)是= d. 二者沒(méi)有區(qū)別 16. 變量和信號(hào)的描述正確的是

36、 b 。 a. 變量可以帶出進(jìn)程 b. 信號(hào)可以帶出進(jìn)程 c. 信號(hào)不能帶出進(jìn)程 d. 二者沒(méi)有區(qū)別17. 關(guān)于vhdl數(shù)據(jù)類型,正確的是 d 。 a. 數(shù)據(jù)類型不同不能進(jìn)行運(yùn)算 b. 數(shù)據(jù)類型相同才能進(jìn)行運(yùn)算 c. 數(shù)據(jù)類型相同或相符就可以運(yùn)算 d. 運(yùn)算與數(shù)據(jù)類型無(wú)關(guān) 18. 下面數(shù)據(jù)中屬于實(shí)數(shù)的是 a 。 a. 4.2 b. 3 c. 1 d. “11011” 19. 下面數(shù)據(jù)中屬于位矢量的是 d 。a. 4.2 b. 3 c. 1 d. “11011” 20. 關(guān)于vhdl數(shù)據(jù)類型,正確的是 。 a. 用戶不能定義子類型 b. 用戶可以定義子類型 c. 用戶可以定義任何類型的數(shù)據(jù) d.

37、 前面三個(gè)答案都是錯(cuò)誤的 21. 可以不必聲明而直接引用的數(shù)據(jù)類型是 c 。 a. std_logic b. std_logic_vector c. bit d. 前面三個(gè)答案都是錯(cuò)誤的 22. std_logig_1164中定義的高阻是字符 d 。 a. x b. x c. z d. z 23. std_logig_1164中字符h定義的是 a 。 a. 弱信號(hào)1 b. 弱信號(hào)0 c. 沒(méi)有這個(gè)定義 d. 初始值 24. 使用std_logig_1164使用的數(shù)據(jù)類型時(shí) b 。 a.可以直接調(diào)用 b.必須在庫(kù)和包集合中聲明 c.必須在實(shí)體中聲明 d. 必須在結(jié)構(gòu)體中聲明 25. 關(guān)于轉(zhuǎn)化函數(shù)

38、正確的說(shuō)法是 。 a. 任何數(shù)據(jù)類型都可以通過(guò)轉(zhuǎn)化函數(shù)相互轉(zhuǎn)化 b. 只有特定類型的數(shù)據(jù)類型可以轉(zhuǎn)化 c. 任何數(shù)據(jù)類型都不能轉(zhuǎn)化 d. 前面說(shuō)法都是錯(cuò)誤的 26. vhdl運(yùn)算符優(yōu)先級(jí)的說(shuō)法正確的是 c 。 a. 邏輯運(yùn)算的優(yōu)先級(jí)最高 b. 關(guān)系運(yùn)算的優(yōu)先級(jí)最高 c. 邏輯運(yùn)算的優(yōu)先級(jí)最低 d. 關(guān)系運(yùn)算的優(yōu)先級(jí)最低 27. vhdl運(yùn)算符優(yōu)先級(jí)的說(shuō)法正確的是 a 。 a. not的優(yōu)先級(jí)最高 b. and和not屬于同一個(gè)優(yōu)先級(jí) c. not的優(yōu)先級(jí)最低 d. 前面的說(shuō)法都是錯(cuò)誤的 28. vhdl運(yùn)算符優(yōu)先級(jí)的說(shuō)法正確的是 d 。 a. 括號(hào)不能改變優(yōu)先級(jí) b. 不能使用括號(hào) c. 括號(hào)

39、的優(yōu)先級(jí)最低 d. 括號(hào)可以改變優(yōu)先級(jí) 29. 如果a=1,b=0,則邏輯表達(dá)式(a and b) or( not b and a)的值是 b 。 a. 0 b. 1 c. 2 d. 不確定 30. 關(guān)于關(guān)系運(yùn)算符的說(shuō)法正確的是 。 a. 不能進(jìn)行關(guān)系運(yùn)算 b. 關(guān)系運(yùn)算和數(shù)據(jù)類型無(wú)關(guān) c. 關(guān)系運(yùn)算數(shù)據(jù)類型要相同 d. 前面的說(shuō)法都錯(cuò)誤 31. 轉(zhuǎn)換函數(shù)to_bitvector(a)的功能是 。 a. 將stdlogic_vector轉(zhuǎn)換為bit_vector b. 將real轉(zhuǎn)換為bit_vector c. 將time轉(zhuǎn)換為bit_vector d. 前面的說(shuō)法都錯(cuò)誤 32. vhdl中順

40、序語(yǔ)句放置位置說(shuō)法正確的是 。 a.可以放在進(jìn)程語(yǔ)句中 b. 可以放在子程序中 c. 不能放在任意位置 d. 前面的說(shuō)法都正確 33. 不屬于順序語(yǔ)句的是 b 。 a. if語(yǔ)句 b. loop語(yǔ)句 c. process語(yǔ)句 d. case語(yǔ)句 34. 正確給變量x賦值的語(yǔ)句是 b 。 a. x=a+b; b. x:=a+b; c. x=a+b; d. 前面的都不正確 35. eda的中文含義是 a 。 a. 電子設(shè)計(jì)自動(dòng)化 b. 計(jì)算機(jī)輔助計(jì)算 c. 計(jì)算機(jī)輔助教學(xué) d. 計(jì)算機(jī)輔助制造 36. 可編程邏輯器件的英文簡(jiǎn)稱是 。 a. fpga b. pla c. pal d. pld 37.

41、 現(xiàn)場(chǎng)可編程門(mén)陣列的英文簡(jiǎn)稱是 。 a. fpga b. pla c. pal d. pld 38. 基于下面技術(shù)的pld器件中允許編程次數(shù)最多的是 。 a. flash b. eerom c. sram d. prom 39. 在eda中,isp的中文含義是 。 a. 網(wǎng)絡(luò)供應(yīng)商 b. 在系統(tǒng)編程 c. 沒(méi)有特定意義 d. 使用編程器燒寫(xiě)pld芯片 40. 在eda中,ip的中文含義是 。 a. 網(wǎng)絡(luò)供應(yīng)商 b. 在系統(tǒng)編程 c. 沒(méi)有特定意義 d. 知識(shí)產(chǎn)權(quán)核41. epf10k20tc144-4具有多少個(gè)管腳 a 。 a. 144個(gè) b. 84個(gè) c. 15個(gè) d. 不確定 42. ep

42、f10k20tc144-x器件,如果x的值越小表示 。 a. 器件的工作頻率越小 b. 器件的管腳越少 c. 器件的延時(shí)越小 d. 器件的功耗越小 43. 如果a=1,b=1,則邏輯表達(dá)式(a xor b) or( not b and a)的值是 a 。 a. 0 b. 1 c. 2 d. 不確定 44. 執(zhí)行下列語(yǔ)句后q的值等于 b 。signal e: std_logic_vector (2 to 5);signal q: std_logic_vector (9 downto 2);e1, 4=0, others=1);qe (2), 4=e (3), 5=1, 7=e (5), othe

43、rs=e (4);a “11011011” b. “00101101” c. “11011001” d. “00101100” 45. vhdl文本編輯中編譯時(shí)出現(xiàn)如下的報(bào)錯(cuò)信息error: vhdl syntax error: signal declaration must have ;,but found begin instead. 其錯(cuò)誤原因是 a 。a. 信號(hào)聲明缺少分號(hào)。b. 錯(cuò)將設(shè)計(jì)文件存入了根目錄,并將其設(shè)定成工程。c. 設(shè)計(jì)文件的文件名與實(shí)體名不一致。 d. 程序中缺少關(guān)鍵詞。46. vhdl文本編輯中編譯時(shí)出現(xiàn)如下的報(bào)錯(cuò)信息error: vhdl syntax error: choice value length must match selector expression value length 其錯(cuò)誤原因是

溫馨提示

  • 1. 本站所有資源如無(wú)特殊說(shuō)明,都需要本地電腦安裝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ù)覽,若沒(méi)有圖紙預(yù)覽就沒(méi)有圖紙。
  • 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)論