>xabsl 2
Behavior Documentation
>
Index
>Agents
>Symbols
>Basic Behaviors
>Options
>> walk-omnidirectional
>>>
go-near
>>>
done
Option walk-omnidirectional
Parameters of that option:
Parameter
Measure
Range
Description
walk-omnidirectional.x
walk-omnidirectional.y
walk-omnidirectional.angle
absolute angle
State Machine
This browser can't display the SVG file
svg/option_walk-omnidirectional.svg
.
The
Adobe SVG Viewer 3.0
can be downloaded from
http://www.adobe.com/svg/viewer/install/main.html
State go-near
If that state is active,
>
The basic behavior
walk
is executed. Parameters:
walk.speed-x
=
(
distance-to
(
::
walk-omnidirectional.x
,
::
walk-omnidirectional.y
)
*
cos
(
angle-to
(
::
walk-omnidirectional.x
,
::
walk-omnidirectional.y
)
))
;
walk.speed-y
=
(
distance-to
(
::
walk-omnidirectional.x
,
::
walk-omnidirectional.y
)
*
sin
(
angle-to
(
::
walk-omnidirectional.x
,
::
walk-omnidirectional.y
)
))
;
walk.rotation-speed
=
((200
/ (
distance-to
(
::
walk-omnidirectional.x
,
::
walk-omnidirectional.y
)
!= 0
?
distance-to
(
::
walk-omnidirectional.x
,
::
walk-omnidirectional.y
) : 0 ))
* (::
walk-omnidirectional.angle
-
robot-pose.angle
)
)
;
The decision tree:
This browser can't display the SVG file
svg/option_walk-omnidirectional_state_go-near.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
(
(
distance-to
(
::
walk-omnidirectional.x
,
::
walk-omnidirectional.y
)
< 100
)
&&
(
abs
(
(
robot-pose.angle
- ::
walk-omnidirectional.angle
)
)
< 10
)
)
//
{
transition-to-state(
done
);
}
else
{
transition-to-state(
go-near
);
}
State done
This state is a target state.
If that state is active,
>
The basic behavior
stand
is executed.
The decision tree:
This browser can't display the SVG file
svg/option_walk-omnidirectional_state_done.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:
transition-to-state(
done
);