MatchLib
Public Types | Public Member Functions | Public Attributes | Static Public Attributes | Protected Member Functions | List of all members
Slave< axiCfg > Class Template Reference

An AXI slave for use in a testbench. More...

#include <Slave.h>

Inheritance diagram for Slave< axiCfg >:

Public Types

typedef axi::axi4< axiCfg > axi4_
 

Public Member Functions

 SC_CTOR (Slave)
 

Public Attributes

axi4_::read::template slave if_rd
 
axi4_::write::template slave if_wr
 
sc_in< bool > reset_bar
 
sc_in< bool > clk
 
std::queue< typename axi4_::ReadPayloadrd_resp
 
std::queue< typename axi4_::Addr > rd_resp_addr
 
std::queue< typename axi4_::AddrPayloadwr_addr
 
std::queue< typename axi4_::WritePayloadwr_data
 
std::queue< typename axi4_::WRespPayloadwr_resp
 
std::map< typename axi4_::Addr, typename axi4_::Data > localMem
 
std::map< typename axi4_::Addr, NVUINT8 > localMem_wstrb
 
std::vector< typename axi4_::Addr > validReadAddresses
 

Static Public Attributes

static const int kDebugLevel = 0
 
static const int bytesPerBeat = axi4_::DATA_WIDTH >> 3
 

Protected Member Functions

void run_rd ()
 
void run_wr ()
 

Detailed Description

template<typename axiCfg>
class Slave< axiCfg >

An AXI slave for use in a testbench.

Template Parameters
axiCfgA valid AXI config.
Overview
This test structure acts as an AXI slave memory, responding to read and write requests and generating responses. An internal memory, initially unpopulated, stores the values of AXI write requests and is accessed for read requests. The block enforces the following by assertion:
  • Read requests are only valid if the address has previously been written to.
  • Write data beats must each assert at least one strobe bit.

Definition at line 45 of file Slave.h.


The documentation for this class was generated from the following file: