Configuration
There's no config file — the SDK is configured in code through a pluggable RingTransport. Choose the transport that matches how your app talks to the ring.
Transports
| Transport | Status | Notes |
|---|---|---|
MockTransport | Available | In-memory; tests and offline demos |
tauriTransport | Needs backend glue | Bridges to a Rust BLE backend over Tauri IPC |
| Web Bluetooth | Planned | navigator.bluetooth against the ratified service UUIDs |
Connecting
import { GesturaRing } from "@gestura/ring-sdk";
import { tauriTransport } from "@gestura/ring-sdk/tauri";
import { invoke } from "@tauri-apps/api/core";
import { listen } from "@tauri-apps/api/event";
const transport = tauriTransport(deviceId, { invoke, listen });
const ring = await GesturaRing.open({ transport });Event Names
The ring emits W3C UI-Events-style events: tap, doubletap, holdstart/holdend, swipeleft/swiperight, rotatecw/rotateccw, plus gesture (with a mapped action), sensorframe, battery, and ack. See the Gesture & Haptic Events guide for the full reference.
Tips
- Prefer
MockTransportin tests — it doesn't require real hardware - The device maintains one active BLE connection; reconnect logic belongs in your transport, not the SDK core
Troubleshooting
- Ring connects but no events fire → confirm your transport's
ring_subscribepassthrough is wired up - Connection drops under load → check BLE signal strength; the ring FIFO caps waveform sends at 1024 samples
FAQ
Can I run multiple ring instances in one app? Yes, each GesturaRing.open() call takes its own transport instance.