X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=src%2Fpinmux_generator.py;h=b95377b4bad5d00485b4ed2c9fac5d56c8305b0a;hb=a51649d0ae94dd90f292892f09ed66c0e181c1d4;hp=42a9381e2409cc4f51a4bc767319ea2dbc5406c3;hpb=f4c61ad1224b12e76e20b899b4a9a02034355ce5;p=pinmux.git diff --git a/src/pinmux_generator.py b/src/pinmux_generator.py index 42a9381..b95377b 100644 --- a/src/pinmux_generator.py +++ b/src/pinmux_generator.py @@ -21,9 +21,6 @@ import os.path import sys from spec import modules, specgen, dummytest -from bsv.pinmux_generator import pinmuxgen as bsvgen -from myhdl.pinmux_generator import pinmuxgen as myhdlgen - def printhelp(): print ('''pinmux_generator.py [-o outputdir] [-v|--validate] [-h|--help] @@ -93,11 +90,16 @@ if __name__ == '__main__': if testing: dummytest(ps, output_dir, output_type) else: - specgen(of, output_dir, pinout, bankspec, pinspec, fixedpins) + specgen(of, output_dir, pinout, + bankspec, ps.muxwidths, pinspec, fixedpins, ps.fastbus) else: - gentypes = {'bsv': bsvgen, 'myhdl': myhdlgen} - if output_type not in gentypes: + if output_type == 'bsv': + from bsv.pinmux_generator import pinmuxgen as gentypes + elif output_type == 'myhdl': + from myhdlgen.pinmux_generator import pinmuxgen as gentypes + else: print ("ERROR: output type '%s' does not exist" % output_type) printhelp() sys.exit(0) - gentypes[output_type](output_dir, validate) + + gentypes(output_dir, validate)