mirror of
https://github.com/TinyTapeout/tt-support-tools.git
synced 2026-11-03 04:36:09 +01:00
fix: broken GL verification
This commit is contained in:
+3
-9
@@ -11,21 +11,15 @@ class CaravelConfig():
|
||||
self.script_dir = os.path.dirname(os.path.realpath(__file__))
|
||||
self.modules_yaml_name = modules_yaml_name
|
||||
|
||||
# instantiate inside user_project_wrapper
|
||||
def instantiate(self):
|
||||
# build the blackbox_project_includes.v file - used for blackboxing when building the GDS
|
||||
with open('verilog/blackbox_project_includes.v', 'w') as fh:
|
||||
for project in self.projects:
|
||||
fh.write(f'`include "gl/{project.get_gl_verilog_filename()}"\n')
|
||||
|
||||
# build GL includes
|
||||
def write_gl_config(self):
|
||||
with open('verilog/includes/includes.gl.caravel_user_project', 'w') as fh:
|
||||
fh.write('-v $(USER_PROJECT_VERILOG)/gl/user_project_wrapper.v\n')
|
||||
fh.write('-v $(USER_PROJECT_VERILOG)/gl/tt_ctrl.v\n')
|
||||
fh.write('-v $(USER_PROJECT_VERILOG)/gl/tt_mux.v\n')
|
||||
for project in self.projects:
|
||||
fh.write(f'-v $(USER_PROJECT_VERILOG)/gl/{project.get_gl_verilog_filename()}\n')
|
||||
fh.write(f'-v $(USER_PROJECT_VERILOG)/../projects/{project.top_module}/{project.get_gl_verilog_filename()}\n')
|
||||
|
||||
def configure_mux(self):
|
||||
with open(self.modules_yaml_name, 'r') as modules_file:
|
||||
module_config = yaml.safe_load(modules_file)
|
||||
configured_macros = set(map(lambda mod: mod['name'], module_config['modules']))
|
||||
|
||||
+4
-2
@@ -25,7 +25,7 @@ class Projects():
|
||||
os.makedirs(self.project_dir)
|
||||
|
||||
self.projects = []
|
||||
project_list = [entry for entry in os.listdir(self.project_dir) if os.path.join(self.project_dir, entry)]
|
||||
project_list = [entry for entry in os.listdir(self.project_dir) if os.path.isdir(os.path.join(self.project_dir, entry))]
|
||||
if args.test:
|
||||
project_list = ['tt_um_factory_test']
|
||||
elif args.sta_projects:
|
||||
@@ -209,7 +209,9 @@ if __name__ == '__main__':
|
||||
projects.build_metrics()
|
||||
|
||||
if args.update_caravel:
|
||||
caravel.instantiate()
|
||||
caravel.configure_mux()
|
||||
if args.test:
|
||||
caravel.write_gl_config()
|
||||
rom.write_rom()
|
||||
if not args.test:
|
||||
docs.build_index()
|
||||
|
||||
Reference in New Issue
Block a user