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

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

?? address_swap_module_8.v

?? Xilinx Virtex5 SGMII高速串行通信例程。
?? V
字號(hào):
//----------------------------------------------------------------------
// Title      : Address Swapping Module
// Project    : Virtex-5 Ethernet MAC Wrappers
//----------------------------------------------------------------------
// File       : address_swap_module_8.v
//----------------------------------------------------------------------
// Copyright (c) 2004-2007 by Xilinx, Inc. All rights reserved.
// This text/file contains proprietary, confidential
// information of Xilinx, Inc., is distributed under license
// from Xilinx, Inc., and may be used, copied and/or
// disclosed only pursuant to the terms of a valid license
// agreement with Xilinx, Inc. Xilinx hereby grants you
// a license to use this text/file solely for design, simulation,
// implementation and creation of design files limited
// to Xilinx devices or technologies. Use with non-Xilinx
// devices or technologies is expressly prohibited and
// immediately terminates your license unless covered by
// a separate agreement.
//
// Xilinx is providing this design, code, or information
// "as is" solely for use in developing programs and
// solutions for Xilinx devices. By providing this design,
// code, or information as one possible implementation of
// this feature, application or standard, Xilinx is making no
// representation that this implementation is free from any
// claims of infringement. You are responsible for
// obtaining any rights you may require for your implementation.
// Xilinx expressly disclaims any warranty whatsoever with
// respect to the adequacy of the implementation, including
// but not limited to any warranties or representations that this
// implementation is free from claims of infringement, implied
// warranties of merchantability or fitness for a particular
// purpose.
//
// Xilinx products are not intended for use in life support
// appliances, devices, or systems. Use in such applications are
// expressly prohibited.
//
// This copyright and support notice must be retained as part
// of this text at all times. (c) Copyright 2004-2007 Xilinx, Inc.
// All rights reserved.

//----------------------------------------------------------------------
// Description: - Takes in frame from the client side EMAC reciever.
//              - Swaps the source address with destination address.
//              - Outputs the modified frame.
//              - rx_data_valid, rx_good_frame, rx_bad_frame are delayed
//                by an equal number of clock cycles as rx_data.
//              - The module consists of a six stage shift register and 
//                multiplexer to select data either from the shift 
//                register output or directly from the data input.  The 
//                destination address is loaded into the shift register 
//                and held whilst the source address is selected 
//                directly from the input.  Once the source address has 
//                been output, data is taken from the shift register.
//----------------------------------------------------------------------

`timescale 1 ns/1 ps

//fsm type and signals
`define wait_sf    3'd0  // awaiting start of frame
`define bypass_sa1 3'd1  // bypassing first byte of source address
`define bypass_sa2 3'd2  // bypassing second byte of source address
`define bypass_sa3 3'd3  // bypassing third byte of source address
`define bypass_sa4 3'd4  // bypassing fourth byte of source address
`define bypass_sa5 3'd5  // bypassing fifth byte of source address
`define bypass_sa6 3'd6  // bypassing sixth byte of source address
`define pass_rof   3'd7  // transmitting remainder of data in frame


module address_swap_module_8 (
      rx_ll_clock,         // Input CLK from TRIMAC Reciever
      rx_ll_reset,         // Synchronous reset signal
      rx_ll_data_in,       // Input data
      rx_ll_sof_in_n,      // Input start of frame
      rx_ll_eof_in_n,      // Input end of frame
      rx_ll_src_rdy_in_n,  // Input source ready
      rx_ll_data_out,      // Modified output data
      rx_ll_sof_out_n,     // Output start of frame
      rx_ll_eof_out_n,     // Output end of frame
      rx_ll_src_rdy_out_n, // Output source ready
      rx_ll_dst_rdy_in_n  // Input destination ready
      );

//Port declarations
   input  rx_ll_clock;
   input  rx_ll_reset;
   input  [7:0] rx_ll_data_in;
   input  rx_ll_sof_in_n;
   input  rx_ll_eof_in_n;
   input  rx_ll_src_rdy_in_n;
   output [7:0] rx_ll_data_out;
   reg    [7:0] rx_ll_data_out;
   output rx_ll_sof_out_n;
   output rx_ll_eof_out_n;
   output rx_ll_src_rdy_out_n;
   input  rx_ll_dst_rdy_in_n;   

   //Signal declarations
   reg        sel_delay_path;        // controls mux in Process data_out_mux
   reg        enable_data_sr;        // clock enable for data shift register
   wire [7:0] data_sr5;              // data after 6 cycle delay
   reg  [7:0] mux_out;               // data to output register

   wire       rx_enable;             // Internal enable signal
   
   //state machine state variable
   reg [2:0]  control_fsm_state;     // holds state of control fsm
   
   //6 stage shift register type and signals
   reg [7:0]  data_sr_content[0:5];  // holds contents of data sr
  

   //7 stage shift register type and signals
   reg 	      eof_sr_content[0:6];   // holds contents of end of frame sr
   reg 	      sof_sr_content[0:6];   // holds contents of start of frame sr
   reg        rdy_sr_content[0:6];   // holds contents of source ready sr
   
   integer    i;  // index for sr processes

   //--------------------------------------------------------------------------
   //Process data_sr_p
   //A six stage shift register to hold six bytes of incoming data.
   //Clock enable signal enable_data_sr allows destination address to be stored
   //in shift register when in bypass mode.
   //--------------------------------------------------------------------------
   always @(posedge rx_ll_clock)
   begin
      if (enable_data_sr == 1'b1 && rx_enable == 1'b1)
	 begin
	    for(i=5; i >0; i=i-1)
               data_sr_content[i] <= data_sr_content [i-1];
	       data_sr_content[0] <= rx_ll_data_in;
	 end
   end   // data_sr_p
   assign data_sr5 = data_sr_content[5];
   

   //--------------------------------------------------------------------------
   //Process data_out_mux_p
   //Selects data_out from the data shift register or from data_in, allowing
   //destination address to be bypassed
   //--------------------------------------------------------------------------
   always @(rx_ll_data_in, data_sr5, sel_delay_path)
   begin
      if (sel_delay_path == 1'b1)
         mux_out = rx_ll_data_in;
      else
         mux_out = data_sr5;
    
   end  //  data_out_mux_p


   //--------------------------------------------------------------------------
   //Process data_out_reg_p
   //Registers data output from output mux
   //--------------------------------------------------------------------------
   always @(posedge rx_ll_clock)
   begin
     if (rx_enable == 1'b1)
       rx_ll_data_out <= mux_out;
   end  // data_out_reg_p

   assign rx_enable = ~(rx_ll_dst_rdy_in_n);


   //--------------------------------------------------------------------------
   //Process data_sof_sr_p
   //Delays start of frame by 7 clock cycles
   //--------------------------------------------------------------------------
   always @(posedge rx_ll_clock)
   begin 
     if (rx_enable == 1'b1)
     begin
       for(i=6; i>0; i=i-1)
         sof_sr_content[i] <= sof_sr_content[i-1];
         sof_sr_content[0] <= !rx_ll_sof_in_n;
     end 
   end   // data_sof_sr_p
   assign rx_ll_sof_out_n = !sof_sr_content[6];

   //--------------------------------------------------------------------------
   //Process data_eof_sr_p
   //Delays end of frame by 7 clock cycles
   //--------------------------------------------------------------------------
   always @(posedge rx_ll_clock)
   begin
    if (rx_enable == 1'b1)
     begin
	 for(i=6; i>0; i=i-1)
           eof_sr_content[i] <= eof_sr_content[i-1];
           eof_sr_content[0] <= !rx_ll_eof_in_n;
     end	
   end // data_bad_sr_p
   assign rx_ll_eof_out_n = !eof_sr_content[6];

   //--------------------------------------------------------------------------
   //Process data_rdy_sr_p
   //Delays source ready by 7 clock cycles
   //--------------------------------------------------------------------------
   always @(posedge rx_ll_clock)
   begin
     if (rx_enable == 1'b1)
     begin
       for(i=6; i>0; i=i-1)
         rdy_sr_content[i] <= rdy_sr_content[i-1];
         rdy_sr_content[0] <= !rx_ll_src_rdy_in_n;
     end	
   end // data_bad_sr_p
   assign rx_ll_src_rdy_out_n = !rdy_sr_content[6];

   //--------------------------------------------------------------------------
   //Process control_fsm_sync_p
   //Synchronous update of next state of control_fsm
   //--------------------------------------------------------------------------
   always @(posedge rx_ll_clock)
   begin
      if (rx_ll_reset == 1)
            control_fsm_state <= `wait_sf;
      else
        if (rx_enable == 1'b1)
        begin
          case(control_fsm_state)
               `wait_sf :     if (sof_sr_content[4] == 1'b1)
                              control_fsm_state <= `bypass_sa1;  // Start of frame detected
                              else
                              control_fsm_state <= `wait_sf;     // Continue to wait for sof
     
                `bypass_sa1 : if (!(sof_sr_content[4] == 1'b0 && eof_sr_content[4] == 1'b1))
                              control_fsm_state <= `bypass_sa2;  // Pass next byte of source address
                              else
                              control_fsm_state <= `wait_sf;     // Frame ended, wait for next frame
 
                `bypass_sa2 : if (!(sof_sr_content[4] == 1'b0 && eof_sr_content[4] == 1'b1))
                              control_fsm_state <= `bypass_sa3;  // Pass next byte of source address
                              else
                              control_fsm_state <= `wait_sf;     // Frame ended, wait for next frame
                   
                `bypass_sa3 : if (!(sof_sr_content[4] == 1'b0 && eof_sr_content[4] == 1'b1))
                              control_fsm_state <= `bypass_sa4;  // Pass next byte of source address
                              else
                              control_fsm_state <= `wait_sf;     // Frame ended, wait for next frame
                   
                `bypass_sa4 : if (!(sof_sr_content[4] == 1'b0 && eof_sr_content[4] == 1'b1))
                              control_fsm_state <= `bypass_sa5;  // Pass next byte of source address
                              else
                              control_fsm_state <= `wait_sf;     // Frame ended, wait for next frame
                   
                `bypass_sa5 : if (!(sof_sr_content[4] == 1'b0 && eof_sr_content[4] == 1'b1))
                              control_fsm_state <= `bypass_sa6;  // Pass next byte of source address
                              else
                              control_fsm_state <= `wait_sf;     // Frame ended, wait for next frame
                   
                `bypass_sa6 : if (!(sof_sr_content[4] == 1'b0 && eof_sr_content[4] == 1'b1))
                              control_fsm_state <= `pass_rof;    // Output remaining data in frame   
                              else
                              control_fsm_state <= `wait_sf;     // Frame ended, wait for next frame  
                   
                `pass_rof :   if (!(sof_sr_content[4] == 1'b0 && eof_sr_content[4] == 1'b1))
                              control_fsm_state <= `pass_rof;    // Output remaining data in frame   
                              else
                              control_fsm_state <= `wait_sf;     // Frame ended, wait for next frame   
            default :         control_fsm_state <= `wait_sf;   
	   
            endcase
        end
   end // control_fsm_sync_p


   //--------------------------------------------------------------------------
   //Process control_fsm_comb_p
   //Determines control signals from control_fsm state
   //--------------------------------------------------------------------------
   always @(control_fsm_state)
   begin
   case (control_fsm_state)
         `wait_sf    : begin
                       sel_delay_path = 1'b0;  // output data from data shift register
                       enable_data_sr = 1'b1;  // enable data to be loaded into shift register
	               end
         `bypass_sa1 : begin
                       sel_delay_path = 1'b1;  // output data directly from input
                       enable_data_sr = 1'b0;  // hold current data in shift register
	               end
         `bypass_sa2 : begin
                       sel_delay_path = 1'b1;  // output data directly from input
                       enable_data_sr = 1'b0;  // hold current data in shift register
	               end
         `bypass_sa3 : begin
                       sel_delay_path = 1'b1;  // output data directly from input
                       enable_data_sr = 1'b0;  // hold current data in shift register
	               end
         `bypass_sa4 : begin
                       sel_delay_path = 1'b1;  // output data directly from input
                       enable_data_sr = 1'b0;  // hold current data in shift register
	               end
         `bypass_sa5 : begin
                       sel_delay_path = 1'b1;  // output data directly from input
                       enable_data_sr = 1'b0;  // hold current data in shift register
	               end
         `bypass_sa6 : begin 
                       sel_delay_path = 1'b1;  // output data directly from input
                       enable_data_sr = 1'b0;  // hold current data in shift register
	               end
         `pass_rof   : begin
                       sel_delay_path = 1'b0;  // output data from data shift register
                       enable_data_sr = 1'b1;  // enable data to be loaded into shift register
	               end
          default    : begin
                       sel_delay_path = 1'b0;
                       enable_data_sr = 1'b1;
	               end
      endcase
   end   // control_fsm_comb_p
   
endmodule






?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
久久亚洲春色中文字幕久久久| 亚洲精品一区二区三区福利| 看片网站欧美日韩| 中文字幕日本乱码精品影院| 91麻豆精品国产91久久久更新时间 | 国产日韩欧美a| 欧美日韩国产高清一区| 成人免费毛片嘿嘿连载视频| 肉丝袜脚交视频一区二区| 国产精品免费久久久久| 56国语精品自产拍在线观看| 91女神在线视频| 成人精品一区二区三区中文字幕 | 国产成人亚洲综合色影视| 亚洲第一激情av| 综合久久给合久久狠狠狠97色| 久久影院午夜论| 欧美一区二区三区男人的天堂 | 久久在线免费观看| 日韩写真欧美这视频| 欧美三级资源在线| 一本久道中文字幕精品亚洲嫩| 国产精品1区2区3区| 韩国av一区二区三区四区 | 奇米一区二区三区| 午夜精品aaa| 亚洲精品成人在线| 亚洲另类在线视频| 亚洲精品日韩一| 亚洲免费av高清| 日韩久久一区二区| 亚洲欧美综合色| 国产精品久久久久久户外露出 | 亚洲人成影院在线观看| 国产精品三级av| 国产精品入口麻豆原神| 国产精品国产三级国产三级人妇| 中文一区二区完整视频在线观看| 国产片一区二区| 国产精品无遮挡| 中文字幕在线观看不卡视频| 亚洲欧美国产77777| 亚洲色图丝袜美腿| 尤物在线观看一区| 亚洲第一福利一区| 奇米在线7777在线精品| 韩国v欧美v日本v亚洲v| 国产不卡视频一区二区三区| 成人免费黄色在线| 91在线播放网址| 欧美色综合影院| 欧美一区二区三区免费在线看| 欧美电影免费观看高清完整版在| 欧美大片在线观看| 精品1区2区在线观看| 欧美极品xxx| 亚洲欧美另类图片小说| 国内精品免费在线观看| 久久国产夜色精品鲁鲁99| 麻豆精品国产91久久久久久| 激情伊人五月天久久综合| 成人网在线免费视频| 91免费观看在线| 欧美精品久久99久久在免费线 | 国产精品久久久久久一区二区三区| 国产精品久久久久桃色tv| 亚洲欧美一区二区在线观看| 亚洲精选视频在线| 免费在线一区观看| 国产91高潮流白浆在线麻豆| 99精品欧美一区二区三区小说 | 久久午夜免费电影| 亚洲欧洲色图综合| 日韩成人一级大片| 国产91精品入口| 欧美精品亚洲二区| 中文字幕第一区| 日欧美一区二区| 成人一级视频在线观看| 欧美日韩在线观看一区二区| 久久先锋资源网| 亚洲一区二区视频在线| 国产一区二区成人久久免费影院 | 美女网站一区二区| 不卡的av网站| 日韩一级免费观看| 综合在线观看色| 黄色日韩三级电影| 在线观看91精品国产入口| 日韩欧美黄色影院| 亚洲精品免费看| 国产一区三区三区| 欧美色综合久久| 亚洲欧洲精品一区二区三区不卡| 人人超碰91尤物精品国产| 波波电影院一区二区三区| 欧美一区二区三区播放老司机| 亚洲三级免费观看| 国产一区二区中文字幕| 欧美性感一区二区三区| 国产精品国产三级国产专播品爱网| 美腿丝袜亚洲三区| 欧美做爰猛烈大尺度电影无法无天| 久久日韩粉嫩一区二区三区| 天天色综合天天| 一本大道久久精品懂色aⅴ| 久久午夜电影网| 日韩电影在线看| 欧美在线一二三四区| 国产精品久久毛片| 国产乱人伦精品一区二区在线观看 | 日韩av电影免费观看高清完整版| 91丝袜美腿高跟国产极品老师 | 国产欧美久久久精品影院| 日韩av一区二| 欧美在线观看视频在线| 中文字幕视频一区| 国产精品一区久久久久| 日韩你懂的在线观看| 日韩不卡手机在线v区| 欧美在线免费播放| 一区二区免费看| 一本色道a无线码一区v| 国产精品久久毛片| 不卡电影一区二区三区| 亚洲国产成人一区二区三区| 国产精品亚洲第一| 久久久精品日韩欧美| 国产在线观看一区二区| 日韩午夜三级在线| 麻豆国产精品一区二区三区| 正在播放亚洲一区| 日日摸夜夜添夜夜添国产精品| 欧美美女激情18p| 偷拍一区二区三区| 欧美日韩一二区| 亚洲成人综合在线| 在线播放国产精品二区一二区四区 | 91久久国产综合久久| 亚洲欧美激情视频在线观看一区二区三区| zzijzzij亚洲日本少妇熟睡| 国产精品不卡在线观看| 欧美一区二区三区四区高清| 免费av网站大全久久| 日韩欧美一级在线播放| 久久aⅴ国产欧美74aaa| 精品国产网站在线观看| 国产精品一二三在| 国产精品视频在线看| 91在线云播放| 亚洲成人av一区二区三区| 91精品久久久久久久91蜜桃| 久久99精品久久久久久国产越南 | 国产在线视频精品一区| 国产日本欧美一区二区| 99re热这里只有精品视频| 一区二区在线免费观看| 欧美精品一级二级| 国内精品久久久久影院色| 国产精品视频你懂的| 99久久精品免费| 午夜欧美大尺度福利影院在线看| 日韩欧美第一区| 国产成人福利片| 综合久久综合久久| 欧美久久久久久久久久| 韩国午夜理伦三级不卡影院| 国产精品你懂的在线欣赏| 欧美在线影院一区二区| 精品一区二区三区久久久| 日本一区二区动态图| 欧美吻胸吃奶大尺度电影| 久久精品国产亚洲a| 国产精品日韩成人| 5月丁香婷婷综合| 成人动漫视频在线| 亚洲成人自拍网| 欧美经典一区二区| 56国语精品自产拍在线观看| 成人一区二区三区中文字幕| 午夜亚洲国产au精品一区二区| 久久久久88色偷偷免费| 欧美亚洲一区二区在线| 国产一区二区三区在线观看免费视频 | 99精品在线免费| 奇米亚洲午夜久久精品| 18涩涩午夜精品.www| 欧美一区二区视频免费观看| 成人精品视频一区二区三区 | 国产精品欧美久久久久无广告| 欧美日韩激情一区二区三区| 懂色av一区二区夜夜嗨| 青娱乐精品在线视频| 亚洲另类色综合网站| 久久精品日产第一区二区三区高清版| 在线观看视频一区| 成人高清视频免费观看| 久久av中文字幕片| 亚欧色一区w666天堂| 亚洲日本青草视频在线怡红院|