Haptic Evaluation Kit Tutorial: Playing a Specific Haptic Effect

Haptic Evaluation Kit Tutorial: Playing a Specific Haptic Effect

Prerequisite: You have already calibrated the DRV2605 to your selected actuator!

DRV2605 Effect Table

DRV2605 Effect Table

Motor.cpp includes the functionality to play any of the 123 effects and 6 libraries that are stored on the DRV2605. As this is probably going to be the most commonly used function we’ve tried to keep it as simple as possible:

playFullHaptic( library , effect )

Where libraries 1 - 5 can be specified for ERMs or library 6 for LRAs, and any of the 123 effects can be selected.

The Haptic Effect Table is useful for looking up specific effects, or if you’ve found an effect to use whilst in the Engineering Mode you can use the True Haptic Menu Map to find the effect ID.

Engineering Mode's True Haptic Menu Map

Engineering Mode's True Haptic Menu Map

Remember you will need to have selected a motor and calibrated the DRV2605 it using the functionsselectMotor(); andautoCalibrate(); to use playFullHaptic();. If you selected an LRA (motorID = 3)then willtheplayFullHaptic(); ignore the value you enter for library and use library 6.

Playing An Effect Without Calibrating The DRV2605

It is also possible to play a haptic effect with your own values for the rated voltage, overdrive voltage, etc:

playFullHaptic( ratedVoltage , overdriveClamp , LRA , compensation , backEMF , feedback );

This is useful if you want to play an effect without calibrating the DRV2605, or are interested in manually fine-tuning how your motor is driven. See the DRV2605 Library resource for syntax and value ranges.

Note that the DRV2605.cpp version of the functionplayFullHaptic(); does not overwrite the stored values from the auto calibration. So to continue to use your own values you must either always call from DRV2605.cpp or use the simpler manuallymotor.playFullHaptic( library , effect ); edit the calibrations[ ] array (defined in line 14 of motor.cpp).

Contact Us

1.07 Canterbury Court
1-3 Brixton Road, London, SW9-6DE
[email protected]
+44 (0) 1932 252 482
(English / FR / DE / ES / IT)
+44 (0) 1932 325 353
PrecisionMicrodrives
@PMDri
Precision Microdrives
Mon. – Fri. 9:00 – 18:00 (BST / UTC)
* Charges vary depending on service provider and country