Skip to content

Haptic Objects Library

Craig McDonald requested to merge feature/haptic-objects into devel

Description

Wrote a library of haptic primitives, all derived from the same abstract haptic object class, that are all demonstrated in the console program HapticObjectTest. This program is meant to be easy to use for all developers, allowing them to get a sense of how the different haptic objects feel.

Some of the more complicated objects have their own additional test programs: HapticFieldTest and HapticMovingWallTest. These demonstrate the additional functions of those classes.

The movement of the haptic wall is set by a trajectory, and I made a new type of trajectory based on the minimum jerk called MinJerkTrajectory. This gives a bell shaped velocity profile, as opposed to the trapezoidal velocity profile you get from the linear trajectory. Now we have two options for the trajectory controlling the wall movement, and the two trajectories now derive from a common Trajectory base class.

Rendering a haptic mass requires an estimate of the acceleration. Brought in from burt-sharp-extensions the RobotAccelerationEstimator class, which gives you access to estimates of the robot joint acceleration and the robot endpoint cartesian acceleration (just using finite difference of the velocities and then a low-pass filter.) There is a RobotAccelerationEstimatorTest in the sandbox as well for validating the acceleration estimate and playing with the filter cutoff frequency. If we decide we want to actually use this haptic mass, or other things that depend on acceleration, it will probably be easier to move this acceleration estimate into the robot controller in the future.

What to focus on

  • The HapticObject code is at the core of everything, and it's functionality is most important.
  • Test all the objects and their different options in the HapticObjectTest
  • Verify that the other test programs are functioning properly (HapticFieldTest, HapticMovingWallTest, RobotAccelerationEstimatorTest)
Edited by Craig McDonald

Merge request reports