Forum Discussion
Altera_Forum
Honored Contributor
8 years agoHi Dave,
I need information about burst write operation in avalon bfm. Below i mentioned the task which i am using. In that burst_size is 3 and burst_count in each burst is 2.So totally 6 data transaction will happen.But In my case i am getting only three data transacation and and address is also not incrementing(Adress is zero for all transaction). Please help me ... I am new to protocol.. ////////////////////////////////Task ////////////////////////////////////// task data_init(output bit[511:0] data [int]); for(int i=0; i<6; i++) data = {$random(), $random()};endtask
task avalon_write ([34:0] addr, bit[511:0] data [int]);
// construct the bfm request
`bfm.set_command_request(req_write);
`bfm.set_command_idle(0, 0);
`bfm.set_command_init_latency(0);
`bfm.set_command_address(addr);
`bfm.set_command_burst_size(3);
`bfm.set_command_burst_count(2);
for(int i=0; i<6; i++)
begin
`bfm.set_command_data(data, i); `BFM.set_command_byte_enable(48'hffff_ffff_ffff,i) ; end // Queue the command `BFM.push_command(); // Wait until the transaction has completed while (`BFM.get_response_queue_size() != 1) @(posedge `BFM.clk); // Dequeue the response and discard `BFM.pop_response(); endtask bit[511:0] wdata[int]; ///////////////////////////// initial begin data_init(wdata); avalon_write('d0,wdata); end /////////////////////////////// Thanks Venkat