Dynamic Configuration Change

Hi All,

I have a requirement, where I have dynamically change configuration, while traffic is in progression. Can any one give me some idea about the best possible, way to do the same.

In reply to kmishra:

You can try this with a Singleton class. It does not have overhead of uvm configuration database.

class MyObject;

   int configuration_1;
   int configuration_2;

   static MyObject myObj;

   // Making constructor local restricts
   // any call to new() outside of the
   // class
   local function new();
   endfunction

   // Creator method
   static function MyObject getObject();
      if(myObj == null)
         myObj = new();
      return myObj;
   endfunction

endclass //MyObject


initial
begin
  // Use this to get the shared object
  MyObject obj = MyObject::getObject();
end

In reply to kmishra:

Hi All,
I have a requirement, where I have dynamically change configuration, while traffic is in progression. Can any one give me some idea about the best possible, way to do the same.

Could you please explain some more details. Does your configuration data depend on pattern generated or how does it work?

In reply to chr_sue:

In reply to kmishra:
Could you please explain some more details. Does your configuration data depend on pattern generated or how does it work?

Hi,

The requirement is, I am working on PCI-E protocol in GEN-3 and I want to configure my ports in GEN-2, while PCI-E frames are in progress. I want to know, how to pass GEN-2 configuration using config_db or some other feature in UVM, while frames are moving.

In reply to kmishra:

I guess you have a limited number of configurations. In this case you could put these config objects to the config_db, prior to starting any traffic. Another option I see is to pass configuratioon data along with an event.