delorie.com/archives/browse.cgi   search  
Mail Archives: geda-user/2017/02/11/05:39:08

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=20161025;
h=date:from:subject:to:in-reply-to:message-id:mime-version
:content-disposition:content-transfer-encoding;
bh=rqc7YItl1qxZoYZdr7jookSnP37dz+KrqyrfOhqExWw=;
b=HlNo4c2GeU4C2OHR23t0TrWtkQM3gyu4P3FfdZ6PK08ZtJoekwv7ZYGLyHsGlwrqnc
mub6zgIIIOule4h9uGaRAZPXSZhkXEGdXT9L7WzOb7MF5ZzrvG+PKp8pAHdIxUto4hEL
PBuZBn1+MI2Uzq5DjvLoNRKlMqh9Hp1eVz6f0A8IpPwdDxGljCJg+MFjcRI2yzeJ+z0c
ThTRFwAjsFddRLTBirimbHMsQSmNctQC2qZEidcTYzFovo85w5NCA1AtNlbDhUGX2rFR
K/I83llmfKSnDQuo0++FfCfeo7HQLoPZgFi6DVp1VO+NE10LKJ1Y8LrE0VvXyexx+PCu
9YLA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20161025;
h=x-gm-message-state:date:from:subject:to:in-reply-to:message-id
:mime-version:content-disposition:content-transfer-encoding;
bh=rqc7YItl1qxZoYZdr7jookSnP37dz+KrqyrfOhqExWw=;
b=d+ZqtEKsjXUt+uKTSWfwTN6sOpcRM4lLO7yJ4zTTrfyE6QriGSefNVoO7a1AWUb3ap
U9fUhh41ImYXHJapcy/4D6HFtBeaoXUq9IK5LN7kkrpMch+mCwxdNCdiPaTsa8qPW9pn
4HGa3qu4eBA6SzrRMVxWP8jWVp2QYrHiGRL5M6sh0er/j3f8A6obYQm2Wfs4xtJBvpUX
w0XtEC8w9TtqdGHe6qMPYPZHiGACRaIOfkxoEeSwKPBuisKgQPLPF/UE2E63H0vsjmvq
Yev2TIA3nNu1OHC3hmRDJ650XPwnx7/oL8zBmU6Gn9PQXgAMN5mTJwWqSdLrORh9Txc0
k3Yg==
X-Gm-Message-State: AMke39nIi0yQjftgUXZvwC3PX9zk7mjIzHRb0MCHAsH8nA4wsyex5LfyqCNoNUrguXVRfg==
X-Received: by 10.99.131.65 with SMTP id h62mr16304741pge.41.1486809468301;
Sat, 11 Feb 2017 02:37:48 -0800 (PST)
Date: Sat, 11 Feb 2017 23:37:41 +1300
From: "Lilith Bryant (dark141 AT gmail DOT com) [via geda-user AT delorie DOT com]" <geda-user AT delorie DOT com>
Subject: Re: [geda-user] gschem gnetlist bug/feature
To: geda-user AT delorie DOT com
In-Reply-To:
<CAJXU7q8jy9H0-1M=bb4pWu1+x6qCxwfP_QwVkdKgjN334-hbuA AT mail DOT gmail DOT com> (from
geda-user AT delorie DOT com on Sat Feb 11 22:46:04 2017)
X-Mailer: Balsa 2.5.2
Message-Id: <DG36jiih+JGX7I1UTBU8bZ@VyjjcOvy0soqr1JeWmCBw>
MIME-Version: 1.0
X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id v1BAbooN016644
Reply-To: geda-user AT delorie DOT com

On 2017-02-11 22:46:04, Peter Clifton (petercjclifton AT googlemail DOT com) [via geda-user AT delorie DOT com] wrote:
> If you want to create a power symbol which can be used for any custom net
> name, you could use a net=xxx:1 attribute and set it to show value only
> (but it would read xxx:1 instead of xxx
> 
> 
> This is how I do it, but if you care about the :1, you can hide the net=
> attribute entirely and add visible text (or a label=... attribute). I
> personally prefer leaving the :1 if it is defined in the schematic, not a
> custom symbol - as having two attributes, one visible, one not - which
> might accidentally be out of sync rather suggests possibility of errors
> creeping in.
> 
> Peter Clifton
> 

Whatever the theoretical reasons are (and I do understand them) I can't 
give my clients schematics with a useless :1 tacked on all the port labels.

So, the solution that I use is to make the schematics without the :1, and 
then use a makefile to execute the gsch2pcb step,  with the following rules:

TEMPSCHEMS=$(patsubst %,temp/%.sch,$(SCHEMS))

temp/%.sch : %.sch 
	sed 's/\(net=[^:]*$$\)/\1:1/' >$@ <$<

pcb : $(TEMPSCHEMS)
	gsch2pcb -f $(if $(KEEP),-k,-r) $(FOOTPRINTDIRS) $^ -o $(PCB)

.PHONY : pcb 

This of course works as long as the only thing you use net= for is for ports.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019