Simulation Runner
The run_simulation() function is the unified entry point for launching cocotb
simulations. It handles library compilation, caching, elaboration, waveform
generation, and test execution across all supported simulator backends.
Usage
from routertl.sim import run_simulation
run_simulation(
top_level="edge_detector",
module="test_edge_detector",
generics={"DATA_WIDTH": 32},
simulator="nvc",
waves=True,
)
API Reference
def run_simulation(
top_level: str,
module: str,
generics: dict | None = None,
simulator: str | None = None,
waves: bool = True,
wave_formats: list[str] | None = None,
waves_dir: str | None = None,
logs_dir: str | None = None,
test_args: list[str] | None = None,
custom_libraries: dict | None = None,
extra_env: dict | None = None,
) -> None:
Module location:
routertl_core.sim.simulation(proxy atsim.cocotb.engine.simulationfor backward compatibility)