Pcbnew crash when trying to fill a zone or reload the pcb-file

Hi,
I draw a zone. Next I wanted to fill it. A popup-window with a progress bar appeared saying “updating netlist” and then Kicad/pcbnew crashed. When I want to re-open the layout/artwork, pcbnew always crashs immediately (but only on that file, in which I tried the zone-fill).

I also started kicad and pcbnew from the terminal to check any error-messages on the terminal. When the crash happens, I get the message “memory access violations”.

System: Arch Linux;
Kicad Version: 4.0.2

Open the kicad_pcb file with a text editor…
Search for entries like:
(zone (net ...
In that bracket look for this piece and delete it completely:
(filled_polygon ... )

After that your kicad_pcb file should be able to load again, just refrain from filling it right away - something must be wrong with the zone.

As for how to solve your problem you have to check the zone you have drawn up and maybe give us a look at the file if you don’t get it sorted.
Might also be unique to the OS/Kicad version you’re using… no idea.

Joan,
thanks for your reply.
Your adivce helps be to recover the pcb-file. Anyhow, the problem itself still remains.
Each time, when I use the command “fill all zones”, pcb crashs.
It crashs independently of the schematic/netlist.
Even if I have just two resistors and draw somewhere the zone, after “fill all zones” pcb crashs.

My felling is: the netlist is fine … it must be an issue that my pcbnew-program has problems with my Arch Linux.

BTW: when I start pcb-new or kicad, I am getting following message (but I do not know, if that has any realation to my zone-fill problem:

14:33:53: Warning: Mismatch between the program and library build versions detected.
The library used 3.0 (wchar_t,compiler with C++ ABI 1009,wx containers,compatible with 2.8),
and your program used 3.0 (wchar_t,compiler with C++ ABI 1010,wx containers,compatible with 2.8).

One thing is very confusing:
When a make a totally new KiCad project (e.g. just two resistors), the issue happens;
When I am loading an old KiCad project with an already existing filled zone, a refill of the zone works;

I was further playing around with the issue:

When I am drawing a fill-zone. Nothing happens. But when I try to fill it, pcbnew crashs; When I re-start pcbnew, it crashs each time when it loads the pcb-file.

When I am drawing a fill-zone, but leave the fill-zone empty, I can save the pcb-file. But when I close and restart pcbnew, I cannot open the pcb-file wihout crashing pcbnew (even I never did the fill-option).

Note: I wanted to upload the pcb-file but this forum doesn’t allow me uploads because I am a new user.
Note: When I am adding in an old project a zone and fill it there is no pop-up window “updating netlist” … but when I add a zone in a new project, this pop-up window “updating netlist” comes up.

Just something to try - does your design have any netlists at all ?
If not, try adding some.
I recall a CPLD tool we used, worked fine in all real cases, but crashed if given a design with zero nett pins out.

Do you know if you happened to be in the Legacy or GAL display modes? Does the fill=crash problem happen also in the other mode?

Regarding having a netlist:
Sure. with eeschema I made a schematic with 2 resistors and a global label; With CVPCB I assigned the “hardware”. All this, I saved as *.net file, which I load to PCBnew.

Regarding Legacy or GAL display modes:
Although I googled “GAL display mode”, I have no glue what this is and how to change to it. Can somebody let me know, where/how I can change this (my os: Arch Linux)

pcbnew… menu > view > … should be able to select the canvas method.

As for the underlying problem - can’t help, me = not a Linux user
You could try to use some older (or newer version if available = nightly) of the program, unless you need a feature of the latest stable version?

Did you check for “Arch” as search if there are others with similar problems yet?

I was maybe unclear - I meant actual NET names in the design as valid connections.
The point was that having no valid nets at all, may go more into untested territory, and the Pour operations do scan the net-names, and check against the net-name allocated to the outline polygon.

Another detail to check , is to be careful to create a closed polygon. ie No gaps or overlaps. (A coarse grid helps there)
If a design with valid nets and a carefully closed (simple) polygon still has issues, then I’d try a working PCB load, and throw stuff overboard until it breaks.
Compare the ASCII PCB files, and see where the difference lies.

I think the poster meant under View, F9,F11,F12 change ‘canvas’, which actually changes quite a lot of core software.
(eg Shove router is only under OpenGL)

OpenGL mode has better polyline editing, as the ends/mid points are tagged and become mouse-moveable.

I have three options in the menu-> view:
Switch Canvas to Legacy --> I think, this is the mode I have upon start-up;
Switch Canvas to OpenGL -> when I do this, the program freezes and I have to do a reboot
Switch Canvas to Cairo -> here I can draw a fill-zone, but I don’t get a menu anymore with the right mouse button. Also, the shortcut such as Ctrl-B is not working. So I cannot initiated the fill-zone command. And when I want to change back to “Legacy”, PCBnew crashs. If I stay in "Cairo, save the file and re-open PCBnew, PCBnew crashs as well (I assume, since it starts in “Legacy” mode by default).

Sounds like maybe a fresh install is needed. Is that even with no design loaded ?
Do you have any other OS PCs about, you can do a quick sanity check on ?

Indeed, the schematic is very stupid (just two resistors in serial, and a global label named GND, which is attached to on of the resistors).
When I want to great the fill-zone, I am getting

GND
Net-(R101-Pad2)

KiCad crashs in all three cases (=regardless which net I chose for the fill-zone). Even in the case, which should result in “pure” copper field.

As mentioned, I can work on older pcb-files which already have a zone. In those files, I can add and fill also new zones without any problems. Of course, I already compared the the “working” and “crashing” PCB-files (ASCII), but I could not find any explanation for my crashes.

I re-installed KiCad in the meantime 3x!
2x out of the Arch-Linux repository
1x directly downloaded from Git-Hub (which took hours to compile)

I have only Arch-Linux computers here. I am now installing Arch-Linux on an old laptop, and I will try if the problem happens there as well.

It could be an OpenGL related problem. The 4.0.3 bugfix release will hopefully be out within 2 weeks and with some luck the problem may have been fixed; there has been some work lately fixing OpenGL related issues.

1 Like

If it is highly predictable and stable on existing files, then clearly there is something about the file that triggers it,
If you have already tried installs, suggest take an older design,and remove items until it is closest, data count wise, to the problem file & confirm ‘ok’ at each removal.

If you get to the stage where they are (nominally) the same and del/save/load/create is also ok, then the next step is to start Successive-Approximation-slice of the two files.
ie take the ‘top’ of the good one, combined with the ‘bottom’ of the bad one, and check, and vice versa. Repeat as you zoom in to the trigger lines.

1 Like

On the laptop (same OS, same KiCad), the problem is the same.
The only difference: changing to OpenGL doesn’t freeze the laptop … but when I change back to default, it crashs … and I have to change back to default, because under OpenGL i have no right-mouse button nor the short-cuts (so I cannot do a fill).

2,5 days just for that problem … that’s far too much waste of a time …

And to “work down” based on an old schematic which works will be also a “hell of work”, because it is a hierachical schematic, with many sub-schematics … to do this all from new … oh man…

And to wait 2 weeks, with still the risk that it isn’t working is pure gambling …
And a forum, which even doesn’t allow me to upload anythink to explain the issue more effizient also is strange.

Pls. excuse that I am frustrated … perhaps my words aren’t fair … I mean it is open software, for free … I should take a break and “cool down”. Sorry again.

1 Like

Did you post the offending file yet, with the exact trigger condition ?

In all View modes, I find Tools.DRC always floods, so you do not need short cuts.

Does the upload button not work for your posting ? Not sure what the triggers for that are, mine seemed to just work ?

There are simple templates you can start with, eg on my Win-8 install they are
C:\Program Files\KiCad\share\kicad\template
there are a ~dozen simple connector grids - just one page.

ie File.NewProject,New Project From Template (^T) expects destination name, then offers a choice of those seed blocks.

On my system, I can Flood (File.NewProject & Tools.DRC) just fine with
*Closed rectangle + 2 SO14 and no connections.
*Closed rectangle + 1 SO14 and no connections.
*Closed rectangle + 0 SO14 and no connections.
Checked & works in all 3 View modes, and works from either ‘B’ or Tools.DRC

I cannot think of more minimal than that ?

1 Like