The Protel 99SE has a Report Generating Mechanism for BOM creation. I want an add-on utility or a process script that can separately count the number of SMD and Through-hole components. Can someone comment on it ?.
The Protel database does not contain full information regarding this. However, one could analyze the database and make certain presumptions:
(1) If all the pads of a component are surface pads, the component is an SMT component.
(2) If any of the pads of a component are through-hole pads (on Multilayer), the component is a through-hole component.
The component records don't contain this information, it will be necessary to analyze the pads. What the component records contain is "Top Layer" or "Bottom Layer," which is a different characteristic; you can have SMT components on either layer and you can also have through-hole components on either layer, through bottom-mounted through-hole components are unusual.
It is also possible that a through-hole component has surface pads associated with it, for example, a heat-sinking pad used with a TO-220 power transistor. It is rare, however, that a surface mount component would have any through-hole pads associated with it. Vias, yes, maybe, pads, no. (Of course, Protel treats vias and pads somewhat interchangeably, but one could ordinarily choose to use vias in an SMT footprint. I'll ignore the possible complication.
A manual procedure to do this with a Protel ASCII file would be the following:
I'd import the database to Excel. (You'd be able to do this through Export to Spreadsheet in Protel except that Protel does not export the component index field that identifies, for each pad, which component, if any, it belongs to. A minor irritation -- it is sometimes beyond me how these choices get made by the programmers.) So to import the file, I'd use "|" as a field separator.
Once the data is in Excel, I'd sort by the RECORD= field and eliminate all records except for pads and components.
I'd eliminate irrelevant fields in both sets of records. Then I'd sort the pad records by layer, and from that extract a list of component numbers for Multilayer pads. The list would be massaged to eliminate duplicates.
From the component records, I would make a list of component reference designators and component numbers. (The component number is the reference number used in the database to link a component with its primitives.)
I'd bring the two lists together to create a list of components with through-holes (at least one), and the remaining components would be presumed to be surface mount. It would be simple, then, to count the lists.
Yes, it would not be difficult to automate this process. Because of my personal programming experience, such as it is, I would probably write a simple program in QuickBasic, which I still use from time to time.
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * To post a message: mailto:[EMAIL PROTECTED] * * To leave this list visit: * http://www.techservinc.com/protelusers/leave.html * * Contact the list manager: * mailto:[EMAIL PROTECTED] * * Forum Guidelines Rules: * http://www.techservinc.com/protelusers/forumrules.html * * Browse or Search previous postings: * http://www.mail-archive.com/[EMAIL PROTECTED] * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *