Option vlc-shooter

The VLC-shooter

State Machine

This browser can't display the SVG file svg/option_vlc-shooter.svg.



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

State init

If that state is active,
 >  The basic behavior stand is executed.
 
 >  These output symbols are set:
 
    head-control-mode  =  head-control-mode.search-auto
 
The decision tree:
  This browser can't display the SVG file svg/option_vlc-shooter_state_init.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 (
(time-of-state-execution > 2000)
&& 
(
(robot-state.head-button-pressed-short)
|| 
(robot-state.fore-back-button-pressed-short)
|| 
(robot-state.middle-back-button-pressed-short)
|| 
(robot-state.hind-back-button-pressed-short)
)
)   // any button pressed short
{
  
transition-to-state(kickoff);
}
else
{
  
transition-to-state(init);
}

State kickoff

If that state is active,
 >  The option get-to-position-and-avoid-obstacles is executed. Parameters:
 
    get-to-position-and-avoid-obstacles.x  =  -200 ;
    get-to-position-and-avoid-obstacles.y  =  0 ;
    get-to-position-and-avoid-obstacles.destination-angle  =  0 ;
    get-to-position-and-avoid-obstacles.max-speed  =  450 ;
    get-to-position-and-avoid-obstacles.no-obstacle-avoidance-distance  =  500 ;
    get-to-position-and-avoid-obstacles.avoid-penalty-areas  =  0 ;
    get-to-position-and-avoid-obstacles.avoidance-level  =  1 ;
 
 >  These output symbols are set:
 
    head-control-mode  =  head-control-mode.search-for-landmarks
 
The decision tree:
  This browser can't display the SVG file svg/option_vlc-shooter_state_kickoff.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 (
(time-of-state-execution > 1000)
&& 
(robot-state.head-button-pressed-short)
)   // head button pressed for 3 sec
{
  
transition-to-state(pauseAndBarking);
}
else if (
(ball.just-seen)
|| 
(distance-to( -200 , 0 ) < 500)
)   //
{
  
transition-to-state(playing);
}
else
{
  
transition-to-state(kickoff);
}

State pauseAndBarking

If that state is active,
 >  The basic behavior stand is executed.
 
 >  These output symbols are set:
 
    sound-request  =  sound-request.bark1
    head-control-mode  =  head-control-mode.look-between-feet
 
The decision tree:
  This browser can't display the SVG file svg/option_vlc-shooter_state_pauseAndBarking.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 (time-of-state-execution > 1200)   //
{
  
transition-to-state(pause);
}
else
{
  
transition-to-state(pauseAndBarking);
}

State pause

If that state is active,
 >  The basic behavior stand is executed.
 
 >  These output symbols are set:
 
    sound-request  =  sound-request.bing01
    head-control-mode  =  head-control-mode.search-auto
 
The decision tree:
  This browser can't display the SVG file svg/option_vlc-shooter_state_pause.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 (
(time-of-state-execution > 500)
&& 
(
(robot-state.head-button-pressed-short)
|| 
(robot-state.fore-back-button-pressed-short)
|| 
(robot-state.middle-back-button-pressed-short)
|| 
(robot-state.hind-back-button-pressed-short)
)
)   // any button pressed short
{
  
transition-to-state(playing);
}
else
{
  
transition-to-state(pause);
}

State playing

If that state is active,
 >  The option vlc-playing is executed.
 
 >  These output symbols are set:
 
    head-control-mode  =  head-control-mode.search-auto
 
The decision tree:
  This browser can't display the SVG file svg/option_vlc-shooter_state_playing.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 (
(time-of-state-execution > 1000)
&& 
(robot-state.head-button-pressed-short)
)   // head button pressed for 3 sec
{
  
transition-to-state(pauseAndBarking);
}
else if (
(time-of-state-execution > 1000)
&& 
(
(robot-state.fore-back-button-pressed-short)
|| 
(robot-state.middle-back-button-pressed-short)
|| 
(robot-state.hind-back-button-pressed-short)
)
)   // one of the back buttons was pressed as an indication for a goal
{
  
transition-to-state(kickoff);
}
else
{
  
transition-to-state(playing);
}