Option goalie-clear-ball

The goalie tries to clear the ball.

State Machine

This browser can't display the SVG file svg/option_goalie-clear-ball.svg.



The Adobe SVG Viewer 3.0 can be downloaded from http://www.adobe.com/svg/viewer/install/main.html

State walk

If that state is active,
 >  The basic behavior go-to-ball-without-turning is executed.
 
The decision tree:
  This browser can't display the SVG file svg/option_goalie-clear-ball_state_walk.svg.



The Adobe SVG Viewer 3.0 can be downloaded from http://www.adobe.com/svg/viewer/install/main.html
 
Pseudo code of the decision tree:
 
if (retrieve-kick( angle.goal-kick-angle , 20 , kick-selection-table.goalie ) != action.nothing)   // kick possible
{
  
transition-to-state(kick);
}
else if (
(abs( ball.seen.y ) < 300)
&& 
(abs( (ball.seen.angle + robot-pose.angle) ) > 100)
)   // ball is behind goalie
{
  
transition-to-state(ball-behind);
}
else
{
  
transition-to-state(walk);
}

State kick

If that state is active,
 >  The option execute-kick is executed. Parameters:
 
    execute-kick.action  =  retrieve-kick( angle.goal-kick-angle , 20 , kick-selection-table.goalie ) ;
 
 >  These output symbols are set:
 
    strategy.ball-handling  =  performing-a-kick
 
The decision tree:
  This browser can't display the SVG file svg/option_goalie-clear-ball_state_kick.svg.



The Adobe SVG Viewer 3.0 can be downloaded from http://www.adobe.com/svg/viewer/install/main.html
 
Pseudo code of the decision tree:
 
if (subsequent-option-reached-target-state)   // kick finished
{
  
transition-to-state(walk);
}
else
{
  
transition-to-state(kick);
}

State ball-behind

If that state is active,
 >  The option turn-and-release is executed. Parameters:
 
    turn-and-release.angle  =  (angle.perfect-angle-to-opponent-goal - (30 * sgn( angle.perfect-angle-to-opponent-goal ))) ;
 
 >  These output symbols are set:
 
    head-control-mode  =  head-control-mode.search-for-ball
    leds.back-front-white  =  back-front-white.llll
 
The decision tree:
  This browser can't display the SVG file svg/option_goalie-clear-ball_state_ball-behind.svg.



The Adobe SVG Viewer 3.0 can be downloaded from http://www.adobe.com/svg/viewer/install/main.html
 
Pseudo code of the decision tree:
 
if (strategy.ball-is-handled-at-the-moment)   // ball is handled
{
  
transition-to-state(ball-behind);
}
else if (abs( (ball.seen.angle + robot-pose.angle) ) < 90)   // ball is no longer behind goalie
{
  
transition-to-state(walk);
}
else
{
  
transition-to-state(ball-behind);
}