[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: gEDA-user: Pick-And-Place Extract



Dan McMahill wrote:
Tony Radice wrote:

Do you have any feel for how widely used IPC-D-356 is? I think I was asking about how useful this would be to folks several years ago and no one seemed interested. Perhaps this has changed now?

Dan - I'm not sure how widely this is used, it came up as one of the
formats a flying-probe testing unit that will be used to test my bare
boards accepts. Since it's documented I figured I would go in that
direction.

ok. I'm all for supporting it. The good news is that it is a documented standard. I can't remember if I ever got as far as looking at the standard to see what it would take. The BOM HID (pcb/src/hid/bom/) has the existing x-y export code and may help with what you need. It is a bit different from the other exporters since it doesn't deal with traces at all, only footprints. Then pcb/src/hid/gerber/ is also useful to look at since it has the RS274-X and Excellon export. Those of course have a bit more.

The x-y export code can show you how to get locations of all pins and pads. Via locations aren't hard either. If you need connectivity information, then it is probably still doable but I would have to go digging.

I took a quick look. I think you want the BOM code as the example. Looks to me like the biggest part of IPC-D-356 is listing out pin/via/pad locations and the x-y part of the BOM exporter has most of that. You will need to see how the connectivity part goes. I'm just not quite familiar enough with that bit to know the answer off hand.

The other thing you'll probably need is a couple of functions for mangling both net names as well as refdes and pin numbers. The reason I say this is that it appears that IPC-D-356 is somewhat restrictive (more so than pcb) on things like net name but yet net name is crucial for the IPC output.

Here is what you don't want:

printf("%s", truncate_to_14_chars( netname ));

because now 2 unique netnames may show up in the output as the same. *NOT* good.

Instead you probably need something like

reset_net_name_mangling(); /* call this at the start of exporting */

......
printf("%s", mangle_net_name( netname ));

where mangle_net_name() is smart enough to always produce an output which is legal for IPC-D-356 but in a way where it doesn't artificially short things out. Maybe it is as simple as allowing 10 characters from the real name and reserving the final 4 for a hash of sorts.

note that these name mangling functions don't exist but shouldn't be so hard to write.

To get going with a new exporter, create pcb/src/hid/ipc-d-356/, edit pcb/configure.ac, pcb/src/Makefile.am, (search for 'bom' for examples of where and how to edit these), create a pcb/src/hid/ipd-d-356/hid.conf (using pcb/src/hid/bom/hid.conf as an example), copy pcb/src/hid/bom/bom.c to pcb/src/hid/ipc-d-356/ipc-d-356.c and edit it to do what you need and you should be good to go.

hmmm... this short summary should probably go in a manual appendix or something...

Hope this helps and don't be afraid to ask questions if you need help.

-Dan



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