Pipe Support Script

Pipe Support Script

Anonymous
Not applicable
914 Views
2 Replies
Message 1 of 3

Pipe Support Script

Anonymous
Not applicable

Hi everyone, I'm trying to make a pipe support like this one from the photo, but I could not load it in Plant 3d, could someone help me with what's missing in my code. I'm a beginner. Thanks

 

from aqa.math import *
from varmain.primitiv import *
from varmain.var_basic import *

@Anonymous(Group="Support", Ports="1", TooltipShort="Trave Simples", TooltipLong="Trave para suporte simples", LengthUnit="in")
@group("MainDimensions")
@param(L0=LENGTH, TooltipShort="Segunda Distancia", TooltipLong="Distancia do centro do tubo até a face do perfil")
@param(L=LENGTH,TooltipShort="Primeira Distancia", TooltipLong="Distancia do centro do tubo até a face do perfil")
@param(HL=LENGTH,TooltipShort="Tamanho Perfil", TooltipLong="Tamanho do Perfil metalico")
@param(WL=LENGTH,TooltipShort="Tamanho Perfil", TooltipLong="Tamanho do Perfil metalico")
@param(TL=LENGTH,TooltipShort="Espessura Perfil", TooltipLong="Tamanho do Perfil metalico")
@param(LL=LENGTH, TooltipShort="Soma das Distancias", TooltipLong="Total da soma de L + L0")
@Group(Name="meaningless enum")
@enum(1, "align X")
@enum(2, "align Y")
@enum(3, "align Z")

def SUPTESTE(s, LL = 0, L = 0.0, LO = 0.0, WL = 0.0, HL = 0.0, TL = 0.0, ID = 'SUPTESTE', **kw):
WL = HL
LL = L + LO
o1 = BOX(s, L=L, LO=L0, WL=WL, HL=HL, TL=TL).rotateY(-90).rotateX(90.0)
o2 = BOX(s, L=L, LO=L0, WL=WL, HL=HL, TL=TL)

#Unite
o1.uniteWith(o2)
o2.erase()

s.setPoint((0, 0, 0), (-1, 0, 0))
s.setLinearDimension('L', (0, 0, 0), (0, 0, -L))pipesup.JPG

the pipe support is like this.

0 Likes
915 Views
2 Replies
Replies (2)
Message 2 of 3

≡ EqVert ≡
Advocate
Advocate

1. 

2019-02-02_183522.png

 

2. Only English characters in the script

3. Try to avoid meaningless ideas, for example,

WL = HL
LL = L + L0
3. For the supports, the connection to the pipe - point 0 of the block, the direction of the pipeline - along the X axis
0 Likes
Message 3 of 3

Anonymous
Not applicable

Thank u for the tips, I'll make the changes and try to improve the code.

0 Likes