guoke1225 Posted March 16, 2017 Share Posted March 16, 2017 I need do cubic B-Spline movement in project, the host program write and read parameter through DPRAM.the golbal variable I42 is set to zero,so each programmed will move takes TM time. when running ,the host program will write the objective postion to UMAC and keep synchronous through HostMoveCounter and UMACMoveCounter variable. ;Spline Movement #define XSentPos M59 XSentPos->F:$060200 #define YSentPos M61 YSentPos->F:$060201 #define ZSentPos M63 ZSentPos->F:$060202 #define ASentPos M64 ASentPos->F:$060203 #define BSentPos M65 BSentPos->F:$060204 #define VSentPos M66 VSentPos->F:$060205 #define UMACMoveCounter M67 UMACMoveCounter->Y:$060206,0,16,U #define HostMoveCounter M68 HostMoveCounter->X:$060206,0,16,U #define SplineSymbol M69 SplineSymbol->Y:$060207,0,16,U OPEN PROG 10 CLEAR ABS SPLINE1 I42=0 ;Use TM to adjust Splline move time TM100 UMACMoveCounter=0 While (SplineSymbol = 1) PointSent=(HostMoveCounter-UMACMoveCounter)%2Power16 If (PointSent = 1) XDesPos=XSentPos YDesPos=YSentPos ZDesPos=ZSentPos ADesPos=ASentPos BDesPos=BSentPos VDesPos=VSentPos UMACMoveCounter=UMACMoveCounter+1 X(XSentPos)Y(YSentPos)Z(ZSentPos)A(ASentPos)B(BSentPos)V(VSentPos) EndIf the issue is that the movement speed is very slow, when I decrease the TM,it leads that the whole movement is not a continuous,it there any solution optimized the speed. Link to comment Share on other sites More sharing options...
curtwilson Posted March 16, 2017 Share Posted March 16, 2017 Your host computer program that is feeding points to the PMAC needs to check frequently the HostMoveCounter and UMACMoveCounter registers, and when it finds them equal, to send the next set of points. The more frequently it does this, the smaller the move time that can be executed. Many people have gotten times of just a few milliseconds using this technique. Link to comment Share on other sites More sharing options...
Recommended Posts