cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Learn all about PTC Community Badges. Engage with PTC and see how many you can earn! X

How to get the number of bends?

CHASEONHO
18-Opal

How to get the number of bends?

Hi, 

 

I have a sheet metal geometry as shown.

s3.png

I am trying to count the number of bends using the toolkit.
Here's how we thought of it:
1. Collect flat, flange, and bend features from the model tree
2. Get vector values of reference planes of collected features
3. Increase the number of horizontal/vertical bends using vector values

 

However, the following problems were expected:

 s2.png
Five flat features are visible in the feature tree in the illustration.

s.png

When looking at the unfolded shape, the number of bends is 1 horizontally and 2 times vertically.

 

Any good way to count the number of bends?
Any ideas would be appreciated.

 

Warm Regards,

SeonHo Cha.

ACCEPTED SOLUTION

Accepted Solutions

I would try the axis.

- Go through all views (or a specified) (ProDrawingViewVisit)

- Go through all SolifdFeats ind the Solid of the View (ProDrawingViewSolidGet, ProDrawingFeatVisit)

- FeatType == PRO_FEAT_UNBEND

- ProFeatureAnnotationelemsVisit ( );

- FeatType == PRO_AXIS

 

So you should get the 3 axis from the Unbend feature. We want to show it ... so we use ProAnnotationByFeatureShow after (FeatType == PRO_FEAT_UNBEND), but it should also be possible to visit and count them.

 

Br,

Eike

View solution in original post

9 REPLIES 9

I would try the axis.

- Go through all views (or a specified) (ProDrawingViewVisit)

- Go through all SolifdFeats ind the Solid of the View (ProDrawingViewSolidGet, ProDrawingFeatVisit)

- FeatType == PRO_FEAT_UNBEND

- ProFeatureAnnotationelemsVisit ( );

- FeatType == PRO_AXIS

 

So you should get the 3 axis from the Unbend feature. We want to show it ... so we use ProAnnotationByFeatureShow after (FeatType == PRO_FEAT_UNBEND), but it should also be possible to visit and count them.

 

Br,

Eike

@Eike_Hauptmann 

This method worked great for me.
I just tried a different way.

 

Flat pattern features can visit the axes of flats and flanges.
Then, we used curve.arrow->end1,end2 of geomitemdata of the axes.

 

The directionality among X, Y, and Z was confirmed through each 3d pnt.
Concordance points were treated as the same axis by comparing the confirmed non-directional PNTs.

 

After merging the same axes, the number of axes for directionality is converted to the number of bands, and the result seems to be quite accurate.

 

Thank you.

@CHASEONHO  Is it possible to share your script?

Thanks

Hello, I don't think that this request is NOT so complex to calculate.

 

My solution would be:

 

  • The Number of cylindrical surfaces which are from the Face/Green (or Offset/White) Side will specify the number of "Bends" in the bended model.

And this is just one Surface Visit filter function, and probably Array Size Get.

 

Before everybody proofs me wrong 😉 please read the following notes:

 

My thougths:

  • You need to analyse only a "quilt" of surfaces, specified by FACE/GREEN or OFFSET/WHITE, not the other Solid Surfaces.
  • You have a sheet of metal with one thickness.
  • To create the model you need to cut out the flat one, before you start to bend.
  • Each bend is a cylindrical surface.

Task to do:

To get the amount of bends, visit all Surfaces and find all cylindrical onces  (SurfaceVisit Function).
For a sheet metal component each surface type is now either the FACE, OFFSET, SIDE or NONE.
SIDE and NONE can be Ignored, the visit filter filter must be FACE/GREEN or OFFSET/WHITE, lets use GREEN

 

By this:

The Number of cylindrical surfaces which are from the Face/Green Side will specify the number of "Bends".


And you get the angle as well, if you analyse the Cylindrical Data.

It is the same Bend, even if later seperated by cuts in the design phase.

 

Quilt Notes:

A hole or a round, which are cylindrical surfaces in the model, are tagged as "SIDE" because you work with a thin piece of Paper only.
A hole or a round (these are cylindrical surfaces as well) are just a circles in the smt quilt of the unbendded model.

 

This site will not render Tcl Code, here an image of the code, see Toolkit Notes at the end as well:

 

p-Shell Code to get the amount of bends in a SNT modelp-Shell Code to get the amount of bends in a SNT model

msteffke
14-Alexandrite
(To:CHASEONHO)

I count the number of bends in the drawing as opposed to the model.  I count the bend notes on the drawing, so every bend would need a note but our specs call for that.   I must note that we have been creating our own custom bend notes (via a toolkit app) since we started using Pro Engineer version 18, (1999) as ProE had nothing at the time.  So our noting is very consistent.   I am checking notes for valid radii values, "an Up or DN"  and key words like hem, etc.   I would say this gives me about 95% accuracy.   Not perfect but it was what I could deliver. 

GabrielZaha
13-Aquamarine
(To:CHASEONHO)

I would have a look at ProSmtFeatureDevldimsGet function. The outputs are one array of dimensions (developed lengths of the bends) and one array of surfaces, which are suppose to be the bent surfaces.

The way I see this is to visit all features in the model. Try to filter the non-relevent features (datum planes, point and so on) out.

In the visiting function call ProSmtFeatureDevldimsGet and then get the size of one of the arrays.

I never tested this but at least in theory it should work.

 

On the other hand the model you are showing is a very good example. For all intents and purposes I expect the result to be 5 bends.

Because the green and yellow sides are the same size, in a practical application this part can be produced with only 3 bend operation.

Interesting exercise.

 

@GabrielZaha Thank you for your replies.
You gave a good idea, but this method is difficult for me to apply.
Thank you again for thinking about our concerns.

RPN
17-Peridot
17-Peridot
(To:GabrielZaha)

Are you sure about this 3 bends?

Thanks a lot for sharing your ideas. 🙏
Based on postings from RPN (count cylindrical surface that are from FACE/GREEN sheetmetal side) and GabrielZaha (number of surfaces returned by ProSmtFeatureDevldimsGet()), I implemented both approaches in a single bend-count-function:

 

Count the number of bends in a sheetmetal model:
- examining only features of type
- Bend (PRO_FEAT_BEND)
- Wall (PRO_FEAT_WALL)
- Smt Conversion (PRO_FEAT_SMT_CONVERSION)
and sum up each feature's bend count.
- For Bend and Wall features, the bend count is the number of surfaces returned by ProSmtFeatureDevldimsGet().
- For Smt Conversion features, the bend count is the number of cylindrical surfaces that belong to the face (green) sheetmetal side (surface property ProSmtSurfType == PRO_SMT_SURF_FACE, via ProSmtSurfaceTypeGet()).

Remarks:
- Only features with status "active" or "active but unregenerated" are being considered.
- This function gives the same result in both sheetmetal states: bended and flattened.
Background:
ProSmtFeatureDevldimsGet() works ootb in both states (bend/flat) and returns the same number of bends.
For Smt Conversion features, the number of child surfaces remain the same in bend/flat state, they only change their in-/active state.
Thus, by examining both the active and inactive surfaces, the relevant cylindrical surfaces can be found and counted as bend (each one).

 

⚠️Limitations:
Counts only bends of the specified features (BEND, WALL, SMT_CONVERSION). (Support for unknown/new features must be added, if needed.)

 

💡 Findings:
For my test case with a bend along a (slightly) curved edge (from a flange feature), this bend-count-function works better than the Creo build-in functionalities 📈 for counting bends:
it does find & count even the curved bend (Creo does not) and counts all other bends correctly.

 

Screenshots of my test case with 10 bends (Creo counted 9, missed the curved edge):
(config.pro option required for the "Sheetmetal" button (Bend Report) to appear: info_output_format text)


0000784_bend_features.prt - bends.png

 

0000784_bend_features.prt - bend report.png

 

0000784_bend_features.prt - geometry search tool.png

 

 

 

Announcements


Top Tags