NX/UG二次开发—刀路事件类型注意事项

一、在做刀路编辑的时候,如果基于NX12以及以上版本,NXOpen封装好了编辑和读取刀路的函数,但是在一些低版本中,实现此功能,需要一些dll导出函数。在libcamsja.dll中NX也封装了一些比较方便的函数,但对于没有内部文档的非正规军,很难去猜测函数的参数类型。但可以通过apimotion可以看到一些调用函数,可以在libcams.dll中全部找到对应的编辑函数。在测试发现一些设置是无效的,开始以为函数不对,后来发现,刀路事件是分类型的,在UFUN帮助文档中给出了明确的类型:

#define    UF_cevent_3x_linear_subtype               150
#define    UF_cevent_3x_linear_with_feed_subtype     151
#define    UF_cevent_3x_linear_cust_feed_subtype     152
#define    UF_cevent_5x_linear_subtype               153
#define    UF_cevent_5x_linear_with_feed_subtype     154
#define    UF_cevent_5x_linear_cust_feed_subtype     155
#define    UF_cevent_3x_circular_subtype             156
#define    UF_cevent_3x_circular_with_feed_subtype   157
#define    UF_cevent_3x_circular_cust_feed_subtype   158
#define    UF_cevent_5x_circular_subtype             159
#define    UF_cevent_5x_circular_with_feed_subtype   160
#define    UF_cevent_5x_circular_cust_feed_subtype   161
#define    UF_cevent_3x_helical_subtype              162
#define    UF_cevent_3x_helical_with_feed_subtype    163
#define    UF_cevent_3x_helical_cust_feed_subtype    164
#define    UF_cevent_5x_helical_subtype              165
#define    UF_cevent_5x_helical_with_feed_subtype    166
#define    UF_cevent_5x_helical_cust_feed_subtype    167
#define    UF_cevent_3x_nurbs_subtype                168
#define    UF_cevent_3x_nurbs_with_feed_subtype      169
#define    UF_cevent_3x_nurbs_cust_feed_subtype      170
#define    UF_cevent_5x_nurbs_subtype                171
#define    UF_cevent_5x_nurbs_with_feed_subtype      172
#define    UF_cevent_5x_nurbs_cust_feed_subtype      173

二、比如3轴或定轴刀路,编辑刀路界面中是不包含指定轴的,可以看下两张图对比,第一张图是三轴程序,第二张图是五轴程序:

三、对于UDOP创建的刀路,可以发现,他的运动类型是定制,与自带策略创建的刀路是不同的,二次修改程序转速进给,刀路是不继承的,还需要重新生成刀路,才生效。主要原因是,UFUN函数调用的底层逻辑创建的刀路类型是***_cust_feed_subtype类型,而且并没有提供设置接口。因此,可以通过刀轨编辑,来实现feed参数的调整。

  • 28
    点赞
  • 22
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

恩·艾克斯·红

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值