Custom Python Script Pipe Supports
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- パーマリンクを表示
- 印刷
- 報告
Hi,
I have a wee bit of a dilemma with my code. I have a Pedestal (Dummy Leg) Support that requires an Isolation Pad under the base plate.
Just don't seem to be able to insert it at the correct position. Code is below as well as some graphics for explanation.
from aqa.math import *
from varmain.primitiv import *
from varmain.custom import *
@Anonymous(Group="Support", TooltipShort="APA IP05 PTFE Isolation Pad (Large)", TooltipLong="APA IP05 PTFE Isolation Pad (Large)", LengthUnit="mm", Ports="1")
@matthias_hein("MainDimensions")
@param(A1=LENGTH, TooltipShort="Pad Length", TooltipLong="Pad Length", Ask4Dist=True)
@param(B1=LENGTH, TooltipShort="Pad Width", TooltipLong="Pad Width")
@param(C1=LENGTH, TooltipShort="Pad Thickness", TooltipLong="Pad Thickness")
@param(H1=LENGTH, TooltipShort="Height to Pipe Ctr of Dummy Leg", TooltipLong="Height to Pipe Ctr of Dummy Leg")
@param(R1=LENGTH, TooltipShort="Pipe Elbow Radius", TooltipLong="Pipe Elbow Radius")
@param(P1=LENGTH, TooltipShort="Run Pipe OD", TooltipLong="Run Pipe OD")
@param(P2=LENGTH, TooltipShort="Dummy Leg Pipe OD", TooltipLong="Dummy Leg Pipe OD")
@matthias_hein(Name="meaningless enum")
@enum(1, "align X")
@enum(2, "align Y")
@enum(3, "align Z")
#--------------------------------------------------------
#(arxload "PnP3dACPAdapter")
#(TESTACPSCRIPT "APAIP05")
def APAIP05(s, A1=110.0, B1=110.0, C1=3.0, H1 = 450.00, R1 = 76.0, P1 = 60.3, P2 = 48.3, ID = 'APAIP05', **kw):
# set variables
leght = H1
elbowrad = R1
R2 = P2 / 2.0
R3 = R2 + 10.0
inspoint = leght
BOX(s, L=A1, W=B1, H=C1).rotateY(90)
# Ob = CYLINDER(s, R=R2, H=leght, O=0)
# Oc = CYLINDER(s, R=R3, H=leght, O=0)
# Ob.subtractFrom(Oc)
# Oc.erase()
# port set point
# s.setPoint(0.0, 0.0, 0.0)
s.setPoint((elbowrad, 0.0, inspoint), (-1.0, 0.0, 0.0))
I need the IP-01 to be in the same place as the PS-01.
Any help gratefully appreciated.