Skip to content

Commit

Permalink
Blocked driver control of lift and arm while lift encoder is resetting
Browse files Browse the repository at this point in the history
  • Loading branch information
nickmertin committed Feb 11, 2018
1 parent dc272c6 commit 6c18066
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ case liftResetEncoder:

void handleLift()
{
if (liftState == liftManaged ) return;
if (liftState == liftManaged || liftState == liftResetEncoder) return;

if (RISING(JOY_LIFT))
{
Expand Down Expand Up @@ -639,7 +639,7 @@ NEW_ASYNC_VOID_1(mobileWaitForSlowHold, TVexJoysticks);

void handleMobile()
{
if (mobileState == mobileManaged)
if (mobileState == mobileManaged || liftState == liftResetEncoder)
return;

if (mobileState == mobileUpToMiddle || mobileState == mobileDownToMiddle || mobileState == mobileMiddle)
Expand Down

0 comments on commit 6c18066

Please sign in to comment.