init
This commit is contained in:
59
device/control/acs/buffercode/rmcposswitchcode.cpp
Normal file
59
device/control/acs/buffercode/rmcposswitchcode.cpp
Normal file
@@ -0,0 +1,59 @@
|
||||
#include "rmcposswitchcode.h"
|
||||
|
||||
RMCPosSwitchCode::RMCPosSwitchCode()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
QString RMCPosSwitchCode::getCode()
|
||||
{
|
||||
QString code("\n");
|
||||
code +=
|
||||
QString("VEL(ZA) = %1\n").arg(ZAAxisToSafePosVel)+
|
||||
QString("ACC(ZA) = %1\n").arg(ZAAxisToSafePosVel*10)+
|
||||
QString("DEC(ZA) = %1\n").arg(ZAAxisToSafePosVel*10)+
|
||||
QString("JERK(ZA) = %1\n").arg(ZAAxisToSafePosVel*100)+
|
||||
QString("KDEC(ZA) = %1\n").arg(ZAAxisToSafePosVel*100)+
|
||||
"ENABLE ZA\n"+
|
||||
QString("PTP/e ZA,%1\n").arg(ZAAxisSafePos)+
|
||||
QString("VEL(X) = %1\n").arg(XAxisVel)+
|
||||
QString("ACC(X) = %1\n").arg(XAxisVel*10)+
|
||||
QString("DEC(X) = %1\n").arg(XAxisVel*10)+
|
||||
QString("JERK(X) = %1\n").arg(XAxisVel*100)+
|
||||
QString("KDEC(X) = %1\n").arg(XAxisVel*100)+
|
||||
QString("VEL(Y) = %1\n").arg(YAxisVel)+
|
||||
QString("ACC(Y) = %1\n").arg(YAxisVel*10)+
|
||||
QString("DEC(Y) = %1\n").arg(YAxisVel*10)+
|
||||
QString("JERK(Y) = %1\n").arg(YAxisVel*100)+
|
||||
QString("KDEC(Y) = %1\n").arg(YAxisVel*100)+
|
||||
"ENABLE (X,Y)\n"+
|
||||
QString("PTP/er (X,Y),%1,%2\n").arg(XAxisTgPos).arg(YAxisTgPos)+
|
||||
"runF = 1\n"
|
||||
"STOP";
|
||||
return code;
|
||||
}
|
||||
|
||||
|
||||
void RMCPosSwitchCode::setTargetPos(double XPos,double YPos)
|
||||
{
|
||||
XAxisTgPos=XPos;
|
||||
YAxisTgPos=YPos;
|
||||
}
|
||||
|
||||
void RMCPosSwitchCode::setZAAxisSafePos(double value)
|
||||
{
|
||||
ZAAxisSafePos = value;
|
||||
}
|
||||
|
||||
void RMCPosSwitchCode::setZAAxisToSafePosVel(double value)
|
||||
{
|
||||
ZAAxisToSafePosVel = value;
|
||||
}
|
||||
|
||||
void RMCPosSwitchCode::setXYAxisVel(double XVel,double YVel)
|
||||
{
|
||||
XAxisVel = XVel;
|
||||
YAxisVel = YVel;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user