Skip to content

Commit

Permalink
feat: preliminary openframe support
Browse files Browse the repository at this point in the history
  • Loading branch information
urish committed Nov 2, 2023
1 parent 98e7cb2 commit c7ae4dd
Showing 1 changed file with 11 additions and 7 deletions.
18 changes: 11 additions & 7 deletions shuttle.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,10 @@ def __init__(self, config, projects, modules_yaml_name: str):
self.projects = projects
self.script_dir = os.path.dirname(os.path.realpath(__file__))
self.modules_yaml_name = modules_yaml_name
if config.get("openframe", False):
self.tt_top_macro = "openframe_project_wrapper"
else:
self.tt_top_macro = "user_project_wrapper"

def configure_mux(self):
with open(self.modules_yaml_name, "r") as modules_file:
Expand Down Expand Up @@ -172,7 +176,7 @@ def copy_final_results(self):
logging.info("copying final results:")
for macro in macros:
lastrun = self.find_last_run(macro)
macro_name = macro if macro != "tt_top" else "user_project_wrapper"
macro_name = macro if macro != "tt_top" else self.tt_top_macro
logging.info(f"** {macro_name} **")
logging.info(f" FROM {lastrun}")
copy_print(f"{lastrun}/final/gds/{macro_name}.gds", f"gds/{macro_name}.gds")
Expand Down Expand Up @@ -211,14 +215,14 @@ def create_efabless_submission(self):
copy_print("shuttle_index.json", "efabless/shuttle_index.json")
copy_print("verilog/rtl/user_defines.v", "efabless/verilog/rtl/user_defines.v")
copy_print(
f"{lastrun}/final/pnl/user_project_wrapper.pnl.v",
f"efabless/verilog/gl/user_project_wrapper.v",
f"{lastrun}/final/pnl/{self.tt_top_macro}.pnl.v",
f"efabless/verilog/gl/{self.tt_top_macro}.v",
)
copy_print(
f"{lastrun}/final/gds/user_project_wrapper.gds",
f"efabless/gds/user_project_wrapper.gds",
f"{lastrun}/final/gds/{self.tt_top_macro}.gds",
f"efabless/gds/{self.tt_top_macro}.gds",
)
copy_print(
f"{lastrun}/final/lef/user_project_wrapper.lef",
f"efabless/lef/user_project_wrapper.lef",
f"{lastrun}/final/lef/{self.tt_top_macro}.lef",
f"efabless/lef/{self.tt_top_macro}.lef",
)

0 comments on commit c7ae4dd

Please sign in to comment.