Sheet Metal Design?

Have some feature requests, feedback, cool stuff to share, or want to know where FreeCAD is going? This is the place.
Forum rules
Be nice to others! Read the FreeCAD code of conduct!
zhivko
Posts: 4
Joined: Thu Feb 19, 2015 3:17 pm

Re: Sheet Metal Design?

Postby zhivko » Fri Feb 20, 2015 3:35 pm

Thanks Ulrich for information and sent macro - indeed it looks very promissing.

Since I came from Autodesk Inventor world I am struggling to make a sketch on existing plane of imported tube (from igs) and than trying to somehow cut it.
I would like to try macro very much - but first I need to cut it:

1) can this be done in FreeCAD or it should be done in Inventor and than import cutted part?
2) I tried in freecad but somehow I cannot select existing pipe plane - when I click draft-utilities-plane, i hover over surface of imported pipe and freecad doesn't offer me that plane - when I click on face it acts like it is in orbit (rotate) pipe mode.

It could be that I am mind contrained with Inventor workflow - but can you please direct me to some tutorial or say if I can refeerence existing plane (from imoprted tube) somehow?

Regards
ulrich1a
Posts: 1920
Joined: Sun Jul 07, 2013 12:08 pm

Re: Sheet Metal Design?

Postby ulrich1a » Sat Feb 21, 2015 12:12 pm

zhivko wrote:but first I need to cut it:

1) can this be done in FreeCAD or it should be done in Inventor and than import cutted part?
This can be done in FreeCAD. I made it with the Step-version of your tube. It seems the Iges-version has problems to do so, because this versions does not define flat faces of the tube-sides.
1. Start FreeCAD and open your step-file.
2. Select the Part-Design Workbench. Have a look here about help for workbenches: http://freecadweb.org/wiki/index.php?ti ... ch_Concept
3. In the 3D-View select a flat face of your tube.
4. In the task-tab select "Create sketch"
5. Draw a small rectangle along the entire length needed to be cutted. (In case of problems with the sketcher, you may have a look into this tutorial: http://freecadweb.org/wiki/index.php?ti ... r_Tutorial)
6. Close the sketch
7. In the Tasks-Tab of the Part-Design workbench select "Pocket"
8. I got the settings for Type: "Dimension" and for Length: 5 mm, which will do a cut of one side of the tube.
9. Select one flat face of the cutted tube in the 3D-View.
10. Call the macro "sheet_ufo12.py" from the macros menu. (You need to copy this python-script into a folder of your convenience. And set this folder as your macro-locoation in the FreeCAD-preferences. Menu: "Edit/Preferences" and select in the dialog "General" and the tab "Macro" )

After some calculation time, you will get a bunch of flattened Shapes. Your tube contains a feature, that can not be handled by the macro. The macro was coded with the assumption, bended portions of the to be unfolded part have only edges parallel or perpendicular to the bend-axis of this portion. This is not the case with your part. The following picture shows the problematic bended face:
Problematic_bend.png
Problematic_bend.png (11.25 KiB) Viewed 2519 times
So the macro returns the unfolded faces it made. Due to the not handled difficult bend feature, it could not generate a solid from the unfolded faces.

In order to get something better with the actual version of the macro, this portion of your part has to be changed into something, that can be handled by the macro.

Otherwise, select the faces, you can use and export them as Step.

Ulrich

This is the FreeCAD-version I used for the unfolding:

OS: Debian GNU/Linux 8.0 (jessie)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.15.4587 (Git)
Branch: remotes/origin/master
Hash: aeabffeed8f26402e278662310deac5c7cbed05e
Python version: 2.7.8
Qt version: 4.8.6
Coin version: 4.0.0a
OCC version: 6.8.0.oce-0.17-dev
zhivko
Posts: 4
Joined: Thu Feb 19, 2015 3:17 pm

Re: Sheet Metal Design?

Postby zhivko » Mon Feb 23, 2015 10:46 am

Ulrich thank you very much for your instructions, here are my findings....
ulrich1a wrote: This can be done in FreeCAD. I made it with the Step-version of your tube. It seems the Iges-version has problems to do so, because this versions does not define flat faces of the tube-sides.
1. Start FreeCAD and open your step-file.
2. Select the Part-Design Workbench. Have a look here about help for workbenches: http://freecadweb.org/wiki/index.php?ti ... ch_Concept
3. In the 3D-View select a flat face of your tube.
I had style set to Inventor and that prevented me to select faces... When I moved back to CAD style I was able to select faces again... GREAT!
ulrich1a wrote: 4. In the task-tab select "Create sketch"
5. Draw a small rectangle along the entire length needed to be cutted. (In case of problems with the sketcher, you may have a look into this tutorial: http://freecadweb.org/wiki/index.php?ti ... r_Tutorial)
Here I have a problem referencing lines from STP - is there any chance to have "Import geometry from", or "Project line" to get reference to mid point of line of face that I am drawing onto?
I know this is beginer question for you professionals :)
ulrich1a wrote: 6. Close the sketch
7. In the Tasks-Tab of the Part-Design workbench select "Pocket"
8. I got the settings for Type: "Dimension" and for Length: 5 mm, which will do a cut of one side of the tube.
9. Select one flat face of the cutted tube in the 3D-View.
10. Call the macro "sheet_ufo12.py" from the macros menu. (You need to copy this python-script into a folder of your convenience. And set this folder as your macro-locoation in the FreeCAD-preferences. Menu: "Edit/Preferences" and select in the dialog "General" and the tab "Macro" )

After some calculation time, you will get a bunch of flattened Shapes. Your tube contains a feature, that can not be handled by the macro. The macro was coded with the assumption, bended portions of the to be unfolded part have only edges parallel or perpendicular to the bend-axis of this portion. This is not the case with your part. The following picture shows the problematic bended face:
The attachment Problematic_bend.png is no longer available
So the macro returns the unfolded faces it made. Due to the not handled difficult bend feature, it could not generate a solid from the unfolded faces.

In order to get something better with the actual version of the macro, this portion of your part has to be changed into something, that can be handled by the macro.

Otherwise, select the faces, you can use and export them as Step.

Ulrich
I was able to flatten this but with exact problem like you had...
UnrolledPipe.jpg
UnrolledPipe.jpg (160.82 KiB) Viewed 2467 times
To succesfully furthe use this on plasma pipe cutter - I would also need to have angle for rotating pipe...
Will try to look if there is some sw that handles this altogether...
ulrich1a
Posts: 1920
Joined: Sun Jul 07, 2013 12:08 pm

Re: Sheet Metal Design?

Postby ulrich1a » Mon Feb 23, 2015 1:05 pm

zhivko wrote:Here I have a problem referencing lines from STP - is there any chance to have "Import geometry from", or "Project line" to get reference to mid point of line of face that I am drawing onto?
You can use the external geometry tool in the sketcher Imageto select lines from the step.
zhivko wrote:To succesfully furthe use this on plasma pipe cutter - I would also need to have angle for rotating pipe...
I have difficulties to understand what you want to do and what you need here. You may explain with a little more detail?

The faces can be tied together as a compound. This function is available in menu of the Part-workbench. So you can handle them alltogether and rotate them in the 3D-view with the placement-tool from the "Edit"-menu.

Alternative try to cut the problematic part away before unfolding.
Unfortunately I can not fix this problem in the macro at a short time frame, as it needs new algorithmn where I need a lot of time for.

I personally have no experience with sheet bending and plasma cutting. I am just learning FreeCAD for two years now as my first CAD-program and liked it, so I added tools, I wanted to have.


Ulrich
zhivko
Posts: 4
Joined: Thu Feb 19, 2015 3:17 pm

Re: Sheet Metal Design?

Postby zhivko » Fri May 15, 2015 9:23 am

It has been while since my last post to this topic - this (uncorrent unrolled surface) is quite limitation for us.
The other aproach would be to write program that can rotate pipe around its axis and get coordinates of plasma pipe cutter.
Is there some python example that I can use to see how to automate rotation of pipe in freecad?
Is this possible at all? What do you guys think about this aproach?
Thank you,
sincere
duk
Posts: 55
Joined: Sun May 17, 2015 1:44 am

Re: Sheet Metal Design?

Postby duk » Wed Jun 10, 2015 12:08 am

as a tool and die maker, years ago i worked in a shop that did a lot of work for gm and developing blank forms for the punching and forming dies was a matter of many days of trial and error

cutting forms and putting it through the process and observing how it formed
User avatar
hhassey
Posts: 134
Joined: Thu Jun 04, 2015 8:01 pm
Location: Ensenada, Mexico

Re: Sheet Metal Design?

Postby hhassey » Wed Jun 10, 2015 10:30 pm

I don't know of any FEA for sheet metal in the open-source world.
Yes Guys, Code_Aster, its capabilities here: http://www.code-aster.org/V2/UPLOAD/DOC ... ter_en.pdf
is very capable of calculating sheet metal, Actually I am doing some 3D FEA Calculations involving Steel studs, and I am modelling them as sheet metal, where I can latter change the thickness.

On the other hand, I have no idea on the unfolding of 3d elements onto 2d sheets, but definitely FreeCAD nees that!

All I can think of is Blender already does that, with it's UV Mapping functions, UV unwrap, etc... maybe you could take a look at its funcitionallity and or code.

That's my 2 cents.
User avatar
shaise
Posts: 355
Joined: Thu Jun 11, 2015 8:11 am

Re: Sheet Metal Design?

Postby shaise » Thu Jun 11, 2015 9:16 am

Hi Everyone,

Here is a small Sheet Metal workbench add on for FreeCad I made. Its very basic, but can considerably speed up workflow:
http://theseger.com/projects/2015/06/sh ... r-freecad/

shai