|
参考chrysler的自动对刀帖子,我做了一个对刀器,并成功对刀
http://www.ourdev.cn/bbs/bbs_content.jsp?bbs_sn=4353898&bbs_page_no=1&search_mode=1&search_text=对刀&bbs_id=1027
目前方法下,对刀后z轴零点为对刀器上平面高度,对刀器本身有一个厚度(假设为X),我想将z轴零点调到对刀器下平面高度?
目前对刀完成后,刀具上升20mm,Z坐标为20.
希望达到的效果,对刀完成后,刀具上升20-X,Z标为20
附带对刀代码,请问如何改动可实现此功能?
'Rem Probe Down by PEU (Based on Erniebro Work)
FeedCurrent = GetOemDRO(818) 'Get the current settings
ZCurrent = GetDro(2)
Code "G4 P1" 'Pause 1 second to give time to position probe plate
Code "F100" 'slow feed rate to 100 MM/MIN
GageH = GetOEMDRO (1002)
Rem Probe Down by PEU (Based on Erniebro Work)
FeedCurrent = GetOemDRO(818) 'Get the current settings
ZCurrent = GetOemDro(802)
Code "G4 P1" 'Pause 1 second to give time to position probe plate
Code "F100" 'slow feed rate to 100 MM/MIN
GageH = GetUserDRO(1152)
ZNew = ZCurrent - 30 'probe down 20 mm
Code "G31 Z" &ZNew
While IsMoving()
Wend
Call SetDro (2,GageH)
FinalMove = GageH * 1
Code "G0 Z" &FinalMove
Code "G0 Z" &20
Code "F" &FeedCurrent 'restore starting feed rate |
阿莫论坛20周年了!感谢大家的支持与爱护!!
曾经有一段真挚的爱情摆在我的面前,我没有珍惜,现在想起来,还好我没有珍惜……
|