Closed duckyb closed 2 years ago
Hi @duckyb ! Just my 2 cents, I think this is a rounding issue, I tried using my fork of PcbDraw and got correct bounds. Note that my fork is just an stable PcbDraw with the fix for the rounding issue. You won't see the rounding issue in the PCB file, the main problem is in the SVG exporter, PcbDraw uses the output of the SVG Plotter. With the patch applied you'll get correct borders.
Hi set-soft,
Is your fork available?
I couldn't find it in the list of forks.
If you could share it, that would be much appreciated.
Is your fork this one? https://github.com/INTI-CMNB/PcbDraw
Cheers! Alaa
@set-soft Thank you for looking into this for us. We've tried your fork too and it worked. It's a shame that this fix isn't part of kikit's dockers but we'll use the fork for now.
BTW @duckyb and @AlaaSaadAbdo the patched PcbDraw is used for KiBot and is available in its GitHub Action and docker images are available. Lamentably I didn't have the time to include KiKit, but is in my TODO list.
Hi, KiKit's docker always includes the latest released version of PcbDraw.
PcbDraw code has changed a lot before this bug was reported, unfortunately. For the sake of simplicity of maintenance, I only move forward, and I don't track divergent branches for patching existing releases. Since the code brings a lot of breaking changes, it has to be a major release. Nevertheless, I didn't manage to release it on schedule (end of June).
The v1 release of PcbDraw is near (I hope in a couple of months). What's left is a tool to manage its library. Version 1 fixes some of the technical debt we had and also allows for custom plot layouts, and it can even export rendered pictures of the board.
PS: I think the fix introduced in INTI-CMNB/PcbDraw doesn't work with boards that KiKit produces as the tolerance is too large, and it skips segments and, therefore, again yields wrongly filled boards. The proper fix is to take the closest point within a tolerance, not any point within a tolerance.
FYI: v1 was released.
This is a follow up of: #96
Sometimes PcbDraw fails to render the Edge.Cuts layer correctly. This seems to be unrelated to the Edge.Cuts tolerance threshold, and more likely to happen with Kicad 6 files.
First Example
PCB File: battoota.zip
PcbDraw output:
Tolerances
This time the issue doesn't seem to come from the edge.cuts tolerance, as we can see from the raw file that all segments start/end match exactly:
Second Example
I have also noticed that on some PCB files, the issue appears after upgrading the file to Kicad 6. Here is an example of that.
PCB File (kicad 5): paroxysm_left.zip
BEFORE upgrading to Kicad 6
AFTER upgrading to Kicad 6
cc: @AlaaSaadAbdo