ganeshrahate
Newbie level 2
- Joined
- Feb 19, 2013
- Messages
- 2
- Helped
- 0
- Reputation
- 0
- Reaction score
- 0
- Trophy points
- 1,281
- Activity points
- 1,300
Hi
I am just working on my very first project on verilog in my final year
I am stuck at one task
I am trying create task for writing data on bus , but i want to send multiple data in same task by using one input declaration as an array
task write_data;
input n_write; // nuber of data to be send
input [data_width-1:0] write_data;
begin
wrdataen = 1'b1;
repeat(n_write) @(posedge clk) // i am thinking of using for loop here
begin
$display ("%t : Value Write is %h", $time, write_data);
wrdata = write_data;
end
wrdataen = 1'b0; // this is write data enable
end
endtask
i wan to call task this
write_data(32'h5555,32'h7777,32'h6666,32'h8888,32'h11111,32'h2222)
I am just working on my very first project on verilog in my final year
I am stuck at one task
I am trying create task for writing data on bus , but i want to send multiple data in same task by using one input declaration as an array
task write_data;
input n_write; // nuber of data to be send
input [data_width-1:0] write_data;
begin
wrdataen = 1'b1;
repeat(n_write) @(posedge clk) // i am thinking of using for loop here
begin
$display ("%t : Value Write is %h", $time, write_data);
wrdata = write_data;
end
wrdataen = 1'b0; // this is write data enable
end
endtask
i wan to call task this
write_data(32'h5555,32'h7777,32'h6666,32'h8888,32'h11111,32'h2222)