Commit d73c5d9d authored by Timothy Stack's avatar Timothy Stack

don't send a wont-execute status, send the status value received

previously, since it has more information
parent 328c7c0c
......@@ -323,15 +323,13 @@ void wheelManager::motionStarted(void)
void wheelManager::motionFinished(int status, wmCallback *callback)
{
this->wm_last_status = status;
if (debug) {
fprintf(stderr, "debug: motion finished -- %d\n", status);
}
if (status != aGARCIA_ERRFLAG_WONTEXECUTE) {
if ((this->wm_last_status != aGARCIA_ERRFLAG_NORMAL) &&
(this->wm_last_status != aGARCIA_ERRFLAG_ABORT)) {
if ((status != aGARCIA_ERRFLAG_NORMAL) &&
(status != aGARCIA_ERRFLAG_ABORT)) {
if (debug) {
fprintf(stderr, "debug: set error LED\n");
}
......@@ -341,10 +339,12 @@ void wheelManager::motionFinished(int status, wmCallback *callback)
this->wm_dashboard->endMove(this->wm_garcia);
this->wm_dashboard->remUserLEDClient(&this->wm_moving_notice);
this->wm_last_status = status;
}
if (callback != NULL) {
callback->call(status);
callback->call(this->wm_last_status);
delete callback;
callback = NULL;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment