![]() Log: UserAppData = C:\Users\Henry\AppData\Roaming\FreeCAD\ Log: SystemParameter = C:\Users\Henry\AppData\Roaming\FreeCAD\system.cfg Log: PythonSearchPath = C:\Program Files\FreeCAD 0.18\bin\python36.zip C:\Program Files\FreeCAD 0.18\bin\DLLs C:\Program Files\FreeCAD 0.18\bin\lib C:\Program Files\FreeCAD 0.18\bin Log: PATH = C:\Program Files\FreeCAD 0.18\bin\Library\bin C:\Users\Henry\Anaconda3 C:\Users\Henry\Anaconda3\Library\mingw-w64\bin C:\Users\Henry\Anaconda3\Library\usr\bin C:\Users\Henry\Anaconda3\Library\bin C:\Users\Henry\Anaconda3\Scripts C:\Users\Henry\Anaconda3\bin C:\Users\Henry\Anaconda3\condabin C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1\bin C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1\libnvvp C:\WINDOWS\system32 C:\WINDOWS C:\WINDOWS\System32\Wbem C:\WINDOWS\System32\WindowsPowerShell\v1.0 C:\WINDOWS\System32\OpenSSH C:\Program Files\MATLAB\R2019a\bin C:\Program Files\NVIDIA Corporation\NVIDIA NGX C:\Program Files\MATLAB\MATLAB Runtime\v94\runtime\win64 C:\Program Files (x86)\Wolfram Research\WolframScript C:\Program Files (x86)\QuickTime\QTSystem C:\Users\Henry\AppData\Local\Microsoft\WindowsApps C:\Users\Henry\AppData\Local\Programs\MiKTeX 2.9\miktex\bin\圆4 Log: LoggingFileName = C:\Users\Henry\AppData\Roaming\FreeCAD\FreeCAD.log Log: DocPath = C:/Program Files/FreeCAD 0.18/doc\ Log: CopyrightInfo = (c) Juergen Riegel, Werner Mayer, Yorik van Havre 2001-2019 Log: BuildRevisionBranch = releases/FreeCAD-0-18 Log: BuildRepositoryURL = git:///FreeCAD/FreeCAD.git releases/FreeCAD-0-18 Log: BinPath = C:/Program Files/FreeCAD 0.18/bin\ Log: AppTempPath = C:\Users\Henry\AppData\Local\Temp\ Log: AppHomePath = C:/Program Files/FreeCAD 0.18/ (c) Juergen Riegel, Werner Mayer, Yorik van Havre 2001-2019 Here it is: Msg: FreeCAD 0.18, Libs: 0.18R4 (GitTag) ![]() ![]() So, as suggested by I tried to change the script file to: import FreeCADīut I still did not get any cylinder. SO, I noticed that it will work, if I put the script file into the same directory as FreeCADmd.exe. It also does not give any warning or error message. The result: it just shows this on the terminal, but does not create any stl file. "C:\Program Files\FreeCAD 0.18\bin\FreeCADCmd.exe" "C:\Users\totyped\Documents\pillar.py" ![]() I closed the GUI and open the terminal, and I type: Mesh.export(_objs_,u"C:/Users/totyped/Desktop/pillar_2.stl") _objs_.append(FreeCAD.getDocument("Unnamed").getObject("Cylinder")) Here is the code: # -*- coding: utf-8 -*. I copy and paste the text from the macro into a python file, which I named "pillar.py" Recorded a macro of me creating a cylinder (Part) and exporting it as an stl file. I would like to create a simple pillar in FreeCAD using python and the export it as. Open your working folder in Code – OSS eg.To get better auto-completion you can also add reference to freecad-stubs folder below I cloned it in my home git folder with git clone. Examples below shows path for Arch/Manjaro with freecad-git installed. To allow auto-completion and your linter like pylint to work partially you need to reference FreeCAD libraries. I am very open to try another documented way if you have one to suggest ! Set up I’m not a big fan of M$ but Code – OSS is quite good and is the one I managed to set up with FreeCAD with a working debugger.
0 Comments
Leave a Reply. |