Merging imported KiCad file with step model

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
Post Reply
Kampi
Posts: 3
Joined: Wed Jun 03, 2020 6:39 pm

Merging imported KiCad file with step model

Post by Kampi »

Hello,

I have a PCB that is imported from a "wrl" file which is generated by KiCad and a battery that is imported as a step model. I create a project for each of the parts and combine the projects. Now I want to create a new part which is the PCB and the battery together, so I create a new assembly, add a part and move the battery inside of the part. I want to do the same for the PCB, but I can´t move the PCB into the part.

I use the following version:

OS: Windows 10
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.18.4 (GitTag)
Build type: Release
Branch: releases/FreeCAD-0-18
Hash: 980bf9060e28555fecd9e3462f68ca74007b70f8
Python version: 3.6.6
Qt version: 5.6.2
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: German/Germany (de_DE)

So what is wrong with the PCB and how can I combine them?

Note:
I can not import the PCB directly with KiCadSetUp, because I don´t have all 3D models for the PCBNew project.
Error.png
Error.png (9.06 KiB) Viewed 1271 times
Thanks
User avatar
Gregory son of Carl
Posts: 99
Joined: Mon Apr 06, 2020 7:42 pm
Location: California

Re: Merging imported KiCad file with step model

Post by Gregory son of Carl »

Based on your picture, the pcb boad and battery actually are both inside your part container (yellow). If you want both objects inside the body (blue) then you will need to use the boolean tool from the Part Design workbench.
Kampi
Posts: 3
Joined: Wed Jun 03, 2020 6:39 pm

Re: Merging imported KiCad file with step model

Post by Kampi »

Hello,

thank you for your answer. I will get this error when I want to do this operation.
Error.png
Error.png (9.58 KiB) Viewed 1229 times
User avatar
Gregory son of Carl
Posts: 99
Joined: Mon Apr 06, 2020 7:42 pm
Location: California

Re: Merging imported KiCad file with step model

Post by Gregory son of Carl »

I see. It looks like wrl files are similar to stl files which are generally ill suited for parametric modeling because the faces, edges, and volume can't be referenced easily. The result is that most CAD tools don't work on them. If you can export your pcb board from KiCad as a step model then you should be able to boolean no problem.

Another option is to select both the battery step and pcb board wrl and export both as a wrl from FreeCAD. That should have the same effect of combining both models.
User avatar
roerich_64
Veteran
Posts: 1465
Joined: Thu May 21, 2015 7:00 pm
Location: Ostfriesland

Re: Merging imported KiCad file with step model

Post by roerich_64 »

Hi Kampi,

you should take an eye at KiCAD-StepUp Workbench ;)

BR
Walter
Die Liebe wird siegen, denn sie ist unzerstörbar :) ;)
Kampi
Posts: 3
Joined: Wed Jun 03, 2020 6:39 pm

Re: Merging imported KiCad file with step model

Post by Kampi »

Gregory son of Carl wrote: Thu Jun 04, 2020 5:55 pm If you can export your pcb board from KiCad as a step model then you should be able to boolean no problem.
Yeah, but I loose many details when I use a step file. Anyway, thank you for your help. I check it with both wrl files and/or KiCad StepUp. The problem with StepUp are some errors when I use KiCad 3D models which only exist as wrl files. So I have to fix this.
daddyzaur
Posts: 16
Joined: Thu Jun 04, 2020 6:21 pm

Re: Merging imported KiCad file with step model

Post by daddyzaur »

Hello Kampy, I loaded a LibreOffice HOWO file I am using to collect tips for my personal use with FreeCAD and KiCAD: http://www.daddyzaur.com/?p=231
You have there the description, step-by-step how to create 3d models with matching PCB footprints in FreeCAD and how to export and load them in KiCAD. The most important tool for this task is the kicadStepUpMod workbench.
Check those chapters:
.
3D Footprint Creation for KiCAD PCB
Assign a 3D FreeCAD model to a KiCAD footprint in 7 easy steps
Step6: Align the STEP model to the PCB footprint
.
Be aware, FreeCAD is not loading and saving STEP models, it cannot do it. Instead it is "importing" and "exporting" some components to/from STEP and FreeCAD formats. It is a very important difference: you MUST always import/export your work, NEVER load/save !!!
.
It is very much impossible to process FreeCAD type files back and forth trough various external tools and addons: the body parts will be scrambled in every witch way. We must select all project component end export them to a STEP container project "InSOP-24D.step". FreeCAD model files are not compatible with any other tool, only FreeCAD can handle its own models. The acceptable way to transfer a FreeCAD project to a 3D KiCAD PCB footprint is trough a "STEP with colors" file model. The parts that are incompatible with STEP models are going to simply be discarded. In any case, those parts are not needed outside FreeCAD, and the original FreeCAD project will remain intact.
.
FreeCAD_PCB_003.png
FreeCAD_PCB_003.png (80.49 KiB) Viewed 1162 times
FreeCAD_PCB_002.png
FreeCAD_PCB_002.png (141.46 KiB) Viewed 1162 times
FreeCAD_PCB_001.png
FreeCAD_PCB_001.png (126.71 KiB) Viewed 1162 times
Post Reply