Actuators Class Reference

#include <actuators.h>

List of all members.

Public Member Functions

 Actuators ()
 ~Actuators ()
void setStiffness (int jointindex, float value)
void setStiffnessHead (float value[])
void setStiffnessAll (float values[])
int setStiffnessAll (float values[], int time)
void setStiffnessNotHead (float values[])
void clearDCM ()
void resetMotorBoards ()
void resetChestBoard ()
void sendFrameToBody (float positions[], float hardnesses[])
void sendFrameToNotHead (float positions[], float hardnesses[])
int goToAngle (int jointindex, float position, int time)
int goToAnglesAll (float positions[], int time)
int goToAnglesWithVelocityAll (float positions[], float velocity)
int goToAnglesNotHead (float positions[], int time)
int goToAnglesWithVelocityNotHead (float positions[], float velocity)
int goToAngleHeadYaw (float position, int time)
int goToAngleHeadPitch (float position, int time)

Static Public Attributes

static float MaxBatteryVoltage = 24654.0

Constructor & Destructor Documentation

Actuators::Actuators (  ) 
Actuators::~Actuators (  ) 

Member Function Documentation

void Actuators::clearDCM (  ) 

Clears the targets saved in the dcm

int Actuators::goToAngle ( int  jointindex,
float  position,
int  time 
)

Specify a new joint for a single joint

Parameters:
jointindex the index of the joint eg. J_L_ANKLE_PITCH
position the new target angle
time the time to get to the target position

Note. that successive calls to this function can make a 'motion curve' because existing dcm commands are only erased if they are AFTER the new command. So goToAngle(0, 0, 100) and goToAngle(0, -1, 300) will make the head goto 0 and then to -1

int Actuators::goToAngleHeadPitch ( float  position,
int  time 
)

Go to the new head pitch position

Parameters:
position the new position in radians
time the time to get to that position in milliseconds
Returns:
finishtime the dcmTime the motion will finish. I stress that this is the dcmTime; the dcmTime the motion will finish; the dcmTime.
int Actuators::goToAngleHeadYaw ( float  position,
int  time 
)

Go to the new head yaw position

Parameters:
position the new position in radians
time the time to get to that position in milliseconds
Returns:
finishtime the dcmTime the motion will finish. I stress that this is the dcmTime; the dcmTime the motion will finish; the dcmTime.
int Actuators::goToAnglesAll ( float  positions[],
int  time 
)

Go to the new positions at the specified velocity (the aldcm does the interpolation)

Parameters:
positions[] the new target positions (must be of length ALIAS_TARGETS_ALL_LENGTH)
time the time in ms from now to reach the desired positions
Returns:
finishTime the dcmTime the motion will finish. I stress that this is the dcmTime; the dcmTime the motion will finish; the dcmTime.
int Actuators::goToAnglesNotHead ( float  positions[],
int  time 
)

Go to the new positions at the specified velocity (the aldcm does the interpolation)

Parameters:
positions[] the new target positions (must be of length ALIAS_TARGETS_NOT_HEAD_LENGTH)
time the time in ms from now to reach the desired positions
Returns:
finishTime the dcmTime the motion will finish. I stress that this is the dcmTime; the dcmTime the motion will finish; the dcmTime.
int Actuators::goToAnglesWithVelocityAll ( float  positions[],
float  velocity 
)

Go to the new positions at the specified velocity (the aldcm does the interpolation)

Parameters:
positions[] the new target positions (must be of length ALIAS_TARGETS_ALL_LENGTH)
velocity the velocity in rad/s
Returns:
finishTime the dcmTime the motion will finish. I stress that this is the dcmTime; the dcmTime the motion will finish; the dcmTime.
int Actuators::goToAnglesWithVelocityNotHead ( float  positions[],
float  velocity 
)

Go to the new positions at the specified velocity (the aldcm does the interpolation)

Parameters:
positions[] the new target positions (must be of length ALIAS_TARGETS_NOT_HEAD_LENGTH)
velocity the velocity in rad/s
Returns:
finishTime the dcmTime the motion will finish. I stress that this is the dcmTime; the dcmTime the motion will finish; the dcmTime.
void Actuators::resetChestBoard (  ) 

Resets the chest board. Use this if you suspect the chest board is playing up

void Actuators::resetMotorBoards (  ) 

Resets the motor boards. Use this to reset all of the motors and hopefully return stiffness

void Actuators::sendFrameToBody ( float  positions[],
float  hardnesses[] 
)

Send an entire motion frame to the whole body

Parameters:
positions[] the target joint positions for the next dcm cycle (must have length == ALIAS_TARGETS_ALL_LENGTH)
hardnesses[] the joint hardnesses for the next dcm cycle (must have length == ALIAS_TARGETS_ALL_LENGTH)
void Actuators::sendFrameToNotHead ( float  positions[],
float  hardnesses[] 
)

Send an entire motion frame to the every joint except the head; the head is for Steve :D

Parameters:
positions[] the target joint positions for the next dcm cycle (must have length == ALIAS_TARGETS_NOT_HEAD_LENGTH)
hardnesses[] the joint hardnesses for the next dcm cycle (must have length == ALIAS_TARGETS_NOT_HEAD_LENGTH)
void Actuators::setStiffness ( int  jointindex,
float  value 
)

Set the stiffness (hardness) for a single joint

Parameters:
jointindex the index of the joint to change the stiffness for (eg. J_L_ANKLE_PITCH)
value the new hardness value
int Actuators::setStiffnessAll ( float  values[],
int  time 
)
void Actuators::setStiffnessAll ( float  values[]  ) 

Set the stiffness for every joint

Parameters:
values[] the new hardness values (must be length == ALIAS_HARDNESS_ALL_LENGTH)
void Actuators::setStiffnessHead ( float  values[]  ) 

Set the stiffness (hardness) for the two head joints

Parameters:
values[2] the new stiffness values
void Actuators::setStiffnessNotHead ( float  values[]  ) 

Set the stiffness for every joint

Parameters:
values[] the new hardness values (must be length == ALIAS_HARDNESS_NOT_HEAD_LENGTH)

Member Data Documentation

float Actuators::MaxBatteryVoltage = 24654.0 [static]

The documentation for this class was generated from the following files:

Generated on Fri Oct 9 13:42:11 2009 for naowalkoptimiser by  doxygen 1.6.1