Skip to content

Issue Running Ariane Co-Simulation Tutorial: Bootram File Loading Problem #89

Description

@GabPGomes

Hi,
I hope this isn't too much of a beginner's question, but I ran into a problem while following the Ariane co-simulation tutorial.

I rolled all the repositories back to the December 2019 versions, when the tutorial was made: dromajo, ariane, verilator, etc. I was able to compile the project successfully, but I couldn't get it to run.

In step 4 of the tutorial, there's a patch to add a bootram file to the Ariane core, which looks like this:

 // sync with dromajo
      if ($value$plusargs("checkpoint=%s", f_name)) begin
        hex_file = $fopen({f_name,".bootram.hex"}, "r");
        while (!$feof(hex_file)) begin
          num_bytes = $fscanf(hex_file, "%d %h\n", address, value);
          $display("%d %h", address, value);
          mem[address] = value;
        end
        $display("Done syncing RAM with dromajo...\n");
      end else begin
        $display("Dromajo error: provide path to a checkpoint.\n");
      end
    end

I couldn't load the file for two reasons:

  1. There are no .bootram.hex files generated—dromajo only produces .bootram files when saving a checkpoint.
  2. The .bootram files appear to be binary, but (if I'm understanding SystemVerilog correctly) $fscanf seems to only support reading text files.
    Could you clarify if there's a step missing in the tutorial or if any additional modifications are needed to process the .bootram files correctly?

Thank you for your help!

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions