Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Denali question - verify reading mem operation, printInfo

Status
Not open for further replies.

tarkyss

Full Member level 6
Joined
Aug 1, 2005
Messages
340
Helped
26
Reputation
52
Reaction score
8
Trophy points
1,298
Location
China
Activity points
4,162
denalimemtransaction

In order to verify reading mem operation,
data prepared in mem with setData function of DenaliMemTransaction class
for example, trans is an instance of DenaliMemTransaction, data1 and data2 are
addr=16'h0
reg [7:0] data1. data2;
data1 = new(2);
data2 = new(2);
trans.setAddress(addr)
trans.setData(data1)
addr=16'h2
trans.setAddress(addr)
trans.setData(data2)

the first data can be write to mem correctly, but the second can not, the second data may be written to unexpected address, why
if write the data to mem and then read them , it is ok, so maybe the dut is right (of course, it is possible wrong too)
if it is not the problem of dut, are there any other reasons?

In addition, when I use printInfo function of the class
the address, data, mask are right as expected
address are 16'h0, 16'h2
the datra are right too
while the width is 0, is it ok?
 

denalimeminstance

denali model has his own function to preload memory!
 

Denali question

ljxpjpjljx, do you know how to preload mem for denali model? thanks
 

Denali question

use denali's PLI , for detailed ,you can reference MMAV user guide.pdf.
 

Re: Denali question

For System Verilog you need to use Denali's system verilog interface not the denali PLI's. You need to define the read/write task/function, something similar to as shown below.

denaliMemInstance inst;
denaliMemTransaction trans;
integer status;

inst = new("testbench.memInst"); //Complete path of denali memory instance

function void writeData(reg [63:0] addr);
reg [7:0] data [];
trans = new;
trans.setAddress(addr);
data = new[4];
data[0] = 'h0;
data[1] = 'h0;
data[2] = 'b0;
data[3] = 'hff;
trans.setData(data);
$display("## WRITE : %x -> %x", trans.getAddress(), data);
status = inst.write(trans);
endfunction

function void readData(reg [63:0] addr);
reg [7:0] data [];
trans = new;
trans.setAddress(addr);
$display("## READ : %x ", trans.getAddress());
status = inst.read(trans);
trans.getData(data);
$display("## READ w/DATA : %x -> %x", trans.getAddress(), data);
endfunction
 

Re: Denali question

Hi,
denali soma file takes an initialization file which has the format something like this...

start_address:end_address 0xff;

the above thing fills the whole memory with 0xff.
u can give individual address with the respective values...

the initialization file has to be included in ur top rtl file as a parameter....

Regards
Srinivas
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top