Added reverse arg fix, tests working
[pinmux.git] / src / pinmux_generator.py
index 0cf35b5d540bf7429037786b8d2aed148b635d45..896c3293477bc0f990d1d67643a81e96adcb61c3 100644 (file)
@@ -22,7 +22,7 @@ import sys
 import json
 from spec import modules, specgen, dummytest
 from spec.ifaceprint import create_sv, temp_create_sv
-
+import jsoncreate
 
 def printhelp():
     print ('''pinmux_generator.py [-o outputdir] [-v|--validate] [-h|--help]
@@ -98,16 +98,19 @@ if __name__ == '__main__':
                     specgen(of, output_dir, pinout,
                             bankspec, ps.muxwidths, pin_spec, fixedpins,
                             ps.fastbus)
-                pm, chip = module.pinparse(ps, pinspec)
+                pm, chip = jsoncreate.pinparse(ps, pinspec)
                 litexmap = ps.pywrite(pyf, pm)
                 jchip = json.dumps(chip)
                 with open("%s/litex_pinpads.json" % pinspec, "w") as f:
                     f.write(jchip)
-                # TODO: fix create_sv to allow different packages (and die images)                
-                # Test with different package size, once working 'create_sv' will be improved                
+                # octavius: please keep line-lengths to below 80 chars
+                # TODO: fix create_sv to allow different packages
+                # (and die images)
+                # Test with different package size, once working
+                # 'create_sv' will be improved
                 if pinspec == "ngi_router":
-                    temp_create_sv("%s/%s.svg" % (pinspec, pinspec), chip)                
-                else:
+                    temp_create_sv("%s/%s.svg" % (pinspec, pinspec), chip)
+                if pinspec == "ls180":
                     create_sv("%s/%s.svg" % (pinspec, pinspec), chip)
     else:
         if output_type == 'bsv':