On Sun, 2008-12-21 at 11:06 -0500, DJ Delorie wrote:

> > I had thought we were leaning towards describing what "should be" on the
> 
> Sample action script:
> 
> NetClearNetlist()
> NetAddConnection(unnamed_net31,R914-2)
> NetAddConnection(unnamed_net31,LED905-2)
> NetAddConnection(unnamed_net30,R913-2)
> NetAddConnection(unnamed_net30,LED904-2)
> NetAddConnection(unnamed_net29,R912-2)
> NetAddConnection(unnamed_net29,LED903-2)
> NetAddConnection(unnamed_net28,R910-2)
> NetAddConnection(unnamed_net28,CONN900-1)
> NetAddConnection(CLOCK3,R906-2)
> . . .
> NetAddConnection(unnamed_net2,R907-1)
> NetAddConnection(unnamed_net2,U903-2)
> NetAddConnection(unnamed_net1,R908-1)
> NetAddConnection(unnamed_net1,U903-1)
> ElementNoteAddStart()
> ElementAddIf(C902,0.1uF,0603dj.fp)
> ElementSetAttr(C902,device,CAPACITOR)
> ElementSetAttr(C902,manufacturer,Kemet)
> ElementSetAttr(C902,manufacturer_part_number,C0603C104K4RACTU)
> ElementSetAttr(C902,vendor,digikey)
> ElementSetAttr(C902,vendor_part_number,399-1096-1-ND)
> ElementAddIf(C901,0.1uF,0603dj.fp)
> ElementSetAttr(C901,device,CAPACITOR)
> ElementSetAttr(C901,manufacturer,Kemet)
> ElementSetAttr(C901,manufacturer_part_number,C0603C104K4RACTU)
> ElementSetAttr(C901,vendor,digikey)
> ElementSetAttr(C901,vendor_part_number,399-1096-1-ND)
> . . .
> ElementAddIf(C906,0.1uF,0603dj.fp)
> ElementSetAttr(C906,device,CAPACITOR)
> ElementSetAttr(C906,manufacturer,Kemet)
> ElementSetAttr(C906,manufacturer_part_number,C0603C104K4RACTU)
> ElementSetAttr(C906,vendor,digikey)
> ElementSetAttr(C906,vendor_part_number,399-1096-1-ND)
> ElementNoteAddDone()
> 
> When PCB sees the "done" action, it erases any appropriate elements
> that weren't mentioned since the "start" action.

Sounds like you've just invented a very awkward netlist and parts-list
format, with each line having an explicit verb ;)

There is of course functionality overlap between this and the existing
netlist import code, but I guess if they are using the same code-paths
underneath, that is fine. (I guess line-by-line processing of a netlist
file in various formats could translate to the same calls as this action
script).

What is:

ElementAddIf(C902,0.1uF,0603dj.fp)

What about if that element is already on the board? Does it skip the
add?

Then you set attributes on it... if you're going with verbs, are you
intending to have a verb to clear existing attributes, or do attributes
which exist on an element, but not in the annotation file get kept?

-- 
Peter Clifton

Electrical Engineering Division,
Engineering Department,
University of Cambridge,
9, JJ Thomson Avenue,
Cambridge
CB3 0FA

Tel: +44 (0)7729 980173 - (No signal in the lab!)



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

Reply via email to