HEXR Docs
Developers / Getting started / Introduction

Getting Started

Install the HEXR SDK, trigger your first haptic event, and learn the core concepts — for Unity and Python.

Note

This is a starter documentation template with the standard structure of a developer docs site. Replace the code samples, package URLs and API names with your real SDK before publishing.

Introduction

HEXR is an untethered pneumatic haptic glove that adds realistic touch to VR and mixed-reality applications. The SDK gives you a small, event-driven API: your app reports contact and force events, and HEXR drives the soft actuators on the glove — with sub-20 ms response and natural, hand-tracked movement.

This guide takes you from an empty project to your first haptic pulse in a few minutes. If you prefer to read code, jump straight to the Quickstart.

Prerequisites

Tip

New to HEXR hardware? Pair and power on the glove first, then confirm it appears in the HEXR companion app before wiring up the SDK.

Installation

Pick your platform. In Unity, choose your runtime tutorial (OpenXR, Meta OVR or MRTK); for Python, install the library.

Each Unity integration ships as a complete tutorial project — the HEXR package plus a working demo scene. Clone the one for your runtime:

shell
# Example: the OpenXR tutorial
git clone https://github.com/MicrotubeTechnologies/HexR-developer-tutorial-XR.git

Clone the Python repo and install its dependencies:

shell
git clone https://github.com/MicrotubeTechnologies/HaptGlovePython.git
cd HaptGlovePython
pip install -r requirements.txt

Then run AddressDiscovery.py to find your glove's Bluetooth address and set it in ExampleHaptics.py.

Note

The Python control library talks to the glove over Bluetooth (BLE) using bleak. It's run from a clone, not yet published as a pip package — adding a pyproject.toml to the repo would enable pip install.

Quickstart

Connect to a glove and fire a short pulse when the user touches an object.

csharp
using Microtube.Hexr;

public class TouchExample : MonoBehaviour {
    HexrGlove glove;

    void Start() {
        // Grab the right-hand glove once it's connected
        glove = HexrManager.GetGlove(Hand.Right);
    }

    // Called from your interaction/collision logic
    void OnTouch(Finger finger) {
        // strength 0–1, duration in milliseconds
        glove.Pulse(finger, strength: 0.8f, duration: 40);
    }
}
python
import asyncio
from bleak import BleakClient
from Haptics import Haptics

DEVICE_ADDRESS = "EC:C9:FF:45:92:86"   # your glove (see AddressDiscovery.py)
CHAR_UUID      = "0000ff01-0000-1000-8000-00805f9b34fb"

async def main():
    haptics = Haptics("right")
    async with BleakClient(DEVICE_ADDRESS) as client:
        # Pressure on all fingers — intensity 0.1–1.0
        data = haptics.hexr_pressure_multiple(
            ["Thumb","Index","Middle","Ring","Pinky"],
            [True]*5, [0.8]*5, [1.0]*5)
        await client.write_gatt_char(CHAR_UUID, data)
        await asyncio.sleep(5)

asyncio.run(main())
Warning

Always check that a glove is connected before sending events — calls to a disconnected glove are ignored, but polling in a tight loop can flood the driver. Gate feedback behind your interaction callbacks.

Core concepts

Events, not frames

HEXR is driven by discrete events — a touch, a grasp, a release — rather than per-frame polling. Send an event when something happens in your scene and let the SDK schedule the actuation.

Actuators & fingers

Each glove exposes soft pneumatic actuators mapped to the fingers. You address feedback per finger, with a strength (0–1) and a duration.

ParameterTypeDescription
fingerFingerWhich finger to actuate (Thumb…Pinky)
strengthfloat 0–1Intensity of the pulse
durationint (ms)How long the pulse lasts

Hand-tracking

HEXR does not track your hand on its own — it relies on external hand-tracking, either from your headset (Meta Quest 2/3/3S, Pico 4, HoloLens) or a device like Leap Motion. HEXR adds the touch-feedback layer on top of that tracking.

Next

Ready to go deeper? Head to the Unity or Python integration guides for setup, or the API reference for the full surface.