Skip to content

Commit aeb7110

Browse files
mozmckandypugh
authored andcommitted
Disable "override limits" at the end of the jog.
This fixes the issue that the override was not cleared in teleop (homed) mode Issue #2482
1 parent 27dca77 commit aeb7110

1 file changed

Lines changed: 14 additions & 0 deletions

File tree

src/emc/motion/control.c

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1399,6 +1399,13 @@ static void get_pos_cmds(long period)
13991399

14001400
axis_sync_carte_pos_to_teleop_tp(+1, pcmd_p); // teleop
14011401

1402+
if ( axis_jog_is_active() ) {
1403+
/* is any limit disabled for this move? */
1404+
if ( emcmotStatus->overrideLimitMask ) {
1405+
emcmotInternal->overriding = 1;
1406+
}
1407+
}
1408+
14021409
/* the next position then gets run through the inverse kins,
14031410
to compute the next positions of the joints */
14041411

@@ -1439,7 +1446,14 @@ static void get_pos_cmds(long period)
14391446

14401447
/* END OF OUTPUT KINS */
14411448

1449+
/* if overriding is true and the jog is complete, the limits should be re-enabled */
1450+
if ( ( emcmotInternal->overriding ) && ( !axis_jog_is_active() ) ) {
1451+
emcmotStatus->overrideLimitMask = 0;
1452+
emcmotInternal->overriding = 0;
1453+
}
1454+
14421455
/* end of teleop mode */
1456+
14431457
break;
14441458

14451459
case EMCMOT_MOTION_DISABLED:

0 commit comments

Comments
 (0)