The following prototype is picked directly from the cookbook(UVM register model). I don’t understand “byte_addressing” usage ?
//
// Prototype for the create_map method
//
function uvm_reg_map create_map(string name, // Name of the map handle
uvm_reg_addr_t base_addr, // The maps base address
int unsigned n_bytes, // Map access width in bytes
uvm_endianness_e endian, // The endianess of the map
bit byte_addressing=1); // Whether byte_addressing is supported
//
// Example:
//
AHB_map = create_map("AHB_map", 'h0, 4, UVM_LITTLE_ENDIAN);
Also I need to know how the argument value(offset) should be incremented,if my work includes includes a simple register file with all regs 8-bit wide and their address is incremented by 1 (i.e. 0x1,0x2, …) ?
I think I may use 8’b01,8’b02 … and so on in my case
function void add_reg (uvm_reg rg, // Register object handle
uvm_reg_addr_t offset, // Register address offset
string rights = "RW", // Register access policy
bit unmapped=0, // If true, register does not appear in the address map
// and a frontdoor access needs to be defined
uvm_reg_frontdoor frontdoor=null);// Handle to register frontdoor access object
Thanks in advance