[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: gEDA-user: Layer selective DRC



Kai-Martin Knaak wrote:

> Just tried it and it works great :-)

I was a victim of wishfull thinking. Seems like I did not set the 
attribute successfully. As a result, the no_drc code path was not 
entered at all. I must have fooled myself with settings.


> For the archive: Syntax in the *.pcb file is: 
>         Attribute("PCB" "skip-drc")

The correct syntax is:
	Attribute("PCB::skip-drc" "1")
The value of the attribute is not evaluated at all. So in stead 
of "1" it could be anything.

Unfortunately, current git head of PCB enters an infinite loop if
the attribute is set correctly. The attached patch fixes this bug.
Now, DRC does indeed ignore the layers marked by the attribute. 
( I triple checked ;-)

However, there is still room for improvement:
It is impossible to start a line on copper of the marked layer if 
auto-enforce-DRC is set. The GUI behaves like there is some rule
in place that prevents connection. Probably, there needs to be 
another check for no_drc at some place in the algorithm. 

By the way, what is the reason for the funny attribute name 
with two colons in the middle? The source treats it just like 
a plain string.

---<)kaimartin(>---
-- 
Kai-Martin Knaak
Email: kmk@xxxxxxxxxxxxxxx
http://pool.sks-keyservers.net:11371/pks/lookup?search=0x6C0B9F53
not happy with moderation of geda-user
From 7f19684ff639cca072600e4eda1ce5461708c506 Mon Sep 17 00:00:00 2001
From: Kai-Martin Knaak <kmk@xxxxxxxxxxxx>
Date: Fri, 5 Aug 2011 04:11:40 +0200
Subject: [PATCH] fix infinite loop on skip-drc

---
 src/find.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/src/find.c b/src/find.c
index 92c8b35..380412e 100644
--- a/src/find.c
+++ b/src/find.c
@@ -1172,7 +1172,13 @@ LookupPVConnectionsToLOList (bool AndRats)
   for (layer = 0; layer < max_copper_layer; layer++)
     {
       if (LAYER_PTR (layer)->no_drc)
+        {
+          LineList[layer].Location = LineList[layer].Number;
+          ArcList[layer].Location = ArcList[layer].Number;
+          PolygonList[layer].Location = PolygonList[layer].Number;
                        continue;
+         }
+
       /* do nothing if there are no PV's */
       if (TotalP + TotalV == 0)
         {
-- 
1.7.5.4



_______________________________________________
geda-user mailing list
geda-user@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-user