77* Author:
88* License: GPL Version 2
99* System: Linux
10- *
10+ *
1111* Copyright (c) 2004 All rights reserved.
1212*
1313********************************************************************/
@@ -217,7 +217,7 @@ int emcOperatorError(const char *fmt, ...)
217217 error_msg.error [0 ] = 0 ;
218218 // append error string
219219 va_start (ap, fmt);
220- vsnprintf (&error_msg.error [strlen (error_msg.error )],
220+ vsnprintf (&error_msg.error [strlen (error_msg.error )],
221221 sizeof (error_msg.error ) - strlen (error_msg.error ), fmt, ap);
222222 va_end (ap);
223223
@@ -466,7 +466,7 @@ static int checkInterpList(NML_INTERP_LIST * il, EMC_STAT * /*stat*/)
466466 emcOperatorError (" %s" , error_msg->error );
467467 break ;
468468 }
469-
469+
470470 // FIXME: there was limit checking tests below, see if they were needed
471471 case EMC_TRAJ_LINEAR_MOVE_TYPE:
472472 break ;
@@ -535,7 +535,7 @@ void readahead_reading(void)
535535 EMC_TASK_INTERP::WAITING;
536536 interp_list.clear ();
537537 emcAbortCleanup (EMC_ABORT::INTERPRETER_ERROR,
538- " interpreter error" );
538+ " interpreter error" );
539539 } else if (execRetval == -1
540540 || execRetval == INTERP_EXIT ) {
541541 emcStatus->task .interpState =
@@ -585,7 +585,7 @@ void readahead_reading(void)
585585
586586 if (emcStatus->task .readLine < programStartLine &&
587587 emcTaskPlanLevel () == 0 ) {
588-
588+
589589 // update the position with our current position, as the other positions are only skipped through
590590 CANON_UPDATE_END_POINT (emcStatus->motion .traj .actualPosition .tran .x ,
591591 emcStatus->motion .traj .actualPosition .tran .y ,
@@ -648,7 +648,7 @@ static void mdi_execute_hook(void)
648648 emcTaskCommand == 0 &&
649649 emcStatus->task .execState ==
650650 EMC_TASK_EXEC::DONE) {
651- emcTaskPlanClearWait ();
651+ emcTaskPlanClearWait ();
652652 mdi_execute_wait = 0 ;
653653 mdi_execute_hook ();
654654 }
@@ -670,11 +670,11 @@ static void mdi_execute_hook(void)
670670 // determine when a MDI command actually finishes normally.
671671 if (interp_list.len () == 0 &&
672672 emcTaskCommand == 0 &&
673- emcStatus->task .execState == EMC_TASK_EXEC::DONE &&
674- emcStatus->task .interpState != EMC_TASK_INTERP::IDLE &&
673+ emcStatus->task .execState == EMC_TASK_EXEC::DONE &&
674+ emcStatus->task .interpState != EMC_TASK_INTERP::IDLE &&
675675 emcStatus->motion .traj .queue == 0 &&
676- emcStatus->io .status == RCS_STATUS::DONE &&
677- !mdi_execute_wait &&
676+ emcStatus->io .status == RCS_STATUS::DONE &&
677+ !mdi_execute_wait &&
678678 !mdi_execute_next) {
679679
680680 // finished. Check for dequeuing of queued MDI command is done in emcTaskPlan().
@@ -1076,7 +1076,7 @@ static int emcTaskPlan(void)
10761076 case EMC_TASK_PLAN_STEP_TYPE:
10771077 // handles case where first action is to step the program
10781078 taskPlanRunCmd.line = 0 ; // run from start
1079- /* ! \todo FIXME-- can have GUI set this; send a run instead of a
1079+ /* ! \todo FIXME-- can have GUI set this; send a run instead of a
10801080 step */
10811081 retval = emcTaskIssueCommand (&taskPlanRunCmd);
10821082 if (retval != 0 ) break ;
@@ -1174,7 +1174,7 @@ static int emcTaskPlan(void)
11741174 break ;
11751175
11761176 case EMC_TASK_PLAN_STEP_TYPE:
1177- emcStatus->motion .traj .stepping = 1 ;
1177+ emcStatus->motion .traj .single_stepping = 1 ;
11781178 stepping = 1 ; // set stepping mode in case it's not
11791179 steppingWait = 0 ; // clear the wait
11801180 break ;
@@ -1189,7 +1189,7 @@ static int emcTaskPlan(void)
11891189
11901190 // handle interp readahead logic
11911191 readahead_reading ();
1192-
1192+
11931193 break ; // EMC_TASK_INTERP::READING
11941194
11951195 case EMC_TASK_INTERP::PAUSED: // ON, AUTO, PAUSED
@@ -1250,7 +1250,7 @@ static int emcTaskPlan(void)
12501250 break ;
12511251
12521252 case EMC_TASK_PLAN_STEP_TYPE:
1253- emcStatus->motion .traj .stepping = 1 ;
1253+ emcStatus->motion .traj .single_stepping = 1 ;
12541254 stepping = 1 ;
12551255 steppingWait = 0 ;
12561256 if (emcStatus->motion .traj .paused &&
@@ -1326,7 +1326,7 @@ static int emcTaskPlan(void)
13261326 break ;
13271327
13281328 case EMC_TASK_PLAN_STEP_TYPE:
1329- emcStatus->motion .traj .stepping = 1 ;
1329+ emcStatus->motion .traj .single_stepping = 1 ;
13301330 stepping = 1 ; // set stepping mode in case it's not
13311331 steppingWait = 0 ; // clear the wait
13321332 break ;
@@ -1895,10 +1895,10 @@ static int emcTaskIssueCommand(NMLmsg * cmd)
18951895
18961896 case EMC_TRAJ_PROBE_TYPE:
18971897 retval = emcTrajProbe (
1898- ((EMC_TRAJ_PROBE *) cmd)->pos ,
1898+ ((EMC_TRAJ_PROBE *) cmd)->pos ,
18991899 ((EMC_TRAJ_PROBE *) cmd)->type ,
19001900 ((EMC_TRAJ_PROBE *) cmd)->vel ,
1901- ((EMC_TRAJ_PROBE *) cmd)->ini_maxvel ,
1901+ ((EMC_TRAJ_PROBE *) cmd)->ini_maxvel ,
19021902 ((EMC_TRAJ_PROBE *) cmd)->acc ,
19031903 ((EMC_TRAJ_PROBE *) cmd)->probe_type );
19041904 break ;
@@ -1910,7 +1910,7 @@ static int emcTaskIssueCommand(NMLmsg * cmd)
19101910 emcAuxInputWaitIndex = -1 ;
19111911 taskExecDelayTimeout = 0.0 ;
19121912 } else {
1913- emcAuxInputWaitType = emcAuxInputWaitMsg->wait_type ; // remember what we are waiting for
1913+ emcAuxInputWaitType = emcAuxInputWaitMsg->wait_type ; // remember what we are waiting for
19141914 emcAuxInputWaitIndex = emcAuxInputWaitMsg->index ; // remember the input to look at
19151915 emcStatus->task .input_timeout = 2 ; // set timeout flag, gets cleared if input changes before timeout happens
19161916 // set the timeout clock to expire at 'now' + delay time
@@ -1927,7 +1927,7 @@ static int emcTaskIssueCommand(NMLmsg * cmd)
19271927 emcTrajUpdateTag (((EMC_TRAJ_LINEAR_MOVE *) cmd)->tag );
19281928 retval = emcTrajRigidTap (((EMC_TRAJ_RIGID_TAP *) cmd)->pos ,
19291929 ((EMC_TRAJ_RIGID_TAP *) cmd)->vel ,
1930- ((EMC_TRAJ_RIGID_TAP *) cmd)->ini_maxvel ,
1930+ ((EMC_TRAJ_RIGID_TAP *) cmd)->ini_maxvel ,
19311931 ((EMC_TRAJ_RIGID_TAP *) cmd)->acc ,
19321932 ((EMC_TRAJ_RIGID_TAP *) cmd)->scale );
19331933 break ;
@@ -2126,7 +2126,7 @@ static int emcTaskIssueCommand(NMLmsg * cmd)
21262126 // clear out the interpreter state
21272127 emcStatus->task .interpState = EMC_TASK_INTERP::IDLE;
21282128 emcStatus->task .execState = EMC_TASK_EXEC::DONE;
2129- emcStatus->motion .traj .stepping = 0 ;
2129+ emcStatus->motion .traj .single_stepping = 0 ;
21302130 stepping = 0 ;
21312131 steppingWait = 0 ;
21322132
@@ -2221,7 +2221,7 @@ static int emcTaskIssueCommand(NMLmsg * cmd)
22212221 break ;
22222222
22232223 case EMC_TASK_PLAN_EXECUTE_TYPE:
2224- emcStatus->motion .traj .stepping = 0 ;
2224+ emcStatus->motion .traj .single_stepping = 0 ;
22252225 stepping = 0 ;
22262226 steppingWait = 0 ;
22272227 execute_msg = (EMC_TASK_PLAN_EXECUTE *) cmd;
@@ -2317,7 +2317,7 @@ static int emcTaskIssueCommand(NMLmsg * cmd)
23172317 retval = -1 ;
23182318 break ;
23192319 }
2320- emcStatus->motion .traj .stepping = 0 ;
2320+ emcStatus->motion .traj .single_stepping = 0 ;
23212321 stepping = 0 ;
23222322 steppingWait = 0 ;
23232323 if (!taskplanopen && emcStatus->task .file [0 ] != 0 ) {
@@ -2366,7 +2366,7 @@ static int emcTaskIssueCommand(NMLmsg * cmd)
23662366 emcTrajResume ();
23672367 emcStatus->task .interpState = interpResumeState;
23682368 emcStatus->task .task_paused = 0 ;
2369- emcStatus->motion .traj .stepping = 0 ;
2369+ emcStatus->motion .traj .single_stepping = 0 ;
23702370 stepping = 0 ;
23712371 steppingWait = 0 ;
23722372 retval = 0 ;
@@ -2597,7 +2597,7 @@ static int emcTaskExecute(void)
25972597 // clear out the interpreter state
25982598 emcStatus->task .interpState = EMC_TASK_INTERP::IDLE;
25992599 emcStatus->task .execState = EMC_TASK_EXEC::DONE;
2600- emcStatus->motion .traj .stepping = 0 ;
2600+ emcStatus->motion .traj .single_stepping = 0 ;
26012601 stepping = 0 ;
26022602 steppingWait = 0 ;
26032603
@@ -2746,7 +2746,7 @@ static int emcTaskExecute(void)
27462746 }
27472747 // delay can be also be because we wait for an input
27482748 // if the index is set (not -1)
2749- if (emcAuxInputWaitIndex >= 0 ) {
2749+ if (emcAuxInputWaitIndex >= 0 ) {
27502750 switch (emcAuxInputWaitType) {
27512751 case WAIT_MODE_HIGH:
27522752 if (emcStatus->motion .synch_di [emcAuxInputWaitIndex] != 0 ) {
@@ -2757,12 +2757,12 @@ static int emcTaskExecute(void)
27572757 }
27582758 break ;
27592759
2760- case WAIT_MODE_RISE:
2760+ case WAIT_MODE_RISE:
27612761 if (emcStatus->motion .synch_di [emcAuxInputWaitIndex] == 0 ) {
27622762 emcAuxInputWaitType = WAIT_MODE_HIGH;
27632763 }
27642764 break ;
2765-
2765+
27662766 case WAIT_MODE_LOW:
27672767 if (emcStatus->motion .synch_di [emcAuxInputWaitIndex] == 0 ) {
27682768 emcStatus->task .input_timeout = 0 ; // clear timeout flag
@@ -2784,7 +2784,7 @@ static int emcTaskExecute(void)
27842784 emcStatus->task .execState = EMC_TASK_EXEC::DONE;
27852785 emcStatus->task .delayLeft = 0 ;
27862786 break ;
2787-
2787+
27882788 default :
27892789 emcOperatorError (" Unknown Wait Mode" );
27902790 }
@@ -3443,7 +3443,7 @@ int main(int argc, char *argv[])
34433443
34443444 // check for subordinate errors, and halt task if so
34453445 if ( emcStatus->motion .status == RCS_STATUS::ERROR
3446- && emcStatus->motion .on_soft_limit ) {
3446+ && emcStatus->motion .on_soft_limit ) {
34473447 if (!gave_soft_limit_message) {
34483448 emcOperatorError (" On Soft Limit" );
34493449 // if gui does not provide a means to switch to joint mode
@@ -3472,7 +3472,7 @@ int main(int argc, char *argv[])
34723472 }
34733473 // motion already should have reported this condition (and set RCS_STATUS::ERROR?)
34743474 // an M19 orient failed to complete within timeout
3475- // if ((emcStatus->motion.status == RCS_STATUS::ERROR) &&
3475+ // if ((emcStatus->motion.status == RCS_STATUS::ERROR) &&
34763476 // (emcStatus->motion.spindle.orient_state == EMCMOT_ORIENT_FAULTED) &&
34773477 // (emcStatus->motion.spindle.orient_fault != 0)) {
34783478 // emcOperatorError("wait for orient complete timed out");
@@ -3505,7 +3505,7 @@ int main(int argc, char *argv[])
35053505 // clear out the interpreter state
35063506 emcStatus->task .interpState = EMC_TASK_INTERP::IDLE;
35073507 emcStatus->task .execState = EMC_TASK_EXEC::DONE;
3508- emcStatus->motion .traj .stepping = 0 ;
3508+ emcStatus->motion .traj .single_stepping = 0 ;
35093509 stepping = 0 ;
35103510 steppingWait = 0 ;
35113511
0 commit comments