Tabnine Logo
HandTrajectoryCommand
Code IndexAdd Tabnine to your IDE (free)

How to use
HandTrajectoryCommand
in
us.ihmc.humanoidRobotics.communication.controllerAPI.command

Best Java code snippets using us.ihmc.humanoidRobotics.communication.controllerAPI.command.HandTrajectoryCommand (Showing top 14 results out of 315)

origin: us.ihmc/IHMCHumanoidRobotics

public WholeBodyTrajectoryCommand()
{
 for (RobotSide robotSide : RobotSide.values)
 {
   HandTrajectoryCommand handTrajectoryControllerCommand = new HandTrajectoryCommand();
   ArmTrajectoryCommand armTrajectoryControllerCommand = new ArmTrajectoryCommand();
   FootTrajectoryCommand footTrajectoryControllerCommand = new FootTrajectoryCommand();
   handTrajectoryControllerCommands.put(robotSide, handTrajectoryControllerCommand);
   armTrajectoryControllerCommands.put(robotSide, armTrajectoryControllerCommand);
   footTrajectoryControllerCommands.put(robotSide, footTrajectoryControllerCommand);
   allControllerCommands.add(handTrajectoryControllerCommand);
   allControllerCommands.add(armTrajectoryControllerCommand);
   allControllerCommands.add(footTrajectoryControllerCommand);
 }
 allControllerCommands.add(chestTrajectoryControllerCommand);
 allControllerCommands.add(pelvisTrajectoryControllerCommand);
}
origin: us.ihmc/CommonWalkingControlModules

public void handleHandTrajectoryCommand(HandTrajectoryCommand command)
{
 boolean success;
 switch (command.getExecutionMode())
 {
 case OVERRIDE:
   boolean initializeToCurrent = stateMachine.getCurrentStateEnum() != HandControlMode.TASKSPACE;
   success = taskspaceControlState.handleHandTrajectoryCommand(command, handControlFrame, initializeToCurrent);
   if (success)
    requestedState.set(taskspaceControlState.getStateEnum());
   else
    PrintTools.warn(this, "Can't execute HandTrajectoryCommand! " + command.getRobotSide());
   return;
 case QUEUE:
   success = taskspaceControlState.queueHandTrajectoryCommand(command);
   if (!success)
   {
    holdPositionInJointspace();
    PrintTools.warn(this, "Can't execute HandTrajectoryCommand! " + command.getRobotSide());
   }
   return;
 default:
   PrintTools.warn(this, "Unknown " + ExecutionMode.class.getSimpleName() + " value: " + command.getExecutionMode() + ". Command ignored.");
   return;
 }
}
origin: us.ihmc/CommonWalkingControlModules

private int queueExceedingTrajectoryPointsIfNeeded(HandTrajectoryCommand command)
{
 int numberOfTrajectoryPoints = command.getNumberOfTrajectoryPoints();
 int maximumNumberOfWaypoints = positionTrajectoryGenerator.getMaximumNumberOfWaypoints() - positionTrajectoryGenerator.getCurrentNumberOfWaypoints();
 if (numberOfTrajectoryPoints <= maximumNumberOfWaypoints)
   return numberOfTrajectoryPoints;
 HandTrajectoryCommand commandForExcedent = commandQueue.addFirst();
 numberOfQueuedCommands.increment();
 commandForExcedent.clear();
 commandForExcedent.setPropertiesOnly(command);
 for (int trajectoryPointIndex = maximumNumberOfWaypoints; trajectoryPointIndex < numberOfTrajectoryPoints; trajectoryPointIndex++)
 {
   commandForExcedent.addTrajectoryPoint(command.getTrajectoryPoint(trajectoryPointIndex));
 }
 double timeOffsetToSubtract = command.getTrajectoryPoint(maximumNumberOfWaypoints - 1).getTime();
 commandForExcedent.subtractTimeOffset(timeOffsetToSubtract);
 return maximumNumberOfWaypoints;
}
origin: us.ihmc/IHMCHumanoidBehaviors

HandTrajectoryCommand command = new HandTrajectoryCommand();
command.set(message);
controllerCommands.add(command);
origin: us.ihmc/DarpaRoboticsChallenge

RobotSide robotSide = command.getRobotSide();
FramePose desiredPose = new FramePose();
command.getLastTrajectoryPoint().getPoseIncludingFrame(desiredPose);
desiredHandPoses.put(robotSide, desiredPose);
DenseMatrix64F selectionMatrix = new DenseMatrix64F(command.getSelectionMatrix());
handSelectionMatrices.put(robotSide, selectionMatrix);
origin: us.ihmc/CommonWalkingControlModules

HandTrajectoryCommand handTrajectoryControllerCommand = new HandTrajectoryCommand(referenceFrame, userHandPoseSide.getEnumValue(), userHandPoseBaseForControl.getEnumValue());
trajectoryPoint.setAngularVelocity(new Vector3d());
handTrajectoryControllerCommand.addTrajectoryPoint(trajectoryPoint);
origin: us.ihmc/ihmc-humanoid-behaviors

message.getSe3Trajectory().getFrameInformation().setTrajectoryReferenceFrameId(MessageTools.toFrameId(chestFrame));
message.getSe3Trajectory().getFrameInformation().setDataReferenceFrameId(MessageTools.toFrameId(worldFrame));
HandTrajectoryCommand command = new HandTrajectoryCommand();
command.getSE3Trajectory().set(worldFrame, chestFrame, message.getSe3Trajectory());
controllerCommands.add(command);
origin: us.ihmc/IHMCHumanoidRobotics

@Override
public void set(WholeBodyTrajectoryCommand other)
{
 for (RobotSide robotSide : RobotSide.values)
 {
   handTrajectoryControllerCommands.get(robotSide).set(other.handTrajectoryControllerCommands.get(robotSide));
   armTrajectoryControllerCommands.get(robotSide).set(other.armTrajectoryControllerCommands.get(robotSide));
   footTrajectoryControllerCommands.get(robotSide).set(other.footTrajectoryControllerCommands.get(robotSide));
 }
 chestTrajectoryControllerCommand.set(other.chestTrajectoryControllerCommand);
 pelvisTrajectoryControllerCommand.set(other.pelvisTrajectoryControllerCommand);
}
origin: us.ihmc/CommonWalkingControlModules

public void handleHandTrajectoryCommands(List<HandTrajectoryCommand> commands)
{
 for (int i = 0; i < commands.size(); i++)
 {
   HandTrajectoryCommand command = commands.get(i);
   RobotSide robotSide = command.getRobotSide();
   handControlModules.get(robotSide).handleHandTrajectoryCommand(command);
 }
}
origin: us.ihmc/IHMCHumanoidRobotics

@Override
public void set(HandTrajectoryCommand other)
{
 super.set(other);
 setPropertiesOnly(other);
}
origin: us.ihmc/IHMCHumanoidRobotics

@Override
public void clear()
{
 for (RobotSide robotSide : RobotSide.values)
 {
   handTrajectoryControllerCommands.get(robotSide).clear();
   armTrajectoryControllerCommands.get(robotSide).clear();
   footTrajectoryControllerCommands.get(robotSide).clear();
 }
 chestTrajectoryControllerCommand.clear();
 pelvisTrajectoryControllerCommand.clear();
}
origin: us.ihmc/DarpaRoboticsChallenge

HandTrajectoryCommand command = new HandTrajectoryCommand();
command.set(message);
controllerCommands.add(command);
origin: us.ihmc/IHMCAvatarInterfaces

RobotSide robotSide = command.getRobotSide();
FramePose desiredPose = new FramePose();
command.getLastTrajectoryPoint().getPoseIncludingFrame(desiredPose);
desiredHandPoses.put(robotSide, desiredPose);
DenseMatrix64F selectionMatrix = new DenseMatrix64F(command.getSelectionMatrix());
handSelectionMatrices.put(robotSide, selectionMatrix);
origin: us.ihmc/IHMCHumanoidRobotics

@Override
public void set(WholeBodyTrajectoryMessage message)
{
 clear();
 for (RobotSide robotside : RobotSide.values)
 {
   HandTrajectoryMessage handTrajectoryMessage = message.getHandTrajectoryMessage(robotside);
   if (handTrajectoryMessage.getUniqueId() != Packet.INVALID_MESSAGE_ID)
    handTrajectoryControllerCommands.get(robotside).set(handTrajectoryMessage);
   ArmTrajectoryMessage armTrajectoryMessage = message.getArmTrajectoryMessage(robotside);
   if (armTrajectoryMessage.getUniqueId() != Packet.INVALID_MESSAGE_ID)
    armTrajectoryControllerCommands.get(robotside).set(armTrajectoryMessage);
   FootTrajectoryMessage footTrajectoryMessage = message.getFootTrajectoryMessage(robotside);
   if (footTrajectoryMessage.getUniqueId() != Packet.INVALID_MESSAGE_ID)
    footTrajectoryControllerCommands.get(robotside).set(footTrajectoryMessage);
 }
 ChestTrajectoryMessage chestTrajectoryMessage = message.getChestTrajectoryMessage();
 if (chestTrajectoryMessage.getUniqueId() != Packet.INVALID_MESSAGE_ID)
   chestTrajectoryControllerCommand.set(chestTrajectoryMessage);
 PelvisTrajectoryMessage pelvisTrajectoryMessage = message.getPelvisTrajectoryMessage();
 if (pelvisTrajectoryMessage.getUniqueId() != Packet.INVALID_MESSAGE_ID)
   pelvisTrajectoryControllerCommand.set(pelvisTrajectoryMessage);
}
us.ihmc.humanoidRobotics.communication.controllerAPI.commandHandTrajectoryCommand

Most used methods

  • <init>
  • getRobotSide
  • set
  • clear
  • getLastTrajectoryPoint
  • getSelectionMatrix
  • setPropertiesOnly
    Same as #set(HandTrajectoryCommand) but does not change the trajectory points.
  • addTimeOffset
  • addTrajectoryPoint
  • getBase
  • getCommandId
  • getExecutionMode
  • getCommandId,
  • getExecutionMode,
  • getNumberOfTrajectoryPoints,
  • getPreviousCommandId,
  • getSE3Trajectory,
  • getTrajectoryPoint,
  • subtractTimeOffset

Popular in Java

  • Reactive rest calls using spring rest template
  • scheduleAtFixedRate (ScheduledExecutorService)
  • getSharedPreferences (Context)
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • ObjectMapper (com.fasterxml.jackson.databind)
    ObjectMapper provides functionality for reading and writing JSON, either to and from basic POJOs (Pl
  • Window (java.awt)
    A Window object is a top-level window with no borders and no menubar. The default layout for a windo
  • IOException (java.io)
    Signals a general, I/O-related error. Error details may be specified when calling the constructor, a
  • Runnable (java.lang)
    Represents a command that can be executed. Often used to run code in a different Thread.
  • IOUtils (org.apache.commons.io)
    General IO stream manipulation utilities. This class provides static utility methods for input/outpu
  • LogFactory (org.apache.commons.logging)
    Factory for creating Log instances, with discovery and configuration features similar to that employ
  • Best plugins for Eclipse
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now