FreeCAD BOM Generator: Difference between revisions
Line 8: | Line 8: | ||
BOM spreadsheet in progress for Seed Home 2 - see link at [[Seed_Home_v2_3D_CAD#Walls]]. Note: about 1400 individual parts are extacted from the CAD file, and are being summed up into a BOM that can be submitted to a supplier. Partial cut lumber is summed into large pieces, such as 14" 2x4 lumber cutoff are summed into a corresponding number of full sticks of framing lumber. | BOM spreadsheet in progress for Seed Home 2 - see link at [[Seed_Home_v2_3D_CAD#Walls]]. Note: about 1400 individual parts are extacted from the CAD file, and are being summed up into a BOM that can be submitted to a supplier. Partial cut lumber is summed into large pieces, such as 14" 2x4 lumber cutoff are summed into a corresponding number of full sticks of framing lumber. | ||
=Structured Way= | =Structured Way - Naming Convention= | ||
We started with [[Phrase Counting Method]]. Too complicated - just use single words | |||
[[ | |||
=Step 1: Extracting Parts Spreadsheet in FreeCAD= | =Step 1: Extracting Parts Spreadsheet in FreeCAD= |
Revision as of 05:37, 11 April 2021
Work Doc
BOM spreadsheet in progress for Seed Home 2 - see link at Seed_Home_v2_3D_CAD#Walls. Note: about 1400 individual parts are extacted from the CAD file, and are being summed up into a BOM that can be submitted to a supplier. Partial cut lumber is summed into large pieces, such as 14" 2x4 lumber cutoff are summed into a corresponding number of full sticks of framing lumber.
Structured Way - Naming Convention
We started with Phrase Counting Method. Too complicated - just use single words
Step 1: Extracting Parts Spreadsheet in FreeCAD
The first step in automated BOM generation is the creation of a FreeCAD spreadsheet populated with all the parts. This can be scripted in the Python console so that this doesn't have to be done manually.
There is a macro from FreeCAD forum [1]. Click on edit mode to see actual code and copy it exactly with spacing as given. It should look like this:
obj = FreeCADGui.Selection.getSelection() bom = App.activeDocument().addObject('Spreadsheet::Sheet','BOM') cell = 0 for x in obj: cell = cell + 1 bom.set("A" + str(cell), x.Label) App.ActiveDocument.recompute()
You can execute this macro in Macros or in the Python console.
Hint: Procedure: Select the parts in the tree view, and you will generate a spreadsheet with all the parts. Then these parts can be counted.
- This generates a spreadsheet, from selected parts in part tree
- Export this to CSV using Spreadsheet Workbench for other spreadsheet apps.
- Spreadsheet workbench allows import of CSV as well.
Note on Groups
If you organize parts in folders (ie, Create group...) - the group name also appears in the above list:
Thus- you can count groups as well (if you name them with space and number at the end so there is a clear name). So for example, you can extract that you have 2 roof modules, 5 walls, with 50 2x12s, 100 hangers, etc. For the 1000 sf Seed Home 2, counting number of roof sections is done easily from the CAD, so it may be useful to only sum up the individual parts, and avoid counting obvious parts.
Groups allow you to keep track of subparts, so they are useful in the BOM generation protocol. Ideally, you have such an example that is pulled out automatically via this process:
- [46] wall panels
- [42] sheets of exterior textured plywood
- [8] window panels
- [4] small windows
- [3] door panels
- [120] 2x6 lumber - 8'
- [310] 2x6 lumber - 9' precut
- [215] 2x6 lumber - 14" long
- Etc...
Note that this process is best effectively suited for producing cut lists. This is because the method works well for itemizing all parts as used. This means that the 'cut list' will include both off-the-shelf parts (such as 9' precut 2x6 lumber), or cut pieces, such as the 14" long pieces. For the partial pieces, these will need to be summed in the spreadsheet software after they are extracted from the CAD.
FreeCAD BOM Automation - Evolution
2018 Progress
- Note comment: part organization is what makes for proper assemblies - not constraints! Exactly. [2]
- Addendum Jan 1, 2020 - By this logic, part organization is what makes for proper BOM generation - not some magical software that tries to do that for you automatically. Such magic software does not exist until strong AI (or artificial general intelligence) is created. The arrival of such capacity is as of yet unknown. See Predictions on the Arrival of Artificial General Intelligence.
2017
https://forum.freecadweb.org/viewtopic.php?t=23592