AutoCAD Plant 3D Forum
Welcome to Autodesk’s AutoCAD Plant 3D Forums. Share your knowledge, ask questions, and explore popular AutoCAD Plant 3D topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Custom Python Pipe Support for Mixed Metric Project

3 REPLIES 3
SOLVED
Reply
Message 1 of 4
Fahad_Ghoerobi
340 Views, 3 Replies

Custom Python Pipe Support for Mixed Metric Project

Hi everyone,

I’m currently developing a custom pipe support for a mixed metric project. I’m using inches ("in") as the LengthUnit in my script.
Then I created a New Support in the SUPPORTS Catalog based on my script,

I imported the Support to the PipeSupportsSpec in my Imperial Project, everything works perfectly. I can modify parameters like stretching without any issues.
However, when I imported the Support to the PipeSupportsSpec in my Mixed Metric Project, I can not alter the parameters. I've set the ComponentDesignation to "Custom".
I've tried to switch the LengthUnit to "mm" and modify all the values in my script to use mm. But when I placed the support it showed so big shape size (seems converted to an inch unit) in the Plant 3D for the first time. I must alter one of the parameters a bit to trigger the correct shape size.

Has anyone else encountered this issue before? If so, how did you handle custom parts for mixed metric projects? Any insights would be greatly appreciated.

Here I attached my script. 

Need help from Top Solution Authors:
@h_eger 
@Michiel.Valcke 
@quan_hm 
Thank You Guys..


Tags (2)
3 REPLIES 3
Message 2 of 4
h_eger
in reply to: Fahad_Ghoerobi

@Fahad_Ghoerobi ,

 

ALL project configurations with Python Script supports work for me.
Enclosed are the two Mixed Metric in imperial and metric units

 

21-08-2024_07-36-59.jpg21-08-2024_07-40-23.jpg

-

If my reply was helpful, please give a "Kudo" or click the "Accept as Solution" button below (or both).

Hartmut Eger
Senior Engineer
Anlagenplanung + Elektotechnik
XING | LinkedIn

EESignature



Message 3 of 4
h_eger
in reply to: Fahad_Ghoerobi

@Fahad_Ghoerobi ,

 

I do not know the background of your P3D Python script training but this line will not work
Calculations in def will not work

def PSB01_A(s, OD=1.9, Lt=200.0/25.4, tt=1.0/25.4, tp=0.0/25.4, ID="PSB01_A", **kw):

 

-

If my reply was helpful, please give a "Kudo" or click the "Accept as Solution" button below (or both).

Hartmut Eger
Senior Engineer
Anlagenplanung + Elektotechnik
XING | LinkedIn

EESignature



Message 4 of 4
Fahad_Ghoerobi
in reply to: h_eger

Thank you for identifying the problem.

However, After I deleted those calculations, the result remained the same—I still can't modify the parameters in 3D.

For now, my workaround is to adjust the script and use millimeters (mm) as the length unit. Then, I created a new support in my Support Metric Catalog and added it to my Pipe Support Spec in my Mixed Metric Project, and that resolved the issue.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report