SystemRDL / PeakRDL-uvm

Generate UVM register model from compiled SystemRDL input
GNU General Public License v3.0
45 stars 25 forks source link
asic eda fpga registers uvm uvm-ral-model uvm-register-model

build PyPI - Python Version

PeakRDL-uvm

Generate UVM register model from compiled SystemRDL input.

For the command line tool, see the PeakRDL project.

Installing

Install from PyPi using pip:

python3 -m pip install peakrdl-uvm

Example

The easiest way to use PeakRDL-uvm is via the PeakRDL command line tool:

# Install the command line tool
python3 -m pip install peakrdl

# Generate UVM
peakrdl uvm your_design.rdl -o your_design.sv

Reference

UVMExporter(**kwargs)

Constructor for the UVM Exporter class

Optional Parameters

UVMExporter.export(node, path, **kwargs)

Perform the export!

Parameters

Optional Parameters

API Example

Pass the elaborated output of the SystemRDL Compiler to the exporter.

import sys
from systemrdl import RDLCompiler, RDLCompileError
from peakrdl_uvm import UVMExporter

rdlc = RDLCompiler()

try:
    rdlc.compile_file("path/to/my.rdl")
    root = rdlc.elaborate()
except RDLCompileError:
    sys.exit(1)

exporter = UVMExporter()
exporter.export(root, "test.sv")