亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? uc_interface_tb.vhd

?? PLD與8051接口的參考設(shè)計
?? VHD
?? 第 1 頁 / 共 3 頁
字號:
-- *********************************** uC Process *********************************
--  Synthesize uProc bus protocol
UCBUS: process
begin

    -- Set up defaults
    uc_done <= '1';
    ad_oe <= '0';
    ale_n <= '1';
    psen_n <= '1';
    addr <= (others => '0');
    ad_out <= (others => '0');
    ucdata_in_ce <= '0';
    wr_n <= '1';
    rd_n <= '1';
    
    -- Wait for go to assert
    wait until go'event and go = '1';
    
    -- start bus cycle
    uc_done <= '0';
    
    -- wait part of ALE_N negation cycle (ALE_N pulse width - address setup time)
    wait for TLHLL - TAVLL;
    
    -- setup address on busses
    addr <= uc_addr(15 downto 8);
    ad_out <= uc_addr(7 downto 0);
    ad_oe <= '1';
    
    -- wait address setup time then assert ALE_N
    wait for TAVLL;
    ale_n <= '0';
    
    
    
    -- determine if this is a program store cycle, write cycle, or read cycle
    if assert_psen = '1' then
        -- program store cycle
    
        -- wait before asserting PSEN_N
        wait for TLLPL;
        psen_n <= '0';
        
        -- wait address hold time then tri-state
        wait for TPLAZ;
        ad_oe <= '0';       -- tri-state ad bus
        
        -- wait for instruction access time then capture data
        -- by asserting clock enable for input data register
        wait for TPLIV;
        ucdata_in_ce <= '1';
        
        -- wait remainder of PSEN_N pulse width then negate PSEN_N and ALE_N
        -- and negate clock enable for input data register
        wait for TPLPH - TPLIV;
        psen_n <= '1';
        ale_n <= '1';
        ucdata_in_ce <= '0';
    
    elsif write = '1' then
        -- write cycle
        -- wait address hold time
        wait for TLLAX;
        
        -- write cycle, put data on ad
        ad_oe <= '1';
        ad_out <= uc_data;
        
        -- wait data setup time then assert WR_N
        wait for TQVWX;
        wr_n <= '0';
        
        -- wait write pulse width then negate WR_N
        wait for TWLWH;
        wr_n <= '1';
        
        -- wait data hold time after WR_N then remove data
        wait for TWHQX;
        ad_oe <= '0';
        
        -- wait remaining ALE_N hold time after WR_N then negate ALE_N
        wait for TWHLH - TWHQX;
        ale_n <= '1';
    
    else
        -- read cycle
        -- wait address hold time
        wait for TLLAX;
        ad_oe <= '0';
        
        -- read cycle, wait address Z time before asserting RD_N
        wait for TRLAZ;
        rd_n <= '0';
        
        -- wait for data to be valid, then capture it
        -- by asserting clock enable for input data register
        wait for TRLDV;
        ucdata_in_ce <= '1';
        
        -- wait remainding time in read pulse then negate RD_N
        -- by negating clock enable for input data register 
        wait for TRLRH - TRLDV;
        rd_n <= '1';
        ucdata_in_ce <= '0';
        
        -- wait ALE_N hold time then negate ALE_N;
        wait for TWHLH;
        ale_n <= '1';
    end if;
    
    -- signify end of bus cycle by asserting UC_DONE
    uc_done <= '1';
    
    -- process will now return to beginning to wait for GO
end process;

-- *********************************** Input Register Process *********************************
-- This process captures data from the ADDR_DATA bus during read and program store bus cycles
-- Data is clocked into the register when the clock enable is asserted from the uC bus cycle
-- process
INPUT_REGS: process(reset, clk)
begin
    if reset = RESET_ACTIVE then
        ucdata_in <= (others => '0');
    elsif clk'event and clk = '1' then
        if ucdata_in_ce = '1' then
            ucdata_in <= addr_data;
        else
            ucdata_in <= ucdata_in;
        end if;
    end if;
end process;

-- *************************************************************************************************
-- *********************************** Application Logic Processes *********************************
-- *************************************************************************************************
-- These processes mock up the application logic by providing data to load into the output data
-- register,and asserting the DATA_RDY and NEED_DATA flags. These processes will operate on a
-- divided version of the system clock
--
-- NOTE: when the real application logic is available, these processes should be removed.


-- ************************** Need Data Flag Assertion Process ***********************************
-- The NEEDDATA_PROCESS assumes that the application logic will grab the first data in the 
-- input data register APP_FIRST_WORD_ACCESS clocks after the APP_EN asserts and then waits the 
-- number of clocks required for the application logic to "work" on the data, APP_WORK_DATA_CLKS,
-- before requesting new data. Therefore, this process asserts the NEED_DATA flag APP_FIRST_WORD_ACCESS
-- clocks after APP_EN asserts. It then asserts the NEED_DATA flag every APP_WORK_DATA_CLKS clocks 
-- after that, assuming that the application logic requires APP_WORK_DATA_CLKS clocks to "work" on the data.
NEEDDATA_PROCESS: process(reset, clk, need_data_reset) 
begin
    if reset = RESET_ACTIVE or need_data_reset = RESET_ACTIVE then
        need_data <= '0';
    elsif clk'event and clk = '1' then
        if app_en = '1' and start = '1' then
            if first_loop = '1' and clk_cnt = APP_FIRST_WORD_ACCESS then
                need_data <= '1';
                first_loop <= '0';
            elsif clk_cnt = APP_WORK_DATA_CLKS then
                need_data <= '1';
            end if;
        end if;
    end if;
end process;

CLKCNT_PROCESS: process(reset, clk)
begin
    if reset = RESET_ACTIVE then
        clk_cnt <= 0;
    elsif clk'event and clk = '1' then
        if ((clk_cnt = APP_FIRST_WORD_ACCESS and first_loop = '1') 
            or (clk_cnt = APP_WORK_DATA_CLKS and first_loop = '0')) then
            clk_cnt <= 0;
        else
            clk_cnt <= clk_cnt + 1;
        end if;
    end if;
end process;

-- ************************** Output Data Process ***********************************
-- The OUTPUTDATA_PROCESS assumes that the application logic will provide data to the 
-- output data register every APP_WORK_DATA_CLKS clocks after the APP_EN asserts.
-- Therefore, this process asserts the DATAOUT_LOAD and DONE signals and assigns data
-- to the APP_DATA bus every 16 clocks after APP_EN asserts while START is asserted. 

OUTPUTDATA_PROCESS: process

variable i,j : integer := 0;

begin

    -- initialize load signal and data
    dataout_load <= '0';
    app_data <= (others => '0');
    done <= '0';
    
    -- wait for application logic to be enabled
    wait until app_en = '1';
    
    -- wait for start signal to be asserted
    wait until start = '1';
        
    -- every APP_WORK_DATA_CLKS clocks, assert DATA_RDY, DATAOUT_LOAD, and send out data
    -- from the EXPECTED DATA array
    while app_en = '1' loop
        for i in 1 to APP_WORK_DATA_CLKS loop
            wait until clk'event and clk = '1';
            if i = 2 then
                -- negate dataout_load 1 clock after expected data was output
                -- negate done as well
                dataout_load <= '0';
                done <= '0';
            end if;
        end loop;
        dataout_load <= '1';
        done <= '1';
        app_data <= EXPECTED_DATA(j);
        if j = 3 then
            j := 0;
        else
            j := j + 1;
        end if;
           
    end loop;
    
end process;

-- ************************** Data Ready Process ***********************************   
-- The DATARDY_PROCESS asserts DATA_RDY whenever the DATAOUT_LOAD signal asserts while
-- START and APP_EN = 1. It negates when DATA_RDY_RESET is asserted.

DATARDY_PROCESS: process (clk, reset, data_rdy_reset)
 
begin     
      if reset = RESET_ACTIVE or data_rdy_reset = RESET_ACTIVE then
        data_rdy <= '0';
      elsif clk'event and clk = '1' then
            if dataout_load = '1' and app_en = '1' then
                    -- assert data rdy flag when data is loaded into output data register
                    -- if application logic has been enabled and start is still 1
                    data_rdy <= '1';
            end if;
      end if;
end process;

-- *********************************** ERROR Process *********************************
-- This process will asynchronously assert ERROR as determined by the constant ERROR_ASSERT_TIME.
-- If this time is set to 0, then ERROR will never be asserted. This allows the testbench to be
-- run without interference of this signal
ERROR_PROC: process

begin
    error <= '0';
    if ERROR_ASSERT_TIME = 0 uS then
        wait;
    else
        wait for ERROR_ASSERT_TIME;
        error <= '0';
        wait for ERROR_ASSERT_TIME;
        error <= '1';
        wait;
    end if;
end process;    

END;

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国内久久精品视频| 亚洲在线视频免费观看| 狠狠色综合日日| 日韩视频免费观看高清完整版在线观看 | 国产成人精品一区二区三区四区| 久久久久国产精品麻豆ai换脸| 国产一区二区伦理| 国产精品色呦呦| 99r精品视频| 亚洲综合在线视频| 欧美一区二区三区视频免费| 蜜桃av一区二区| 久久久九九九九| 99麻豆久久久国产精品免费优播| 亚洲婷婷综合色高清在线| 91成人免费电影| 久久精品国产亚洲5555| 国产欧美日本一区二区三区| 色婷婷久久99综合精品jk白丝| 亚洲国产日韩精品| 日韩欧美中文字幕精品| 成人免费视频app| 亚洲成人高清在线| 2欧美一区二区三区在线观看视频| 粉嫩av一区二区三区在线播放| 日韩理论片一区二区| 欧美人动与zoxxxx乱| 国产精品一级在线| 午夜精品久久久久久久久久 | 国产精品一级二级三级| 亚洲精品高清在线| 精品国产不卡一区二区三区| 波多野结衣中文字幕一区二区三区 | 国产拍欧美日韩视频二区| 波多野结衣91| 亚洲成人激情自拍| 久久久777精品电影网影网| www.66久久| 水野朝阳av一区二区三区| 在线看日本不卡| 日韩黄色免费电影| 久久久久久久久久久99999| 成人av电影在线| 午夜精品久久久久久久久久| 亚洲精品在线三区| 色婷婷一区二区| 蜜桃久久久久久久| 国产精品久久久久久久久快鸭| 欧美私模裸体表演在线观看| 欧美aa在线视频| 国产精品乱码人人做人人爱| 欧美精选一区二区| 成人综合婷婷国产精品久久蜜臀 | 日本网站在线观看一区二区三区| 久久精品日产第一区二区三区高清版 | 亚洲一区二区三区中文字幕| www久久精品| 91国产成人在线| 国产乱人伦偷精品视频不卡 | 精品国产一区二区三区忘忧草 | 99精品欧美一区二区三区综合在线| 亚洲综合精品久久| 国产欧美一区二区精品性色| 国产麻豆视频一区二区| 精品一区二区影视| 欧美日韩国产首页在线观看| 色综合天天综合| 亚洲永久免费av| 久久久精品tv| 91精品婷婷国产综合久久 | 一区精品在线播放| 国产在线精品不卡| 久久久国产精品麻豆| 99r国产精品| 亚洲1区2区3区4区| 2020日本不卡一区二区视频| 风流少妇一区二区| 亚洲最快最全在线视频| 91精品国产入口在线| 国产福利一区二区三区| 亚洲精品乱码久久久久久黑人 | 国产精品一区二区在线观看不卡| 国产精品无人区| 欧美色综合网站| 韩国精品主播一区二区在线观看 | 欧美日韩一区二区电影| 日本视频中文字幕一区二区三区| www国产成人免费观看视频 深夜成人网| 国产99久久久精品| 午夜成人在线视频| 国产日本亚洲高清| 欧美老人xxxx18| 成人少妇影院yyyy| 亚洲一级在线观看| 国产精品亲子伦对白| 6080国产精品一区二区| 成人网在线播放| 日韩成人免费电影| 自拍偷拍亚洲欧美日韩| 欧美成人一区二区三区片免费| thepron国产精品| 日日欢夜夜爽一区| 亚洲欧洲日韩综合一区二区| 欧美一区二区三区视频在线观看| www.色综合.com| 久久超级碰视频| 亚洲主播在线播放| 中文字幕五月欧美| 国产日韩亚洲欧美综合| 正在播放亚洲一区| 欧美亚洲高清一区二区三区不卡| 粉嫩一区二区三区在线看| 日韩精品久久理论片| 亚洲四区在线观看| 国产精品美女久久久久久久久久久 | 欧美日韩精品一区二区三区四区| 成人app软件下载大全免费| 久久99日本精品| 亚洲国产成人av网| 亚洲激情图片一区| 国产精品久久久久久福利一牛影视| 欧美成人猛片aaaaaaa| 5858s免费视频成人| 在线中文字幕不卡| 色悠悠久久综合| 成人动漫一区二区三区| 国产精品综合视频| 久久99精品久久久久| 免费不卡在线观看| 美腿丝袜一区二区三区| 免费成人在线网站| 久久成人综合网| 国产一区二区不卡| 毛片不卡一区二区| 亚洲国产欧美一区二区三区丁香婷| 国产校园另类小说区| 欧美久久久久免费| 欧美日韩mp4| 欧美精品一区二区高清在线观看| 精品国产髙清在线看国产毛片| 精品国产sm最大网站免费看| 亚洲精品一区二区三区香蕉| 精品成人一区二区三区四区| 精品捆绑美女sm三区| 26uuu色噜噜精品一区二区| 2024国产精品| 欧美激情一区不卡| 亚洲人成伊人成综合网小说| 国产欧美中文在线| 中文字幕亚洲视频| 亚洲福利视频三区| 久久国产精品色婷婷| 国产suv精品一区二区三区| 9l国产精品久久久久麻豆| 99在线精品视频| 欧美日韩在线三区| 欧美一激情一区二区三区| 精品国免费一区二区三区| 国产亚洲成aⅴ人片在线观看| 中文字幕av一区二区三区| 一区二区视频在线| 日本怡春院一区二区| 国产精品综合一区二区三区| 91网站在线观看视频| 91精品国产综合久久久蜜臀图片 | 日韩欧美精品三级| 中文字幕中文字幕一区| 亚洲午夜av在线| 免费黄网站欧美| 成人av网址在线观看| 69p69国产精品| 中文字幕日本不卡| 免费精品99久久国产综合精品| 丁香激情综合国产| 欧美日韩美少妇| 欧美国产在线观看| 天堂一区二区在线| av在线这里只有精品| 欧美妇女性影城| 国产精品污网站| 久久精品国产成人一区二区三区 | 亚洲成人精品一区| 国产成人亚洲精品青草天美| 欧美日韩国产另类一区| 欧美高清在线精品一区| 麻豆精品视频在线| 欧美综合在线视频| 国产精品国产自产拍高清av王其| 日本不卡高清视频| 91国偷自产一区二区开放时间| 精品国产91乱码一区二区三区 | 国产精品久久久久久久久免费丝袜| 日韩专区一卡二卡| 色综合久久久久久久久| 国产午夜亚洲精品羞羞网站| 日产国产欧美视频一区精品| 欧美性videosxxxxx| 亚洲日本在线观看| 麻豆成人综合网| 91网站在线播放|