On 10/7/07, Randall Nortman <[EMAIL PROTECTED]> wrote: > If I have made a change to a footprint, is there an easy way to update > a layout that uses that footprint, the way gschem can update embedded > symbols? That is, replace the element on the layout with the new > footprint, using the same position and rotation. (Obviously, a DRC > check would be highly advisable after doing something like this.) > > I recognize that I could do this manually, but that sounds like a lot > of trouble. If anybody has already scripted this, that would be very > helpful. It seems like it should be possible, since the original > footprint name seems to be stored in the pcb file (at least when it > was put there by gsch2pcb, which is how all of mine get there). In > the worst case, I think some cut & paste with a text editor on the pcb > file is probably easier than trying to do it manually in the GUI and > get everything lined up properly (at least for newlib footprints -- m4 > is not friendly to cut & paste). Am I right? Copy and paste the new > footprint, copy in coordinates and rotation from old footprint, remove > old footprint? And the coordinates within the element seem to be > relative to the element's base coordinates and rotation, so nothing > else to do, right?
You could definately do it with a script but unless you have a lot of footprints to update or have to update a number of layouts it may not be worth it. The cleanup after the script finishes may be more difficult than the cleanup prior to doing a manual replace. If your components are on the grid manual replacement goes quickly. I have a couple of scripts that do component placement in PCB files. I have a write-up on scripted component placement at --- http://www.luciani.org/not-quite-ready/not-quite-ready-index.html My script pcb-matrix replicates a pcb layout. The script reads in the position of each element in the original PCB layout adds an offset and then places the element in a new layout http://www.luciani.org/geda/util/util-index.html#matrix (* jcl *) -- http://www.luciani.org _______________________________________________ geda-user mailing list [email protected] http://www.seul.org/cgi-bin/mailman/listinfo/geda-user

