Class Follower

java.lang.Object
edu.tufts.hrilab.ava.Follower

public class Follower extends Object
Helper class to "track" target obstacle and calculate velocities for robot following behavior.
  • Constructor Details

    • Follower

      public Follower()
  • Method Details

    • reset

      public void reset()
      Clear the last target.
    • getObstacleToFollow

      public Obstacle getObstacleToFollow(org.apache.commons.lang3.tuple.Pair<javax.vecmath.Point3d,javax.vecmath.Quat4d> currPose, List<Obstacle> obstacles)
      Select the obstacle to follow.
      Returns:
    • calculateFollowVelocity

      public float[] calculateFollowVelocity(org.apache.commons.lang3.tuple.Pair<javax.vecmath.Point3d,javax.vecmath.Quat4d> currPose, Obstacle target)
      Use the robot pose and target obstacle location to calculate translation and rotation velocities.
      Parameters:
      currPose - - current robot pose
      target - - target obstacle to move towards
      Returns:
      {transVelocity (m/s), rotVelocity(rad/s)}