Handshake is a Haptic Effects Library which uses HTML5's Vibrate API.
Play with the demo at http://o2labs.github.io/handshake-html5-vibrate-haptic-library/
Currently, it works on
- Firefox for Android
- Chrome (beta) for Android
- Firefox Mobile
- BlackBerry 10
Other browsers will come in time :-)
We encourage you to submit interesting and useful vibration patterns as pull requests.
The vibrate API works by defining how long the phone or tablet's vibration motor is on or off.
navigator.vibrate([200, 100, 500]);
means vibrate for 200ms, pause for 100ms, vibrate for 500ms.
Read our blog post about Handshake https://thelab.o2.com/2014/01/introducing-handshake-a-haptic-effects-library/