Problem with 3D crashing pcbnew

Software:
pcbnew build (2013-jul-07)-stable
freecad revision 0.16
XUbuntu 14.04, 64-bit

I started with a PCB that has a lot of custom components on it, most of which don’t have 3D models. I need to send a model off to the case guy, so I’m suddenly motivated.

I poke View -> 3D Display. After a pause, I get a 3D display of the board with lots of components not installed.

I made a fairly simple model in FreeCad, exported it as .wrl, set that model as belonging to a component. Fortunately I hadn’t done this before so I just did one.

Then to see my work I poked View -> 3D Display. After a pause, pcbnew crashed.

Doing this from the command line gives me the oh-so-informative message “Segmentation fault (core dumped)”

So – clues? Clues? Clues for the clueless?

Update: I tried using meshconv to scrub the files from KiCad, inspired by this tutorial: http://happyrobotlabs.com/posts/tutorials/tutorial-3d-kicad-parts-using-openscad-and-wings3d/

The KiCad files (both .step and .wrl) crashed meshconv. So – not much joy here.

Hi @Tim_Wescott
EDIT you are using a quite OLD version of Kicad…
Please consider to use latest stable release 4.0.2 (released in February 2016)
Anyway … if you are planning to use STEP MCAD models, there is a consolidated road to use them also fine with old 4022 stable release…
please have a look here for the STEP mechanical exporter


and here for a lot of library models already tested for kicad

and some ready to go 3D libs


3D kicad libraries List:
Resistors_SMD.3dshapes
Capacitors_SMD.3dshapes
Capacitors_Tantalum_SMD.3dshapes
Housing_SOIC.3dshapes
Housings_QFP.3dshapes

Maurice

1 Like

Thanks Maul – I hadn’t realized that there was a new stable release.

Would you happen to know if it’s made it to Ubuntu 16.04? Depending on the app, trying to upgrade outside of the official path sometimes works under Ubuntu and sometimes fails in an extraordinary miserable way. I may need to upgrade 'buntu.

have a look here:


I think it should be fine in 16.04

There are many bugs in the legacy parsers, but in general the VRML output from Maui’s scripts should be fine. The development branch has new model parsers (which hopefully don’t have any bugs) and the 3D models are now handled by plugins. The next stable release (whenever that happens) will have the new model parsers, a new 3DViewer, and even the ability to use IGES/STEP models directly in the 3DViewer (no more need for VRML).

If you can build software and would like to play with the latest toys, the branch with a new 3DViewer (uses the plugin system) is here:
https://code.launchpad.net/~mrluzeiro/kicad/kicad_new3d-viewer

and the IGES/STEP plugin is here:

The main development branch has the 3D plugins but still has the older 3DViewer which can’t actually use the data from those plugins.

Are you sure, the KiCad blog at http://kicad-pcb.org/post/in-development-3d-plugins/ says that the new 3D viewer was merged into Nightlies inn 6664.
I am using Nightlies on a 16.04 machine successfully
There should be no need to build your own.

The post says the new 3D plugins were merged; at the bottom of the post you can see it stated that you need to use Mario’s newer 3DViewer, which is still in development, if you want to see the plugin data displayed in 3DViewer. The current 3DViewer still uses the legacy parsers so it will still segfault on many good files or fail to correctly display some valid files.

For MSWin users there is a nightly build of the new 3DViewer branch:
http://downloads.kicad-pcb.org/windows/testing/kicad_new3d-viewer/

I didn’t ask for any nightly build for any type of Linux since it is relatively easy to configure/build/install on those systems. I didn’t request any OSX builds either since there are very few OSX devs and I don’t want to add to their work at this stage.

@Tim_Wescott
please consider that if you use the latest develop branch or the latest 3d-viewer branch, at this time, both of build have environment variable support broken, particularly if they are assigned as system variables. They are honored only if set as internal kicad variable. That misbehavior should be fixed I hope asap… (tested with KISYS3DMOD and KIPRJMOD)
Maurice

2 Likes

Hmmm, I can see why this needs to be fixed before a 4.1.0 release then

@davidsrsb
this is affecting only develop releases … anyway it should be fixed asap IMO :smiley:

I forgot about that. The patches have been submitted over a month ago but I suspect Wayne has forgotten. I’ll nag him when he’s back from holidays.

@maul:

Actually, I was asking if it’d work with 14.04. Yes, I need to get around to upgrading my distro.

At any rate, I uninstalled the native Ubuntu version and installed the latest stable version, and the wrl files produced by FreeCAD don’t crash the viewer. They don’t seem to show up at all, but they don’t crash the viewer.

I’m drifting off topic here – but is there a good tutorial on how to make 3D models and have them work in version 4.02-stable?

Hi @Tim_Wescott
have you tried the wrl at these libraries?


3D kicad libraries List:
ResistorsSMD.3dshapes
CapacitorsSMD.3dshapes
CapacitorsTantalum_SMD.3dshapes
HousingSOIC.3dshapes
HousingsQFP.3dshapes
are you working with 4.0.2 stable?
they should be fine with the stable release…
moreover you can have a look at kicad StepUp… inside the StepUp tools there is a button (function) to export FC 3D models to kicad wrl compatible with stable and dev branches…

please let me know if you have any issues…
Maurice
Fixed thanx @Rene_Poschl :smiley:

14.04 is still the most recent Ubuntu LTS and will be until 16.04.1 happens in a few months.
I use it on a few PCs, some with 4.0.2 and one Nightly

No problems