Following is a sample file that I have which has a combination of addresses and data on individual lines,
- @0
- 1A
- 1B
- @C
- 2D
…
I would like to understand if I can implement the following steps while reading the above file in systemverilog testbench or if there are alternatives to do this,
A) Identify the lines with @ symbol & then identify the associated address value.
B) Add the address value (Ex: C from @C) to a base address.
C) Run a for() loop until the next address is hit while reading the file and then repeat A, B & C.
I am trying with $readmemh(), but stuck in step-A.