Files
fvh_vezbe/code/Vezba 13 - prateci materijal/reset_agent/sv/reset_config.sv

47 lines
1.5 KiB
Systemverilog
Raw Normal View History

2026-06-12 07:53:32 +02:00
/****************************************************************************
+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+ +-+-+-+-+-+-+-+-+
|F|u|n|c|t|i|o|n|a|l| |V|e|r|i|f|i|c|a|t|i|o|n| |o|f| |H|a|r|d|w|a|r|e|
+-+-+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+-+-+-+-+ +-+-+ +-+-+-+-+-+-+-+-+
FILE reset_config.sv
DESCRIPTION configuration class for reset agent
****************************************************************************/
`ifndef RESET_CONFIG_SV
`define RESET_CONFIG_SV
/**
* Class: reset_config
*/
class reset_config extends uvm_object;
// reset value at the start of simulation
bit value_at_0 = 0;
// 1 = reset is active high; 0 = active low
bit active_high = 1;
// is agent active or passive
uvm_active_passive_enum is_active = UVM_ACTIVE;
// checks and coverage control
bit has_checks = 1;
bit has_coverage = 1;
// UVM factory registration
`uvm_object_utils_begin(reset_config)
`uvm_field_int(value_at_0, UVM_DEFAULT)
`uvm_field_int(active_high, UVM_DEFAULT)
`uvm_field_enum(uvm_active_passive_enum, is_active, UVM_DEFAULT)
`uvm_field_int(has_checks, UVM_DEFAULT)
`uvm_field_int(has_coverage, UVM_DEFAULT)
`uvm_object_utils_end
// new - constructor
function new(string name = "reset_config");
super.new(name);
endfunction : new
endclass : reset_config
`endif