Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 21a73717a5 |
Submodule sinqMotor updated: 8689c79f19...7a0de4e9d9
@@ -357,7 +357,10 @@ asynStatus masterMacsAxis::doPoll(bool *moving) {
|
|||||||
|
|
||||||
if (timedOut) {
|
if (timedOut) {
|
||||||
setAxisParamChecked(this, motorMessageText,
|
setAxisParamChecked(this, motorMessageText,
|
||||||
"Timed out while waiting for a handshake");
|
"Timed out while waiting for a handshake. "
|
||||||
|
"Please call the support.");
|
||||||
|
|
||||||
|
poll_status = asynError;
|
||||||
}
|
}
|
||||||
|
|
||||||
pC_->read(axisNo_, 86, response);
|
pC_->read(axisNo_, 86, response);
|
||||||
@@ -377,14 +380,10 @@ asynStatus masterMacsAxis::doPoll(bool *moving) {
|
|||||||
pMasterMacsA_->waitForHandshake = false;
|
pMasterMacsA_->waitForHandshake = false;
|
||||||
pMasterMacsA_->targetReachedUninitialized = false;
|
pMasterMacsA_->targetReachedUninitialized = false;
|
||||||
} else {
|
} else {
|
||||||
// Still waiting for the handshake - try again in the next busy
|
|
||||||
// poll. This is already part of the movement procedure.
|
|
||||||
*moving = true;
|
*moving = true;
|
||||||
|
|
||||||
setAxisParamChecked(this, motorStatusMoving, *moving);
|
setAxisParamChecked(this, motorStatusMoving, *moving);
|
||||||
setAxisParamChecked(this, motorStatusDone, !(*moving));
|
setAxisParamChecked(this, motorStatusDone, !(*moving));
|
||||||
|
return poll_status;
|
||||||
return asynSuccess;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -403,6 +402,9 @@ asynStatus masterMacsAxis::doPoll(bool *moving) {
|
|||||||
return rw_status;
|
return rw_status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// If we wait for a handshake, but the motor was moving in its last poll
|
||||||
|
// cycle and has reached its target, it is not moving. Otherwise it is
|
||||||
|
// considered moving, even if we're still waiting for the handshake.
|
||||||
if (pMasterMacsA_->targetReachedUninitialized) {
|
if (pMasterMacsA_->targetReachedUninitialized) {
|
||||||
*moving = false;
|
*moving = false;
|
||||||
} else {
|
} else {
|
||||||
@@ -679,7 +681,6 @@ asynStatus masterMacsAxis::doPoll(bool *moving) {
|
|||||||
if (pl_status != asynSuccess) {
|
if (pl_status != asynSuccess) {
|
||||||
return pl_status;
|
return pl_status;
|
||||||
}
|
}
|
||||||
|
|
||||||
return poll_status;
|
return poll_status;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -805,8 +806,8 @@ asynStatus masterMacsAxis::doReset() {
|
|||||||
|
|
||||||
asynStatus status = asynSuccess;
|
asynStatus status = asynSuccess;
|
||||||
|
|
||||||
// Reset the controller ("node reset")
|
// Reset any errors
|
||||||
status = pC_->write(axisNo_, 16, "");
|
status = pC_->write(axisNo_, 17, "");
|
||||||
if (status != asynSuccess) {
|
if (status != asynSuccess) {
|
||||||
setAxisParamChecked(this, motorStatusProblem, true);
|
setAxisParamChecked(this, motorStatusProblem, true);
|
||||||
}
|
}
|
||||||
@@ -822,9 +823,9 @@ asynStatus masterMacsAxis::nodeReset() {
|
|||||||
|
|
||||||
asynStatus status = asynSuccess;
|
asynStatus status = asynSuccess;
|
||||||
|
|
||||||
// Reset any errors in the controller. Since the node reset results in a
|
// Reset the controller ("node reset"). Since the node reset results in a
|
||||||
// power cycle, we use the corresponding timeout.
|
// power cycle, we use the corresponding timeout.
|
||||||
status = pC_->write(axisNo_, 17, "", PowerCycleTimeout);
|
status = pC_->write(axisNo_, 16, "", PowerCycleTimeout);
|
||||||
if (status != asynSuccess) {
|
if (status != asynSuccess) {
|
||||||
setAxisParamChecked(this, motorStatusProblem, true);
|
setAxisParamChecked(this, motorStatusProblem, true);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user