-
Notifications
You must be signed in to change notification settings - Fork 263
A memory mapped bus functional model library
kraigher edited this page May 30, 2017
·
3 revisions
The purpose of the library is to provide a convenient way to interact with a device under test using any memory mapped bus protocol. The library will consist of several parts:
- A general API to read and write data to an address space.
- A memory model where data can be allocated, read and written.
- Bus transactors for translation between general read/write commands on the API to actual bus signaling such as AXI or XILINX BRAM interface.
-- Raw API, migth have higher level convenience procedures for 32-bit, 16-bit etc
procedure write(signal net : inout net_t; address : integer; data : integer_vector; num_bytes : integer; timeout : time);
procedure read(signal net : inout net_t; address : integer; variable data : inout integer_vector; num_bytes : integer; timeout : time);
The memory model supports:
- Reading and writing data to it
- Setting access flags on addresses such as write_only, read_only, read_write, write_reference_data
- Allocating address space in the memory for data buffers with meta-data information to provide good error messages such as the name of the buffer and the internal offset as well as the number of bytes per word and potentially also line pitch for images.
- Method to check that an address space has been written with the expected reference data.
The following bus transactors are initially planned to be implemented.
- AXI master talking either directly to the memory model.
- AXI lite slave
- XILINX BRAM slave
The bus transactors should also support several bus specific configuration that can be changed at run time such as the data rate and fifo depths for different AXI channels.