X-Authentication-Warning: delorie.com: mail set sender to geda-user-bounces using -f X-Recipient: geda-user AT delorie DOT com X-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=NWXcBBpEMiNZ1Lh4/fyyYP9eEtmby2LjWuE/NNyvq+U=; b=RB9wt2X9GgWMf+p5ms4u1DWAWm3dZN2YnUmcwCB04or1HmUFsszaHY4m8Y9jbC/x/V wbgVc7HbsVJxiTHlxjeho4jK6Jshw10ij4TbfccOkRNhTDWzeFLsDZK07v1sDrGobVyk PPMtE2U0EHCBbEnWGF4mLeQtalV09v9mmsCLZ92+o0R/YxHlU1QJIINsDFHw7AxJ3a1V SebpKgQHSgXepXEQucR30loFoBCjVyP7JqLruYof6D6fCoZqsm7ORksJ5rj3fwPIepyp P3dBf8ETpdliuH3IHeRl/h8EOtfDt6kWgshj18PK+tFKpnjUW+Cy/ICP8YqyagFeEt+4 4NeQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=NWXcBBpEMiNZ1Lh4/fyyYP9eEtmby2LjWuE/NNyvq+U=; b=Fm9OJbJs1majmECOGzuH4T3Ql7BrNNECdp6Ry7YyUhkjNJn9x4+cwYBAISe28HTzRG ZILDc9IKB7FMcXC3mb19SosWK078DFVqsY0u7/10LVi1/DHofQZ9HOga0Hq7QOUM0HDw 3bCv+6u8a9ENv0vdHoIfTQyHzUz/v9u3ckxRLapoaICz8yzEC83ifQXirvvCTXMomyis BcVmZjFpK6CZ1EXo9RJ8EsPNWnJWbm2eEaD0L4kQqb1AtPxzJlOORS0w1n3j7vI18HMe wCpu17xj2Wje0mWT6QoJ+eqdTPQnRiVtpXYdqCxLCdmrTy6+mmSpf9uGg1UEtKFfnfGe w+rg== X-Gm-Message-State: AOPr4FVr4E+oU4dS97+BPyF1ukrhz0eyVRmgQN7ZZSJBErA+yKCJNQS/v/Mkss0sHlK8Cg== X-Received: by 10.25.139.213 with SMTP id n204mr2001885lfd.161.1463781868943; Fri, 20 May 2016 15:04:28 -0700 (PDT) Date: Sat, 21 May 2016 00:04:23 +0200 From: "Nicklas Karlsson (nicklas DOT karlsson17 AT gmail DOT com) [via geda-user AT delorie DOT com]" To: Peter Clifton Cc: geda-user AT delorie DOT com Subject: [geda-user] Re: PCB DRC - Hi guys --> clearance, net class Message-Id: <20160521000423.38c536a3e48290a79bee2b11@gmail.com> In-Reply-To: References: X-Mailer: Sylpheed 3.5.0beta1 (GTK+ 2.24.25; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Reply-To: geda-user AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: geda-user AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk Had an hour more to spend on this. I also discovered I already factored out different drc calculations in sub functions. As is now pcb calculation for is called for each pin in each element. A global value is used for clearance and here a loop have to be added for each clearance value used. There need to be a function to figure out which clearance value to use, probably: global, net class, net. If I get a few more hours this weekend I should give it a try. Nicklas Karlsson On Mon, 16 May 2016 11:59:43 +0100 Peter Clifton wrote: > Hi All, (OFFLIST - to avoid general flame war and bike-shed painting!). > > > I hope things are going well with you all, this is a quick email to discuss > PCB's DRC... > > I'm currently working on a project involving some moderately sizable power > converters operating at mains voltage, which, (as you might guess) involves > a lot of regulatory compliance work regarding creepages and clearances. > > As an aid to procrastination (and to help with the work), I started > teaching the tools a few new tricks... > > gnetlist, read and track "netclass=" attributes so I can identify which > nets belong in clearance groups with chasis earth, DC-, DC+, etc... > > PCB, ability to store netclass in the netlist, and actions to set it. (This > might want to be reworked to be more general in future though). > > gnet-pcbfwd.scm, read and emit netclass settings when driven by an updated > gnetlist. > > PCB, ability to determine, for given a piece of copper, pin etc.., which > netclass it should belong to. (Currently this operation is moderately > expensive, as it uses the "find" infrastructure to back track and find > object (or X,Y) -> what is it connected to -> pins -> netlist -> nteclass). > > > I've extended the "crosshair shows DRC clearance" to be able to figure out > what netclass the lines you're drawing should belong to, and tweaked the > auto-enforce DRC to allow any additional clearance required when colliding > with objects belonging to a different netclass. Additional fields on object > structures also allow me to render this additional clearance zone around > obstacle objects as you hit them (allowing visualisation of where the > auto-enforce has hit an obstacle, or to help you route manually if > auto-enforce is turned off). > > On my short-term TODO list, is fixing the auto-enforce behaviours to work > properly for "all direction lines", and the single 45-degree lines editing > modes. (They never did). > > Currently, my netclass names (and clearance values) are hard-coded for my > particular board, as I needed to make progress with the design (rather than > worrying about how to save / restore clearance data for an arbitrary > project) - this will also need addressing > > > I've been thinking about the DRC, and will shortly come to a point where it > could help dramatically to implement the use of netclass in the main DRC. > > Nicklas - you expressed an interest in working on this at one point, so I'm > including you here. > > Britton - I recall (but not intimately) that you had a branch re-working > some of the DRC code, so I'm wondering if this is relevant, or orthogonal > to what I'm looking at here. > > Do you think that between us we can work out a plan to hit improved DRC for > multiple netclass with different clearance rules? I will probably make some > initial attempt over the coming weeks, but figured it was more in the > spirit of good collaboration to sound you guys out over it. (I'm still > hopeful that I can re-align my "little" patch-series / mini-fork with git > HEAD, so it stands a chance of merge rather than ever growing divergence. > > Peter