1 ------------------------------------------------------------------------------- 2 -- File : AxiReadEmulate.vhd 3 -- Company : SLAC National Accelerator Laboratory 4 -- Created : 2013-04-02 5 -- Last update: 2016-04-26 6 ------------------------------------------------------------------------------- 7 -- Description: AXI4 Read Emulation Module 8 ------------------------------------------------------------------------------- 9 -- This file is part of 'SLAC Firmware Standard Library'. 10 -- It is subject to the license terms in the LICENSE.txt file found in the 11 -- top-level directory of this distribution and at: 12 -- https://confluence.slac.stanford.edu/display/ppareg/LICENSE.html. 13 -- No part of 'SLAC Firmware Standard Library', including this file, 14 -- may be copied, modified, propagated, or distributed except according to 15 -- the terms contained in the LICENSE.txt file. 16 ------------------------------------------------------------------------------- 19 use ieee.std_logic_1164.
all;
20 use ieee.std_logic_arith.
all;
21 use ieee.std_logic_unsigned.
all;
61 cnt => (others => '0'), 90 -- Latch the current value 93 -- Reset the variables 98 ---------------------------------------------------------------------- 101 v.cnt := (others => '0');
106 -- Check for a memory request 116 -- Increment the counter 119 ---------------------------------------------------------------------- 121 -- Check if ready to move data 134 -- Check if transaction is completed 138 -- Check if request in pipeline 140 -- Preset the counter 149 ---------------------------------------------------------------------- 157 -- Register the variable for next clock cycle 167 if (rising_edge(axiClk)) then
(IDLE_S,DATA_S) StateType
AxiReadMasterType :=(arvalid => '0',araddr =>( others => '0'),arid =>( others => '0'),arlen =>( others => '0'),arsize =>( others => '0'),arburst =>( others => '0'),arlock =>( others => '0'),arprot =>( others => '0'),arcache =>( others => '0'),arqos =>( others => '0'),arregion =>( others => '0'),rready => '0') AXI_READ_MASTER_INIT_C
out sAxiReadSlaveAxiReadSlaveType
slv( 1023 downto 0) rdata
in mAxiReadSlaveAxiReadSlaveType
SIM_DEBUG_Gboolean := false
out mAxiReadMasterAxiReadMasterType
in axiReadMasterAxiReadMasterType
AXI_CONFIG_GAxiConfigType := AXI_CONFIG_INIT_C
out axiReadSlaveAxiReadSlaveType
RegType :=(latency => 0,state => IDLE_S,cnt =>( others => '0'),iMaster => AXI_READ_MASTER_INIT_C,iSlave => AXI_READ_SLAVE_INIT_C) REG_INIT_C
AxiReadMasterType iMaster
natural range 0 to LATENCY_G latency
AxiReadMasterType intReadMaster
in sAxiReadMasterAxiReadMasterType
positive range 1 to 128 DATA_BYTES_C
AxiConfigType :=axiConfig(ADDR_WIDTH_C => 32,DATA_BYTES_C => 4,ID_BITS_C => 12,LEN_BITS_C => 4) AXI_CONFIG_INIT_C
AxiReadSlaveType intReadSlave
AXI_CONFIG_GAxiConfigType := AXI_CONFIG_INIT_C
AxiReadSlaveType :=(arready => '0',rdata =>( others => '0'),rlast => '0',rvalid => '0',rid =>( others => '0'),rresp =>( others => '0')) AXI_READ_SLAVE_INIT_C