Project

General

Profile

Revision 80224838

ID80224838c853a4de884f958ae76c265379e11e9c
Parent c15f2677
Child e117f879, fa5ca6e3

Added by Priya over 3 years ago

Hacky fix to pause to work around issue that sending motor commands sometimes does nothing.

View differences:

scout/libscout/src/behaviors/pause_scout.cpp
27 27

  
28 28
void pause_scout::run()
29 29
{
30
  motors->set_sides(0, 0, MOTOR_ABSOLUTE);
31
  spinOnce();
32
  loop_rate->sleep();
30
  Duration delay(0.1);
31
  for(int i=0; i < 100; i++)
32
  {
33
    motors->set_sides(0, 0, MOTOR_ABSOLUTE);
34
    delay.sleep();
35
    spinOnce();
36
    loop_rate->sleep();
37
  }
33 38
}

Also available in: Unified diff