Skip to content

Commit

Permalink
Fix build error
Browse files Browse the repository at this point in the history
  • Loading branch information
alexDickhans committed Jan 23, 2022
1 parent f863a0b commit 6831456
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/driver/motorButton.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -76,15 +76,16 @@ namespace Pronounce {
this->motor->move_velocity(neutralAuthority);
break;
}
}


double speed = this->motor->get_actual_velocity();
double jammed = jammed;

// set jammed to true if the speed of the motor indicates that it is jammed
if (speed < dejamSpeed && this->getButtonStatus() != NEUTRAL) {
this->jammed = true;
} else {
}
else {
this->jammed = false;
}

Expand All @@ -97,7 +98,7 @@ namespace Pronounce {
if (this->dejamStartTime - pros::millis() > dejamTime && jammed) {
this->motor->move_velocity(dejamAuthority);
}
}
}

MotorButton::~MotorButton() {
}
Expand Down

0 comments on commit 6831456

Please sign in to comment.