Skip to content

Update Haptic Indicator Vibrations

Craig McDonald requested to merge feature/vibrate into devel

Description

Added CoAP route /session/vibrate_freq to mainboard firmware, which expects a struct like VibrateSettingsFreq having frequency, amplitude, and duration parameters. This way we can control frequency in addition to the other two parameters.

Added a sandbox program called HapticIndicatorTest to easily adjust parameters and start/stop vibrations on the robot.

A couple of things to not about the "haptic indicator" as defined by the mainboard firmware that I was not clear on before making these changes:

  • sinusoidal torque commands are only sent to joint 3, instead of all 3 joints, which makes sense
  • the calculation of the signal to be sent to J3 actually includes multiplication by a term like (duration - time_elapsed) which scales down to zero linearly as time increases, i.e., the amplitude of the signal decays to zero linearly over the duration.

What to focus on

  • This can be tested with the mainboard firmware tagged "mainboard-vibration-api-test"
  • Use the program HapticIndicatorTest to change the frequency, amplitude, and duration of the vibration and send the command to the robot.
Edited by Craig McDonald

Merge request reports

Loading