Closed loiiiic closed 2 years ago
@loiiiic 1) I'm not sure if it can be the culprit, but could you remove the last slash '/' at the end of the first field '/usr/share/kicad/3dmodels/' 2) it could be a permissions issue... can FC access and read those 3D models? (i.e. import a 3d model manually using FC?) or even better testing with some python command like:
import FreeCAD import ImportGui FreeCAD.newDocument("Unnamed") FreeCAD.ActiveDocument=FreeCAD.getDocument("Unnamed") ImportGui.insert('/usr/share/kicad/3dmodels/Resistor_SMD.3dshapes/R_0805_2012Metric.step',FreeCAD.ActiveDocument.Name)
Hi @easyw ,
Thank you for your quick answer.
However, there are read rights on the folder 3dmodels:
ls -l
drwxr-xr-x 91 root root 4096 juin 24 14:50 3dmodels
This is what I get with the Python commands :
>>> import FreeCAD
>>> import ImportGui
>>> FreeCAD.newDocument("Unnamed")
<Document object at 0x55f6ce9dd020>
>>> # App.setActiveDocument("Unnamed")
>>> # App.ActiveDocument=App.getDocument("Unnamed")
>>> # Gui.ActiveDocument=Gui.getDocument("Unnamed")
>>> FreeCAD.ActiveDocument=FreeCAD.getDocument("Unnamed")
>>> ImportGui.insert('/usr/share/kicad/3dmodels/Resistor_SMD.3dshapes/R_0805_2012Metric.step',FreeCAD.ActiveDocument.Name)
Traceback (most recent call last):
File "<input>", line 1, in <module>
OSError: cannot read STEP file
@loiiiic this seems an issue in how FC can read the folders (is FC installed or AppImage or Flatpack?) or an issue in kicad installation process... Can you read/access the '/usr/share/kicad/3dmodels/Resistor_SMD.3dshapes/R_0805_2012Metric.step' i.e. in a text editor?
If I click on the three small dots to look for the path, the kicad folder is not present in the window
that is strange
can you i.e.
ls /usr/share/kicad/3dmodels/Resistor_SMD.3dshapes/R_0805_2012Metric.step
@easyw
I can open /usr/share/kicad/3dmodels/Resistor_SMD.3dshapes/R_0805_2012Metric.step with a text editor.
Freecad was installed via Flatpak (version 0.20).
I just installed it via apt (version 0.19) and it works.
thanks for your feedback... it seems an issue of flatpack then may you try FC0.20 via AppImage? https://github.com/FreeCAD/FreeCAD/releases/download/0.20/FreeCAD-0.20.0-Linux-x86_64.AppImage
@easyw
It is working with the AppImage, I will stay with the AppImage.
Thank you for your help and for your addon! :-)
Hello,
When using the "Load board" function with a *.kicad_pcb file (KiCad 6), the 3D models of the components are not found. I get this error :
I set up the path like this in FreeCad:
If I copy the 3dmodels folder from /usr/share/kicad to /home/loiiiic/Documents/ and declare the paths below, it works. There is something I don't understand.
Thank you for your feedback.