protected static double GetAxisPosition(TKUnit.IOTable.AxisType p_Axis) { if (!Common.CTAPSetup.EnableTK) { return(0); } int iPitch = 0, iPulse = 0, iCounter = 0, itemp2 = 0, itemp3 = 0, itemp4 = 0; //TK.CCTKform.TK_Motion.CCMotionModule_GetPitch((int)p_Axis, ref iPitch, ref itemp2, ref itemp3, ref itemp4); //TK.CCTKform.TK_Motion.CCMotionModule_GetMotorPulse((int)p_Axis, ref iPulse, ref itemp2, ref itemp3, ref itemp4); //TK.CCTKform.TK_Motion.CCMotionModule_GetCounter((int)p_Axis, ref iCounter, ref itemp2, ref itemp3, ref itemp4); if (iPulse > 0) { return(iCounter * (iPitch / iPulse)); } else { return(0); } }
protected static bool IsRunning(TKUnit.IOTable.AxisType p_Axis) { //return (TK.CCTKform.TK_Motion.CCMotionModule_IsMotorRunning((int)p_Axis) == 1 ? true : false); return(false); }