def make_machine(machine): print("boms.py:") boms(machine) print("sheets.py:") sheets(machine) print("stls.py:") stls(machine)
def main(out_path: str = "", out_path_scripts: str = ""): sheet = sheets() sheetName = "Persons" dataClassName = "Person" personHeader, personTypes = sheet.GetHeaderAndTypes(sheetName) persons = sheet.GetTableDic(sheetName, personHeader, personTypes) with open(out_path + sheetName + '.json', 'wt', encoding='utf-8') as file: to = {sheetName: list(persons[id] for id in sorted(persons.keys()))} json.dump(to, file, ensure_ascii=False, indent=2, sort_keys=True) with open(out_path_scripts + dataClassName + 'StaticData.cs', 'wt', encoding='utf-8') as file: to = tools.CreateDataScript(dataClassName, personHeader, personTypes) file.write(to) with open(out_path_scripts + sheetName + 'StaticModel.cs', 'wt', encoding='utf-8') as file: to = tools.CreateModelScript(sheetName, dataClassName, sheetName) file.write(to)
def make_machine(machine): boms(machine) sheets(machine) stls(machine) plates(machine)
def make_machine(machine): boms(machine) sheets(machine) stls(machine) accessories(machine) plates(machine)
dxf_name = base_name + ".dxf" openscad.run("-o", dxf_name, dxf_maker_name) # # Make SVG drill template # dxf_to_svg(dxf_name) # # Make PDF for printing # InkCL.run("-f", base_name + ".svg", "-A", base_name + ".pdf") if __name__ == '__main__': if len(sys.argv) > 1: sheets(sys.argv[1]) else: print "usage: sheets [mendel|sturdy|your_machine]" sys.exit(1) ########NEW FILE######## __FILENAME__ = stls #!/usr/bin/env python import os import openscad import shutil import sys import c14n_stl source_dir = "scad"
# base_name = target_dir + "/" + module[:-4] dxf_name = base_name + ".dxf" openscad.run("-o", dxf_name, dxf_maker_name) # # Make SVG drill template # dxf_to_svg(dxf_name) # # Make PDF for printing # InkCL.run("-f", base_name + ".svg", "-A", base_name + ".pdf") if __name__ == '__main__': if len(sys.argv) > 1: sheets(sys.argv[1]) else: print "usage: sheets [mendel|sturdy|your_machine]" sys.exit(1) ########NEW FILE######## __FILENAME__ = stls #!/usr/bin/env python import os import openscad import shutil import sys import c14n_stl source_dir = "scad"