6 #ifndef STANDING_DEMO_ACTIONS_H
7 #define STANDING_DEMO_ACTIONS_H
10 #define NAME_HEAD_PITCH "head_pitch"
11 #define NAME_HEAD_YAW "neck_yaw"
12 #define NAME_LEFT_SHOULDER_PITCH "left_shoulder_pitch"
13 #define NAME_LEFT_SHOULDER_ROLL "left_shoulder_roll"
14 #define NAME_LEFT_ELBOW_PITCH "left_elbow_pitch"
15 #define NAME_RIGHT_SHOULDER_PITCH "right_shoulder_pitch"
16 #define NAME_RIGHT_SHOULDER_ROLL "right_shoulder_roll"
17 #define NAME_RIGHT_ELBOW_PITCH "right_elbow_pitch"
18 #define NAME_LEFT_KNEE_PITCH "left_knee_pitch"
19 #define NAME_LEFT_ANKLE_PITCH "left_ankle_pitch"
20 #define NAME_LEFT_ANKLE_ROLL "left_ankle_roll"
21 #define NAME_RIGHT_KNEE_PITCH "right_knee_pitch"
22 #define NAME_RIGHT_ANKLE_PITCH "right_ankle_pitch"
23 #define NAME_RIGHT_ANKLE_ROLL "right_ankle_roll"
26 #define DSP_HEAD_PITCH 0.00
27 #define DSP_HEAD_YAW 0.00
28 #define DSP_LEFT_SHOULDER_PITCH -0.26
29 #define DSP_LEFT_SHOULDER_ROLL 0.00
30 #define DSP_LEFT_ELBOW_PITCH -0.74
31 #define DSP_RIGHT_SHOULDER_PITCH -0.26
32 #define DSP_RIGHT_SHOULDER_ROLL 0.00
33 #define DSP_RIGHT_ELBOW_PITCH -0.74
36 #define MIN_NOTHING_DELAY 2.5
37 #define MAX_NOTHING_DELAY 10.0
38 #define MIN_LEG_DANGLE_TIME 5.0
39 #define MAX_LEG_DANGLE_TIME 20.0
40 #define MIN_HEAD_IDLE_TIME 5.0
41 #define MAX_HEAD_IDLE_TIME 20.0
42 #define MIN_POST_MOTION_DELAY 1.0
43 #define MAX_POST_MOTION_DELAY 4.0
44 #define MIN_NUM_MOTIONS 1
45 #define MAX_NUM_MOTIONS 4
48 #define MAIN_FN_DELAY 3.0 // Time to wait at the beginning of the main function before doing anything
49 #define INIT_DELAY 5.0 // Time to wait during initialisation before planning the first action
50 #define PRE_ACTION_DELAY 1.0 // Time to wait (after cessation of all previous motion) before executing a new action
51 #define DEFAULT_EFFORT 0.25 // Default effort to use for normal standing-based motions
52 #define RETURN_STANDING_VELOCITY 0.60 // Angular velocity with which to return to the default standing position in the return to standing state
53 #define RETURN_STANDING_EFFORT 0.10 // Effort with which to return to the default standing position in the return to standing state
54 #define LIMB_CONTROL_TIME_BIAS 0.05 // Number of seconds to bias limbControlFinishTime by in order to make reasonably sure limb control is really finished when we query it again
60 namespace statecontroller
66 namespace standing_demo
85 const std::string DemoActionName[NUM_ACTIONS + 1] =
95 class StandingDemoAction
99 static void ActDoNothing(StandingDemoSC* sc, StateQueue* Q);
100 static void ActHeadIdle(StandingDemoSC* sc, StateQueue* Q);
101 static void ActPlayMotions(StandingDemoSC* sc, StateQueue* Q);
102 static void ActPlayMotionsHI(StandingDemoSC* sc, StateQueue* Q);
Implements a dynamic State queue.
Definition: state_controller.h:522