iCAx开思工具箱

 找回密码
 立即注册

QQ登录

只需一步,快速开始

查看: 24169|回复: 1
打印 上一主题 下一主题

如何调用KF自动生成程序中的参数?

[复制链接]
跳转到指定楼层
楼主
发表于 2005-10-9 21:16:44 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式

马上注册登录,享用更多网站功能!

您需要 登录 才可以下载或查看,没有帐号?立即注册

x
下面的程序是KF自动生成的,如何调用其中的axis   这句(Number Modifiable) axis: 50; 是我加的
#! UGNX/KF 2.0

DefClass: Syl_kf_gear (ug_base_part);

(Number Modifiable) axis: 50;

(Child) axis_gear: {
Class, ug_expression;
value, 0;
};

(Child) axis_kf: {
Class, ug_expression;
value, ug_askValueOfExpressionStr( "axis" );
};

(Child) udf_axis1: {
Class, ug_udfs;
Name, "udf_axis1";
Library, "/Metric";
Parameters, {{axis,
40},
{Diameter,
40},
{b,
43.5}};
References, {};
referenceFrame, FrameXY(Point_(0,0,0,worldFrame());Vector_(1,0,0,worldFrame());Vector_(0,1,0,worldFrame()));
Suppress?, if axis_gear:value:=0 then
FALSE
else TRUE;
targetLayer, 0;
demandOrder, {axis_gear:};
};

(Child) udf_bond1: {
Class, ug_udfs;
Name, "udf_bond1";
Library, "/Metric";
Parameters, {{z,
80},
{m,
2},
{axis,
30},
{b_bond,
if (ug_askValueOfExpressionStr( "axis" )<25) then 6 else 12},
{h_bond,
if (ug_askValueOfExpressionStr( "axis" )<25) then 4 else 8},
{alpha,
20},
{p173,
11}};
References, {};
referenceFrame, FrameXY(Point_(0,0,0,worldFrame());Vector_(1,0,0,worldFrame());Vector_(0,1,0,worldFrame()));
Suppress?, if axis_gear:value:=1 then TRUE else FALSE;
targetLayer, 0;
demandOrder, {axis_gear:};
};

(Child) udf_gear01: {
Class, ug_udfs;
Name, "udf_gear01";
Library, "/Metric";
Parameters, {{alpha,
20},
{z,
125},
{m,
2},
{b,
43.5}};
References, {};
referenceFrame, FrameXY(Point_(0,0,0,worldFrame());Vector_(1,0,0,worldFrame());Vector_(0,1,0,worldFrame()));
Suppress?, FALSE;
targetLayer, 0;
demandOrder, {axis_gear:};
};

(Child) udf_gear_02: {
Class, ug_udfs;
Name, "udf_gear_02";
Library, "/Metric";
Parameters, {{depth,
17.4},
{Diameter,
229}};
References, {};
referenceFrame, FrameXY(Point_(0,0,0,worldFrame());Vector_(1,0,0,worldFrame());Vector_(0,1,0,worldFrame()));
Suppress?, if axis_gear:value:=0 then FALSE else TRUE;
targetLayer, 0;
demandOrder, {axis_gear:};
};

(Child) udf_gear_array: {
Class, ug_udfs;
Name, "udf_gear_array";
Library, "/Metric";
Parameters, {{m,
2},
{z,
80},
{axis,
30}};
References, {};
referenceFrame, FrameXY(Point_(0,0,0,worldFrame());Vector_(1,0,0,worldFrame());Vector_(0,1,0,worldFrame()));
Suppress?, if ug_askValueOfExpressionStr( "da" )<50 then
TRUE
else FALSE;
targetLayer, 0;
demandOrder, {axis_gear:};
};

(Child) udf_gear_blend1: {
Class, ug_udfs;
Name, "udf_gear_blend1";
Library, "/Metric";
Parameters, {{b,
43.5}};
referenceFrame, FrameXY(Point_(0,0,0,worldFrame());Vector_(1,0,0,worldFrame());Vector_(0,1,0,worldFrame()));
References, {};
targetLayer, 0;
Suppress?, FALSE;
};

(Child) udf_gear_boss1: {
Class, ug_udfs;
Name, "udf_gear_boss1";
Library, "/Metric";
Parameters, {{Limit_1,
-2.25},
{b,
43.5},
{axis,
40},
{Limit_2,
45.75}};
References, {};
referenceFrame, FrameXY(Point_(0,0,0,worldFrame());Vector_(1,0,0,worldFrame());Vector_(0,1,0,worldFrame()));
Suppress?, if axis_gear:value:=1 then TRUE else FALSE;
targetLayer, 0;
demandOrder, {axis_gear:};
};
分享到:  QQ好友和群QQ好友和群 QQ空间QQ空间 腾讯微博腾讯微博 腾讯朋友腾讯朋友
收藏收藏 分享淘帖 支持支持
沙发
发表于 2005-10-10 15:10:57 | 只看该作者

马上注册登录,享用更多网站功能!

您需要 登录 才可以下载或查看,没有帐号?立即注册

x
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

手板模型制作,在线3D打印服务

QQ|小黑屋|手机版|开思工具箱 CAD工具箱_CAM工具箱  

GMT+8, 2024-11-27 21:30 , Processed in 0.019538 second(s), 8 queries , Gzip On, Redis On.

Powered by Discuz! X3.3

© 2002-2024 www.iCAx.org

快速回复 返回顶部 返回列表