Hi,
I have a variable (int) in my sequence. How can I set the value to it in my test case ??
My sequence looks like this:
class my_seq extends uvm_sequence#(my_txn);
int N;
`uvm_object_utils_begin(my_seqI) // register with factory
`uvm_field_int (N,UVM_DEFAULT)
`uvm_object_utils_end
function new(string name);
super.new(name);
endfunction
task body();
repeat (N)
begin
....
end
endtask:body
endclass:my_seqI have an handle for sequence in test. From My test case I want to control the value of N, Is there any other method other than assigning the value directly ?

Don't understand the title of your post in relation to the question being asked.
For classes not derived from uvm_component, you must explicitly get the value from the config db.
if (!uvm_config_db#(int)(context,"",N)) `uvm_error("code","message);
Your context could be m_sequencer or it could be null if this is a global setting.
Dave Rich
Mentor Graphics
http://go.mentor.com/drich
Hi Dave,
Thanx... That worked for me...