diff --git a/.scripts/foot_gen.py b/.scripts/foot_gen.py index 179bfdb..bef59ec 100644 --- a/.scripts/foot_gen.py +++ b/.scripts/foot_gen.py @@ -162,6 +162,7 @@ for foot in saved: # Export the step file os.system("kicad-cli pcb export vrml --units 'tenths' -f --user-origin " + str(ToMM(brd_cent.x)) + "x" + str(ToMM(brd_cent.y)) + "mm -o /tmp/dummy.wrl " + sys.argv[1]) +os.system("kicad-cli pcb export step -f --subst-models --user-origin " + str(ToMM(brd_cent.x)) + "x" + str(ToMM(brd_cent.y)) + "mm -o /tmp/dummy.stp " + sys.argv[1]) # Import the 3d model of the actual PCB dummy = FOOTPRINT(pcb) @@ -179,7 +180,9 @@ pcb.Add(dummy) # Save and export step of board + mating connectors SaveBoard("test/test.kicad_pcb", pcb) final_model_path = sys.path[0] + "/../../libs/melon3d/" + foot_path + ".3dshapes/" + foot_name + ".wrl" +final_model_path_stp = sys.path[0] + "/../../libs/melon3d/" + foot_path + ".3dshapes/" + foot_name + ".stp" os.system("kicad-cli pcb export vrml -f --units 'mm' --user-origin " + str(ToMM(brd_cent.x)) + "x" + str(ToMM(brd_cent.y)) + "mm -o " + final_model_path + " test/test.kicad_pcb") +os.system("kicad-cli pcb export step -f --subst-models --user-origin " + str(ToMM(brd_cent.x)) + "x" + str(ToMM(brd_cent.y)) + "mm -o " + final_model_path_stp + " test/test.kicad_pcb") # Generate footprint