Mail Archives: geda-user/2013/05/16/14:55:34
--f46d04389247a4105b04dcda650b
Content-Type: text/plain; charset=ISO-8859-1
Ok - I've been thinking a bit more about what I was trying to accomplish,
and how best to do it. My current thinking goes something like this:
Using the technique I saw here:
1. Create a dummy schem containing the subcircuit you wish to layout. Do
not make the subcircuit portion of the refdes explicit. (ie, leave it S? so
that the netlist looks like: S?/U1-7 S?/R1-2 S?/L1-1 ....
2. Do the layout for the subcircuit.
3. Load layout to pastebuffer.
4. Paste (modifications to CopyPastebufferToLayout() described below)
What I'm proposing here, is to modify CopyPastebufferToLayout() so that if
the the element names are of the form S?/Cn, AND the netlist matches
S[1-4]/Cn, but S1/Cn already exists, then we must be pasting S2/Cn, and so
on. I'm not absolutely certain if all the information needed to do that is
available in that function, or if that's in fact the best place to put it.
To my thinking, it fits the use case well, but perhaps I lack imagination
for how other usages could break it, or if this is too specific to one work
flow to be put into the paste behavior. It's possible that really simple
subcircuits could posses identical netlists, but different layouts.
Alternatively, I was just planning to rename the actual refdes based on
substring patterns (rather than do the logical renumber mapping like
ActionRenumber does).
So a couple questions:
1) Is this broad enough to be done in core paste functionality, and if not,
is there a better place for it?
2) Is there anything else that should be pulled into doing this - it occurs
to me that conceptually, this is sort of an extension of 'import
schematic', in that you're tying elements of your layout into another
source file.
3) One additional idea I had was possibly adding an optional attribute to a
component which could tell PCB to go ahead and load all my "postage stamps"
on import of the schematic. Sort of like 'footprint' on steroids. Any
comments on this idea?
Opening the floor to any comments, suggestions, and criticism.
Nathan
On Wed, May 15, 2013 at 8:26 AM, Nathan Stewart <
therealnathanstewart AT gmail DOT com> wrote:
> I started playing around with the renumber command. I changed the
> implementation slightly, so that if anything is selected, it restricts the
> renumbering to the selection. I was getting into parsing refdes of the
> form Sn/Cn when I realized it probably bears discussion.
>
> I was trying to get to being able to renumber subcircuit layouts. I know
> this has been done with scripts, but I dislike multi-homed work flows -
> tweak file in program A, modify it with program B, reload in A.
>
> The renumber also doesn't do exactly what I want anyway. It's going to
> homogenize the names on the board. I want to modify the refdes itself in
> the layout I loaded to the buffer. This could be done by supplying a
> prefix.
>
> Any thoughts on this one?
>
--f46d04389247a4105b04dcda650b
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
<div dir=3D"ltr"><div><div>Ok - I've been thinking a bit more about wha=
t I was trying to accomplish, and how best to do it. My current thinking go=
es something like this:<br><br></div>Using the technique I saw here:<br><br=
>
1. Create a dummy schem containing the subcircuit you wish to layout. Do no=
t make the subcircuit portion of the refdes explicit. (ie, leave it S? so t=
hat the netlist looks like: S?/U1-7 S?/R1-2 S?/L1-1 ....<br></div><div>
2. Do the layout for the subcircuit.<br></div><div>3. Load layout to pasteb=
uffer. <br></div><div>4. Paste (modifications to CopyPastebufferToLayout() =
described below)<br><br></div><div>What I'm proposing here, is to modif=
y CopyPastebufferToLayout() so that if the the element names are of the for=
m S?/Cn, AND the netlist matches S[1-4]/Cn, but S1/Cn already exists, then =
we must be pasting S2/Cn, and so on. I'm not absolutely certain if all =
the information needed to do that is available in that function, or if that=
's in fact the best place to put it. <br>
<br></div><div>To my thinking, it fits the use case well, but perhaps I lac=
k imagination for how other usages could break it, or if this is too specif=
ic to one work flow to be put into the paste behavior.=A0 It's possible=
that really simple subcircuits could posses identical netlists, but differ=
ent layouts.=A0 Alternatively, I was just planning to rename the actual ref=
des based on substring patterns (rather than do the logical renumber mappin=
g like ActionRenumber does).<br>
<br></div><div>So a couple questions:<br></div><div>1) Is this broad enough=
to be done in core paste functionality, and if not, is there a better plac=
e for it? <br></div><div>2) Is there anything else that should be pulled in=
to doing this - it occurs to me that conceptually, this is sort of an exten=
sion of 'import schematic', in that you're tying elements of yo=
ur layout into another source file. <br>
</div><div>3) One additional idea I had was possibly adding an optional att=
ribute to a component which could tell PCB to go ahead and load all my &quo=
t;postage stamps" on import of the schematic. Sort of like 'footpr=
int' on steroids. Any comments on this idea? <br>
<br></div><div>Opening the floor to any comments, suggestions, and criticis=
m.<br></div><div>Nathan<br></div><div><br></div><div><br></div><div><div><b=
r></div></div></div><div class=3D"gmail_extra"><br><br><div class=3D"gmail_=
quote">
On Wed, May 15, 2013 at 8:26 AM, Nathan Stewart <span dir=3D"ltr"><<a hr=
ef=3D"mailto:therealnathanstewart AT gmail DOT com" target=3D"_blank">therealnatha=
nstewart AT gmail DOT com</a>></span> wrote:<br><blockquote class=3D"gmail_quot=
e" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir=3D"ltr"><div>I started playing around with the renumber command. I=
changed the implementation slightly, so that if anything is selected, it r=
estricts the renumbering to the selection.=A0 I was getting into parsing re=
fdes of the form Sn/Cn when I realized it=A0 probably bears discussion.<br>
<br></div><div>I was trying to get to being able to renumber subcircuit lay=
outs. I know this has been done with scripts, but I dislike multi-homed wor=
k flows - tweak file in program A, modify it with program B, reload in A. <=
br>
<br></div><div>The renumber also doesn't do exactly what I want anyway.=
It's going to homogenize the names on the board. I want to modify the =
refdes itself in the layout I loaded to the buffer.=A0 This could be done b=
y supplying a prefix. <br>
<br>Any thoughts on this one?<br></div></div>
</blockquote></div><br></div>
--f46d04389247a4105b04dcda650b--
- Raw text -